View Issue Details

IDProjectCategoryView StatusLast Update
0025133mantisbtuipublic2019-03-16 20:20
Reportercproensa Assigned Tocproensa  
PrioritynormalSeverityminorReproducibilityhave not tried
Status closedResolutionfixed 
Product Version2.19.0 
Target Version2.20.0Fixed in Version2.20.0 
Summary0025133: Project selection is shown even if the user has no accesible projects

Currently, the project selector is hidden if the user has only one accessible project.
However, if the user has no accessible projects, the project list is shown only containing "all projects"

For consistency, in that scenario, the project list shouldn't be displayed.

TagsNo tags attached.


related to 0007956 closedcproensa Disable project selection for users with only one project 


There are no notes attached to this issue.

Related Changesets

MantisBT: master 8c704951

2018-12-31 05:53


Committer: dregad

Details Diff
Rewrite hide project list and default project check

Previously, when a user only has one project, some things happens:
- The project selector was hidden, as it is not useful without more
- A check is performed where if current project is ALL_PROJECTS, then
current and default project are updated to the only available project.

To fix issues with that implementation, the logic has been separated:
- Helper function to check if the user has more than one project. It's
used in layout_api to decide if the project selector must be shown.
- Helper function to check if the user has ALL_PROJECTS as
current/default project when only one is available. In that case,
update current and modify default in user preferences.

Fixes: 0025110, 0025133
Affected Issues
0025110, 0025133
mod - core/current_user_api.php Diff File
mod - core/layout_api.php Diff File
mod - core/user_api.php Diff File