Skip to content
This repository has been archived by the owner on Sep 16, 2019. It is now read-only.

Commit

Permalink
Add filter for users and roles pages (#180)
Browse files Browse the repository at this point in the history
  • Loading branch information
satterly authored Nov 22, 2018
1 parent d3457a2 commit 6ebf87b
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 12 deletions.
8 changes: 7 additions & 1 deletion app/partials/perms.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@

<div class="container-fluid">

<div class="row">
<div class="col-md-5 col-sm-5 col-xs-12">
<input class="form-control input" ng-model="filter" size="8" placeholder="Find a role...">
</div>
</div> <!-- row -->

<div class="row-fluid">
<div class="span12">

Expand All @@ -10,7 +16,7 @@
<th>Scopes</th>
<th></th>
</tr>
<tr ng-repeat="perm in perms">
<tr ng-repeat="perm in perms | filter:filter">
<td><tt>{{ perm.match }}</tt></td>
<td><span ng-repeat="scope in perm.scopes"><span class="label label-primary">{{ scope }}</span> </span></td>
<td><button ng-disabled="!hasPermission('admin:perms')" type="button" class="btn btn-default btn-sm" ng-click="deletePerm(perm.id);"><i class="glyphicon glyphicon-trash"></i> Delete</button></td>
Expand Down
22 changes: 11 additions & 11 deletions app/partials/users.html
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@

<div class="container-fluid">

<div class="row-fluid">
<div class="span12">

<div>
<table class="table">
<tr>
<td><b>Allowed E-mail Domains: </b>{{domains.join(', ') }}</td>
</tr>
</table>
<div class="row">
<div class="col-md-5 col-sm-5 col-xs-12">
<input class="form-control input" ng-model="filter" size="8" placeholder="Find a user...">
</div>

<div class="col-md-3 col-sm-3 col-xs-12">
<b>Allowed E-mail Domains: </b>{{domains.join(', ') }}
</div>
</div> <!-- row -->

<div class="row">
<div class="col-md-12">
<table class="table">
<tr>
<th>Name</th>
Expand All @@ -23,7 +23,7 @@
<th class="hidden-xs">Comment</th>
<th>Access</th>
</tr>
<tr ng-repeat="user in users track by user.id">
<tr ng-repeat="user in users | filter:filter">
<td>{{ user.name }}</td>
<td>{{ user.login || user.email }}</td>
<td ng-show="user.email_verified"><i class="glyphicon glyphicon-envelope"></i> <i class="glyphicon glyphicon-ok"></i></td>
Expand Down

0 comments on commit 6ebf87b

Please sign in to comment.