Page MenuHomePhabricator

When picking a default menu item to render, don't pick disabled items
ClosedPublic

Authored by epriestley on Mar 31 2019, 9:13 PM.
Tags
None
Referenced Files
F14062306: D20359.id48578.diff
Mon, Nov 18, 11:28 AM
F14058411: D20359.diff
Sun, Nov 17, 11:48 AM
F13992454: D20359.id48610.diff
Tue, Oct 22, 4:47 PM
F13989146: D20359.id48579.diff
Mon, Oct 21, 6:23 PM
F13986755: D20359.id48578.diff
Mon, Oct 21, 5:17 AM
F13985908: D20359.diff
Sun, Oct 20, 11:33 PM
Unknown Object (File)
Oct 10 2024, 1:53 AM
Unknown Object (File)
Oct 8 2024, 4:50 AM
Subscribers
None

Details

Summary

Depends on D20358. Fixes T12871. After refactoring, we can now tell when a "storage" menu item generated only disabled "display" menu items, and not pick any of them as the default rendering.

This means that if you're looking at a portal/menu with several dashboards, but can't see some at the top, you'll get the first one you can see.

Also clean up a lot of minor issues with less-common states.

Test Plan
  • Created a portal with two private dashboards and a public dashboard.
  • Viewed it as another user, saw the default view show the dashboard I can actually see.
  • Minor fix: Disabled and enabled the hard-coded "Home" item, now worked cleanly with the right menu state.
  • Minor fix: added a motivator panel.

Diff Detail

Repository
rP Phabricator
Branch
portal9
Lint
Lint Passed
Unit
Tests Passed
Build Status
Buildable 22452
Build 30733: Run Core Tests
Build 30732: arc lint + arc unit

Event Timeline

src/applications/search/engine/PhabricatorProfileMenuItemViewList.php
96–101

This is the actual fix to T12871 after shuffling a thousand lines of code around.

This revision is now accepted and ready to land.Apr 2 2019, 9:01 PM
This revision was automatically updated to reflect the committed changes.