Page MenuHomePhabricator

Add ability to query dashboard panels by paneltype
ClosedPublic

Authored by chad on Feb 17 2015, 2:55 AM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Nov 10, 8:06 AM
Unknown Object (File)
Sun, Nov 10, 8:06 AM
Unknown Object (File)
Fri, Nov 8, 10:16 PM
Unknown Object (File)
Oct 18 2024, 2:08 PM
Unknown Object (File)
Oct 15 2024, 7:03 AM
Unknown Object (File)
Oct 13 2024, 10:14 AM
Unknown Object (File)
Oct 6 2024, 2:34 PM
Unknown Object (File)
Sep 26 2024, 10:06 PM
Subscribers

Details

Summary

Pretty basic, but you can now search panels by type (query, text, tab).

Test Plan

Searched for a few different types of panels, results look correct

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

chad retitled this revision from to Add ability to query dashboard panels by paneltype.
chad updated this object.
chad edited the test plan for this revision. (Show Details)
chad added reviewers: epriestley, btrahan.
epriestley edited edge metadata.
epriestley added inline comments.
src/applications/dashboard/query/PhabricatorDashboardPanelSearchEngine.php
76–78

This should be auto-generated, so new panel types show up automatically as we (or third parties) add them.

You can do something like this, I think:

$panel_types = PhabricatorDashboardPanelType::getAllPanelTypes();
$panel_types = mpull($panel_types, 'getPanelTypeName', 'getPanelTypeKey');
asort($panel_types);
$panel_types = array(
  '' => pht('(All Types)'),
+ $panel_types;

And then:

->setOptions($panel_types)
This revision now requires changes to proceed.Feb 17 2015, 1:04 PM
chad edited edge metadata.
  • Update per comments
epriestley edited edge metadata.
This revision is now accepted and ready to land.Feb 18 2015, 6:49 PM
This revision was automatically updated to reflect the committed changes.