CSIT Fix for SDC-2585
[sdc.git] / catalog-ui / src / app / view-models / modals / confirmation-modal / confirmation-modal-view.html
1 <!--
2   ~ Copyright (C) 2018 AT&T Intellectual Property. All rights reserved.
3   ~
4   ~ Licensed under the Apache License, Version 2.0 (the "License");
5   ~ you may not use this file except in compliance with the License.
6   ~ You may obtain a copy of the License at
7   ~
8   ~      http://www.apache.org/licenses/LICENSE-2.0
9   ~
10   ~ Unless required by applicable law or agreed to in writing, software
11   ~ distributed under the License is distributed on an "AS IS" BASIS,
12   ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13   ~ See the License for the specific language governing permissions and
14   ~ limitations under the License.
15 -->
16
17 <ng1-modal modal="modalInstanceConfirmation" type="classic" class="w-sdc-modal-confirmation modal-type-{{confirmationModalModel.type}}" header="{{confirmationModalModel.title}}" show-close-button="true">
18     <form novalidate class="w-sdc-form" name="editForm">
19         <label class="i-sdc-form-label required w-sdc-modal-label" data-ng-bind-html="confirmationModalModel.message"></label>
20
21         <div class="i-sdc-form-item">
22             <textarea class="w-sdc-modal-body-comment"
23                       data-tests-id="checkindialog"
24                       autofocus="autofocus"
25                       data-ng-show="confirmationModalModel.showComment===true"
26                       data-ng-model="comment.text"
27                       placeholder="Comment..."
28                       maxlength="256"
29                       data-required
30                       name="comment1"
31                       data-ng-pattern="commentValidationPattern"
32                       data-ng-maxlength="256"></textarea>
33
34             <div class="input-error" data-ng-show="editForm.comment1.$dirty && editForm.comment1.$invalid">
35                 <span ng-show="editForm.comment1.$error.pattern" translate="VALIDATION_ERROR_SPECIAL_CHARS_NOT_ALLOWED"></span>
36                 <span ng-show="editForm.comment1.$error.required" translate="VALIDATION_ERROR_REQUIRED" translate-values="{'field': 'Comment' }"></span>
37             </div>
38         </div>
39     </form>
40     <div class="w-sdc-modal-footer classic">
41         <button class="tlv-btn {{okButtonColor}}" data-tests-id="OK" data-ng-click="ok()" data-ng-disabled="confirmationModalModel.showComment===true && (!comment.text || comment.text && comment.text.length===0)">OK</button>
42         <button class="tlv-btn grey" data-ng-if="hideCancelButton===false" data-tests-id="Cancel" data-ng-click="cancel()" >Cancel</button>
43         <!--<button class="tlv-btn blue add-property-add-another" data-ng-if="isNew" data-ng-click="saveAndAnother()" type="reset" data-ng-disabled="editForm.$invalid">Add Another</button>-->
44     </div>
45 </ng1-modal>