mirror of
https://repository.entgra.net/community/device-mgt-core.git
synced 2025-10-06 02:01:45 +00:00
ui improvements to device cloud
This commit is contained in:
parent
8a07639d6b
commit
587f847934
@ -35,18 +35,18 @@
|
|||||||
<div class="tile-icon"><i class="fw fw-mobile"></i></div>
|
<div class="tile-icon"><i class="fw fw-mobile"></i></div>
|
||||||
<div class="tile-stats">
|
<div class="tile-stats">
|
||||||
<span id="device-count">{{deviceCount}}</span>
|
<span id="device-count">{{deviceCount}}</span>
|
||||||
<span class="tile-stats-free">
|
<span class="tile-stats-free">
|
||||||
<!--suppress HtmlUnknownTarget -->
|
<!--suppress HtmlUnknownTarget -->
|
||||||
{{#if deviceCount}}
|
{{#if deviceCount}}
|
||||||
<a href="{{@app.context}}/devices">
|
<a href="{{@app.context}}/devices">
|
||||||
<span class="fw-stack">
|
<span class="fw-stack">
|
||||||
<i class="fw fw-circle-outline fw-stack-2x"></i>
|
<i class="fw fw-circle-outline fw-stack-2x"></i>
|
||||||
<i class="fw fw-view fw-stack-1x"></i>
|
<i class="fw fw-view fw-stack-1x"></i>
|
||||||
</span>
|
</span>
|
||||||
View
|
View
|
||||||
</a>
|
</a>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
<!--suppress HtmlUnknownTarget -->
|
<!--suppress HtmlUnknownTarget -->
|
||||||
<a href="{{@app.context}}/device/enroll">
|
<a href="{{@app.context}}/device/enroll">
|
||||||
<span class="fw-stack">
|
<span class="fw-stack">
|
||||||
<i class="fw fw-circle-outline fw-stack-2x"></i>
|
<i class="fw fw-circle-outline fw-stack-2x"></i>
|
||||||
@ -66,7 +66,7 @@
|
|||||||
<div class="tile-icon"><i class="fw fw-group"></i></div>
|
<div class="tile-icon"><i class="fw fw-group"></i></div>
|
||||||
<div class="tile-stats">
|
<div class="tile-stats">
|
||||||
<span id="group-count">{{groupCount}}</span>
|
<span id="group-count">{{groupCount}}</span>
|
||||||
<span class="tile-stats-free">
|
<span class="tile-stats-free">
|
||||||
{{#if groupCount}}
|
{{#if groupCount}}
|
||||||
<!--suppress HtmlUnknownTarget -->
|
<!--suppress HtmlUnknownTarget -->
|
||||||
<a href="{{@app.context}}/groups">
|
<a href="{{@app.context}}/groups">
|
||||||
@ -77,14 +77,16 @@
|
|||||||
View
|
View
|
||||||
</a>
|
</a>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
<!--suppress HtmlUnknownTarget -->
|
<!--suppress HtmlUnknownTarget -->
|
||||||
<a href="{{@app.context}}/group/add">
|
{{#unless isCloud}}
|
||||||
|
<a href="{{@app.context}}/group/add">
|
||||||
<span class="fw-stack">
|
<span class="fw-stack">
|
||||||
<i class="fw fw-circle-outline fw-stack-2x"></i>
|
<i class="fw fw-circle-outline fw-stack-2x"></i>
|
||||||
<i class="fw fw-add fw-stack-1x"></i>
|
<i class="fw fw-add fw-stack-1x"></i>
|
||||||
</span>
|
</span>
|
||||||
Add
|
Add
|
||||||
</a>
|
</a>
|
||||||
|
{{/unless}}
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -97,7 +99,7 @@
|
|||||||
<div class="tile-icon"><i class="fw fw-user"></i></div>
|
<div class="tile-icon"><i class="fw fw-user"></i></div>
|
||||||
<div class="tile-stats">
|
<div class="tile-stats">
|
||||||
<span id="user-count">{{userCount}}</span>
|
<span id="user-count">{{userCount}}</span>
|
||||||
<span class="tile-stats-free">
|
<span class="tile-stats-free">
|
||||||
{{#if userCount}}
|
{{#if userCount}}
|
||||||
<!--suppress HtmlUnknownTarget -->
|
<!--suppress HtmlUnknownTarget -->
|
||||||
<a href="{{@app.context}}/users">
|
<a href="{{@app.context}}/users">
|
||||||
@ -108,14 +110,16 @@
|
|||||||
View
|
View
|
||||||
</a>
|
</a>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
<!--suppress HtmlUnknownTarget -->
|
<!--suppress HtmlUnknownTarget -->
|
||||||
<a href="{{@app.context}}/user/add">
|
{{#unless isCloud}}
|
||||||
|
<a href="{{@app.context}}/user/add">
|
||||||
<span class="fw-stack">
|
<span class="fw-stack">
|
||||||
<i class="fw fw-circle-outline fw-stack-2x"></i>
|
<i class="fw fw-circle-outline fw-stack-2x"></i>
|
||||||
<i class="fw fw-add fw-stack-1x"></i>
|
<i class="fw fw-add fw-stack-1x"></i>
|
||||||
</span>
|
</span>
|
||||||
Add
|
Add
|
||||||
</a>
|
</a>
|
||||||
|
{{/unless}}
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -128,7 +132,7 @@
|
|||||||
<div class="tile-icon"><i class="fw fw-policy"></i></div>
|
<div class="tile-icon"><i class="fw fw-policy"></i></div>
|
||||||
<div class="tile-stats">
|
<div class="tile-stats">
|
||||||
<span id="policy-count">{{policyCount}}</span>
|
<span id="policy-count">{{policyCount}}</span>
|
||||||
<span class="tile-stats-free">
|
<span class="tile-stats-free">
|
||||||
{{#if policyCount}}
|
{{#if policyCount}}
|
||||||
<!--suppress HtmlUnknownTarget -->
|
<!--suppress HtmlUnknownTarget -->
|
||||||
<a href="{{@app.context}}/policies">
|
<a href="{{@app.context}}/policies">
|
||||||
@ -139,14 +143,16 @@
|
|||||||
View
|
View
|
||||||
</a>
|
</a>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
<!--suppress HtmlUnknownTarget -->
|
<!--suppress HtmlUnknownTarget -->
|
||||||
<a href="{{@app.context}}/policy/add">
|
{{#unless isCloud}}
|
||||||
|
<a href="{{@app.context}}/policy/add">
|
||||||
<span class="fw-stack">
|
<span class="fw-stack">
|
||||||
<i class="fw fw-circle-outline fw-stack-2x"></i>
|
<i class="fw fw-circle-outline fw-stack-2x"></i>
|
||||||
<i class="fw fw-add fw-stack-1x"></i>
|
<i class="fw fw-add fw-stack-1x"></i>
|
||||||
</span>
|
</span>
|
||||||
Add
|
Add
|
||||||
</a>
|
</a>
|
||||||
|
{{/unless}}
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -171,13 +177,15 @@
|
|||||||
</a>
|
</a>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
<!--suppress HtmlUnknownTarget -->
|
<!--suppress HtmlUnknownTarget -->
|
||||||
<a href="{{@app.context}}/role/add">
|
{{#unless isCloud}}
|
||||||
|
<a href="{{@app.context}}/role/add">
|
||||||
<span class="fw-stack">
|
<span class="fw-stack">
|
||||||
<i class="fw fw-circle-outline fw-stack-2x"></i>
|
<i class="fw fw-circle-outline fw-stack-2x"></i>
|
||||||
<i class="fw fw-add fw-stack-1x"></i>
|
<i class="fw fw-add fw-stack-1x"></i>
|
||||||
</span>
|
</span>
|
||||||
Add
|
Add
|
||||||
</a>
|
</a>
|
||||||
|
{{/unless}}
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@ -40,6 +40,7 @@ function onRequest() {
|
|||||||
viewModel.userCount = userModule.getUsersCount();
|
viewModel.userCount = userModule.getUsersCount();
|
||||||
viewModel.policyCount = policyModule.getPoliciesCount();
|
viewModel.policyCount = policyModule.getPoliciesCount();
|
||||||
viewModel.roleCount = userModule.getRolesCount();
|
viewModel.roleCount = userModule.getRolesCount();
|
||||||
|
viewModel.isCloud = devicemgtProps.isCloud;
|
||||||
|
|
||||||
return viewModel;
|
return viewModel;
|
||||||
}
|
}
|
||||||
@ -142,8 +142,14 @@ function loadRoles() {
|
|||||||
class: "text-right content-fill text-left-on-grid-view no-wrap",
|
class: "text-right content-fill text-left-on-grid-view no-wrap",
|
||||||
data: null,
|
data: null,
|
||||||
render: function (data, type, row, meta) {
|
render: function (data, type, row, meta) {
|
||||||
return '' +
|
var isCloud = false;
|
||||||
'<a onclick="javascript:loadRoleBasedActionURL(\'edit\', \'' + data.name + '\')" ' +
|
if ($('#is-cloud').length > 0){
|
||||||
|
isCloud = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
var innerhtml = '';
|
||||||
|
|
||||||
|
var editLink = '<a onclick="javascript:loadRoleBasedActionURL(\'edit\', \'' + data.name + '\')" ' +
|
||||||
'data-role="' + data.name + '" ' +
|
'data-role="' + data.name + '" ' +
|
||||||
'data-click-event="edit-form" ' +
|
'data-click-event="edit-form" ' +
|
||||||
'class="btn padding-reduce-on-grid-view edit-role-link">' +
|
'class="btn padding-reduce-on-grid-view edit-role-link">' +
|
||||||
@ -156,8 +162,9 @@ function loadRoles() {
|
|||||||
'</span>' +
|
'</span>' +
|
||||||
'</span>' +
|
'</span>' +
|
||||||
'<span class="hidden-xs hidden-on-grid-view">Edit</span>' +
|
'<span class="hidden-xs hidden-on-grid-view">Edit</span>' +
|
||||||
'</a>' +
|
'</a>';
|
||||||
'<a onclick="javascript:loadRoleBasedActionURL(\'edit-permission\', \'' + data.name + '\')" ' +
|
|
||||||
|
var editPermissionLink = '<a onclick="javascript:loadRoleBasedActionURL(\'edit-permission\', \'' + data.name + '\')" ' +
|
||||||
'data-role="' + data.name + '" ' +
|
'data-role="' + data.name + '" ' +
|
||||||
'data-click-event="edit-form" ' +
|
'data-click-event="edit-form" ' +
|
||||||
'class="btn padding-reduce-on-grid-view edit-permission-link">' +
|
'class="btn padding-reduce-on-grid-view edit-permission-link">' +
|
||||||
@ -170,8 +177,9 @@ function loadRoles() {
|
|||||||
'</span>' +
|
'</span>' +
|
||||||
'</span>' +
|
'</span>' +
|
||||||
'<span class="hidden-xs hidden-on-grid-view">Edit Permission</span>' +
|
'<span class="hidden-xs hidden-on-grid-view">Edit Permission</span>' +
|
||||||
'</a>' +
|
'</a>';
|
||||||
'<a data-role="' + data.name + '" ' +
|
|
||||||
|
car removeLink = '<a data-role="' + data.name + '" ' +
|
||||||
'data-click-event="remove-form" ' +
|
'data-click-event="remove-form" ' +
|
||||||
'class="btn padding-reduce-on-grid-view remove-role-link">' +
|
'class="btn padding-reduce-on-grid-view remove-role-link">' +
|
||||||
'<span class="fw-stack">' +
|
'<span class="fw-stack">' +
|
||||||
@ -180,6 +188,11 @@ function loadRoles() {
|
|||||||
'</span>' +
|
'</span>' +
|
||||||
'<span class="hidden-xs hidden-on-grid-view">Remove</span>' +
|
'<span class="hidden-xs hidden-on-grid-view">Remove</span>' +
|
||||||
'</a>';
|
'</a>';
|
||||||
|
|
||||||
|
if (!isCloud){
|
||||||
|
innerhtml = editLink + editPermissionLink + removeLink;
|
||||||
|
}
|
||||||
|
return innerhtml;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
|
|||||||
@ -35,6 +35,7 @@
|
|||||||
{{/zone}}
|
{{/zone}}
|
||||||
|
|
||||||
{{#zone "navbarActions"}}
|
{{#zone "navbarActions"}}
|
||||||
|
{{#unless isCloud}}
|
||||||
<li>
|
<li>
|
||||||
<!--suppress HtmlUnknownTarget -->
|
<!--suppress HtmlUnknownTarget -->
|
||||||
<a href="{{@app.context}}/role/add" class="cu-btn">
|
<a href="{{@app.context}}/role/add" class="cu-btn">
|
||||||
@ -45,16 +46,22 @@
|
|||||||
Add Role
|
Add Role
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
{{/unless}}
|
||||||
{{/zone}}
|
{{/zone}}
|
||||||
|
|
||||||
{{#zone "content"}}
|
{{#zone "content"}}
|
||||||
<div id="loading-content" class="col-centered">
|
<div id="loading-content" class="col-centered">
|
||||||
|
{{#unless isCloud}}
|
||||||
{{#if removePermitted}}
|
{{#if removePermitted}}
|
||||||
<input type="hidden" id="can-remove" value="true" />
|
<input type="hidden" id="can-remove" value="true" />
|
||||||
{{/if}}
|
{{/if}}
|
||||||
{{#if editPermitted}}
|
{{#if editPermitted}}
|
||||||
<input type="hidden" id="can-edit" value="true" />
|
<input type="hidden" id="can-edit" value="true" />
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
{{/unless}}
|
||||||
|
{{#if isCloud}}
|
||||||
|
<input type="hidden" id="is-cloud" value="true" />
|
||||||
|
{{/if}}
|
||||||
<i class="fw fw-settings fw-spin fw-2x"></i>
|
<i class="fw fw-settings fw-spin fw-2x"></i>
|
||||||
Loading roles . . .
|
Loading roles . . .
|
||||||
<br>
|
<br>
|
||||||
|
|||||||
@ -32,6 +32,7 @@ function onRequest(context) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
context["adminRole"] = deviceMgtProps["adminRole"];
|
context["adminRole"] = deviceMgtProps["adminRole"];
|
||||||
|
context["isCloud"] = deviceMgtProps["isCloud"];
|
||||||
|
|
||||||
return context;
|
return context;
|
||||||
}
|
}
|
||||||
@ -37,94 +37,99 @@
|
|||||||
|
|
||||||
{{#zone "content"}}
|
{{#zone "content"}}
|
||||||
{{#if canView}}
|
{{#if canView}}
|
||||||
{{#zone "contentTitle"}}
|
{{#zone "contentTitle"}}
|
||||||
<div class="row wr-device-board">
|
<div class="row wr-device-board">
|
||||||
<div class="col-lg-12 wr-secondary-bar">
|
<div class="col-lg-12 wr-secondary-bar">
|
||||||
<label class="device-id device-select" data-username="{{user.username}}">
|
<label class="device-id device-select" data-username="{{user.username}}">
|
||||||
{{#if user.firstname}}
|
{{#if user.firstname}}
|
||||||
{{user.firstname}} {{user.lastname}}
|
{{user.firstname}} {{user.lastname}}
|
||||||
{{else}}
|
{{else}}
|
||||||
{{user.username}}
|
{{user.username}}
|
||||||
{{/if}}
|
{{/if}}
|
||||||
</label>
|
</label>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
{{/zone}}
|
||||||
{{/zone}}
|
|
||||||
|
|
||||||
<div class="row no-gutter add-padding-5x add-margin-top-5x" style="border: 1px solid #e4e4e4;">
|
<div class="row no-gutter add-padding-5x add-margin-top-5x" style="border: 1px solid #e4e4e4;">
|
||||||
<div class="media">
|
<div class="media">
|
||||||
<div class="media-left media-middle asset-image col-xs-2 col-sm-2 col-md-2 col-lg-2">
|
<div class="media-left media-middle asset-image col-xs-2 col-sm-2 col-md-2 col-lg-2">
|
||||||
<div class="thumbnail icon" style="margin-bottom: 43px"><i class="square-element text fw fw-user"></i>
|
<div class="thumbnail icon" style="margin-bottom: 43px"><i
|
||||||
|
class="square-element text fw fw-user"></i>
|
||||||
|
</div>
|
||||||
|
<div class="media">
|
||||||
|
|
||||||
|
{{#unless isCloud}}
|
||||||
|
{{#if editPermitted}}
|
||||||
|
<button class="wr-btn"
|
||||||
|
onclick="location.href='{{@app.context}}/users/edit-user?username={{user.username}}';"
|
||||||
|
id="sortUpdateBtn"
|
||||||
|
style="width: 100%; vertical-align: bottom; background-color: #7fa030;"><span><i
|
||||||
|
class="fw fw-edit"></i> Edit</span></button>
|
||||||
|
{{/if}}
|
||||||
|
{{/unless}}
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="media">
|
<div class="media-body asset-desc add-padding-left-5x">
|
||||||
{{#if editPermitted}}
|
<div style="background: #11375B; color: #fff; padding: 10px; margin-bottom: 5px">Profile Overview
|
||||||
<button class="wr-btn"
|
</div>
|
||||||
onclick="location.href='{{@app.context}}/users/edit-user?username={{user.username}}';"
|
{{#defineZone "user-detail-properties"}}
|
||||||
id="sortUpdateBtn"
|
<table class="table table-responsive table-striped" id="members">
|
||||||
style="width: 100%; vertical-align: bottom; background-color: #7fa030;"><span><i
|
<tbody>
|
||||||
class="fw fw-edit"></i> Edit</span></button>
|
<tr role="row" class="even">
|
||||||
{{/if}}
|
<td class="sorting_1" style="padding:10px 15px; width: 7%;">Username</td>
|
||||||
|
<td style="padding:10px 15px;">{{user.username}}</td>
|
||||||
|
</tr>
|
||||||
|
<tr role="row" class="odd">
|
||||||
|
<td class="sorting_1" style="padding:10px 15px;">First Name</td>
|
||||||
|
<td style="padding:10px 15px;">{{user.firstname}}</td>
|
||||||
|
</tr>
|
||||||
|
<tr role="row" class="even">
|
||||||
|
<td class="sorting_1" style="padding:10px 15px;">Last Name</td>
|
||||||
|
<td style="padding:10px 15px;">{{user.lastname}}</td>
|
||||||
|
</tr>
|
||||||
|
<tr role="row" class="even">
|
||||||
|
<td class="sorting_1" style="padding:10px 15px;">Email</td>
|
||||||
|
<td style="padding:10px 15px;">{{user.emailAddress}}</td>
|
||||||
|
</tr>
|
||||||
|
<tr role="row" class="even">
|
||||||
|
<td class="sorting_1" style="padding:10px 15px;">Roles</td>
|
||||||
|
<td style="padding:10px 15px;">
|
||||||
|
{{#each userRoles}}
|
||||||
|
<option selected="selected">{{this}}</option>
|
||||||
|
{{/each}}
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
{{/defineZone}}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="media-body asset-desc add-padding-left-5x">
|
<div class="media">
|
||||||
<div style="background: #11375B; color: #fff; padding: 10px; margin-bottom: 5px">Profile Overview</div>
|
<div class="media-left col-xs-12 col-sm-2 col-md-2 col-lg-2">
|
||||||
{{#defineZone "user-detail-properties"}}
|
<ul class="list-group" role="tablist">
|
||||||
<table class="table table-responsive table-striped" id="members">
|
<li class="active"><a class="list-group-item" href="#enrolled_devices" role="tab"
|
||||||
<tbody>
|
data-toggle="tab" aria-controls="enrolled_devices">Enrolled Devices</a>
|
||||||
<tr role="row" class="even">
|
</li>
|
||||||
<td class="sorting_1" style="padding:10px 15px; width: 7%;">Username</td>
|
</ul>
|
||||||
<td style="padding:10px 15px;">{{user.username}}</td>
|
</div>
|
||||||
</tr>
|
{{#defineZone "user-enrolled-devices"}}
|
||||||
<tr role="row" class="odd">
|
<div class="media-body add-padding-left-5x remove-padding-xs tab-content">
|
||||||
<td class="sorting_1" style="padding:10px 15px;">First Name</td>
|
<div class="panel-group tab-content">
|
||||||
<td style="padding:10px 15px;">{{user.firstname}}</td>
|
<div class="panel panel-default tab-pane active" id="enrolled_devices"
|
||||||
</tr>
|
role="tabpanel" aria-labelledby="enrolled_devices">
|
||||||
<tr role="row" class="even">
|
<div class="panel-heading">Enrolled Devices by
|
||||||
<td class="sorting_1" style="padding:10px 15px;">Last Name</td>
|
{{#if user.firstname}}
|
||||||
<td style="padding:10px 15px;">{{user.lastname}}</td>
|
{{user.firstname}} {{user.lastname}}
|
||||||
</tr>
|
{{else}}
|
||||||
<tr role="row" class="even">
|
{{user.username}}
|
||||||
<td class="sorting_1" style="padding:10px 15px;">Email</td>
|
{{/if}}
|
||||||
<td style="padding:10px 15px;">{{user.emailAddress}}</td>
|
</div>
|
||||||
</tr>
|
<div class="panel-body">
|
||||||
<tr role="row" class="even">
|
<div id="enrolled_devices-container">
|
||||||
<td class="sorting_1" style="padding:10px 15px;">Roles</td>
|
<div class="panel-body">
|
||||||
<td style="padding:10px 15px;">
|
{{#each devices}}
|
||||||
{{#each userRoles}}
|
<div class="wr-list-group wr-sortable policy-list">
|
||||||
<option selected="selected">{{this}}</option>
|
|
||||||
{{/each}}
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
{{/defineZone}}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="media">
|
|
||||||
<div class="media-left col-xs-12 col-sm-2 col-md-2 col-lg-2">
|
|
||||||
<ul class="list-group" role="tablist">
|
|
||||||
<li class="active"><a class="list-group-item" href="#enrolled_devices" role="tab"
|
|
||||||
data-toggle="tab" aria-controls="enrolled_devices">Enrolled Devices</a>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
{{#defineZone "user-enrolled-devices"}}
|
|
||||||
<div class="media-body add-padding-left-5x remove-padding-xs tab-content">
|
|
||||||
<div class="panel-group tab-content">
|
|
||||||
<div class="panel panel-default tab-pane active" id="enrolled_devices"
|
|
||||||
role="tabpanel" aria-labelledby="enrolled_devices">
|
|
||||||
<div class="panel-heading">Enrolled Devices by
|
|
||||||
{{#if user.firstname}}
|
|
||||||
{{user.firstname}} {{user.lastname}}
|
|
||||||
{{else}}
|
|
||||||
{{user.username}}
|
|
||||||
{{/if}}
|
|
||||||
</div>
|
|
||||||
<div class="panel-body">
|
|
||||||
<div id="enrolled_devices-container">
|
|
||||||
<div class="panel-body">
|
|
||||||
{{#each devices}}
|
|
||||||
<div class="wr-list-group wr-sortable policy-list">
|
|
||||||
<span class="list-group-item" id="{{id}}">
|
<span class="list-group-item" id="{{id}}">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-lg-3 clearfix">
|
<div class="col-lg-3 clearfix">
|
||||||
@ -155,19 +160,19 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
{{/each}}
|
{{/each}}
|
||||||
|
</div>
|
||||||
|
<br class="c-both"/>
|
||||||
</div>
|
</div>
|
||||||
<br class="c-both"/>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
{{/defineZone}}
|
||||||
{{/defineZone}}
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
{{else}}
|
||||||
{{else}}
|
|
||||||
<h1 class="page-sub-title">
|
<h1 class="page-sub-title">
|
||||||
Permission Denied
|
Permission Denied
|
||||||
</h1>
|
</h1>
|
||||||
|
|||||||
@ -20,6 +20,7 @@ function onRequest(context) {
|
|||||||
var userModule = require("/app/modules/business-controllers/user.js")["userModule"];
|
var userModule = require("/app/modules/business-controllers/user.js")["userModule"];
|
||||||
var username = request.getParameter("username");
|
var username = request.getParameter("username");
|
||||||
var user = userModule.getUser(username)["content"];
|
var user = userModule.getUser(username)["content"];
|
||||||
|
var deviceMgtProps = require("/app/modules/conf-reader/main.js")["conf"];
|
||||||
|
|
||||||
var userName = request.getParameter("username");
|
var userName = request.getParameter("username");
|
||||||
|
|
||||||
@ -45,5 +46,8 @@ function onRequest(context) {
|
|||||||
if (userModule.isAuthorized("/permission/admin/device-mgt/users/view")) {
|
if (userModule.isAuthorized("/permission/admin/device-mgt/users/view")) {
|
||||||
canView = true;
|
canView = true;
|
||||||
}
|
}
|
||||||
return {"user": user, "userRoles": userRoles, "devices": devices, "canView": canView};
|
|
||||||
|
var isCloud = deviceMgtProps.isCloud;
|
||||||
|
|
||||||
|
return {"user": user, "userRoles": userRoles, "devices": devices, "canView": canView, "isCloud" : isCloud};
|
||||||
}
|
}
|
||||||
|
|||||||
@ -35,6 +35,7 @@
|
|||||||
{{/zone}}
|
{{/zone}}
|
||||||
|
|
||||||
{{#zone "navbarActions"}}
|
{{#zone "navbarActions"}}
|
||||||
|
{{#unless isCloud}}
|
||||||
<li>
|
<li>
|
||||||
<!--suppress HtmlUnknownTarget -->
|
<!--suppress HtmlUnknownTarget -->
|
||||||
<a href="{{@app.context}}/user/add">
|
<a href="{{@app.context}}/user/add">
|
||||||
@ -45,18 +46,21 @@
|
|||||||
Add User
|
Add User
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
{{/unless}}
|
||||||
{{/zone}}
|
{{/zone}}
|
||||||
|
|
||||||
{{#zone "content"}}
|
{{#zone "content"}}
|
||||||
<input type="hidden" id="user" value="{{user.username}}">
|
<input type="hidden" id="user" value="{{user.username}}">
|
||||||
<!-- content -->
|
<!-- content -->
|
||||||
<div id="loading-content" class="col-centered">
|
<div id="loading-content" class="col-centered">
|
||||||
{{#if canManage}}
|
{{#unless isCloud}}
|
||||||
<input type="hidden" id="can-remove" value="true"/>
|
{{#if canManage}}
|
||||||
<input type="hidden" id="can-edit" value="true"/>
|
<input type="hidden" id="can-remove" value="true"/>
|
||||||
<input type="hidden" id="can-invite" value="true"/>
|
<input type="hidden" id="can-edit" value="true"/>
|
||||||
<input type="hidden" id="can-reset-password" value="true"/>
|
<input type="hidden" id="can-invite" value="true"/>
|
||||||
{{/if}}
|
<input type="hidden" id="can-reset-password" value="true"/>
|
||||||
|
{{/if}}
|
||||||
|
{{/unless}}
|
||||||
{{#if canView}}
|
{{#if canView}}
|
||||||
<input type="hidden" id="can-view" value="true"/>
|
<input type="hidden" id="can-view" value="true"/>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
@ -108,14 +112,16 @@
|
|||||||
Enter new password
|
Enter new password
|
||||||
<br><br>
|
<br><br>
|
||||||
<div>
|
<div>
|
||||||
<input type="password" autocomplete="off" class="form-control modal-input operationDataKeys new-password"
|
<input type="password" autocomplete="off"
|
||||||
|
class="form-control modal-input operationDataKeys new-password"
|
||||||
data-key="message"/>
|
data-key="message"/>
|
||||||
</div>
|
</div>
|
||||||
<br>
|
<br>
|
||||||
Retype new password
|
Retype new password
|
||||||
<br><br>
|
<br><br>
|
||||||
<div>
|
<div>
|
||||||
<input type="password" autocomplete="off" class="form-control modal-input operationDataKeys confirmed-password"
|
<input type="password" autocomplete="off"
|
||||||
|
class="form-control modal-input operationDataKeys confirmed-password"
|
||||||
data-key="message"/>
|
data-key="message"/>
|
||||||
</div>
|
</div>
|
||||||
<br>
|
<br>
|
||||||
|
|||||||
@ -33,6 +33,7 @@ function onRequest(context) {
|
|||||||
|
|
||||||
page["currentUser"] = userModule.getCarbonUser().username;
|
page["currentUser"] = userModule.getCarbonUser().username;
|
||||||
page["adminUser"] = deviceMgtProps["adminUser"].split("@")[0];
|
page["adminUser"] = deviceMgtProps["adminUser"].split("@")[0];
|
||||||
|
page["isCloud"] = deviceMgtProps["isCloud"];
|
||||||
|
|
||||||
if (userModule.isAuthorized("/permission/admin/device-mgt/users/manage")) {
|
if (userModule.isAuthorized("/permission/admin/device-mgt/users/manage")) {
|
||||||
page.canManage = true;
|
page.canManage = true;
|
||||||
|
|||||||
@ -29,80 +29,80 @@
|
|||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
<li class="visible-inline-block">
|
<!--<li class="visible-inline-block">-->
|
||||||
|
|
||||||
<a href="#" target="_blank" class="dropdown" data-toggle="dropdown" title="Account">
|
<!--<a href="#" target="_blank" class="dropdown" data-toggle="dropdown" title="Account">-->
|
||||||
|
|
||||||
<span class="icon fw-stack fw-lg" style="color: red">
|
<!--<span class="icon fw-stack fw-lg" style="color: red">-->
|
||||||
<i class="fw fw-resource fw-stack-1x" title="Account"></i>
|
<!--<i class="fw fw-resource fw-stack-1x" title="Account"></i>-->
|
||||||
</span>
|
<!--</span>-->
|
||||||
<span class="hidden-xs" style="color: red">
|
<!--<span class="hidden-xs" style="color: red">-->
|
||||||
Trial – 14 days to upgrade
|
<!--Trial – 14 days to upgrade-->
|
||||||
</span>
|
<!--</span>-->
|
||||||
|
|
||||||
<span class="caret"></span>
|
<!--<span class="caret"></span>-->
|
||||||
</a>
|
<!--</a>-->
|
||||||
|
|
||||||
<ul class="dropdown-menu dropdown-menu-right float-remove-xs position-static-xs text-center-xs remove-margin-xs slideInDown"
|
<!--<ul class="dropdown-menu dropdown-menu-right float-remove-xs position-static-xs text-center-xs remove-margin-xs slideInDown"-->
|
||||||
role="menu">
|
<!--role="menu">-->
|
||||||
|
|
||||||
<li>
|
<!--<li>-->
|
||||||
<a title="Upgrade Now"
|
<!--<a title="Upgrade Now"-->
|
||||||
href="{{upgradeNowURL}}"
|
<!--href="{{upgradeNowURL}}"-->
|
||||||
target="_self">
|
<!--target="_self">-->
|
||||||
<i class="fw fw-export" title="Upgrade Now"></i> Upgrade Now
|
<!--<i class="fw fw-export" title="Upgrade Now"></i> Upgrade Now-->
|
||||||
</a>
|
<!--</a>-->
|
||||||
</li>
|
<!--</li>-->
|
||||||
|
|
||||||
<li>
|
<!--<li>-->
|
||||||
<a title="Monetization"
|
<!--<a title="Monetization"-->
|
||||||
href="{{monetizationURL}}"
|
<!--href="{{monetizationURL}}"-->
|
||||||
target="_self">
|
<!--target="_self">-->
|
||||||
<i class="fa fa-money fa-lg" title="Monetization"></i> Monetization
|
<!--<i class="fa fa-money fa-lg" title="Monetization"></i> Monetization-->
|
||||||
</a>
|
<!--</a>-->
|
||||||
</li>
|
<!--</li>-->
|
||||||
|
|
||||||
<li>
|
<!--<li>-->
|
||||||
<a title="Request Extension"
|
<!--<a title="Request Extension"-->
|
||||||
href="{{requestExtensionURL}}"
|
<!--href="{{requestExtensionURL}}"-->
|
||||||
target="_blank">
|
<!--target="_blank">-->
|
||||||
<i class="fw fw-mail" title="Request Extension"></i> Request Extension
|
<!--<i class="fw fw-mail" title="Request Extension"></i> Request Extension-->
|
||||||
</a>
|
<!--</a>-->
|
||||||
</li>
|
<!--</li>-->
|
||||||
|
|
||||||
</ul>
|
<!--</ul>-->
|
||||||
</li>
|
<!--</li>-->
|
||||||
|
|
||||||
<li class="visible-inline-block">
|
<!--<li class="visible-inline-block">-->
|
||||||
|
|
||||||
<a href="#" target="null" class="dropdown" data-toggle="dropdown" title="App Management">
|
<!--<a href="#" target="null" class="dropdown" data-toggle="dropdown" title="App Management">-->
|
||||||
<span class="icon fw-stack fw-lg">
|
<!--<span class="icon fw-stack fw-lg">-->
|
||||||
<i class="fw fw-settings fw-stack-1x" title="App Management"></i>
|
<!--<i class="fw fw-settings fw-stack-1x" title="App Management"></i>-->
|
||||||
</span>
|
<!--</span>-->
|
||||||
<span class="hidden-xs">
|
<!--<span class="hidden-xs">-->
|
||||||
App Management
|
<!--App Management-->
|
||||||
</span>
|
<!--</span>-->
|
||||||
<span class="caret"></span>
|
<!--<span class="caret"></span>-->
|
||||||
</a>
|
<!--</a>-->
|
||||||
|
|
||||||
<ul class="dropdown-menu dropdown-menu-right float-remove-xs position-static-xs text-center-xs remove-margin-xs slideInDown"
|
<!--<ul class="dropdown-menu dropdown-menu-right float-remove-xs position-static-xs text-center-xs remove-margin-xs slideInDown"-->
|
||||||
role="menu">
|
<!--role="menu">-->
|
||||||
<li class="visible-inline-block">
|
<!--<li class="visible-inline-block">-->
|
||||||
<a title="Mobile App Publisher" href="{{publisherURL}}"
|
<!--<a title="Mobile App Publisher" href="{{publisherURL}}"-->
|
||||||
target="_self">
|
<!--target="_self">-->
|
||||||
<i class="fw fw-user" title="Mobilr App Publisher"></i> App Publisher
|
<!--<i class="fw fw-user" title="Mobilr App Publisher"></i> App Publisher-->
|
||||||
</a>
|
<!--</a>-->
|
||||||
</li>
|
<!--</li>-->
|
||||||
|
|
||||||
<li class="visible-inline-block">
|
<!--<li class="visible-inline-block">-->
|
||||||
<a title="App Store " href="{{storeURL}}"
|
<!--<a title="App Store " href="{{storeURL}}"-->
|
||||||
target="_self">
|
<!--target="_self">-->
|
||||||
<i class="fw fw-store" title="App Store"></i> App Store
|
<!--<i class="fw fw-store" title="App Store"></i> App Store-->
|
||||||
</a>
|
<!--</a>-->
|
||||||
</li>
|
<!--</li>-->
|
||||||
|
|
||||||
</ul>
|
<!--</ul>-->
|
||||||
</li>
|
<!--</li>-->
|
||||||
|
|
||||||
<li class="visible-inline-block">
|
<li class="visible-inline-block">
|
||||||
<a href="{{contactUsURL}}" target="_self"
|
<a href="{{contactUsURL}}" target="_self"
|
||||||
|
|||||||
@ -18,8 +18,8 @@
|
|||||||
|
|
||||||
{{#if isCloud}}
|
{{#if isCloud}}
|
||||||
{{#zone "productName"}}WSO2 Cloud{{/zone}}
|
{{#zone "productName"}}WSO2 Cloud{{/zone}}
|
||||||
{{#zone "productNameResponsive"}}WSO2 Cloud{{/zone}}
|
{{#zone "productNameResponsive"}} Cloud{{/zone}}
|
||||||
{{else}}
|
{{else}}
|
||||||
{{#zone "productName"}}WSO2 IoT Server{{/zone}}
|
{{#zone "productName"}}WSO2 IoT Server{{/zone}}
|
||||||
{{#zone "productNameResponsive"}}WSO2 IoT Server{{/zone}}
|
{{#zone "productNameResponsive"}} IoT Server{{/zone}}
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
|||||||
@ -30,6 +30,8 @@
|
|||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
|
||||||
|
{{#unless isCloud}}
|
||||||
{{#if permissions.VIEW_DASHBOARD}}
|
{{#if permissions.VIEW_DASHBOARD}}
|
||||||
<li>
|
<li>
|
||||||
<a href="javascript:statisticLoad('/portal/t/{{currentUser.domain}}/dashboards/device-statistics-dashboard/')">
|
<a href="javascript:statisticLoad('/portal/t/{{currentUser.domain}}/dashboards/device-statistics-dashboard/')">
|
||||||
@ -57,6 +59,9 @@
|
|||||||
</div>
|
</div>
|
||||||
</li>
|
</li>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
{{/unless}}
|
||||||
|
|
||||||
|
|
||||||
{{#if permissions.LIST_GROUPS}}
|
{{#if permissions.LIST_GROUPS}}
|
||||||
<li>
|
<li>
|
||||||
<a href="{{@app.context}}/groups">
|
<a href="{{@app.context}}/groups">
|
||||||
@ -81,6 +86,8 @@
|
|||||||
{{#if permissions.LIST_POLICIES}}
|
{{#if permissions.LIST_POLICIES}}
|
||||||
<li><a href="{{@app.context}}/policies"><i class="fw fw-policy"></i>Policy Management</a></li>
|
<li><a href="{{@app.context}}/policies"><i class="fw fw-policy"></i>Policy Management</a></li>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
|
||||||
|
{{#unless isCloud}}
|
||||||
{{#if permissions.TENANT_CONFIGURATION}}
|
{{#if permissions.TENANT_CONFIGURATION}}
|
||||||
<li><a><i class="fw fw-settings"></i>Configuration Management</a>
|
<li><a><i class="fw fw-settings"></i>Configuration Management</a>
|
||||||
<ul>
|
<ul>
|
||||||
@ -92,6 +99,10 @@
|
|||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
{{/unless}}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
{{/zone}}
|
{{/zone}}
|
||||||
|
|
||||||
{{#zone "navbarCollapsableRightItems"}}
|
{{#zone "navbarCollapsableRightItems"}}
|
||||||
|
|||||||
@ -52,6 +52,7 @@ function onRequest(context) {
|
|||||||
context["isAuthorizedForNotifications"] = isAuthorizedForNotifications;
|
context["isAuthorizedForNotifications"] = isAuthorizedForNotifications;
|
||||||
context["currentUser"] = currentUser;
|
context["currentUser"] = currentUser;
|
||||||
context["appContext"] = mdmProps["appContext"];
|
context["appContext"] = mdmProps["appContext"];
|
||||||
|
context["isCloud"] = mdmProps["isCloud"];
|
||||||
|
|
||||||
return context;
|
return context;
|
||||||
}
|
}
|
||||||
Loading…
Reference in New Issue
Block a user