diff options
Diffstat (limited to 'testapi/opnfv_testapi')
4 files changed, 13 insertions, 23 deletions
diff --git a/testapi/opnfv_testapi/handlers/sign_handlers.py b/testapi/opnfv_testapi/handlers/sign_handlers.py index 7540662..2039971 100644 --- a/testapi/opnfv_testapi/handlers/sign_handlers.py +++ b/testapi/opnfv_testapi/handlers/sign_handlers.py @@ -46,7 +46,7 @@ class SigninReturnHandler(SignBaseHandler): dbapi.db_update(self.table, q_user, login_user) self.clear_cookie(constants.TESTAPI_ID) - self.set_secure_cookie(constants.TESTAPI_ID, user) + self.set_secure_cookie(constants.TESTAPI_ID, user, 1) self.redirect(url=CONF.ui_url) diff --git a/testapi/opnfv_testapi/ui/components/projects/project/project.html b/testapi/opnfv_testapi/ui/components/projects/project/project.html index b6a751c..2762fff 100644 --- a/testapi/opnfv_testapi/ui/components/projects/project/project.html +++ b/testapi/opnfv_testapi/ui/components/projects/project/project.html @@ -16,25 +16,11 @@ <div class="table-responsive"> <table class="table" ng-data="ctrl.data.pods"> <tbody> - <tr style="padding:9px"> - <td class="podsTableTd">Id :</td> - <td class="podsTableLeftTd">{{ctrl.data._id}}</td> + <tr ng-repeat-start="(index, detail) in ctrl.data_field" style="padding:9px"> + <td class="podsTableTd">{{detail | capitalize}} :</td> + <td width="85%" class="podsTableLeftTd">{{ctrl.data[index]}}</td> </tr> - <tr style="padding:9px"> - <td class="podsTableTd">Name :</td> - <td width="90%" class="podsTableLeftTd">{{ctrl.data.name}}</td> - </tr> - <tr style="padding:9px"> - <td class="podsTableTd">Creator :</td> - <td width="90%" class="podsTableLeftTd">{{ctrl.data.creator}}</td> - </tr> - <tr style="padding:9px"> - <td class="podsTableTd">Created at :</td> - <td width="90%" class="podsTableLeftTd">{{ctrl.data['creation_date']}}</td> - </tr> - <tr style="padding:9px"> - <td class="podsTableTd">Description :</td> - <td width="90%" class="podsTableLeftTd">{{ctrl.data.description}}</td> + <tr ng-repeat-end=> </tr> </tbody> </table> diff --git a/testapi/opnfv_testapi/ui/components/projects/project/projectController.js b/testapi/opnfv_testapi/ui/components/projects/project/projectController.js index 78b805d..9dc9e27 100644 --- a/testapi/opnfv_testapi/ui/components/projects/project/projectController.js +++ b/testapi/opnfv_testapi/ui/components/projects/project/projectController.js @@ -21,7 +21,7 @@ ProjectController.$inject = [ '$scope', '$http', '$filter', '$state', '$window', '$uibModal', 'testapiApiUrl','raiseAlert', - 'confirmModal' + 'confirmModal', 'dataFieldService' ]; /** @@ -30,12 +30,13 @@ * through projects declared in TestAPI. */ function ProjectController($scope, $http, $filter, $state, $window, $uibModal, testapiApiUrl, - raiseAlert, confirmModal) { + raiseAlert, confirmModal, dataFieldService) { var ctrl = this; ctrl.name = $state.params['name']; ctrl.url = testapiApiUrl + '/projects/' + ctrl.name; ctrl.loadDetails = loadDetails; + ctrl.data_field = {} /** * This will contact the TestAPI to get a listing of declared projects. @@ -45,6 +46,7 @@ ctrl.projectsRequest = $http.get(ctrl.url).success(function (data) { ctrl.data = data; + ctrl.data_field = dataFieldService.dataFunction(ctrl.data, ctrl.data_field) }).catch(function (error) { ctrl.data = null; ctrl.showError = true; diff --git a/testapi/opnfv_testapi/ui/components/scenarios/modals/customModal.html b/testapi/opnfv_testapi/ui/components/scenarios/modals/customModal.html index 0cd2663..4225749 100644 --- a/testapi/opnfv_testapi/ui/components/scenarios/modals/customModal.html +++ b/testapi/opnfv_testapi/ui/components/scenarios/modals/customModal.html @@ -6,14 +6,16 @@ <legend>{{customModalCtrl.data.text}}</legend> <div class="row"> <div class="update-project"> - <label for="cpid" class="control-label col-sm-4">Custom: </label> + <label for="cpid" class="control-label col-sm-2">Custom: </label> <table cellpadding="0" cellspacing="0"> <tbody> <tr> <td> <div class="col-sm-12"> <input type="text" class="form-control" ng-model="customModalCtrl.custom"/> - <p class="help-block"></p> + <p class="help-block"> + Please separate multiple customs with space or comma + </p> </div> </td> </tr> |