From e1850b3c4e4efec5d8c4a3b9423ba0f3a8d65ece Mon Sep 17 00:00:00 2001 From: Mukunda Modell Date: Mon, 12 Jun 2017 11:00:39 -0500 Subject: [PATCH] Allow dashboard panels to be found by monogram Summary: Just add the monogram to the datasource's `name` field so that it will match when typing Wnn in the typeahead field. Test Plan: Tested locally on my dev phab. Try searching for a panel by monogram in the 'Add existing panel' dialog on the 'arrange workboard' interface. Previously: typing W123 showed no results. After this change: typing W123 finds the panel W123 Reviewers: chad, epriestley, #blessed_reviewers Reviewed By: epriestley, #blessed_reviewers Subscribers: Korvin Differential Revision: https://secure.phabricator.com/D18121 --- .../typeahead/PhabricatorDashboardPanelDatasource.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/applications/dashboard/typeahead/PhabricatorDashboardPanelDatasource.php b/src/applications/dashboard/typeahead/PhabricatorDashboardPanelDatasource.php index 958883d34e..d534d32adc 100644 --- a/src/applications/dashboard/typeahead/PhabricatorDashboardPanelDatasource.php +++ b/src/applications/dashboard/typeahead/PhabricatorDashboardPanelDatasource.php @@ -42,8 +42,7 @@ final class PhabricatorDashboardPanelDatasource $properties = $panel->getProperties(); $result = id(new PhabricatorTypeaheadResult()) - ->setName($panel->getName()) - ->setDisplayName($monogram.' '.$panel->getName()) + ->setName($monogram.' '.$panel->getName()) ->setPHID($id) ->setIcon($impl->getIcon()) ->addAttribute($type_text);