Project

General

Profile

Actions

Bug #6640

closed

[Workbench] Ensure projects menu consistently shows all "my projects"

Added by Brett Smith almost 9 years ago. Updated over 8 years ago.

Status:
Resolved
Priority:
Normal
Assigned To:
Category:
Workbench
Target version:
Story points:
0.5

Description

Background

I (Brett) have attached two screenshots of the projects menu pulldown in two tabs opened back-to-back in the same session. They don't show the same list of projects. Presumably this has something to do with me being an admin, and there's some explicit or implicit limit on the number of projects Workbench renders.

At the very least, the menu should always render all of my own projects, and it should always render the same set of projects. We can hash out how we want to deal with large project lists generally.

I (now Tom) am guessing the "unpredictable subset of projects shown" bug means Workbench is fetching only one page of projects from the API, and without specifying a predictable order. But the real problem here is that we are trying to show the entire set of readable projects in a dropdown in the first place. Rather than try to make the bogus UI work better, we're going to change the UI.

Implementation

Instead of trying to show a large number of projects in a dropdown the "projects" drop-down should reduce to:
  • a "Search all projects (N)" item, where N is the total number of projects readable by the current user. This opens the "search projects" dialog, much like the existing "move to project..." feature does but with a "Show" action button instead of "Move".
  • a "Browse public projects" item. Just like we have now, but formatted as a menu item instead of a button.
  • a "Create a new project" item. Just like we have now, but formatted as a menu item instead of a button.
  • a heading "My projects"
  • the current user's "Home" project
  • the hierarchy below it (just like we have now)
  • no list of "projects shared with me"

Similarly, the "project" dropdown in the "search" dialog should lose the "projects shared with me" part: only "All projects" and the "My projects" hierarchy will remain.

This will leave us without a hierarchical view of "projects shared with me", which is probably a good thing. The hierarchy of shared projects looks different depending on (for example) whether the common parent of two shared projects is visible, so this view is inherently unpredictable.

The current API doesn't offer an efficient way to get a list of the current user's project hierarchy. For now, we'll just do it the way we do now (i.e., do multiple API calls to get all projects, arrange them into trees, and just show the tree whose root is current_user.uuid) in order to improve the UI. Adding a more efficient API might be done concurrently or in the future, but is not a dependency of this UI change in any case.

Meanwhile this story does require a new test case (and perhaps some fixtures) that specifically confirms the original bug here is fixed: i.e., if a user has more than one page worth of projects, possibly even in the "My projects" hierarchy, the same subset gets loaded every time (presumably this subset will be the full set).


Files

Brett projects 1.png (15.5 KB) Brett projects 1.png Brett Smith, 07/16/2015 11:37 AM
Brett projects 2.png (12.7 KB) Brett projects 2.png Brett Smith, 07/16/2015 11:37 AM
project_menu.png (53 KB) project_menu.png Manoj Malipeddu, 08/10/2015 06:41 PM
alternate_project_menu.png (52.2 KB) alternate_project_menu.png Manoj Malipeddu, 08/10/2015 07:28 PM
project_menu.png (56.3 KB) project_menu.png Manoj Malipeddu, 08/11/2015 01:49 PM

Subtasks 3 (0 open3 closed)

Task #6898: Review 6640-projects-menu-incompleteResolvedManoj Malipeddu08/05/2015Actions
Task #6944: Mock up specified UIResolvedManoj Malipeddu08/10/2015Actions
Task #6945: Review UI design mocksResolvedManoj Malipeddu08/10/2015Actions
Actions

Also available in: Atom PDF