/
container-list.component.html
96 lines (91 loc) · 3.83 KB
/
container-list.component.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
<div class="container-listing">
<dot-portlet-base *ngIf="vm$ | async as vm">
<dot-listing-data-table
#listing
*ngIf="vm.tableColumns && vm.actionHeaderOptions"
[actionHeaderOptions]="vm.actionHeaderOptions"
[columns]="vm.tableColumns"
[actions]="[]"
[checkbox]="true"
[mapItems]="getContainersWithDisabledEntities"
(selectedItems)="updateSelectedContainers($event)"
(rowWasClicked)="handleRowClick($event)"
url="v1/containers?system=true"
dataKey="inode"
>
<div class="container-listing__header-options">
<div class="container-listing__filter-controls">
<button
class="p-button-secondary p-button"
[label]="'Search' | dm"
type="button"
pButton
></button>
<p-checkbox
[label]="'Show-Archived' | dm"
[binary]="true"
(onChange)="handleArchivedFilter($event.checked)"
data-testid="archiveCheckbox"
></p-checkbox>
</div>
<div>
<button
class="p-button-secondary p-button"
[label]="'Actions' | dm"
[disabled]="!vm.selectedContainers.length"
(click)="actionsMenu.toggle($event)"
type="button"
pButton
icon="pi pi-ellipsis-v"
attr.data-testid="bulkActions"
></button>
<p-menu
#actionsMenu
[popup]="true"
[model]="vm.containerBulkActions"
appendTo="body"
></p-menu>
</div>
</div>
<ng-template #beforeSearchTemplate>
<dot-content-type-selector
(selected)="changeContentTypeSelector($event)"
></dot-content-type-selector>
</ng-template>
<ng-template #rowTemplate *ngIf="vm.tableColumns as tableColumns" let-rowData="rowData">
<td [ngStyle]="{ 'text-align': tableColumns[0].textAlign }">
{{ rowData.name }}
</td>
<td [ngStyle]="{ 'text-align': tableColumns[1].textAlign }">
<dot-state-icon
[labels]="vm.stateLabels"
[state]="getContainerState(rowData)"
size="14px"
>
</dot-state-icon>
</td>
<td [ngStyle]="{ 'text-align': tableColumns[2].textAlign }">
{{ rowData.friendlyName }}
</td>
<td [ngStyle]="{ 'text-align': tableColumns[3].textAlign }">
{{ rowData.modDate }}
</td>
<td style="width: 5%">
<dot-action-menu-button
class="listing-datatable__action-button"
*ngIf="!rowData.disableInteraction"
[attr.data-testid]="rowData.identifier"
[actions]="setContainerActions(rowData)"
[item]="rowData"
>
</dot-action-menu-button>
</td>
</ng-template>
</dot-listing-data-table>
<dot-add-to-bundle
*ngIf="vm.addToBundleIdentifier"
[assetIdentifier]="vm.addToBundleIdentifier"
(cancel)="resetBundleIdentifier()"
></dot-add-to-bundle>
</dot-portlet-base>
</div>