aboutsummaryrefslogtreecommitdiffstats
path: root/catalog-ui/src/app/ng2/components/logic/inputs-table/inputs-table.component.html
diff options
context:
space:
mode:
authorMichaelMorris <michael.morris@est.tech>2020-11-27 17:26:46 +0000
committerVasyl Razinkov <vasyl.razinkov@est.tech>2020-12-15 14:24:59 +0000
commit08fee6aa89ec2a0fd021c969af78ba422f86949f (patch)
treeffdb1001016bde3fdf265ad95db8f2ea21a564da /catalog-ui/src/app/ng2/components/logic/inputs-table/inputs-table.component.html
parent3f816f6fdeb32061c77ab9799e18f2cb41ce8ea7 (diff)
Add metadata to topology inputs1.8.0
Change-Id: If57e16003532d59552fa0b5cacc69a792e5b877a Issue-ID: SDC-3399 Signed-off-by: MichaelMorris <michael.morris@est.tech>
Diffstat (limited to 'catalog-ui/src/app/ng2/components/logic/inputs-table/inputs-table.component.html')
-rw-r--r--catalog-ui/src/app/ng2/components/logic/inputs-table/inputs-table.component.html49
1 files changed, 47 insertions, 2 deletions
diff --git a/catalog-ui/src/app/ng2/components/logic/inputs-table/inputs-table.component.html b/catalog-ui/src/app/ng2/components/logic/inputs-table/inputs-table.component.html
index d3db53aa43..ee090245f0 100644
--- a/catalog-ui/src/app/ng2/components/logic/inputs-table/inputs-table.component.html
+++ b/catalog-ui/src/app/ng2/components/logic/inputs-table/inputs-table.component.html
@@ -32,6 +32,9 @@
<div class="table-cell col4" (click)="sort('required')" *ngIf="componentType == 'SERVICE'">
<span tooltip="Required in Runtime" tooltipDelay="400">Req. in RT</span>
</div>
+ <div class="table-cell" [class.metadata-col-small]="!hasInputMetadata()" [class.metadata-col-wide]="hasInputMetadata()">
+ <div [class.metadata-col-wide-text]="hasInputMetadata()">Metadata</div>
+ </div>
<div class="table-cell valueCol">Value</div>
</div>
<div class="table-body">
@@ -65,8 +68,51 @@
(checkedChange)="onRequiredChanged(input, $event)"
[disabled]="readonly"></sdc-checkbox>
</div>
+ <!-- Metadata -->
+ <div class="table-cell" [class.metadata-col-small]="!hasInputMetadata()" [class.metadataCol]="hasInputMetadata()">
+ <div class="inner-cell-div metadata-add" tooltip="Add key value pair">
+ <a class="property-icon add-item" (click)="createNewMetadataEntry(input);" [ngClass]="{'disabled':readonly}">Add metadata</a>
+ </div>
+ <ng-container >
+ <div class="metadata-container">
+ <ng-container *ngFor="let metadataEntry of input.metadataEntries;">
+ <div class="metadata-entry">
+ <ng-container>
+ <div class="metadata-key-value metadata-key" >
+ <dynamic-element #metadataViewChildren
+ class="value-input"
+ pattern="validationUtils.getValidationPattern(string)"
+ [value]="metadataEntry.key"
+ type="string"
+ name="{{input.name}}_{{metadataEntry.key}}"
+ (elementChanged)="onMetadataKeyChanged(input, $event, metadataEntry)"
+ [readonly]="readonly"
+ [testId]="'prop-key-' + propertyTestsId"
+ ></dynamic-element>
+ </div>
+ </ng-container>
+ <ng-container>
+ <div class="metadata-key-value">
+ <dynamic-element
+ class="value-input"
+ pattern="validationUtils.getValidationPattern(string)"
+ [value]="metadataEntry.value"
+ type="string"
+ [name]="metadataEntry.key"
+ (elementChanged)="onMetadataValueChanged(input, $event, metadataEntry)"
+ [readonly]="readonly"
+ [testId]="'prop-key-' + propertyTestsId"
+ ></dynamic-element>
+ </div>
+ <span (click)="deleteMetadataEntry(input, metadataEntry);" class="delete-icon sprite-new delete-item-icon" [ngClass]="{'disabled':readonly}"></span>
+ </ng-container>
+ </div>
+ </ng-container>
+ </div>
+ </ng-container>
+ </div>
<!-- Value -->
- <div class="table-cell valueCol input-value-col" [class.inner-table-container]="input.childrenProperties || !input.isSimpleType">
+ <div class="table-cell valueCol" [class.inner-table-container]="input.childrenProperties || !input.isSimpleType">
<dynamic-element class="value-input"
*ngIf="checkInstanceFePropertiesMapIsFilled() && input.isSimpleType"
pattern="validationUtils.getValidationPattern(input.type)"
@@ -82,7 +128,6 @@
<span *ngIf="input.instanceUniqueId && !readonly" class="sprite-new delete-btn" (click)="openDeleteModal(input)" data-tests-id="delete-input-button"></span>
</div>
</div>
-
</div>
</div>
</div>