summaryrefslogtreecommitdiffstats
path: root/testapi
diff options
context:
space:
mode:
authorSerena Feng <feng.xiaowei@zte.com.cn>2017-09-05 12:08:46 +0000
committerGerrit Code Review <gerrit@opnfv.org>2017-09-05 12:08:46 +0000
commit70b35ca066dc67e1756125020c209ced08040521 (patch)
tree1085de6160e71f35701e0ac34f9191d0670e8311 /testapi
parent568ec7d2bbc8b63c1dd613eec75cec1539b7bab2 (diff)
parentd2ef79fe576e34a5c1a4370c1b5b3f47f492d33b (diff)
Merge "hide create_pod function from anonymous user"
Diffstat (limited to 'testapi')
-rw-r--r--testapi/3rd_party/static/testapi-ui/components/pods/pods.html10
-rw-r--r--testapi/3rd_party/static/testapi-ui/components/pods/podsController.js5
2 files changed, 8 insertions, 7 deletions
diff --git a/testapi/3rd_party/static/testapi-ui/components/pods/pods.html b/testapi/3rd_party/static/testapi-ui/components/pods/pods.html
index 7ce36ca..e366670 100644
--- a/testapi/3rd_party/static/testapi-ui/components/pods/pods.html
+++ b/testapi/3rd_party/static/testapi-ui/components/pods/pods.html
@@ -1,8 +1,12 @@
-<h3>{{ctrl.pageHeader}}</h3>
-<p>{{ctrl.pageParagraph}}</p>
+<h3>Pods</h3>
+<p>This page is used to create or query pods.<br>
+ Querying pods is open to everybody.<br>
+ But only login users are granted the privilege to create the new pod.
+</p>
+
<div class="row" style="margin-bottom:24px;"></div>
-<div class="pod-create">
+<div class="pod-create" ng-class="{ 'hidden': ! auth.isAuthenticated }">
<h4>Create</h4>
<div class="row">
<div ng-repeat="require in ctrl.createRequirements">
diff --git a/testapi/3rd_party/static/testapi-ui/components/pods/podsController.js b/testapi/3rd_party/static/testapi-ui/components/pods/podsController.js
index 2012586..894fcc1 100644
--- a/testapi/3rd_party/static/testapi-ui/components/pods/podsController.js
+++ b/testapi/3rd_party/static/testapi-ui/components/pods/podsController.js
@@ -20,7 +20,7 @@
.controller('PodsController', PodsController);
PodsController.$inject = [
- '$scope', '$http', '$filter', '$state', 'testapiApiUrl','raiseAlert'
+ '$rootScope', '$scope', '$http', '$filter', '$state', 'testapiApiUrl','raiseAlert'
];
/**
@@ -52,9 +52,6 @@
ctrl.mode = 'metal';
ctrl.details = '';
- ctrl.pageHeader = 'Pods';
- ctrl.pageParagraph = 'This page is used to create or query pods.';
-
/**
* This is called when the date filter calendar is opened. It
* does some event handling, and sets a scope variable so the UI