diff options
author | Serena Feng <feng.xiaowei@zte.com.cn> | 2017-11-21 02:13:12 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@opnfv.org> | 2017-11-21 02:13:12 +0000 |
commit | b8c925baa4f00185d5465e6f85ebce832c0c41f6 (patch) | |
tree | 8d96b1e2d47cd6b55433e97fe3c4760f9d2e4398 /testapi/3rd_party/static | |
parent | 4dced360ffbde66755ec49715db8fd876fa11d09 (diff) | |
parent | 141e16fcbdcacc02ff30d861bf76082b51d4c287 (diff) |
Merge "Update and Delete functionalities for projects"
Diffstat (limited to 'testapi/3rd_party/static')
5 files changed, 21 insertions, 2 deletions
diff --git a/testapi/3rd_party/static/testapi-ui/Gruntfile.js b/testapi/3rd_party/static/testapi-ui/Gruntfile.js index f82269e..13f484f 100644 --- a/testapi/3rd_party/static/testapi-ui/Gruntfile.js +++ b/testapi/3rd_party/static/testapi-ui/Gruntfile.js @@ -14,7 +14,9 @@ module.exports = function (grunt) { base: './', middleware: function(connect, options, middlewares) { middlewares.unshift(function(req, res, next) { - if (req.method.toUpperCase() == 'POST') req.method='GET'; + if (req.method.toUpperCase() == 'POST' || req.method.toUpperCase() == "PUT"){ + req.method='GET'; + } return next(); }); return middlewares; @@ -118,6 +120,7 @@ module.exports = function (grunt) { coverageDir: '../../../opnfv_testapi/tests/UI/coverage', args: { specs: ['../../../opnfv_testapi/tests/UI/e2e/podsControllerSpec.js', + '../../../opnfv_testapi/tests/UI/e2e/projectsControllerSpec.js', '../../../opnfv_testapi/tests/UI/e2e/projectControllerSpec.js'] } }, diff --git a/testapi/3rd_party/static/testapi-ui/app.js b/testapi/3rd_party/static/testapi-ui/app.js index 0b35162..dbb56a6 100644 --- a/testapi/3rd_party/static/testapi-ui/app.js +++ b/testapi/3rd_party/static/testapi-ui/app.js @@ -69,6 +69,11 @@ templateUrl: 'testapi-ui/components/projects/projects.html', controller: 'ProjectsController as ctrl' }). + state('project', { + url: '/projects/:name', + templateUrl: 'testapi-ui/components/projects/project/project.html', + controller: 'ProjectController as ctrl' + }). state('communityResults', { url: '/community_results', templateUrl: 'testapi-ui/components/results/results.html', diff --git a/testapi/3rd_party/static/testapi-ui/index.html b/testapi/3rd_party/static/testapi-ui/index.html index 45162dc..ac29aca 100644 --- a/testapi/3rd_party/static/testapi-ui/index.html +++ b/testapi/3rd_party/static/testapi-ui/index.html @@ -47,6 +47,7 @@ <script src="testapi-ui/components/auth-failure/authFailureController.js"></script> <script src="testapi-ui/components/logout/logoutController.js"></script> <script src="testapi-ui/components/projects/projectsController.js"></script> + <script src="testapi-ui/components/projects/project/projectController.js"></script> <!-- Filters --> <script src="testapi-ui/shared/filters.js"></script> diff --git a/testapi/3rd_party/static/testapi-ui/shared/alerts/confirmModal.html b/testapi/3rd_party/static/testapi-ui/shared/alerts/confirmModal.html index 82478a5..e5397e0 100644 --- a/testapi/3rd_party/static/testapi-ui/shared/alerts/confirmModal.html +++ b/testapi/3rd_party/static/testapi-ui/shared/alerts/confirmModal.html @@ -1,11 +1,21 @@ <div class="modal-header"><h3 class="modal-title">Confirm</h3></div> <div class="modal-body"> + <div class="confirm" ng-class="{ 'hidden': confirmModal.data.text=='Delete' }"> <div class="form-group"> <label for="confirmText">{{confirmModal.data.text}}:</label> <textarea type="text" class="form-control" rows="5" ng-model="confirmModal.inputText" id="confirmText"> </textarea> </div> + </div> + <div class="Delete" ng-class="{ 'hidden': confirmModal.data.text!='Delete' }"> + <div class="form-group"> + <label for="confirmText"> You are about to delete.</label> + <br> + Do you want to proceed? + </div> + </div> + </div> <div class="modal-footer"> <button class="btn btn-primary" ng-click="confirmModal.confirm()">Ok</button> diff --git a/testapi/3rd_party/static/testapi-ui/shared/alerts/confirmModalFactory.js b/testapi/3rd_party/static/testapi-ui/shared/alerts/confirmModalFactory.js index 76c74df..aba205e 100644 --- a/testapi/3rd_party/static/testapi-ui/shared/alerts/confirmModalFactory.js +++ b/testapi/3rd_party/static/testapi-ui/shared/alerts/confirmModalFactory.js @@ -13,7 +13,7 @@ function confirmModal($uibModal) { return function(text, successHandler) { $uibModal.open({ - templateUrl: '/shared/alerts/confirmModal.html', + templateUrl: '/testapi-ui/shared/alerts/confirmModal.html', controller: 'CustomConfirmModalController as confirmModal', size: 'md', resolve: { |