Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
Findeton committed Sep 8, 2023
1 parent d608204 commit c7a7f43
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
8 changes: 7 additions & 1 deletion avAdmin/admin-controller/admin-controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,13 @@ angular
{name: 'questions', icon: 'question-circle'},
{name: 'auth', icon: 'unlock'},
{name: 'censusConfig', icon: 'newspaper-o'},
{name: 'census', icon: 'users'},
{
name: 'census',
icon: 'users',
permsFunc: function() {
return scope.hasPerms(["view-census", "edit"]);
}
},
//{name: 'successAction', icon: 'star-o'},
{name: 'adminFields', icon: 'user'},
//{name: 'tally', icon: 'pie-chart'},
Expand Down
4 changes: 2 additions & 2 deletions avAdmin/admin-sidebar-directive/admin-sidebar-directive.html
Original file line number Diff line number Diff line change
Expand Up @@ -69,8 +69,8 @@

<div
class="nav nav-pills nav-stacked"
ng-repeat="l in sidebarlinks"
ng-if="'adminFields' !== l.name || !!hasAdminFields"
ng-repeat="l in sidebarlinks"
ng-if="('adminFields' !== l.name || !!hasAdminFields) && (!l.permsFunc || l.permsFunc())"
>
<li
role="presentation"
Expand Down

0 comments on commit c7a7f43

Please sign in to comment.