sogo/UI/Templates/UIxAclEditor.wox
2015-06-12 12:02:14 -04:00

82 lines
3.5 KiB
XML

<?xml version="1.0" standalone="yes"?>
<!DOCTYPE container>
<container
xmlns="http://www.w3.org/1999/xhtml"
xmlns:var="http://www.skyrix.com/od/binding"
xmlns:const="http://www.skyrix.com/od/constant"
xmlns:label="OGo:label"
xmlns:uix="OGo:uix">
<md-dialog flex="50" flex-sm="100">
<md-dialog-content>
<h2 class="md-headline"><var:string label:value="Access Rights"/> - {{folder.name}}</h2>
<md-list>
<md-list-item
ng-repeat="user in users | orderBy:['userClass', 'displayName']"
ng-click="selectUser(user)">
<div layout="column" layout-fill="true">
<div layout="row">
<md-button>
<div layout="row" layout-align="space-between center"
layout-fill="true">
<span class="card-picture" ng-switch="user.userClass">
<div ng-switch-when="normal-user" class="sg-avatar"><!-- normal-user --></div>
<div ng-switch-when="public-user" class="sg-list-avatar"><!-- public-user --></div>
</span>
<span class="name">{{user.$shortFormat()}}</span>
</div>
</md-button>
<md-button
ng-click="removeUser(user)"
type="button"
layout="row" layout-align="end center"
ng-hide="user.uid != selectedUser.uid || user.$isSpecial()">
<div class="md-icon-delete"><!-- delete --></div>
</md-button>
</div>
<span id="AccessRightList" ng-show="user.uid == selectedUser.uid">
<md-checkbox ng-model="user.isSubscribed"
label:arial-label="Subscribe User"
ng-disabled="user.wasSubscribed"
ng-true-value="1"
ng-false-value="0"
ng-hide="user.$isSpecial()">
<var:string label:value="Subscribe User"/>
</md-checkbox>
<div ng-include="'UIxUserRightsEditor'">
<!--
Load ng-template #UIxUserRightsEditor from main module wox. Inner wox templates are:
- UI/Templates/ContactsUI/UIxContactsUserRightsEditor.wox
- UI/Templates/MailerUI/UIxMailUserRightsEditor.wox
- UI/Templates/SchedulerUI/UIxCalUserRightsEditor.wox
--></div>
</span>
</div>
<md-divider><!-- divider --></md-divider>
</md-list-item>
</md-list>
</md-dialog-content>
<div class="md-actions">
<md-autocomplete
class="md-flex"
md-selected-item="userToAdd"
md-search-text="searchText"
md-selected-item-change="addUser(user)"
md-items="user in userFilter(searchText)"
md-min-length="0"
label:placeholder="Add">
<span class="md-contact-suggestion" layout="row" layout-align="space-between center">
<span class="md-contact-name"
md-highlight-text="searchText"
md-highlight-flags="^i">{{user.cn}}</span> <span class="md-contact-email"
md-highlight-text="searchText"
md-highlight-flags="^i">{{user.c_email}}</span>
</span>
</md-autocomplete>
<md-button ng-click="closeModal()"><var:string label:value="Close"/></md-button>
<md-button class="md-primitive" ng-click="saveModal()"><var:string label:value="Save"/></md-button>
</div>
</md-dialog>
</container>