2 ============LICENSE_START==================================================
4 ===========================================================================
5 Copyright (C) 2017-2018 AT&T Intellectual Property. All rights reserved.
6 ===========================================================================
7 Licensed under the Apache License, Version 2.0 (the "License");
8 you may not use this file except in compliance with the License.
9 You may obtain a copy of the License at
11 http://www.apache.org/licenses/LICENSE-2.0
13 Unless required by applicable law or agreed to in writing, software
14 distributed under the License is distributed on an "AS IS" BASIS,
15 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 See the License for the specific language governing permissions and
17 limitations under the License.
18 ============LICENSE_END====================================================
20 <div ng-controller="optimizationController">
23 <div class="form-group row">
24 <div class="form-group col-sm-6">
25 <label>Policy Name:<sup><b>*</b></sup></label> <input type="text"
26 class="form-control" ng-disabled="temp.policy.readOnly"
27 ng-readonly="temp.policy.editPolicy"
28 ng-model="temp.policy.policyName" required pattern="\S+"
29 title="Enter Policy Name without any spaces and special characters and will accept _." />
31 <div class="form-group col-sm-6">
32 <label>Description:</label> <input type="text" class="form-control"
33 ng-disabled="temp.policy.readOnly"
34 ng-model="temp.policy.policyDescription"
35 title="Description field will accept any type of data."/>
38 <div class="form-group row">
39 <div class="form-group col-sm-3">
40 <label>Onap Name:<sup><b>*</b></sup></label> <select
41 class="form-control" ng-disabled="temp.policy.readOnly"
42 ng-model="temp.policy.onapName"
43 ng-options="option for option in onapNameDictionaryDatas track by option"
44 required pattern="\S+" title="Select the dropdown value driven from OnapName (common)Dictionary."></select>
46 <div class="form-group col-sm-3">
47 <label>Time to Live Date:</label> <input type="text" id="ttlDate"
48 class="form-control" name="ttlDate" ng-disabled="temp.policy.readOnly"
49 ng-model="temp.policy.ttlDate" title="Select the date from calender onclick on the field."/>
51 <div class="form-group col-sm-3">
52 <label>Guard:<sup><b>*</b></sup></label> <select
53 class="form-control" ng-disabled="temp.policy.readOnly"
54 ng-model="temp.policy.guard"
55 required pattern="\S+" title="Select the dropdown Guard value.">
57 <option>False</option></select>
59 <div class="form-group col-sm-3">
60 <label>Risk Type:<sup><b>*</b></sup></label> <select
61 class="form-control" ng-disabled="temp.policy.readOnly"
62 ng-model="temp.policy.riskType"
63 ng-options="option for option in riskTypeDictionaryDatas track by option"
64 required pattern="\S+" title="Select the dropdown value driven from RiskType (Safe Policy)Dictionary."></select>
67 <div class="form-group row">
68 <div class="form-group col-sm-3">
69 <label>Risk Level:<sup><b>*</b></sup></label> <select
70 class="form-control" ng-disabled="temp.policy.readOnly"
71 ng-model="temp.policy.riskLevel"
72 required pattern="\S+" title="Select the dropdown Risk level value.">
77 <option>5</option></select>
79 <div class="form-group col-sm-3">
80 <label>Priority:<sup><b>*</b></sup></label> <select
81 class="form-control" ng-disabled="temp.policy.readOnly"
82 ng-model="temp.policy.priority"
83 ng-options="option for option in priorityDatas track by option" title="Select the dropdown Priority value.">
84 <option value="">{{temp.policy.priority}}</option>
87 <div class="form-group col-sm-3">
88 <label>Optimization Model:<sup><b>*</b></sup></label> <select
89 class="form-control" ng-disabled="temp.policy.readOnly"
90 ng-model="temp.policy.serviceType"
91 ng-options="option for option in optimizationModelsDictionaryDatas track by option"
92 ng-init="pullVersion(temp.policy.serviceType);"
93 ng-click="pullVersion(temp.policy.serviceType);"
94 title="Select the dropdown value driven from Optimization Models (Optimization Policy)Dictionary."></select>
96 <div class="form-group col-sm-3">
97 <label>Optimization Model Version:<sup><b>*</b></sup></label> <select
98 class="form-control" ng-disabled="temp.policy.readOnly"
99 ng-model="temp.policy.version"
100 ng-options="option for option in optimizationModelsDictionaryVersionDatas track by option"
101 ng-init="addDataToFields(temp.policy.serviceType, temp.policy.version);"
102 ng-change="addDataToFields(temp.policy.serviceType, temp.policy.version);"
103 title="Select the dropdown value driven based on Optimization Models (Optimization Policy)Dictionary selection."></select>
108 <div class="form-group col-sm-12" id="DynamicTemplate">
109 <label>Optimization Model Attributes:<sup><b>*</b></sup></label><br>
112 <div class="form-group row"></div>
115 <div id="validate" style="width: 70%"></div>
117 <div class="modal-footer">
118 <button class="btn btn-primary" herf="javascript:void(0)"
119 ng-disabled="temp.policy.readOnly"
120 ng-click="validatePolicy(temp.policy);" title="Validate the data entered in the Policy fields.">Validate</button>
121 <button class="btn btn-success" herf="javascript:void(0)"
122 ng-disabled="savebutton" ng-disabled="temp.policy.readOnly"
123 ng-click="savePolicy(temp);" title="Save the Policy with validated data.">Save</button>
124 <button type="button" class="btn btn-default" ng-click="refresh();" title="Close the template.">Close</button>