2 ~ Copyright � 2016-2018 European Support Limited
4 ~ Licensed under the Apache License, Version 2.0 (the "License");
5 ~ you may not use this file except in compliance with the License.
6 ~ You may obtain a copy of the License at
8 ~ http://www.apache.org/licenses/LICENSE-2.0
10 ~ Unless required by applicable law or agreed to in writing, software
11 ~ distributed under the License is distributed on an "AS IS" BASIS,
12 ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 ~ See the License for the specific language governing permissions and
14 ~ limitations under the License.
17 <div class="interface-operation">
18 <loader [display]="isLoading" [size]="'large'" [relative]="true"></loader>
21 class="top-add-btn add-btn"
22 *ngIf="!isListEmpty()"
23 [ngClass]="{'disabled': readonly}"
24 data-tests-id="add-operation"
25 (click)="onEditOperation()">
26 {{ 'INTERFACE_ADD_OPERATION' | translate }}
29 <div class="operation-list">
32 class="empty-list-container"
33 *ngIf="isListEmpty() && !isLoading">
35 class="empty-list-add-btn"
36 data-tests-id="add-operation"
37 [ngClass]="{'disabled': readonly}"
38 (click)="onEditOperation()">
43 [disabled]="readonly">
45 <div class="button-text">{{ 'INTERFACE_ADD_OPERATION' | translate }}</div>
49 <div *ngIf="!isListEmpty()">
51 <div class="expand-collapse">
54 data-tests-id="expand-all"
55 [ngClass]="{'disabled': isAllExpanded()}"
56 (click)="collapseAll(false)">
57 {{ 'INTERFACE_EXPAND_ALL' | translate }}
61 data-tests-id="collapse-all"
62 [ngClass]="{'disabled': isAllCollapsed()}"
63 (click)="collapseAll()">
64 {{ 'INTERFACE_COLLAPSE_ALL' | translate }}
70 *ngFor="let interface of interfaces"
71 [attr.data-tests-id]="'interface-' + interface.displayType()">
74 class="interface-accordion"
75 [attr.data-tests-id]="'interface-' + interface.displayType() + '-toggle'"
76 (click)="interface.toggleCollapse()">
78 class="chevron-container"
79 [ngClass]="{'isCollapsed': interface.isCollapsed}">
86 <span class="interface-name">{{interface.displayType()}}</span>
91 *ngIf="!interface.isCollapsed">
92 <div class="header-row table-row">
94 class="cell header-cell field-name header-name">
95 {{ 'INTERFACE_HEADER_NAME' | translate }}
98 class="cell header-cell field-description header-description">
99 {{ 'INTERFACE_HEADER_DESCRIPTION' | translate }}
102 class="cell header-cell field-actions header-actions">
109 *ngFor="let operation of interface.operations"
110 [attr.data-tests-id]="'operation-' + operation.name"
111 (click)="onEditOperation(operation)">
113 class="cell field-name"
114 [attr.data-tests-id]="'operation-' + operation.name + '-name'">
118 class="cell field-description"
119 [ngClass]="{'collapsed': operation.isCollapsed}"
120 [attr.data-tests-id]="'operation-' + operation.name + '-description'">
121 {{operation.getDescriptionEllipsis()}}
123 class="more-or-less link"
124 (click)="operation.toggleCollapsed($event)"
125 [attr.data-tests-id]="'operation-' + operation.name + '-ellipsis'">
126 {{!operation.isEllipsis ? '' : operation.isCollapsed ? 'More' : 'Less'}}
129 <span class="cell field-actions">
131 class="delete-action"
132 [attr.data-tests-id]="'remove-operation-' + operation.name"
133 (click)="onRemoveOperation($event, operation)">