admin: Make menu items active on rights pages
This commit is contained in:
parent
3c237819c3
commit
bd35705f58
@ -79,23 +79,23 @@ const indextpl = `<!DOCTYPE html>
|
||||
|
||||
<div class="collapse navbar-collapse" id="adminMenu">
|
||||
<ul class="navbar-nav mr-auto">
|
||||
<li class="nav-item"><a class="nav-link" href="teams">Équipes</a></li>
|
||||
<li class="nav-item"><a class="nav-link" href="pki">PKI</a></li>
|
||||
<li class="nav-item"><a class="nav-link" href="themes">Thèmes</a></li>
|
||||
<li class="nav-item"><a class="nav-link" href="exercices">Exercices</a></li>
|
||||
<li class="nav-item"><a class="nav-link" href="public/0">Public</a></li>
|
||||
<li class="nav-item"><a class="nav-link" href="events">Événements</a></li>
|
||||
<li class="nav-item"><a class="nav-link" href="claims" ng-controller="ClaimsTinyListController">
|
||||
<li class="nav-item" ng-class="{'active': $location.path().startsWith('/teams')}"><a class="nav-link" href="teams">Équipes</a></li>
|
||||
<li class="nav-item" ng-class="{'active': $location.path().startsWith('/pki')}"><a class="nav-link" href="pki">PKI</a></li>
|
||||
<li class="nav-item" ng-class="{'active': $location.path().startsWith('/themes')}"><a class="nav-link" href="themes">Thèmes</a></li>
|
||||
<li class="nav-item" ng-class="{'active': $location.path().startsWith('/exercices')}"><a class="nav-link" href="exercices">Exercices</a></li>
|
||||
<li class="nav-item" ng-class="{'active': $location.path().startsWith('/public')}"><a class="nav-link" href="public/0">Public</a></li>
|
||||
<li class="nav-item" ng-class="{'active': $location.path().startsWith('/events')}"><a class="nav-link" href="events">Événements</a></li>
|
||||
<li class="nav-item" ng-class="{'active': $location.path().startsWith('/claims')}"><a class="nav-link" href="claims" ng-controller="ClaimsTinyListController">
|
||||
Tâches
|
||||
<span class="badge badge-{{ "{{ priorities[myClaimsMaxLevel] }}" }}" ng-show="myClaims">{{ "{{ myClaims }}" }}</span>
|
||||
<span class="badge badge-{{ "{{ priorities[newClaimsMaxLevel] }}" }}" ng-show="newClaims">{{ "{{ newClaims }}" }}</span>
|
||||
</a></li>
|
||||
<li class="nav-item">
|
||||
<li class="nav-item" ng-class="{'active': $location.path().startsWith('/sync')}">
|
||||
<a class="nav-link" href="sync" ng-show="settings.wip">
|
||||
Synchronisation
|
||||
</a>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
<li class="nav-item" ng-class="{'active': $location.path().startsWith('/settings')}">
|
||||
<a class="nav-link" href="settings">
|
||||
Paramètres
|
||||
</a>
|
||||
|
@ -450,7 +450,8 @@ angular.module("FICApp")
|
||||
};
|
||||
})
|
||||
|
||||
.run(function($rootScope, $http, $interval, Settings) {
|
||||
.run(function($rootScope, $http, $interval, Settings, $location) {
|
||||
$rootScope.$location = $location;
|
||||
function refresh() {
|
||||
$http.get("api/settings.json").then(function(response) {
|
||||
response.data.start = new Date(response.data.start);
|
||||
|
Loading…
Reference in New Issue
Block a user