|
|
@ -2,121 +2,9 @@
|
|
|
|
@inherits PlexRequests.UI.Helpers.AngularViewBase
|
|
|
|
@inherits PlexRequests.UI.Helpers.AngularViewBase
|
|
|
|
|
|
|
|
|
|
|
|
@Html.LoadUserManagementAssets()
|
|
|
|
@Html.LoadUserManagementAssets()
|
|
|
|
<div ng-controller="userManagementController" ng-init="init()">
|
|
|
|
<div id="wrapper" class="toggled" ng-controller="userManagementController" ng-init="init()" ng-cloak>
|
|
|
|
|
|
|
|
<!--Sidebar-->
|
|
|
|
<br />
|
|
|
|
<div id="sidebar-wrapper" class="shadow">
|
|
|
|
<br />
|
|
|
|
|
|
|
|
<br />
|
|
|
|
|
|
|
|
<div class="col-md-7">
|
|
|
|
|
|
|
|
<br>
|
|
|
|
|
|
|
|
<br>
|
|
|
|
|
|
|
|
<div ng-show="error.error" ng-bind="error.errorMessage"></div>
|
|
|
|
|
|
|
|
<form name="userform" ng-submit="addUser()" novalidate>
|
|
|
|
|
|
|
|
<div class="form-group">
|
|
|
|
|
|
|
|
<input id="username" type="text" placeholder="user" ng-model="user.username" class="form-control form-control-custom" />
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="form-group">
|
|
|
|
|
|
|
|
<input id="password" type="password" placeholder="password" ng-model="user.password" class="form-control form-control-custom" />
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="form-group">
|
|
|
|
|
|
|
|
<input id="email" type="email" placeholder="email address" ng-model="user.email" class="form-control form-control-custom" />
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div class="checkbox" ng-repeat="claim in claims">
|
|
|
|
|
|
|
|
<input id="claimCheckbox_{{$id}}" class="checkbox-custom" name="selectedClaims[]"
|
|
|
|
|
|
|
|
ng-checked="claim.selected" ng-model="claim.selected" type="checkbox" value="claim" />
|
|
|
|
|
|
|
|
<label for="claimCheckbox_{{$id}}">{{claim.name}}</label>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<input type="submit" class="btn btn-success-outline" value="Add" />
|
|
|
|
|
|
|
|
</form>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<form>
|
|
|
|
|
|
|
|
<div class="form-group">
|
|
|
|
|
|
|
|
<div class="input-group">
|
|
|
|
|
|
|
|
<div class="input-group-addon">
|
|
|
|
|
|
|
|
<i class="fa fa-search"></i>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<input type="text" class="form-control" placeholder="Search" ng-model="searchTerm">
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
</form>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<table class="table table-striped table-hover table-responsive table-condensed">
|
|
|
|
|
|
|
|
<thead>
|
|
|
|
|
|
|
|
<tr>
|
|
|
|
|
|
|
|
<th>
|
|
|
|
|
|
|
|
<a href="#" ng-click="sortType = 'username'; sortReverse = !sortReverse">
|
|
|
|
|
|
|
|
Username
|
|
|
|
|
|
|
|
<span ng-show="sortType == 'username' && !sortReverse" class="fa fa-caret-down"></span>
|
|
|
|
|
|
|
|
<span ng-show="sortType == 'username' && sortReverse" class="fa fa-caret-up"></span>
|
|
|
|
|
|
|
|
</a>
|
|
|
|
|
|
|
|
</th>
|
|
|
|
|
|
|
|
<th>
|
|
|
|
|
|
|
|
<a href="#" ng-click="sortType = 'alias'; sortReverse = !sortReverse">
|
|
|
|
|
|
|
|
Alias
|
|
|
|
|
|
|
|
<span ng-show="sortType == 'alias' && !sortReverse" class="fa fa-caret-down"></span>
|
|
|
|
|
|
|
|
<span ng-show="sortType == 'alias' && sortReverse" class="fa fa-caret-up"></span>
|
|
|
|
|
|
|
|
</a>
|
|
|
|
|
|
|
|
</th>
|
|
|
|
|
|
|
|
<th>
|
|
|
|
|
|
|
|
<a href="#" ng-click="sortType = 'emailAddress'; sortReverse = !sortReverse">
|
|
|
|
|
|
|
|
Email
|
|
|
|
|
|
|
|
<span ng-show="sortType == 'emailAddress' && !sortReverse" class="fa fa-caret-down"></span>
|
|
|
|
|
|
|
|
<span ng-show="sortType == 'emailAddress' && sortReverse" class="fa fa-caret-up"></span>
|
|
|
|
|
|
|
|
</a>
|
|
|
|
|
|
|
|
</th>
|
|
|
|
|
|
|
|
<th>
|
|
|
|
|
|
|
|
Roles
|
|
|
|
|
|
|
|
</th>
|
|
|
|
|
|
|
|
<th>
|
|
|
|
|
|
|
|
<a href="#" ng-click="sortType = 'type'; sortReverse = !sortReverse">
|
|
|
|
|
|
|
|
User Type
|
|
|
|
|
|
|
|
<span ng-show="sortType == 'type' && !sortReverse" class="fa fa-caret-down"></span>
|
|
|
|
|
|
|
|
<span ng-show="sortType == 'type' && sortReverse" class="fa fa-caret-up"></span>
|
|
|
|
|
|
|
|
</a>
|
|
|
|
|
|
|
|
</th>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<th>
|
|
|
|
|
|
|
|
<a href="#" ng-click="sortType = 'lastLoggedIn'; sortReverse = !sortReverse">
|
|
|
|
|
|
|
|
Last Logged In
|
|
|
|
|
|
|
|
<span ng-show="sortType == 'lastLoggedIn' && !sortReverse" class="fa fa-caret-down"></span>
|
|
|
|
|
|
|
|
<span ng-show="sortType == 'lastLoggedIn' && sortReverse" class="fa fa-caret-up"></span>
|
|
|
|
|
|
|
|
</a>
|
|
|
|
|
|
|
|
</th>
|
|
|
|
|
|
|
|
</tr>
|
|
|
|
|
|
|
|
</thead>
|
|
|
|
|
|
|
|
<tbody>
|
|
|
|
|
|
|
|
<tr ng-repeat="u in users | orderBy:sortType:sortReverse | filter:searchTerm">
|
|
|
|
|
|
|
|
<td>
|
|
|
|
|
|
|
|
{{u.username}}
|
|
|
|
|
|
|
|
</td>
|
|
|
|
|
|
|
|
<td>
|
|
|
|
|
|
|
|
{{u.alias}}
|
|
|
|
|
|
|
|
</td>
|
|
|
|
|
|
|
|
<td>
|
|
|
|
|
|
|
|
{{u.emailAddress}}
|
|
|
|
|
|
|
|
</td>
|
|
|
|
|
|
|
|
<td>
|
|
|
|
|
|
|
|
{{u.claims}}
|
|
|
|
|
|
|
|
</td>
|
|
|
|
|
|
|
|
<td>
|
|
|
|
|
|
|
|
{{u.type === 1 ? 'Local User' : 'Plex User'}}
|
|
|
|
|
|
|
|
</td>
|
|
|
|
|
|
|
|
<td>
|
|
|
|
|
|
|
|
{{u.lastLoggedIn}}
|
|
|
|
|
|
|
|
</td>
|
|
|
|
|
|
|
|
<td>
|
|
|
|
|
|
|
|
<a href="#" ng-click="selectUser(u.id)" class="btn btn-sm btn-info-outline">Details/Edit</a>
|
|
|
|
|
|
|
|
</td>
|
|
|
|
|
|
|
|
</tr>
|
|
|
|
|
|
|
|
</tbody>
|
|
|
|
|
|
|
|
</table>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div class="col-md-5 col-md-push-1 user-management-menu" ng-show="selectedUser.username">
|
|
|
|
|
|
|
|
<br />
|
|
|
|
<br />
|
|
|
|
<br />
|
|
|
|
<br />
|
|
|
|
<img ng-show="selectedUser.plexInfo.thumb" class="col-md-pull-1 img-circle" style="position: absolute" ng-src="{{selectedUser.plexInfo.thumb}}" />
|
|
|
|
<img ng-show="selectedUser.plexInfo.thumb" class="col-md-pull-1 img-circle" style="position: absolute" ng-src="{{selectedUser.plexInfo.thumb}}" />
|
|
|
@ -160,8 +48,123 @@
|
|
|
|
<button ng-click="deleteUser()" class="btn btn-danger-outline">Delete</button>
|
|
|
|
<button ng-click="deleteUser()" class="btn btn-danger-outline">Delete</button>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<!--SideBar End-->
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div>
|
|
|
|
|
|
|
|
<div class="container-fluid">
|
|
|
|
|
|
|
|
<div>
|
|
|
|
|
|
|
|
<br />
|
|
|
|
|
|
|
|
<br />
|
|
|
|
|
|
|
|
<br />
|
|
|
|
|
|
|
|
<div class="col-md-12">
|
|
|
|
|
|
|
|
<br>
|
|
|
|
|
|
|
|
<br>
|
|
|
|
|
|
|
|
<div ng-show="error.error" ng-bind="error.errorMessage"></div>
|
|
|
|
|
|
|
|
<form name="userform" ng-submit="addUser()" novalidate>
|
|
|
|
|
|
|
|
<div class="form-group">
|
|
|
|
|
|
|
|
<input id="username" type="text" placeholder="user" ng-model="user.username" class="form-control form-control-custom" />
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="form-group">
|
|
|
|
|
|
|
|
<input id="password" type="password" placeholder="password" ng-model="user.password" class="form-control form-control-custom" />
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="form-group">
|
|
|
|
|
|
|
|
<input id="email" type="email" placeholder="email address" ng-model="user.email" class="form-control form-control-custom" />
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div class="checkbox" ng-repeat="claim in claims">
|
|
|
|
|
|
|
|
<input id="claimCheckbox_{{$id}}" class="checkbox-custom" name="selectedClaims[]"
|
|
|
|
|
|
|
|
ng-checked="claim.selected" ng-model="claim.selected" type="checkbox" value="claim" />
|
|
|
|
|
|
|
|
<label for="claimCheckbox_{{$id}}">{{claim.name}}</label>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<input type="submit" class="btn btn-success-outline" value="Add" />
|
|
|
|
|
|
|
|
</form>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<form>
|
|
|
|
|
|
|
|
<div class="form-group">
|
|
|
|
|
|
|
|
<div class="input-group">
|
|
|
|
|
|
|
|
<div class="input-group-addon">
|
|
|
|
|
|
|
|
<i class="fa fa-search"></i>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<input type="text" class="form-control" placeholder="Search" ng-model="searchTerm">
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
</form>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<table class="table table-striped table-hover table-responsive table-condensed">
|
|
|
|
|
|
|
|
<thead>
|
|
|
|
|
|
|
|
<tr>
|
|
|
|
|
|
|
|
<th>
|
|
|
|
|
|
|
|
<a href="#" ng-click="sortType = 'username'; sortReverse = !sortReverse">
|
|
|
|
|
|
|
|
Username
|
|
|
|
|
|
|
|
<span ng-show="sortType == 'username' && !sortReverse" class="fa fa-caret-down"></span>
|
|
|
|
|
|
|
|
<span ng-show="sortType == 'username' && sortReverse" class="fa fa-caret-up"></span>
|
|
|
|
|
|
|
|
</a>
|
|
|
|
|
|
|
|
</th>
|
|
|
|
|
|
|
|
<th>
|
|
|
|
|
|
|
|
<a href="#" ng-click="sortType = 'alias'; sortReverse = !sortReverse">
|
|
|
|
|
|
|
|
Alias
|
|
|
|
|
|
|
|
<span ng-show="sortType == 'alias' && !sortReverse" class="fa fa-caret-down"></span>
|
|
|
|
|
|
|
|
<span ng-show="sortType == 'alias' && sortReverse" class="fa fa-caret-up"></span>
|
|
|
|
|
|
|
|
</a>
|
|
|
|
|
|
|
|
</th>
|
|
|
|
|
|
|
|
<th>
|
|
|
|
|
|
|
|
<a href="#" ng-click="sortType = 'emailAddress'; sortReverse = !sortReverse">
|
|
|
|
|
|
|
|
Email
|
|
|
|
|
|
|
|
<span ng-show="sortType == 'emailAddress' && !sortReverse" class="fa fa-caret-down"></span>
|
|
|
|
|
|
|
|
<span ng-show="sortType == 'emailAddress' && sortReverse" class="fa fa-caret-up"></span>
|
|
|
|
|
|
|
|
</a>
|
|
|
|
|
|
|
|
</th>
|
|
|
|
|
|
|
|
<th>
|
|
|
|
|
|
|
|
Roles
|
|
|
|
|
|
|
|
</th>
|
|
|
|
|
|
|
|
<th>
|
|
|
|
|
|
|
|
<a href="#" ng-click="sortType = 'type'; sortReverse = !sortReverse">
|
|
|
|
|
|
|
|
User Type
|
|
|
|
|
|
|
|
<span ng-show="sortType == 'type' && !sortReverse" class="fa fa-caret-down"></span>
|
|
|
|
|
|
|
|
<span ng-show="sortType == 'type' && sortReverse" class="fa fa-caret-up"></span>
|
|
|
|
|
|
|
|
</a>
|
|
|
|
|
|
|
|
</th>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<th>
|
|
|
|
|
|
|
|
<a href="#" ng-click="sortType = 'lastLoggedIn'; sortReverse = !sortReverse">
|
|
|
|
|
|
|
|
Last Logged In
|
|
|
|
|
|
|
|
<span ng-show="sortType == 'lastLoggedIn' && !sortReverse" class="fa fa-caret-down"></span>
|
|
|
|
|
|
|
|
<span ng-show="sortType == 'lastLoggedIn' && sortReverse" class="fa fa-caret-up"></span>
|
|
|
|
|
|
|
|
</a>
|
|
|
|
|
|
|
|
</th>
|
|
|
|
|
|
|
|
</tr>
|
|
|
|
|
|
|
|
</thead>
|
|
|
|
|
|
|
|
<tbody>
|
|
|
|
|
|
|
|
<tr ng-repeat="u in users | orderBy:sortType:sortReverse | filter:searchTerm">
|
|
|
|
|
|
|
|
<td>
|
|
|
|
|
|
|
|
{{u.username}}
|
|
|
|
|
|
|
|
</td>
|
|
|
|
|
|
|
|
<td>
|
|
|
|
|
|
|
|
{{u.alias}}
|
|
|
|
|
|
|
|
</td>
|
|
|
|
|
|
|
|
<td>
|
|
|
|
|
|
|
|
{{u.emailAddress}}
|
|
|
|
|
|
|
|
</td>
|
|
|
|
|
|
|
|
<td>
|
|
|
|
|
|
|
|
{{u.claims}}
|
|
|
|
|
|
|
|
</td>
|
|
|
|
|
|
|
|
<td>
|
|
|
|
|
|
|
|
{{u.type === 1 ? 'Local User' : 'Plex User'}}
|
|
|
|
|
|
|
|
</td>
|
|
|
|
|
|
|
|
<td ng-bind="u.lastLoggedIn === minDate ? 'Never' : formatDate(u.lastLoggedIn)"></td>
|
|
|
|
|
|
|
|
<td>
|
|
|
|
|
|
|
|
<a href="#" ng-click="selectUser(u.id)" class="btn btn-sm btn-info-outline detailsBtn">Details/Edit</a>
|
|
|
|
|
|
|
|
</td>
|
|
|
|
|
|
|
|
</tr>
|
|
|
|
|
|
|
|
</tbody>
|
|
|
|
|
|
|
|
</table>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
</div> <!-- End of user side menu -->
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|