graphdb-workbench
Version:
The web application for GraphDB APIs
82 lines (77 loc) • 4.08 kB
HTML
<h1>
{{title}}
<span class="btn btn-link"
uib-popover-template="'js/angular/templates/titlePopoverTemplate.html'"
popover-trigger="mouseenter"
popover-placement="bottom-right"
popover-append-to-body="true"><span class="icon-info"></span></span>
</h1>
<div id="wb-users" ng-hide="loader">
<div class="mb-1">
<div class="pull-right">
<span id="toggle-security" class="mr-1">
<span class="security-switch-label">Security is <span class="tag {{securityEnabled() ? 'tag-primary' : 'tag-default'}}">{{securityEnabled() ? 'ON' : 'OFF'}}</span></span>
<span uib-tooltip="Click to {{securityEnabled() ? 'disable' : 'enable'}} security" tooltip-placement="top" tooltip-trigger="mouseenter" ng-click="toggleSecurity()" class="switch">
<input type="checkbox" class="switch" ng-checked="securityEnabled()"/>
<label for="toggleSecurity"></label>
</span>
</span>
<span ng-show="securityEnabled()" id="toggle-freeaccess">
<span>Free Access is <span class="tag {{freeAccessEnabled() ? 'tag-primary' : 'tag-default'}}">{{freeAccessEnabled() ? 'ON' : 'OFF'}}</span></span>
<span uib-tooltip="Click to {{freeAccessEnabled() ? 'disable' : 'enable'}} free access to non-admin functionality" tooltip-placement="top" tooltip-trigger="mouseenter" ng-click="toggleFreeAccess()" class="switch">
<input type="checkbox" class="switch" ng-checked="freeAccessEnabled()"/>
<label for="toggleFreeAccess"></label>
</span>
<span ng-show="freeAccessEnabled()">
Free Access Settings
<a style="padding-left: 0px;" class="btn btn-link" href="#"><em class="icon-settings" uib-tooltip="Free access configuration" ng-click="editFreeAccess()"></em></a>
</span>
</span>
</div>
<a id="wb-users-userCreateLink" class="btn btn-primary" href="user/create"><span class="icon-plus"></span> Create new user</a>
</div>
<div ng-show="hasExternalAuth()">
<div> </div>
<div class="alert alert-info no-icon mt-1">
<p>Using external authentication and authorization database {{getAuthImplementation()}}.</p>
<p>You can modify the user settings for users that logged in previously but you cannot change their credentials or access rights.</p>
</div>
</div>
<table id="wb-users-userInUsers" class="table table-striped" aria-describedby="Users table">
<thead>
<tr>
<th id="usernameColumn">Username</th>
<th id="roleColumn">Role</th>
<th id="repoRightsColumn">Repository rights</th>
<th id="creationDateColumn">Date created</th>
<th id="actionsColumn">Actions</th>
</tr>
</thead>
<tbody>
<tr ng-repeat="user in users | orderBy: 'username'">
<td class="username"><span>{{user.username}}</span></td>
<td class="user-type">{{user.userTypeDescription}}</td>
<td class="repository-rights">
<div ng-show="user.userType === 'user'" ng-repeat="(repo, rights) in user.repositories track by $index">
<em class="icon-eye" ng-class="rights.read ? 'text-tertiary' : 'text-muted'" uib-tooltip="{{rights.read ? 'Has read access' : 'Does not have read access'}}"></em>
<em class="icon-edit" ng-class="rights.write ? 'text-tertiary' : 'text-muted'" uib-tooltip="{{rights.read ? 'Has write access' : 'Does not have write access'}}"></em>
{{repo}}
</div>
<div ng-show="user.userType !== 'user'">Unrestricted</div>
</td>
<td class="date-created"><span>{{user.dateCreated | date: 'yyyy-MM-dd HH:mm:ss'}}</span></td>
<td class="actions-bar">
<span>
<a class="btn btn-link edit-user-btn" href="user/{{encodeURIComponent(user.username)}}">
<em class="icon-edit" uib-tooltip="Edit user"></em>
</a>
<a class="btn btn-link secondary delete-user-btn" ng-show="user.username != 'admin'" href ng-click="removeUser(user.username)">
<em class="icon-trash" uib-tooltip="Delete user"></em>
</a>
</span>
</td>
</tr>
</tbody>
</table>
</div>
<div class="ot-loader ot-main-loader" onto-loader size="50" ng-show="loader"></div>