Commit 4b5ade990e119307ff2ec55f36b3c3f472b9e840
1 parent
2ba04f86
Added Manage edge for customers and filter by type
Showing
4 changed files
with
11 additions
and
2 deletions
... | ... | @@ -42,6 +42,12 @@ |
42 | 42 | </button> |
43 | 43 | <button mat-raised-button color="primary" |
44 | 44 | [disabled]="(isLoading$ | async)" |
45 | + (click)="onEntityAction($event, 'manageEdges')" | |
46 | + [fxShow]="!isEdit"> | |
47 | + {{'customer.manage-edges' | translate }} | |
48 | + </button> | |
49 | + <button mat-raised-button color="primary" | |
50 | + [disabled]="(isLoading$ | async)" | |
45 | 51 | (click)="onEntityAction($event, 'delete')" |
46 | 52 | [fxShow]="!hideDelete() && !isEdit && !isPublic"> |
47 | 53 | {{'customer.delete' | translate }} | ... | ... |
... | ... | @@ -179,6 +179,9 @@ export class CustomersTableConfigResolver implements Resolve<EntityTableConfig<C |
179 | 179 | case 'manageDashboards': |
180 | 180 | this.manageCustomerDashboards(action.event, action.entity); |
181 | 181 | return true; |
182 | + case 'manageEdges': | |
183 | + this.manageCustomerEdges(action.event, action.entity); | |
184 | + return true; | |
182 | 185 | } |
183 | 186 | return false; |
184 | 187 | } | ... | ... |
... | ... | @@ -300,7 +300,7 @@ export class DashboardsTableConfigResolver implements Resolve<EntityTableConfig< |
300 | 300 | if (dashboardScope === 'edge') { |
301 | 301 | actions.push( |
302 | 302 | { |
303 | - name: this.translate.instant('dashboard.unassign-dashboards-from-edge'), | |
303 | + name: this.translate.instant('dashboard.unassign-dashboards'), | |
304 | 304 | icon: 'portable_wifi_off', |
305 | 305 | isEnabled: true, |
306 | 306 | onAction: ($event, entities) => this.unassignDashboardsFromEdge($event, entities) | ... | ... |
... | ... | @@ -167,7 +167,7 @@ export class EdgesTableConfigResolver implements Resolve<EntityTableConfig<EdgeI |
167 | 167 | } |
168 | 168 | if (edgeScope === 'customer') { |
169 | 169 | this.config.entitiesFetchFunction = pageLink => |
170 | - this.edgeService.getCustomerEdgeInfos(this.customerId, pageLink); | |
170 | + this.edgeService.getCustomerEdgeInfos(this.customerId, pageLink, this.config.componentsData.edgeType); | |
171 | 171 | this.config.deleteEntity = id => this.edgeService.unassignEdgeFromCustomer(id.id); |
172 | 172 | } |
173 | 173 | } | ... | ... |