Replace ecomp references
[portal.git] / ecomp-portal-FE-common / client / app / views / user-notifications-admin / user.notifications.modal.page.html
1 <!--
2   ============LICENSE_START==========================================
3   ONAP Portal
4   ===================================================================
5   Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
6   ===================================================================
7  
8   Unless otherwise specified, all software contained herein is licensed
9   under the Apache License, Version 2.0 (the "License");
10   you may not use this software except in compliance with the License.
11   You may obtain a copy of the License at
12  
13               http://www.apache.org/licenses/LICENSE-2.0
14  
15   Unless required by applicable law or agreed to in writing, software
16   distributed under the License is distributed on an "AS IS" BASIS,
17   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
18   See the License for the specific language governing permissions and
19   limitations under the License.
20  
21   Unless otherwise specified, all documentation contained herein is licensed
22   under the Creative Commons License, Attribution 4.0 Intl. (the "License");
23   you may not use this documentation except in compliance with the License.
24   You may obtain a copy of the License at
25  
26               https://creativecommons.org/licenses/by/4.0/
27  
28   Unless required by applicable law or agreed to in writing, documentation
29   distributed under the License is distributed on an "AS IS" BASIS,
30   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
31   See the License for the specific language governing permissions and
32   limitations under the License.
33  
34   ============LICENSE_END============================================
35  
36   
37   -->
38 <div class="user-notification-details-modal">
39
40                 <div class="b2b-modal-header">
41                         <h2 class="account-details-title" id="account-add-details-title">{{modalPgTitle}}</h2>
42
43                         <div class="corner-button in">
44                                 <button type="button" class="close" aria-label="Close" id="user-notification-button-close"
45                                         ng-click="$dismiss('cancel')"></button>
46                         </div>
47                 </div>
48
49                 <div class="b2b-modal-body">
50                                         <div class="user-notification-details-contents">
51                 <div class="left-container">
52                         <div class="add-widget-field" style="{{isEditMode? 'opacity : 0.6; pointer-events: none;':' '}} ">
53                                 <div class="user-notif-label">Broadcast to All Categories</div>
54                                 <div class="user-notif-label">
55                                         <label for="radio-button-yes" class="radio"> 
56                                 <input type="radio" ng-model="newNotifModel.isForAllRoles" id="radio-button-yes" name="YES" value="Y" > 
57                                 <i class="skin"></i> 
58                                 <span>Yes</span> 
59                             </label>
60                                 </div>
61                                 <div class="user-notif-label">
62                             <label for="radio-button-no" class="radio"> 
63                                 <input type="radio" ng-model="newNotifModel.isForAllRoles" id="radio-button-no" name="NO" value="N" > 
64                                 <i class="skin"></i> 
65                                 <span>No</span> 
66                             </label>
67                         </div> 
68                         </div>
69                         <div 
70                                 style="padding-left: 10px; {{(! newNotifModel.isForAllRoles ||newNotifModel.isForAllRoles=='Y')? 'opacity : 0.6; pointer-events: none;':' '}} {{isEditMode? 'opacity : 0.6;':' '}} "
71                                 class="user-notif-label">
72                                 <div id="notifcation-label-user" class="user-notif-label">
73                                         <span ng-show="newNotifModel.isForAllRoles=='N'" runat="server" ID="required" class="notifcation-label-user-requiredId">*</span>
74                                         Categories
75                                 </div>
76                                 <div>
77
78                                 <div id="notifcation-label-user-div" class="user-notif-label"></div>
79                                 <div class="user-notif-label">
80                             <label for="funcMenu-label-yes" class="radio"> 
81                                 <input type="radio" ng-model="newNotifModel.isFunctionalMenu" ng-click="getFunctionalMenu()" id="funcMenu-label-yes" name="FUNCTIONAL MENU" value="Y" > 
82                                 <i class="skin"></i> 
83                                 <span>Functional Menu</span> 
84                             </label>
85                         </div>
86                                 <div class="user-notif-label">
87                             <label for="approles-label-no" class="radio"> 
88                                 <input type="radio"ng-model="newNotifModel.isFunctionalMenu" ng-click="getAppRoleIds()" id="approles-label-no" name="APPLICATION ROLES" value="N" > 
89                                 <i class="skin"></i> 
90                                 <span>Application Roles</span> 
91                             </label>
92                         </div>
93
94                                 <div id="approles-checkbox" ng-show="!newNotifModel.anyTreeItemSelected&&(newNotifModel.isForAllRoles=='N')&&(!newNotifModel.isEditMode)">
95                                         
96                                         <div id="approles-checkbox-required" ng-show="!newNotifModel.anyTreeItemSelected" >
97                                                 
98
99                                                 <small class="checkbox-categories">At least
100                                                         one category is required</small>
101
102                                         </div>
103                                 </div>
104                                 
105                                 </div>
106                                 
107                                 
108                 
109                 <br>
110                          <div id="user-notif-tree-div" class="tree-div" >
111                                  <div id="user-notif-tree" class="b2b-tree-checkbox" style="{{isEditMode? 'pointer-events: none;':' '}}">
112                             <b2b-tree-node-checkbox  id="jqTreeUserNotif" collection="treedata" set-role="tree" group-it="false" ></b2b-tree-node-checkbox>
113                         </div>
114                          </div>  
115                         </div>
116                         <div>
117
118                                 
119                         </div>
120                 </div>
121                 <div id="app-conatiner-right" class="right-container">
122                 <div id="add-user-notif-priority" class="add-widget-field" style="{{isEditMode? 'opacity : 0.6; pointer-events: none;':' '}} ">
123                                         <div id="user-notification-priority-label" class="user-notif-label">Priority</div>
124                                         <div class="user-notification-priority-label">
125                             <label for="label-important" class="radio"> 
126                                 <input type="radio" ng-model="newNotifModel.selectedPriority" id="label-important" name="NORMAL" value="1" > 
127                                 <i class="skin"></i> 
128                                 <span>Normal</span> 
129                             </label>
130                             </div>
131                                         <div class="user-notification-priority-label">
132                             <label for="label-normal" class="radio"> 
133                                 <input type="radio" ng-model="newNotifModel.selectedPriority" id="label-normal" name="IMPORTANT" value="2" > 
134                                 <i class="skin"></i> 
135                                 <span>Important</span> 
136                             </label>
137                             </div>
138                                 </div>
139
140                         <div id="add-user-notif-startdate" class="add-widget-field"
141                                 style="padding-bottom: 12px; width: 301px !important;{{( isEditMode )? 'opacity : 0.6; pointer-events: none;':' '}}">
142                                 <div id="user-notification-startdate-label" class="user-notif-label">
143                                         <div class="user-notif-label">
144                                                 <span runat="server" ID="required" class="notifcation-label-user-requiredId">*</span>
145                                                 Start Date (Local Time)
146                                         </div>
147                                         <div class="datepicker-container">
148                                                 <input class="notif-input-calendar" id="datepicker-start" type="text" 
149                                                         ng-model="newNotifModel.startTime" b2b-datepicker min="minDate" max="maxDate" 
150                                                         required />
151                                         </div>
152                                         <div style="{{( isEditMode )? 'opacity : 0; pointer-events: none;':' '}}">
153                                                 <div id="user-startdate-required" ng-show="!isDateValid(newNotifModel.startTime)">
154                                                         <small class="mandatory-categories">Please enter valid date in MM/DD/YYYY format!</small>
155                                                 </div>
156                                                 <div id="user-startdate-required" ng-show="!isStartDateValidFromToday(newNotifModel.startTime)">
157                                                         <small class="date-validation">Date should not be greater than 4 months from current date!</small>
158                                                 </div>
159                                         </div>
160                                 </div>
161                                 <div ng-show="!isEditMode" ng-init="formatStartDate()"></div> 
162                         </div>                  
163
164                         <div id="add-user-notif-enddate" class="add-widget-field"
165                                 style="padding-bottom: 12px; width: 301px !important; {{( isEditMode )? 'opacity : 0.6; pointer-events: none;':' '}}">
166                                 <div id="user-notification-enddate-label" class="user-notif-label">
167                                         <span runat="server" ID="required" class="notifcation-label-user-requiredId">*</span> EndDate (Local Time)
168                                 </div>
169                                 <div class="datepicker-container">
170                                         <input class="notif-input-calendar" type="text" id="datepicker-end" 
171                                                 ng-model="newNotifModel.endTime" b2b-datepicker min="minDate" max="maxDate" 
172                                                 required />
173                                 </div>
174                                 <div style="{{( isEditMode )? 'opacity : 0; pointer-events: none;':' '}}">
175                                         <div id="user-endDate-required" ng-show="!isDateValid(newNotifModel.endTime)">
176                                                 <small class="mandatory-categories">Please enter valid date in MM/DD/YYYY format!</small>
177                                         </div>
178                                         <div id="user-startdate-required"  ng-show="!isStartDateValidFromToday(newNotifModel.endTime)">
179                                                 <small class="endDate-validation">Date should not be greater than 4 months from current date!</small>
180                                         </div>
181                                         <div id="user-enddate-error" ng-show="newNotifModel.endTime&&newNotifModel.startTime&&newNotifModel.startTime.getTime()>=newNotifModel.endTime.getTime()" class="user-enddate-error-txt">
182                                                 <small class="mandatory-categories">End Date must be greater than start Date</small>
183                                         </div>
184                                 </div>
185                                 <div ng-show="!isEditMode" ng-init="formatEndDate()" ></div> 
186                         </div>
187
188                         <div id="add-user-notif-title" class="add-widget-field"
189                                 style="padding-bottom: 12px; {{( isEditMode )? 'opacity : 0.6; pointer-events: none;':' '}}">
190                                 <div id="user-notification-title-label" class="user-notif-label">
191                                         <span runat="server" ID="required" class="notifcation-label-user-requiredId"
192                                                 visible="false"> *</span> Title
193                                 </div>
194                                 <textarea id="add-notification-input-title" class="notif-input" ng-model="newNotifModel.msgHeader" name="content" class="add-notification-input-title-ht">
195                 </textarea>
196                                 <div id="user-title-required" ng-show="newNotifModel.msgHeader.length == 0">
197                                         <small class="mandatory-categories">Title is Required</small>
198                                 </div>
199                         </div>
200                         
201                         <div id="add-user-notif-message" class="add-widget-field"
202                                 style="padding-bottom: 12px; {{( isEditMode )? 'opacity : 0.6; pointer-events: none;':' '}}">
203                                 <div id="user-notif-message-label" class="user-notif-label">
204                                         <span runat="server" ID="required" class="notifcation-label-user-requiredId"
205                                                 visible="false"> *</span> Message
206                                 </div>
207                                 <textarea id="user-notif-input-message" class="notif-input" class="add-notification-input-title-ht"
208                                         ng-model="newNotifModel.msgDescription" name="content">
209                                 </textarea>
210                                 <div id="user-notif-message-required" ng-show="newNotifModel.msgDescription.length ==0 ">
211                                         <small class="mandatory-categories">Message is Required</small>
212                                 </div>
213                         </div>
214
215                 
216                         
217                 </div>
218         </div>
219                         </div>
220                         <br>
221                         <div class="b2b-modal-footer">
222                                 <div class="dialog-control">
223                                 <a ng-show="!isEditMode">
224                                 <button id="button-notification-save" class="btn btn-alt btn-small" size="small" ng-disabled="addUserNotificationValidation()" ng-click="addUserNotification()">Save</button></a>       
225                                                 <button id="button-notification-cancel" class="btn btn-alt btn-small" ng-click="$dismiss('cancel')"role="button" tabindex="0">Cancel</button>
226                                                 
227                                         </div>
228                         </div>
229                         
230                         
231                         
232
233 </div>
234
235 <script>
236 $(document).ready(function(){
237     $(".ngdialog-close").attr('id','dialog-close');
238 });
239 </script>