Deliver centralized role management feature
[portal.git] / ecomp-portal-FE-common / client / app / views / user-notifications-admin / user.notifications.tpl.html
1 <!--
2   ================================================================================
3   ECOMP Portal
4   ================================================================================
5   Copyright (C) 2017 AT&T Intellectual Property
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
10   
11        http://www.apache.org/licenses/LICENSE-2.0
12   
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   ================================================================================
19   -->
20 <div class="w-ecomp-user-notification-admin"
21         ng-style="{bottom: tabBottom}">
22          <div class="w-ecomp-main-container" >
23         <div class="user-notification" id="page-content">
24                 <div id="title" class="w-ecomp-main-view-title">
25                         <h1 class="heading-page" >User Notifications</h1>
26                 </div>
27                 <div class="userNotifTable">
28                 
29                    <div class="table-control-fields">
30                    <input class="input-table-search" type="text" id="table-search-field"
31                                                 placeholder="Search in entire table" ng-model="searchString" />
32                                         </div>
33                           <div class="table-control-buttons" ng-controller="userNotificationsCtrl">
34                                                 <button class="btn btn-alt btn-small"id="button-openAddNewApp"   ng-click="userNotifications.openUserNotificationModal()" >
35                                         <i class="icon-people-userbookmark" aria-hidden="true"></i>&nbsp;Add Notification
36                                 </button> 
37                                         </div>
38                 
39                         <span class="ecomp-spinner" ng-show="isLoadingTable"></span>
40                         <div class="b2b-table-div" b2b-table table-data="adminNotifications"
41                                 ng-hide="isLoadingTable" id="table-main" search-string="searchString">
42                                 <table  id="table-main" >
43                                         <thead b2b-table-row type="header">
44                                                 <tr>
45                                                         <th id="th-notif-0" b2b-table-header key="msgSource"
46                                                                 sortable="true" style=" width: 10px;">Message Source</th>
47                                                         <th id="th-notif-1" b2b-table-header key="msgHeader"
48                                                                 sortable="true" style=" width: 10px;">Message</th>
49                                                         <th id="th-notif-2"  b2b-table-header key="startTime"
50                                                                 sortable="true">Start Date (Local Time)</th>
51                                                         <th id="th-notif-3" b2b-table-header key="endTime"
52                                                                 sortable="true">End Date  (Local Time)</th>
53                                                         <th id="th-notif-4" b2b-table-header key="priority"
54                                                                 sortable="true">Priority</th>
55                                                         <th id="th-notif-5" b2b-table-header key="loginId"
56                                                                 sortable="true">Created By</th>
57                                                         <th id="th-notif-6" b2b-table-header key="createdDate"
58                                                                 sortable="true">Created Time</th>
59                                                         <th id="th-notif-7" b2b-table-header key="isForAllRoles"
60                                                                 sortable="true">All Users (Roles)?</th>
61                                                         <th id="th-notif-8" b2b-table-header key="edit" sortable="false">View/Delete</th>
62                                                 </tr>
63                                         </thead>
64                                         <tbody b2b-table-row type="body" class="table-body"
65                                 row-repeat="rowData in tableAdminNotifItems | filter:searchString | startFrom:(currentPage1-1)*viewPerPage1 | limitTo:viewPerPage1 "track-by="$index">
66                                                 <tr>
67                                                         <td b2b-table-body style="{{rowData.expired?'color:lightgray !important':''}}">
68                                                                 <div  id="{{$index}}-msgSource">{{rowData.msgSource}}</div>
69                                                         </td>
70                                                         <td b2b-table-body style="{{rowData.expired?' color:lightgray !important':''}}">
71                                                                 <div id="{{$index}}-msgHeader" style="font-weight: bold;">{{rowData.msgHeader}}</div>
72                                                                 <div id="{{$index}}-message" ng-if="rowData.msgSource==='EP'" style="width:500px"  ng-bind="rowData.msgDescription"></div>
73                                                                 <div id="{{$index}}-message" ng-if="rowData.msgSource!=='EP'"  ng-bind="rowData.msgDescription| elipsis: 27"></div>
74                                                         </td>
75                                                         <td b2b-table-body style="{{rowData.expired?'color:lightgray !important':''}}">
76                                                                 <div id="{{$index}}-startTime">{{rowData.startTime |
77                                                                         date:'medium'}}</div>
78                                                         </td >
79                                                         <td b2b-table-body style="{{rowData.expired?'color:lightgray !important':''}}">
80                                                                 <div id="{{$index}}-endTime">{{rowData.endTime |
81                                                                         date:'medium'}}</div>
82                                                         </td>
83                                                         <td b2b-table-body style="{{rowData.expired?'color:lightgray !important':''}}">
84                                                                 <div id="{{$index}}-priority">{{priorityItems[rowData.priority]}}</div>
85                                                         </td>
86                                                         <td b2b-table-body style="{{rowData.expired?'color:lightgray !important':''}}">
87                                                                 <div id="{{$index}}-loginId">{{!rowData.loginId ?externalNotification: rowData.loginId}}</div>
88                                                         </td>
89                                                         <td b2b-table-body style="{{rowData.expired?'color:lightgray !important':''}}">
90                                                                 <div id="{{$index}}-createdDate">{{rowData.createdDate |
91                                                                         date:'medium'}}</div>
92                                                         </td>
93                                                         <td b2b-table-body style="{{rowData.expired?'color:lightgray !important':''}}">
94                                                                 <div id="{{$index}}-isForAllRoles">{{rowData.isForAllRoles}}</div>
95                                                         </td>
96                                                         <td b2b-table-body style="{{rowData.expired?' color:lightgray !important':''}}">
97                                                         
98                                                         <p id="{{$index}}-notification-edit" ng-if="rowData.msgSource==='EP'" ng-click="userNotifications.editUserNotificationModal(rowData)"class="icon-overview"  >  /</p> 
99                                                         <p id="{{$index}}-notification-edit" ng-if="rowData.msgSource!=='EP'" ng-click="userNotifications.showDetailedJsonMessage(rowData)"class="icon-overview"  >/ </p> 
100                                                         <p id="{{$index}}-notification-delete" ng-click="userNotifications.removeUserNotification(rowData)" class="icon-misc-trash"></p> 
101                                                         
102                                                 
103                                                         </td>
104                                                 </tr>
105                                         </tbody>
106                                 </table>
107                                 
108                         </div>
109                                         <div b2b-pagination="" total-pages="totalPages1"
110                                                 current-page="currentPage1" click-handler="customPageHandler"
111                                                 role="navigation" aria-label="Customer Data Pages"></div>
112                                 
113                                                 
114                 </div>
115         </div>
116 </div>