summaryrefslogtreecommitdiffstats
path: root/base/tps/shared/webapps/tps/ui
diff options
context:
space:
mode:
authorEndi S. Dewata <edewata@redhat.com>2015-04-10 22:51:22 -0400
committerEndi S. Dewata <edewata@redhat.com>2015-04-17 13:31:57 -0400
commitf79bb45a68c542fd0647f9b84a090e05f30bb565 (patch)
treedb87ad0724c58671e7e09f6a378220874098eaed /base/tps/shared/webapps/tps/ui
parent7e58da6db8570e8472f5d76d0f50563f3c0e1970 (diff)
downloadpki-f79bb45a68c542fd0647f9b84a090e05f30bb565.tar.gz
pki-f79bb45a68c542fd0647f9b84a090e05f30bb565.tar.xz
pki-f79bb45a68c542fd0647f9b84a090e05f30bb565.zip
Fixed action menu in TPS UI.
The TPS UI has been modified to display the appropriate actions menu based on the roles of the user. TPS agent can only enable and disable profiles, and also approve or reject pending requests. TPS admin can only edit disabled profiles, then submit it for approval, or cancel the request. https://fedorahosted.org/pki/ticket/1292
Diffstat (limited to 'base/tps/shared/webapps/tps/ui')
-rw-r--r--base/tps/shared/webapps/tps/ui/audit.html9
-rw-r--r--base/tps/shared/webapps/tps/ui/authenticator.html21
-rw-r--r--base/tps/shared/webapps/tps/ui/config.html14
-rw-r--r--base/tps/shared/webapps/tps/ui/connector.html21
-rw-r--r--base/tps/shared/webapps/tps/ui/group.html6
-rw-r--r--base/tps/shared/webapps/tps/ui/home.html14
-rw-r--r--base/tps/shared/webapps/tps/ui/index.html4
-rw-r--r--base/tps/shared/webapps/tps/ui/profile-mapping.html21
-rw-r--r--base/tps/shared/webapps/tps/ui/profile.html21
-rw-r--r--base/tps/shared/webapps/tps/ui/token.html10
-rw-r--r--base/tps/shared/webapps/tps/ui/user.html6
11 files changed, 94 insertions, 53 deletions
diff --git a/base/tps/shared/webapps/tps/ui/audit.html b/base/tps/shared/webapps/tps/ui/audit.html
index f9da85196..06457de62 100644
--- a/base/tps/shared/webapps/tps/ui/audit.html
+++ b/base/tps/shared/webapps/tps/ui/audit.html
@@ -25,10 +25,11 @@
<span class="pki-actions">
-<span name="view" class="pki-actions-menu">
-<a name="edit" href="#">Edit</a><br>
-<a name="enable" href="#">Enable</a><a name="disable" href="#" style="display: none;">Disable</a><br>
-</span>
+<ul name="view" class="pki-actions-menu">
+<li name="edit" style="display: none;"><a href="#">Edit</a></li>
+<li name="enable" style="display: none;"><a href="#">Enable</a></li>
+<li name="disable" style="display: none;"><a href="#">Disable</a></li>
+</ul>
<span name="edit" class="pki-actions-menu" style="display: none;">
<button name="cancel">Cancel</button>
diff --git a/base/tps/shared/webapps/tps/ui/authenticator.html b/base/tps/shared/webapps/tps/ui/authenticator.html
index cde9e65c4..60fbf7cfe 100644
--- a/base/tps/shared/webapps/tps/ui/authenticator.html
+++ b/base/tps/shared/webapps/tps/ui/authenticator.html
@@ -26,10 +26,15 @@
<span class="pki-actions">
-<span name="view" class="pki-actions-menu">
-<a name="edit" href="#">Edit</a><br>
-<a name="enable" href="#">Enable</a><a name="disable" href="#" style="display: none;">Disable</a><br>
-</span>
+<ul name="view" class="pki-actions-menu">
+<li name="edit" style="display: none;"><a href="#">Edit</a></li>
+<li name="submit" style="display: none;"><a href="#">Submit</a></li>
+<li name="cancel" style="display: none;"><a href="#">Cancel</a></li>
+<li name="approve" style="display: none;"><a href="#">Approve</a></li>
+<li name="reject" style="display: none;"><a href="#">Reject</a></li>
+<li name="enable" style="display: none;"><a href="#">Enable</a></li>
+<li name="disable" style="display: none;"><a href="#">Disable</a></li>
+</ul>
<span name="edit" class="pki-actions-menu" style="display: none;">
<button name="cancel">Cancel</button>
@@ -51,16 +56,18 @@
</fieldset>
</div>
+<div name="properties">
+
<h2>Properties</h2>
-<table name="properties">
+<table name="list">
<thead>
<tr>
<th class="pki-table-actions" colspan="3">
<span name="search">
<input name="search" type="text" placeholder="Search...">
</span>
- <span class="pki-table-buttons" style="display: none;">
+ <span class="pki-table-buttons">
<button name="add">Add</button>
<button name="remove">Remove</button>
</span>
@@ -103,6 +110,8 @@
</tfoot>
</table>
+</div>
+
<div id="property-dialog" class="modal">
<div class="modal-dialog">
<div class="modal-content">
diff --git a/base/tps/shared/webapps/tps/ui/config.html b/base/tps/shared/webapps/tps/ui/config.html
index 2a8e85902..224697551 100644
--- a/base/tps/shared/webapps/tps/ui/config.html
+++ b/base/tps/shared/webapps/tps/ui/config.html
@@ -25,9 +25,9 @@
<span class="pki-actions">
-<span name="view" class="pki-actions-menu">
-<a name="edit" href="#">Edit</a><br>
-</span>
+<ul name="view" class="pki-actions-menu">
+<li name="edit"><a href="#">Edit</a></li>
+</ul>
<span name="edit" class="pki-actions-menu" style="display: none;">
<button name="cancel">Cancel</button>
@@ -38,14 +38,16 @@
</div>
-<table name="properties">
+<div name="properties">
+
+<table name="list">
<thead>
<tr>
<th class="pki-table-actions" colspan="3">
<span name="search">
<input name="search" type="text" placeholder="Search...">
</span>
- <span class="pki-table-buttons" style="display: none;">
+ <span class="pki-table-buttons">
<button name="add">Add</button>
<button name="remove">Remove</button>
</span>
@@ -88,6 +90,8 @@
</tfoot>
</table>
+</div>
+
<div id="property-dialog" class="modal">
<div class="modal-dialog">
<div class="modal-content">
diff --git a/base/tps/shared/webapps/tps/ui/connector.html b/base/tps/shared/webapps/tps/ui/connector.html
index 782c6d245..bb10f7219 100644
--- a/base/tps/shared/webapps/tps/ui/connector.html
+++ b/base/tps/shared/webapps/tps/ui/connector.html
@@ -26,10 +26,15 @@
<span class="pki-actions">
-<span name="view" class="pki-actions-menu">
-<a name="edit" href="#">Edit</a><br>
-<a name="enable" href="#">Enable</a><a name="disable" href="#" style="display: none;">Disable</a><br>
-</span>
+<ul name="view" class="pki-actions-menu">
+<li name="edit" style="display: none;"><a href="#">Edit</a></li>
+<li name="submit" style="display: none;"><a href="#">Submit</a></li>
+<li name="cancel" style="display: none;"><a href="#">Cancel</a></li>
+<li name="approve" style="display: none;"><a href="#">Approve</a></li>
+<li name="reject" style="display: none;"><a href="#">Reject</a></li>
+<li name="enable" style="display: none;"><a href="#">Enable</a></li>
+<li name="disable" style="display: none;"><a href="#">Disable</a></li>
+</ul>
<span name="edit" class="pki-actions-menu" style="display: none;">
<button name="cancel">Cancel</button>
@@ -51,16 +56,18 @@
</fieldset>
</div>
+<div name="properties">
+
<h2>Properties</h2>
-<table name="properties">
+<table name="list">
<thead>
<tr>
<th class="pki-table-actions" colspan="3">
<span name="search">
<input name="search" type="text" placeholder="Search...">
</span>
- <span class="pki-table-buttons" style="display: none;">
+ <span class="pki-table-buttons">
<button name="add">Add</button>
<button name="remove">Remove</button>
</span>
@@ -103,6 +110,8 @@
</tfoot>
</table>
+</div>
+
<div id="property-dialog" class="modal">
<div class="modal-dialog">
<div class="modal-content">
diff --git a/base/tps/shared/webapps/tps/ui/group.html b/base/tps/shared/webapps/tps/ui/group.html
index 11c9944b2..df933815f 100644
--- a/base/tps/shared/webapps/tps/ui/group.html
+++ b/base/tps/shared/webapps/tps/ui/group.html
@@ -26,9 +26,9 @@
<span class="pki-actions">
-<span name="view" class="pki-actions-menu">
-<a name="edit" href="#">Edit</a><br>
-</span>
+<ul name="view" class="pki-actions-menu">
+<li name="edit"><a href="#">Edit</a></li>
+</ul>
<span name="edit" class="pki-actions-menu" style="display: none;">
<button name="cancel">Cancel</button>
diff --git a/base/tps/shared/webapps/tps/ui/home.html b/base/tps/shared/webapps/tps/ui/home.html
index 08c467255..eb6874e50 100644
--- a/base/tps/shared/webapps/tps/ui/home.html
+++ b/base/tps/shared/webapps/tps/ui/home.html
@@ -27,8 +27,8 @@
<div class="panel-heading">
<h3 class="panel-title">Token Management</h3>
</div>
- <div class="panel-body">
- <ul class="pki-menu">
+ <div class="panel-body pki-menu">
+ <ul>
<li><a href="#tokens">Tokens</a></li>
<li><a href="#certs">Certificates</a></li>
<li><a href="#activities">Activities</a></li>
@@ -40,10 +40,10 @@
<div class="panel-heading">
<h3 class="panel-title">Account Management</h3>
</div>
- <div class="panel-body">
- <ul class="pki-menu">
+ <div class="panel-body pki-menu">
+ <ul>
<li><a href="#users">Users</a></li>
- </li><a href="#groups">Groups</a></li>
+ <li><a href="#groups">Groups</a></li>
</ul>
</div>
</div>
@@ -52,8 +52,8 @@
<div class="panel-heading">
<h3 class="panel-title">System Management</h3>
</div>
- <div class="panel-body">
- <ul class="pki-menu">
+ <div class="panel-body pki-menu">
+ <ul>
<li name="config" style="display: none;"><a href="#config">General Configuration</a></li>
<li name="authenticators" style="display: none;"><a href="#authenticators">Authentication Sources</a></li>
<li name="connectors" style="display: none;"><a href="#connectors">Subsystem Connections</a></li>
diff --git a/base/tps/shared/webapps/tps/ui/index.html b/base/tps/shared/webapps/tps/ui/index.html
index 3bda3cb40..357ade514 100644
--- a/base/tps/shared/webapps/tps/ui/index.html
+++ b/base/tps/shared/webapps/tps/ui/index.html
@@ -217,7 +217,7 @@ $(function() {
});
router.route("profiles/:id", "profile", function(id) {
- new ConfigEntryPage({
+ new ProfilePage({
el: content,
url: "profile.html",
model: new ProfileModel({ id: id })
@@ -225,7 +225,7 @@ $(function() {
});
router.route("new-profile", "new-profile", function() {
- new ConfigEntryPage({
+ new ProfilePage({
el: content,
url: "profile.html",
model: new ProfileModel(),
diff --git a/base/tps/shared/webapps/tps/ui/profile-mapping.html b/base/tps/shared/webapps/tps/ui/profile-mapping.html
index fea71ce9d..2dfbf2aa8 100644
--- a/base/tps/shared/webapps/tps/ui/profile-mapping.html
+++ b/base/tps/shared/webapps/tps/ui/profile-mapping.html
@@ -26,10 +26,15 @@
<span class="pki-actions">
-<span name="view" class="pki-actions-menu">
-<a name="edit" href="#">Edit</a><br>
-<a name="enable" href="#">Enable</a><a name="disable" href="#" style="display: none;">Disable</a><br>
-</span>
+<ul name="view" class="pki-actions-menu">
+<li name="edit" style="display: none;"><a href="#">Edit</a></li>
+<li name="submit" style="display: none;"><a href="#">Submit</a></li>
+<li name="cancel" style="display: none;"><a href="#">Cancel</a></li>
+<li name="approve" style="display: none;"><a href="#">Approve</a></li>
+<li name="reject" style="display: none;"><a href="#">Reject</a></li>
+<li name="enable" style="display: none;"><a href="#">Enable</a></li>
+<li name="disable" style="display: none;"><a href="#">Disable</a></li>
+</ul>
<span name="edit" class="pki-actions-menu" style="display: none;">
<button name="cancel">Cancel</button>
@@ -51,16 +56,18 @@
</fieldset>
</div>
+<div name="properties">
+
<h2>Properties</h2>
-<table name="properties">
+<table name="list">
<thead>
<tr>
<th class="pki-table-actions" colspan="3">
<span name="search">
<input name="search" type="text" placeholder="Search...">
</span>
- <span class="pki-table-buttons" style="display: none;">
+ <span class="pki-table-buttons">
<button name="add">Add</button>
<button name="remove">Remove</button>
</span>
@@ -103,6 +110,8 @@
</tfoot>
</table>
+</div>
+
<div id="property-dialog" class="modal">
<div class="modal-dialog">
<div class="modal-content">
diff --git a/base/tps/shared/webapps/tps/ui/profile.html b/base/tps/shared/webapps/tps/ui/profile.html
index 1720d4850..b2e90856c 100644
--- a/base/tps/shared/webapps/tps/ui/profile.html
+++ b/base/tps/shared/webapps/tps/ui/profile.html
@@ -26,10 +26,15 @@
<span class="pki-actions">
-<span name="view" class="pki-actions-menu">
-<a name="edit" href="#">Edit</a><br>
-<a name="enable" href="#">Enable</a><a name="disable" href="#" style="display: none;">Disable</a><br>
-</span>
+<ul name="view" class="pki-actions-menu">
+<li name="edit" style="display: none;"><a href="#">Edit</a></li>
+<li name="submit" style="display: none;"><a href="#">Submit</a></li>
+<li name="cancel" style="display: none;"><a href="#">Cancel</a></li>
+<li name="approve" style="display: none;"><a href="#">Approve</a></li>
+<li name="reject" style="display: none;"><a href="#">Reject</a></li>
+<li name="enable" style="display: none;"><a href="#">Enable</a></li>
+<li name="disable" style="display: none;"><a href="#">Disable</a></li>
+</ul>
<span name="edit" class="pki-actions-menu" style="display: none;">
<button name="cancel">Cancel</button>
@@ -51,16 +56,18 @@
</fieldset>
</div>
+<div name="properties">
+
<h2>Properties</h2>
-<table name="properties">
+<table name="list">
<thead>
<tr>
<th class="pki-table-actions" colspan="3">
<span name="search">
<input name="search" type="text" placeholder="Search...">
</span>
- <span class="pki-table-buttons" style="display: none;">
+ <span class="pki-table-buttons">
<button name="add">Add</button>
<button name="remove">Remove</button>
</span>
@@ -103,6 +110,8 @@
</tfoot>
</table>
+</div>
+
<div id="property-dialog" class="modal">
<div class="modal-dialog">
<div class="modal-content">
diff --git a/base/tps/shared/webapps/tps/ui/token.html b/base/tps/shared/webapps/tps/ui/token.html
index 39d54c6cd..ad681e9a0 100644
--- a/base/tps/shared/webapps/tps/ui/token.html
+++ b/base/tps/shared/webapps/tps/ui/token.html
@@ -26,11 +26,11 @@
<span class="pki-actions">
-<span name="view" class="pki-actions-menu">
-<a name="edit" href="#">Edit</a><br>
-<a name="changeStatus" href="#">Change Status</a><br>
-<a name="showCerts" href="#">Show Certificates</a><br>
-</span>
+<ul name="view" class="pki-actions-menu">
+<li name="edit"><a href="#">Edit</a></li>
+<li name="changeStatus"><a href="#">Change Status</a></li>
+<li name="showCerts"><a href="#">Show Certificates</a></li>
+</ul>
<span name="edit" class="pki-actions-menu" style="display: none;">
<button name="cancel">Cancel</button>
diff --git a/base/tps/shared/webapps/tps/ui/user.html b/base/tps/shared/webapps/tps/ui/user.html
index 9d6b0597a..9a9f9505b 100644
--- a/base/tps/shared/webapps/tps/ui/user.html
+++ b/base/tps/shared/webapps/tps/ui/user.html
@@ -26,9 +26,9 @@
<span class="pki-actions">
-<span name="view" class="pki-actions-menu">
-<a name="edit" href="#">Edit</a><br>
-</span>
+<ul name="view" class="pki-actions-menu">
+<li name="edit"><a href="#">Edit</a></li>
+</ul>
<span name="edit" class="pki-actions-menu" style="display: none;">
<button name="cancel">Cancel</button>