2018-01-17 00:21:32 +00:00
|
|
|
<h2>
|
|
|
|
Tâches et réclammations ({{ claims.length }})
|
2018-11-18 20:34:08 +00:00
|
|
|
<button type="button" ng-click="show('new')" class="float-right btn btn-sm btn-primary"><span class="glyphicon glyphicon-plus" aria-hidden="true"></span> Ajouter une tâche</button>
|
2018-01-17 00:21:32 +00:00
|
|
|
<small style="height: 0px;">
|
2018-02-04 21:04:54 +00:00
|
|
|
<div class="btn-group btn-group-toggle float-right mr-2">
|
2020-01-25 17:44:26 +00:00
|
|
|
<label class="btn btn-sm btn-secondary" ng-class="{active: showOnlyNew, 'btn-warning': showOnlyNew}">
|
|
|
|
<input type="checkbox" ng-model="showOnlyNew"> Nouvelles
|
|
|
|
</label>
|
2018-02-04 21:04:54 +00:00
|
|
|
<label class="btn btn-sm btn-secondary" ng-class="{active: showOnlyUnassigned, 'btn-warning': showOnlyUnassigned}">
|
|
|
|
<input type="checkbox" ng-model="showOnlyUnassigned"> Non assignée
|
|
|
|
</label>
|
|
|
|
<label class="btn btn-sm btn-secondary" ng-class="{active: showOnlyMines, 'btn-warning': showOnlyMines}" ng-show="whoami">
|
|
|
|
<input type="checkbox" ng-model="showOnlyMines"> Que mes tâches
|
|
|
|
</label>
|
|
|
|
<label class="btn btn-sm btn-secondary" ng-class="{active: showClosed, 'btn-warning': showClosed}">
|
|
|
|
<input type="checkbox" ng-model="showClosed"> Tâches closes
|
|
|
|
</label>
|
|
|
|
</div>
|
2018-01-17 00:21:32 +00:00
|
|
|
</small>
|
|
|
|
</h2>
|
|
|
|
|
2018-12-04 02:15:35 +00:00
|
|
|
<p><input type="search" class="form-control form-control-sm" placeholder="Search" ng-model="query" autofocus></p>
|
2018-01-17 00:21:32 +00:00
|
|
|
<table class="table table-hover table-bordered table-striped table-sm">
|
|
|
|
<thead class="thead-dark">
|
|
|
|
<tr>
|
|
|
|
<th ng-repeat="field in fields" ng-click="chOrder(field)">
|
|
|
|
{{ field }}
|
|
|
|
</th>
|
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
<tbody>
|
2020-01-25 17:44:26 +00:00
|
|
|
<tr ng-repeat="claim in claims | filter: query | orderBy:order" ng-click="show(claim.id)" ng-class="{'table-info': claim.priority == 'medium', 'table-warning': claim.priority == 'high', 'table-danger': claim.priority == 'critical'}" ng-if="((showClosed && (claim.state == 'closed' || claim.state == 'invalid')) || (!showClosed && (claim.state != 'closed' && claim.state != 'invalid'))) && (!showOnlyNew || claim.state == 'new') && (!showOnlyMines || claim.id_assignee == whoami) && (!showOnlyUnassigned || !claim.id_assignee)">
|
2018-01-17 00:21:32 +00:00
|
|
|
<td ng-repeat="field in fields">
|
2020-01-24 17:24:20 +00:00
|
|
|
<span ng-if="field != 'id_assignee' && field != 'id_team' && field != 'last_update'">
|
2018-02-04 21:04:54 +00:00
|
|
|
{{ claim[field] }}
|
|
|
|
</span>
|
|
|
|
<span ng-if="field == 'id_assignee'">
|
|
|
|
<span ng-repeat="assignee in assignees" ng-if="assignee.id == claim.id_assignee">
|
|
|
|
{{ assignee.name }}
|
|
|
|
</span>
|
|
|
|
</span>
|
2020-01-24 17:24:20 +00:00
|
|
|
<span ng-if="field == 'last_update'">
|
|
|
|
<span ng-controller="ClaimLastUpdateController" ng-init="init(claim)">
|
|
|
|
{{ last_update }}
|
|
|
|
</span>
|
|
|
|
</span>
|
2018-02-04 21:04:54 +00:00
|
|
|
<span ng-if="field == 'id_team'">
|
2020-01-20 08:24:24 +00:00
|
|
|
<a ng-href="teams/{{ claim.id_team }}">{{ teams[claim.id_team].name }}</a>
|
2018-02-04 21:04:54 +00:00
|
|
|
</span>
|
2018-01-17 00:21:32 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
</tbody>
|
|
|
|
</table>
|
|
|
|
|
|
|
|
<hr>
|
|
|
|
|
|
|
|
<div ng-controller="AssigneesListController">
|
|
|
|
<h2>
|
|
|
|
Assignables à
|
2018-11-18 20:34:08 +00:00
|
|
|
<button type="button" ng-click="newAssignee()" class="float-right btn btn-sm btn-primary"><span class="glyphicon glyphicon-plus" aria-hidden="true"></span> Ajouter une personne</button>
|
2018-01-17 00:21:32 +00:00
|
|
|
</h2>
|
|
|
|
<table class="table table-hover table-bordered table-striped table-sm">
|
|
|
|
<thead class="thead-dark">
|
|
|
|
<tr>
|
|
|
|
<th>ID</th>
|
|
|
|
<th>Nom</th>
|
|
|
|
<th></th>
|
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
<tbody>
|
2020-01-20 14:57:26 +00:00
|
|
|
<tr ng-repeat="a in assignees" ng-click="edit(a)" ng-if="a.id !== 0">
|
2018-01-17 00:21:32 +00:00
|
|
|
<td>
|
|
|
|
{{ a.id }}
|
|
|
|
</td>
|
|
|
|
<td>
|
|
|
|
<span ng-if="a.id && !a.edit">{{ a.name }}</span>
|
|
|
|
<input type="text" class="form-control form-control-sm" ng-model="a.name" ng-if="!a.id || a.edit">
|
|
|
|
</td>
|
|
|
|
<td style="width: 10%;">
|
2018-11-18 20:34:08 +00:00
|
|
|
<button type="button" class="btn btn-sm btn-info" ng-if="a.id" ng-click="setMyAId(a.id)" ng-class="{'disabled': whoami == a.id}"><span class="glyphicon glyphicon-user"></span></button>
|
|
|
|
<button type="button" class="btn btn-sm btn-danger" ng-if="a.id && !a.edit" ng-click="removeAssignee(a)"><span class="glyphicon glyphicon-remove"></span></button>
|
|
|
|
<button type="button" class="btn btn-sm btn-success" ng-if="!a.id || a.edit" ng-click="updateAssignee(a)"><span class="glyphicon glyphicon-ok"></span></button>
|
2018-01-17 00:21:32 +00:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
</tbody>
|
|
|
|
</table>
|
|
|
|
</div>
|