Only show "Add New Project" subnav if user has permissions to do so
This commit is contained in:
parent
0dd350112c
commit
8539238566
@ -6,7 +6,7 @@
|
|||||||
"Projects",
|
"Projects",
|
||||||
href=url_for("workspaces.workspace_projects", workspace_id=workspace.id),
|
href=url_for("workspaces.workspace_projects", workspace_id=workspace.id),
|
||||||
active=request.url_rule.rule.startswith('/workspaces/<workspace_id>/projects'),
|
active=request.url_rule.rule.startswith('/workspaces/<workspace_id>/projects'),
|
||||||
subnav=[
|
subnav=None if not user_can(permissions.ADD_APPLICATION_IN_WORKSPACE) else [
|
||||||
{
|
{
|
||||||
"label": "Add New Project",
|
"label": "Add New Project",
|
||||||
"href": url_for('workspaces.new_project', workspace_id=workspace.id),
|
"href": url_for('workspaces.new_project', workspace_id=workspace.id),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user