3 class="page-layout simple left-sidenav inner-sidenav motion-list"
7 class="header md-accent-bg"
9 layout-align="space-between center"
12 <div layout="row" layout-align="start center">
13 <div class="logo" layout="row" layout-align="start center">
14 <span class="logo-icon">
15 <md-icon md-font-icon="icon-whatsapp" class="s24"></md-icon>
17 <span class="logo-text" translate="WHATSAPP.WHATSAPPACCOUNTS"
18 >WhatsappAccounts</span
27 class="search-input-wrapper"
29 layout-align="start center"
32 <md-icon md-font-icon="icon-magnify"></md-icon>
34 <md-input-container md-no-float class="m-0">
37 placeholder="Search for anyone"
39 ng-model="vm.query.filter"
40 ng-model-options="{ debounce: 1000 }"
42 translate-attr-placeholder="WHATSAPP.SEARCH_FOR_ANYONE"
53 ng-show="vm.selectedWhatsappAccounts.length > 0"
54 class="selected-bar header animate-slide-down md-accent-bg"
56 layout-align="start center"
59 class="close-button-wrapper"
60 ng-click="vm.selectedWhatsappAccounts =[]"
62 <md-button layout="row" layout-align="start center">
63 <md-icon md-font-icon="icon-arrow-left" class="mr-8"></md-icon>
64 <span translate="WHATSAPP.BACK">Back</span>
68 <div flex layout="row" layout-align="space-between center">
70 <span class="selected-whatsappAccounts-count">
71 <span>{{vm.selectedWhatsappAccounts.length}}</span>
72 <span translate="WHATSAPP.SELECTED">selected</span>
75 <md-menu class="select-menu" ng-if="!vm.currentThread">
77 class="md-icon-button"
78 ng-click="$mdMenu.open($event)"
79 aria-label="multi select toggle"
81 translate-attr-aria-label="WHATSAPP.MULTI_SELECT_TOGGLE"
83 <md-icon md-font-icon="icon-menu-down"></md-icon>
85 <md-menu-content width="3">
88 ng-click="vm.selectAllWhatsappAccounts()"
89 translate="WHATSAPP.SELECT_ALL"
96 ng-click="vm.deselectWhatsappAccounts()"
97 translate="WHATSAPP.SELECT_NONE"
106 <div class="multi-select-actions">
108 class="md-icon-button"
109 ng-csv="vm.exportSelectedWhatsappAccounts"
111 filename="whatsappAccounts.csv"
113 <md-icon md-font-icon="icon-file-excel"></md-icon>
116 class="md-icon-button"
117 ng-if="vm.crudPermissions.canDelete"
118 ng-click="vm.deleteSelectedWhatsappAccounts($event)"
119 aria-label="delete selected"
121 translate-attr-label="WHATSAPP.DELETE_SELECTED"
123 <md-icon md-font-icon="icon-delete"></md-icon>
128 <!-- / SELECTED BAR -->
131 <div class="content" md-background-bg layout="row" layout-align="start start">
133 <div class="main scrollable" ms-scroll>
134 <!-- WHATSAPPACCOUNT TABLE -->
141 ng-model="vm.selectedWhatsappAccounts"
142 md-progress="vm.promise"
146 md-order="vm.query.sort"
147 md-on-reorder="vm.getWhatsappAccounts"
152 ng-if="vm.table == 'users' || vm.table == 'agents'"
155 <th md-column md-order-by="id">
156 {{ 'WHATSAPP.ID' | translate }}
158 <th md-column md-order-by="name">
159 {{ 'WHATSAPP.NAME' | translate }}
161 <th md-column md-order-by="key">
162 {{ 'WHATSAPP.KEY' | translate }}
164 <th md-column md-order-by="ListId">
165 {{ 'WHATSAPP.LIST' | translate }}
167 <th md-column md-order-by="type">
168 {{ 'WHATSAPP.TYPE' | translate }}
170 <th md-column md-order-by="phone">
171 {{ 'WHATSAPP.PHONE' | translate }}
173 <th md-column md-order-by="description">
174 {{ 'WHATSAPP.DESCRIPTION' | translate }}
176 <th md-column width="10px"></th>
180 <tr md-row ng-hide="vm.whatsappAccounts.rows.length">
181 <td md-cell colspan="8">
182 <div layout="row" layout-align="center center">
183 <span translate="WHATSAPP.NO_AVAILABLE_INFO"
184 >No Available Info</span
191 md-select="whatsappAccount"
193 ng-repeat="whatsappAccount in vm.whatsappAccounts.rows"
195 <td md-cell ng-if="whatsappAccount.userpic">
198 alt="{{whatsappAccount.name}}"
199 ng-src="api/users/{{whatsappAccount.id}}/avatar"
204 ng-if="!whatsappAccount.userpic && (vm.table == 'users' || vm.table == 'agents')"
208 alt="{{whatsappAccount.name}}"
209 ng-src="assets/images/avatars/profile.png"
213 ng-click="vm.crudPermissions.readOnly || (vm.crudPermissions.canDelete && !vm.crudPermissions.canEdit) ? vm.editstate(whatsappAccount, ev) : vm.createOrEditWhatsappAccount($event, whatsappAccount)"
217 {{whatsappAccount.id}}
220 ng-click="vm.crudPermissions.readOnly || (vm.crudPermissions.canDelete && !vm.crudPermissions.canEdit) ? vm.editstate(whatsappAccount, ev) : vm.createOrEditWhatsappAccount($event, whatsappAccount)"
224 {{whatsappAccount.name}}
227 ng-click="vm.crudPermissions.readOnly || (vm.crudPermissions.canDelete && !vm.crudPermissions.canEdit) ? vm.editstate(whatsappAccount, ev) : vm.createOrEditWhatsappAccount($event, whatsappAccount)"
231 {{whatsappAccount.key}}
234 ng-click="vm.crudPermissions.readOnly || (vm.crudPermissions.canDelete && !vm.crudPermissions.canEdit) ? vm.editstate(whatsappAccount, ev) : vm.createOrEditWhatsappAccount($event, whatsappAccount)"
238 {{ (vm.lists | filter : {'id':whatsappAccount.ListId} :
242 ng-click="vm.crudPermissions.readOnly || (vm.crudPermissions.canDelete && !vm.crudPermissions.canEdit) ? vm.editstate(whatsappAccount, ev) : vm.createOrEditWhatsappAccount($event, whatsappAccount)"
246 {{ vm.arraytype[whatsappAccount.type].option }}
249 ng-click="vm.crudPermissions.readOnly || (vm.crudPermissions.canDelete && !vm.crudPermissions.canEdit) ? vm.editstate(whatsappAccount, ev) : vm.createOrEditWhatsappAccount($event, whatsappAccount)"
253 {{whatsappAccount.phone}}
256 ng-click="vm.crudPermissions.readOnly || (vm.crudPermissions.canDelete && !vm.crudPermissions.canEdit) ? vm.editstate(whatsappAccount, ev) : vm.createOrEditWhatsappAccount($event, whatsappAccount)"
260 {{whatsappAccount.description}}
263 <td md-cell class="actions">
266 class="md-icon-button"
269 translate-attr-aria-label="WHATSAPP.MORE"
270 ng-click="$mdMenu.open($event)"
272 <md-icon md-font-icon="icon-dots-vertical"></md-icon>
275 <md-menu-content width="3">
280 <md-menu-item ng-if="vm.crudPermissions.canEdit">
282 ng-click="vm.editstate(whatsappAccount, $event )"
283 translate="WHATSAPP.EDIT_WHATSAPPACCOUNT"
295 ng-click="vm.interactionsgoto(whatsappAccount, $event )"
296 translate="WHATSAPP.INTERACTIONS_WHATSAPPACCOUNT"
298 Interactions WhatsappAccount
308 ng-click="vm.agentadddialog(whatsappAccount, $event )"
309 translate="WHATSAPP.AGENTADD_WHATSAPPACCOUNT"
311 AgentAdd WhatsappAccount
319 <md-menu-item ng-if="vm.crudPermissions.canDelete">
321 ng-click="vm.deleteconfirm(whatsappAccount, $event )"
322 translate="WHATSAPP.DELETE_WHATSAPPACCOUNT"
324 Delete WhatsappAccount
333 </md-table-container>
336 md-label="{page: '{{'WHATSAPP.PAGE' | translate}}:', rowsPerPage: '{{'WHATSAPP.ROWSPERPAGE' | translate}}:', of: '{{'WHATSAPP.OF' | translate}}'}"
337 md-limit="vm.query.limit"
338 md-limit-options="[10, 15, 20, 50, 100, 250]"
339 md-page="vm.query.page"
340 md-total="{{vm.whatsappAccounts.count}}"
341 md-on-paginate="vm.getWhatsappAccounts"
343 ></md-table-pagination>
345 <!-- / WHATSAPPACCOUNT TABLE -->
348 <!-- / NO RESULTS -->
354 <!-- ADD WHATSAPPACCOUNT BUTTON -->
356 ng-if="vm.crudPermissions.canEdit"
357 class="md-fab md-accent add-item-button"
358 id="add-whatsappAccount-button"
359 ng-click="vm.createOrEditWhatsappAccount($event)"
360 aria-label="add whatsappAccount"
362 translate-attr-aria-label="WHATSAPP.ADD_WHATSAPPACCOUNT"
364 <md-icon md-font-icon="icon-plus"></md-icon>
366 <!-- / ADD WHATSAPPACCOUNT BUTTON -->