2 * ============LICENSE_START=======================================================
4 * ================================================================================
5 * Copyright (C) 2021 Nordix Foundation. All rights reserved.
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
11 * http://www.apache.org/licenses/LICENSE-2.0
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 * ============LICENSE_END=========================================================
21 <div class="operation-handler">
22 <loader [display]="isLoading" [size]="'large'" [relative]="true"></loader>
24 <form class="w-sdc-form">
26 <div class="side-by-side">
27 <div class="form-item">
29 label="{{ 'OPERATION_INTERFACE_TYPE' | translate }}"
30 [(value)]="interfaceType"
31 [disabled]=isViewOnly>
35 <div class="form-item">
37 label="{{ 'OPERATION_NAME' | translate }}"
38 [(value)]="operationToUpdate.name"
39 [disabled]=isViewOnly>
44 <div class="form-item">
46 label="{{'OPERATION_DESCRIPTION' | translate}}"
47 [(value)]="operationToUpdate.description"
48 testId="interface-operation-description"
49 (valueChange)="onDescriptionChange($event)"
50 [disabled]=isViewOnly>
54 <div class="group-with-border content-row">
55 <label class="occurrences-label"> {{ 'INTERFACE_OPERATION_IMPLEMENTATION' | translate}}</label>
56 <div class="form-item">
57 <checkbox [label]="'Add Artifact To Implementation'"
58 [(checked)]="enableAddArtifactImplementation"
59 (checkedChange)="onMarkToAddArtifactToImplementation($event)"
60 [disabled]=isViewOnly>
63 <div class="form-item" *ngIf="!enableAddArtifactImplementation">
65 label="{{'INTERFACE_OPERATION_IMPLEMENTATION_NAME' | translate}}"
66 testId="interface-operation-implementation-name"
67 [(value)]="artifactName"
68 (valueChange)="onImplementationNameChange($event)"
69 [disabled]=isViewOnly>
73 <div class="side-by-side" *ngIf="enableAddArtifactImplementation">
74 <div class="form-item" *ngIf="toscaArtifactTypes">
76 label="{{ 'TOSCA_ARTIFACT_TYPE' | translate }}"
77 testId="selectToscaArtifactType"
79 [selectedOption]="toscaArtifactTypeSelected"
80 placeHolder="{{toscaArtifactTypeSelected != undefined ? toscaArtifactTypeSelected : 'Select...'}}"
81 (changed)="onSelectToscaArtifactType($event)"
82 [options]="toscaArtifactTypes"
83 [disabled]=isViewOnly>
86 <div class="form-item" *ngIf="toscaArtifactTypeSelected && enableAddArtifactImplementation">
88 label="{{ 'INTERFACE_OPERATION_IMPLEMENTATION_FILE' | translate }}"
89 data-tests-id="artifactFile"
90 [(value)]="artifactName"
92 (valueChange)="onArtifactFileChange($event)"
93 [disabled]=isViewOnly>
96 <div class="form-item">
98 label="{{ 'ARTIFACT_VERSION' | translate }}"
99 data-tests-id="artifactVersion"
100 [(value)]="artifactVersion"
101 (valueChange)="onArtifactVersionChange($event)"
102 [disabled]=isViewOnly>
106 <div class="form-item" *ngIf="toscaArtifactTypeSelected && enableAddArtifactImplementation">
108 *ngIf="artifactTypeProperties && dataTypeMap"
109 [title]="'ARTIFACT_PROPERTY_LIST_TITLE' | translate"
110 [emptyMessage]="'ARTIFACT_PROPERTY_LIST_EMPTY' | translate"
111 [inputs]="artifactTypeProperties"
112 [dataTypeMap]="dataTypeMap"
113 [isViewOnly]="isViewOnly"
114 [allowDeletion]="false"
115 (onValueChange)="onArtifactPropertyValueChange($event)"
120 <div class="group-with-border content-row" *ngIf="dataTypeMap">
122 [title]="'INPUT_LIST_TITLE' | translate"
123 [emptyMessage]="'INPUT_LIST_EMPTY' | translate"
125 [dataTypeMap]="dataTypeMap"
126 [isViewOnly]="isViewOnly"
127 [allowDeletion]="true"
128 (onValueChange)="onInputValueChange($event)"
129 (onDelete)="onInputDelete($event)"
133 <div class="group-with-border content-row">
135 [dataTypeMap]="dataTypeMap$"
136 [isView]="isViewOnly"
137 [existingInputNames]="collectInputNames()"
138 (onAddInput)="onAddInput($event)"