2 * ============LICENSE_START=======================================================
4 * ================================================================================
5 * Copyright (C) 2017 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 <script type="text/ng-template" id="add_fwTermList_popup.html">
21 <div class="modal" tabindex="-1">
22 <div class="modal-dialog modal-lg">
23 <div class="modal-content">
24 <div class="modal-header">
25 <h2 class="font-showcase-font-name" style="color: #157bb2">{{label}}</h2>
27 <form name="formdata" ng-submit="saveTermName(editTermList);" novalidate>
28 <div class="modal-body">
29 <div class="form-group row">
30 <div class="form-group col-sm-6" ng-class="{ 'has-error' : formdata.termName.$invalid && !formdata.termName.$pristine }">
31 <label>Rule Name:<sup><b>*</b></sup></label><br>
32 <input type="text" ng-model="editTermList.termName" class="form-control" name= "termName" required/>
33 <p ng-show="formdata.termName.$invalid && !formdata.termName.$pristine" class="help-block">Rule Name is required.</p>
35 <div class="form-group col-sm-6" >
36 <label>Rule Description:<sup><b>*</b></sup></label><br>
37 <input type="text" ng-model="editTermList.termDescription" class="form-control"/>
40 <div class="form-group row">
41 <div class="form-group col-sm-6">
42 <label>From-Zone:</label><br>
43 <button type="button" class="btn btn-secondary btn-small" ng-click="addFromZoneNewChoice()"><i class="fa fa-plus"></i></button>
46 <div class="form-group row">
47 <div class="form-group">
48 <div data-ng-repeat="choice in fromZonechoices">
49 <div class="form-group row">
50 <div class="form-group col-sm-5" ng-class="{ 'has-error' : formdata.option.$invalid && !formdata.option.$pristine }">
51 <select class="form-control" ng-model="choice.option" ng-options="option for option in zoneDictionaryDatas track by option" name= "option" required>
52 <option value = "">{{choice.option}}</option></select>
53 <p ng-show="formdata.option.$invalid && !formdata.option.$pristine" class="help-block">From-Zone is required.</p>
55 <div class="form-group col-sm-1">
56 <button type="button" class="btn btn-secondary btn-small" ng-show="$last" ng-click="removeFromZoneChoice()"><i class="fa fa-minus"></i></button>
62 <div class="form-group row">
63 <div class="form-group col-sm-6">
64 <label>To-Zone:</label><br>
65 <button type="button" class="btn btn-secondary btn-small" ng-click="addToZoneNewChoice()"><i class="fa fa-plus"></i></button>
68 <div class="form-group row">
69 <div class="form-group">
70 <div data-ng-repeat="choice in toZonechoices">
71 <div class="form-group row">
72 <div class="form-group col-sm-5" ng-class="{ 'has-error' : formdata.option.$invalid && !formdata.option.$pristine }">
73 <select class="form-control" ng-model="choice.option" ng-options="option for option in zoneDictionaryDatas track by option"><option value = "" name= "option" required>{{choice.option}}</option></select>
74 <p ng-show="formdata.option.$invalid && !formdata.option.$pristine" class="help-block">To-Zone is required.</p>
76 <div class="form-group col-sm-1">
77 <button type="button" class="btn btn-secondary btn-small" ng-show="$last" ng-click="removeToZoneChoice()"><i class="fa fa-minus"></i></button>
83 <div class="form-group row">
84 <div class="form-group col-sm-6">
85 <label>Source-List:</label><br>
86 <button type="button" class="btn btn-secondary btn-small" ng-click="addSourceListNewChoice()"><i class="fa fa-plus"></i></button>
89 <div class="form-group row">
90 <div class="form-group">
91 <div data-ng-repeat="choice in sourceListchoices">
92 <div class="form-group row">
93 <div class="form-group col-sm-5" ng-class="{ 'has-error' : formdata.option.$invalid && !formdata.option.$pristine }">
94 <select class="form-control" ng-model="choice.option" ng-options="option for option in groupAddresses track by option"><option value = "" name= "option" required>{{choice.option}}</option></select>
95 <p ng-show="formdata.option.$invalid && !formdata.option.$pristine" class="help-block">Source-List is required.</p>
97 <div class="form-group col-sm-1">
98 <button type="button" class="btn btn-secondary btn-small" ng-show="$last" ng-click="removeSourceListChoice()"><i class="fa fa-minus"></i></button>
104 <div class="form-group row">
105 <div class="form-group col-sm-6">
106 <label>Destination-List:</label><br>
107 <button type="button" class="btn btn-secondary btn-small" ng-click="addDListNewChoice()"><i class="fa fa-plus"></i></button>
110 <div class="form-group row">
111 <div class="form-group">
112 <div data-ng-repeat="choice in destinationListchoices">
113 <div class="form-group row">
114 <div class="form-group col-sm-5" ng-class="{ 'has-error' : formdata.option.$invalid && !formdata.option.$pristine }">
115 <select class="form-control" ng-model="choice.option" ng-options="option for option in groupAddresses track by option"><option value = "" name= "option" required>{{choice.option}}</option></select>
116 <p ng-show="formdata.option.$invalid && !formdata.option.$pristine" class="help-block">Destination-List is required.</p>
118 <div class="form-group col-sm-1">
119 <button type="button" class="btn btn-secondary btn-small" ng-show="$last" ng-click="removeDlistChoice()"><i class="fa fa-minus"></i></button>
125 <div class="form-group row">
126 <div class="form-group col-sm-6">
127 <label>Source-Services:</label><br>
128 <button type="button" class="btn btn-secondary btn-small" ng-click="addSourceServiceNewChoice()"><i class="fa fa-plus"></i></button>
131 <div class="form-group row">
132 <div class="form-group">
133 <div data-ng-repeat="choice in sourceServicechoices">
134 <div class="form-group row">
135 <div class="form-group col-sm-5" ng-class="{ 'has-error' : formdata.option.$invalid && !formdata.option.$pristine }">
136 <select class="form-control" ng-model="choice.option" ng-options="option for option in groupServices track by option" ng-options="option for option in groupServices track by option"><option value = "" name= "option" required>{{choice.option}}</option></select>
137 <p ng-show="formdata.option.$invalid && !formdata.option.$pristine" class="help-block">Source-Services is required.</p>
139 <div class="form-group col-sm-1">
140 <button type="button" class="btn btn-secondary btn-small" ng-show="$last" ng-click="removeSourceServiceChoice()"><i class="fa fa-minus"></i></button>
146 <div class="form-group row">
147 <div class="form-group col-sm-6">
148 <label>Destination-Services:</label><br>
149 <button type="button" class="btn btn-secondary btn-small" ng-click="addDServicesNewChoice()"><i class="fa fa-plus"></i></button>
152 <div class="form-group row">
153 <div class="form-group">
154 <div data-ng-repeat="choice in destinationServicechoices">
155 <div class="form-group row">
156 <div class="form-group col-sm-5" ng-class="{ 'has-error' : formdata.option.$invalid && !formdata.option.$pristine }">
157 <select class="form-control" ng-model="choice.option" ng-options="option for option in groupServices track by option" ng-options="option for option in groupServices track by option" name= "option" required><option value = "">{{choice.option}}</option></select>
158 <p ng-show="formdata.option.$invalid && !formdata.option.$pristine" class="help-block">Destination-Services is required.</p>
160 <div class="form-group col-sm-1">
161 <button type="button" class="btn btn-secondary btn-small" ng-show="$last" ng-click="removeDServicesChoice()"><i class="fa fa-minus"></i></button>
168 <div class="form-group row">
169 <div class="form-group col-sm-6">
170 <label>Action-List:</label><br>
171 <button type="button" class="btn btn-secondary btn-small" ng-click="addActionListNewChoice()"><i class="fa fa-plus"></i></button>
174 <div class="form-group row">
175 <div class="form-group">
176 <div data-ng-repeat="choice in actionListchoices">
177 <div class="form-group row">
178 <div class="form-group col-sm-5" ng-class="{ 'has-error' : formdata.option.$invalid && !formdata.option.$pristine }">
179 <select class="form-control" ng-model="choice.option" ng-options="option for option in actionListDictionaryDatas track by option" name= "option" required><option value = "">{{choice.option}}</option></select>
180 <p ng-show="formdata.option.$invalid && !formdata.option.$pristine" class="help-block">Action-List is required.</p>
182 <div class="form-group col-sm-1">
183 <button type="button" class="btn btn-secondary btn-small" ng-show="$last" ng-click="removeActionListChoice()"><i class="fa fa-minus"></i></button>
190 <div class="modal-footer">
191 <button class="btn btn-success" type="submit" ng-disabled="formdata.$invalid">Save</button>
192 <button class="btn btn-default" type="button" ng-click="close()">Close</button>