2 * Copyright 2017 Huawei Technologies Co., Ltd.
\r
4 * Licensed under the Apache License, Version 2.0 (the "License");
\r
5 * you may not use this file except in compliance with the License.
\r
6 * You may obtain a copy of the License at
\r
8 * http://www.apache.org/licenses/LICENSE-2.0
\r
10 * Unless required by applicable law or agreed to in writing, software
\r
11 * distributed under the License is distributed on an "AS IS" BASIS,
\r
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
\r
13 * See the License for the specific language governing permissions and
\r
14 * limitations under the License.
\r
21 * @name app.controller:HomeCtrl
\r
24 * Controller of the app
\r
28 .module('vnfmarket')
\r
29 .controller('functionalTestOnboardingCtrl', functionalTest);
\r
31 functionalTest.$inject = [ 'vnfConfig', 'baseUrlConfig', '$mdDialog', 'functionalTestService', '$stateParams'];
\r
35 * Using function declarations
\r
36 * and bindable members up top.
\r
39 function functionalTest(vnfConfig, baseUrlConfig, $mdDialog, functionalTestService,$stateParams) {
\r
41 vm.csarId = $stateParams.csarId;
\r
42 console.log("functionalTest")
\r
48 vm.listViewActions = {
\r
52 vm.pagination = [5, 10, 15, {
\r
55 return vm.validations.length ? vm.validations.length : 0;
\r
59 vm.paginationQuery = {
\r
65 vm.paginationOptions = {
\r
69 //autoSelect: false,
\r
71 largeEditDialog: false,
\r
76 vm.getvalidations = function(){
\r
77 console.log(vm.functionalTests)
\r
81 vm.hide = function(answer) {
\r
82 $mdDialog.hide(answer);
\r
87 vm.getFunctionTestDetails = function() {
\r
88 functionalTestService.getFunctionTestDetails(vm.csarId).then(function(response){
\r
89 vm.validations = response.data;
\r
93 vm.getFunctionTestDetails();
\r
95 vm.cancel = function() {
\r