Fixed permissions in list views.
This commit is contained in:
parent
4ee2b85b76
commit
071b0a76be
@ -69,7 +69,7 @@
|
||||
<div ui-tree="treeOptions" class="col-sm-6">
|
||||
<ol ui-tree-nodes="" ng-model="speakers">
|
||||
<li ng-repeat="speaker in speakers | filter: {begin_time: null}" ui-tree-node>
|
||||
<i ui-tree-handle="" class="fa fa-arrows-v"></i>
|
||||
<i os-perms="agenda.can_manage" ui-tree-handle="" class="fa fa-arrows-v"></i>
|
||||
{{ $index + 1 }}.
|
||||
{{ speaker.user.get_full_name() }}
|
||||
<button os-perms="agenda.can_manage" ng-click="removeSpeaker(speaker.id)"
|
||||
|
@ -31,8 +31,8 @@
|
||||
<div class="col-sm-6">
|
||||
<form class="form-inline">
|
||||
<!-- delete mode -->
|
||||
<button os-perms-lite="agenda.can_manage" class="btn btn-default"
|
||||
ng-click="isDeleteMode = !isDeleteMode; uncheckAll()">
|
||||
<button os-perms="agenda.can_manage" class="btn btn-default"
|
||||
ng-click="$parent.isDeleteMode = !$parent.isDeleteMode; uncheckAll()">
|
||||
<i class="fa fa-check-square-o"></i>
|
||||
<translate>Select ...</translate>
|
||||
</button>
|
||||
@ -104,13 +104,13 @@
|
||||
<!-- projector column -->
|
||||
<th ng-show="!isDeleteMode" os-perms="core.can_manage_projector" class="minimum"></th>
|
||||
<!-- delete selection column -->
|
||||
<th ng-show="isDeleteMode" os-perms-lite="agenda.can_manage" class="minimum deleteColumn"
|
||||
<th ng-show="isDeleteMode" os-perms="agenda.can_manage" class="minimum deleteColumn"
|
||||
ng-click="$event.stopPropagation();">
|
||||
<input type="checkbox" ng-model="selectedAll" ng-change="checkAll()">
|
||||
<input type="checkbox" ng-model="$parent.selectedAll" ng-change="checkAll()">
|
||||
<!-- agenda item column -->
|
||||
<th>
|
||||
<translate>Agenda item</translate>
|
||||
<th os-perms="agenda.can_manage">
|
||||
<th os-perms="agenda.can_see_hidden_items">
|
||||
<translate>Duration</translate>
|
||||
<th class="minimum">
|
||||
<translate>Done</translate>
|
||||
@ -153,13 +153,13 @@
|
||||
ng-bootbox-confirm-action="deleteRelatedItem(item)" translate>Delete</a>
|
||||
</span>
|
||||
</div>
|
||||
<td ng-if="!item.quickEdit" class="optional">
|
||||
<td ng-show="!item.quickEdit" os-perms="agenda.can_see_hidden_items" class="optional">
|
||||
{{ item.duration }}
|
||||
<span ng-if="item.duration" translate-comment="'h' means time in hours" translate>h</span>
|
||||
<td ng-if="!item.quickEdit">
|
||||
<input type="checkbox" ng-model="item.closed" ng-change="save(item.id);">
|
||||
<!-- quickEdit columns -->
|
||||
<td ng-if="item.quickEdit" os-perms-lite="agenda.can_manage" colspan="3">
|
||||
<td ng-if="$parent.item.quickEdit" os-perms="agenda.can_manage" colspan="3">
|
||||
<form ng-submit="save(item)">
|
||||
<h4>{{ item.getTitle() }} <span class="text-muted">– QuickEdit</span></h4>
|
||||
<alert ng-show="alert.show" type="{{ alert.type }}" ng-click="alert={}" close="alert={}">
|
||||
|
@ -23,8 +23,8 @@
|
||||
<div class="col-sm-6">
|
||||
<form class="form-inline">
|
||||
<!-- delete mode -->
|
||||
<button os-perms-lite="assignments.can_manage" class="btn btn-default"
|
||||
ng-click="isDeleteMode = !isDeleteMode; uncheckAll()">
|
||||
<button os-perms="assignments.can_manage" class="btn btn-default"
|
||||
ng-click="$parent.isDeleteMode = !$parent.isDeleteMode; uncheckAll()">
|
||||
<i class="fa fa-check-square-o"></i>
|
||||
<translate>Select ...</translate>
|
||||
</button>
|
||||
@ -78,8 +78,8 @@
|
||||
<!-- projector column -->
|
||||
<th ng-show="!isDeleteMode" os-perms="core.can_manage_projector" class="minimum">
|
||||
<!-- delete selection column -->
|
||||
<th ng-show="isDeleteMode" os-perms-lite="assignments.can_manage" class="minimum deleteColumn">
|
||||
<input type="checkbox" ng-model="selectedAll" ng-change="checkAll()">
|
||||
<th ng-show="isDeleteMode" os-perms="assignments.can_manage" class="minimum deleteColumn">
|
||||
<input type="checkbox" ng-model="$parent.selectedAll" ng-change="checkAll()">
|
||||
<th ng-click="toggleSort('title')" class="sortable">
|
||||
<translate>Title</translate>
|
||||
<i class="pull-right fa" ng-show="sortColumn === 'title' && header.sortable != false"
|
||||
@ -101,7 +101,7 @@
|
||||
class="animate-item"
|
||||
ng-class="{ 'activeline': assignment.isProjected(), 'selected': assignment.selected }">
|
||||
<!-- projector column -->
|
||||
<td ng-show="!isDeleteMode" os-perms-lite="core.can_manage_projector">
|
||||
<td ng-show="!isDeleteMode" os-perms="core.can_manage_projector">
|
||||
<a class="btn btn-default btn-sm"
|
||||
ng-class="{ 'btn-primary': assignment.isProjected() }"
|
||||
ng-click="assignment.project()"
|
||||
|
@ -56,7 +56,7 @@
|
||||
</div>
|
||||
|
||||
<!-- countdowns -->
|
||||
<div class="section" os-perms-lite="core.can_manage_projector">
|
||||
<div class="section" os-perms="core.can_manage_projector">
|
||||
<a href="#" ng-click="isCountdowns = !isCountdowns">
|
||||
<i class="fa toggle-icon" ng-class="isCountdowns ? 'fa-angle-up' : 'fa-angle-down'"></i>
|
||||
<h4 translate>Countdowns</h4>
|
||||
|
@ -30,8 +30,8 @@
|
||||
<div class="row">
|
||||
<div class="col-sm-6">
|
||||
<!-- delete mode -->
|
||||
<button os-perms-lite="motions.can_manage" class="btn btn-default"
|
||||
ng-click="isDeleteMode = !isDeleteMode; uncheckAll()">
|
||||
<button os-perms="motions.can_manage" class="btn btn-default"
|
||||
ng-click="$parent.isDeleteMode = !$parent.isDeleteMode; uncheckAll()">
|
||||
<i class="fa fa-check-square-o"></i>
|
||||
<translate>Select ...</translate>
|
||||
</button>
|
||||
@ -82,10 +82,10 @@
|
||||
<thead>
|
||||
<tr>
|
||||
<!-- projector column -->
|
||||
<th ng-show="!isDeleteMode" os-perms="core.can_manage_projector" class="firstColumn">
|
||||
<th ng-show="!$parent.isDeleteMode" os-perms="core.can_manage_projector" class="firstColumn">
|
||||
<!-- delete selection column -->
|
||||
<th ng-show="isDeleteMode" os-perms-lite="motions.can_manage" class="firstColumn deleteColumn">
|
||||
<input type="checkbox" ng-model="selectedAll" ng-change="checkAll()">
|
||||
<th ng-show="$parent.isDeleteMode" os-perms="motions.can_manage" class="firstColumn deleteColumn">
|
||||
<input type="checkbox" ng-model="$parent.selectedAll" ng-change="checkAll()">
|
||||
<th ng-click="toggleSort('identifier')" class="sortable minimum">
|
||||
<translate>Identifier</translate>
|
||||
<i class="pull-right fa" ng-show="sortColumn === 'identifier' && header.sortable != false"
|
||||
@ -117,7 +117,7 @@
|
||||
class="animate-item"
|
||||
ng-class="{ 'activeline': motion.isProjected(), 'selected': motion.selected }">
|
||||
<!-- projector column -->
|
||||
<td ng-show="!isDeleteMode" os-perms-lite="core.can_manage_projector">
|
||||
<td ng-show="!isDeleteMode" os-perms="core.can_manage_projector">
|
||||
<a class="btn btn-default btn-sm"
|
||||
ng-class="{ 'btn-primary': motion.isProjected() }"
|
||||
ng-click="motion.project()"
|
||||
|
@ -40,8 +40,8 @@
|
||||
<div class="row">
|
||||
<div class="col-sm-6">
|
||||
<!-- delete mode -->
|
||||
<button os-perms-lite="users.can_manage" class="btn btn-default"
|
||||
ng-click="isDeleteMode = !isDeleteMode; uncheckAll()">
|
||||
<button os-perms="users.can_manage" class="btn btn-default"
|
||||
ng-click="$parent.isDeleteMode = !$parent.isDeleteMode; uncheckAll()">
|
||||
<i class="fa fa-check-square-o"></i>
|
||||
<translate>Select ...</translate>
|
||||
</button>
|
||||
@ -92,8 +92,8 @@
|
||||
<!-- projector column -->
|
||||
<th ng-show="!isDeleteMode" os-perms="core.can_manage_projector" class="firstColumn">
|
||||
<!-- delete selection column -->
|
||||
<th ng-show="isDeleteMode" os-perms-lite="users.can_manage" class="firstColumn deleteColumn">
|
||||
<input type="checkbox" ng-model="selectedAll" ng-change="checkAll()">
|
||||
<th ng-show="isDeleteMode" os-perms="users.can_manage" class="firstColumn deleteColumn">
|
||||
<input type="checkbox" ng-model="$parent.selectedAll" ng-change="checkAll()">
|
||||
<th ng-click="toggleSort('first_name')" class="sortable">
|
||||
<translate>Name</translate>
|
||||
<!-- TODO: sort by first OR last name -->
|
||||
@ -148,6 +148,10 @@
|
||||
<div ng-repeat="group in user.groups">
|
||||
{{ (groups | filter: {id: group})[0].name }}
|
||||
</div>
|
||||
<td><input type="checkbox" ng-model="user.is_present" ng-click="save(user)">
|
||||
<td>
|
||||
<span os-perms="!users.can_manage">
|
||||
<i ng-if="user.is_present" class="fa fa-check-square-o"></i>
|
||||
</span>
|
||||
<input os-perms="users.can_manage" type="checkbox" ng-model="user.is_present" ng-click="save(user)">
|
||||
</table>
|
||||
</div>
|
||||
|
Loading…
Reference in New Issue
Block a user