diff options
Diffstat (limited to 'cvp')
3 files changed, 11 insertions, 4 deletions
diff --git a/cvp/3rd_party/static/testapi-ui/components/results/results.html b/cvp/3rd_party/static/testapi-ui/components/results/results.html index 8d7e4482..f53023d9 100644 --- a/cvp/3rd_party/static/testapi-ui/components/results/results.html +++ b/cvp/3rd_party/static/testapi-ui/components/results/results.html @@ -29,6 +29,7 @@ <th>Status</th> <th>Log</th> <th>SUT</th> + <th>SUT Version</th> <th class="col-md-2">Operation</th> <th class="col-md-2">Share List</th> </tr> @@ -40,10 +41,11 @@ <td><a uib-tooltip="{{ result.id }}" tooltip-placement="top" tooltip-append-to-body="true" ng-click="ctrl.gotoResultDetail(result.id, result._id)">{{ result.id | limitTo:8 }}</a></td> <td>{{ result.owner }}</td> <td>{{ result.filename || "None"}}</td> - <td><div class="popover-wrapper"><a editable-theme="bs3" onbeforesave="ctrl.changeLabel(result, $data)" editable-text="result.label"> {{ result.label || "None" }}</a></div></td> + <td><div class="popover-wrapper"><a editable-theme="bs3" onbeforesave="ctrl.changeLabel(result, 'label', $data)" editable-text="result.label"> {{ result.label || "None" }}</a></div></td> <td>{{ result.status }}</td> <td><a ng-click="ctrl.downloadLogs(result.id)">logs</a></td> <td><a ng-click="ctrl.gotoSUT(result.id)">info</a></td> + <td><div class="popover-wrapper"><a editable-theme="bs3" onbeforesave="ctrl.changeLabel(result, 'sut_label', $data)" editable-text="result.sut_label"> {{ result.sut_label || "None" }}</a></div></td> <td> <div class="btn-group" uib-dropdown> <a id="single-button" type="button" class="btn btn-success cvp-btn medium accent-color regular-button" uib-dropdown-toggle> diff --git a/cvp/3rd_party/static/testapi-ui/components/results/resultsController.js b/cvp/3rd_party/static/testapi-ui/components/results/resultsController.js index 0b0bbbc8..aa593dc0 100644 --- a/cvp/3rd_party/static/testapi-ui/components/results/resultsController.js +++ b/cvp/3rd_party/static/testapi-ui/components/results/resultsController.js @@ -191,12 +191,12 @@ }); } - function changeLabel(result, data){ - toggleCheck(result, 'label', data); + function changeLabel(result, key, data){ + toggleCheck(result, key, data); } function toReview(result, value){ - var resp = confirm('Once you submit a test result for review, it will become readable to all CVP reviewers. Do you want to proceed?'); + var resp = confirm('Once you submit a test result for review, it will become readable to all OVP reviewers. Do you want to proceed?'); if(resp){ toggleCheck(result, 'status', value); } diff --git a/cvp/opnfv_testapi/resources/test_handlers.py b/cvp/opnfv_testapi/resources/test_handlers.py index 2b5f28c2..b28a15d3 100644 --- a/cvp/opnfv_testapi/resources/test_handlers.py +++ b/cvp/opnfv_testapi/resources/test_handlers.py @@ -218,6 +218,11 @@ class TestsGURHandler(GenericTestHandler): self.finish_request({'code': 403, 'msg': msg}) return + if not test['sut_label']: + msg = 'Please fill out SUT version before submission' + self.finish_request({'code': 403, 'msg': msg}) + return + query['owner'] = curr_user db_keys.append('owner') |