1 <form class="artifact-form" novalidate name="artifactForm">
3 <onap-file-upload [disabled]="isViewOnly || showTypeFields && !artifact.artifactType" [convertToBase64]="true" [(value)]="artifact.artifactName" (fileUpload)="onUploadFile($event)" [placeHolder]="'Select File'" [label]="'Upload File'" [testId]="'fileUploadElement'" [required]="true">
6 <div class="artifact-form-container">
7 <div class="left-form-container" *ngIf="showTypeFields">
8 <sdc-input #artifactLabel
10 [(value)]="artifact.artifactLabel"
12 [label]="'Artifact Label'"
13 [disabled]="isViewOnly || artifact && artifact.uniqueId"
14 [testId]="'artifactLabel'"
15 (keyup)="verifyTypeAndFileWereFilled()">
17 <sdc-validation [validateElement]="artifactLabel" (validityChanged)="onLabelChange($event)">
18 <sdc-required-validator [message]="'ADD_ARTIFACT_ERROR_LABEL_REQUIRED' | translate"></sdc-required-validator>
19 <sdc-regex-validator [message]="'VALIDATION_ERROR_SPECIAL_CHARS_NOT_ALLOWED' | translate"
20 [pattern]="validationPatterns['label']"></sdc-regex-validator>
23 <sdc-dropdown #artifactType [disabled]="isViewOnly || artifact && artifact.uniqueId" label="Type" [required]="true"
24 [selectedOption]="selectedFileType" placeHolder="Please choose type" (changed)="onTypeChange($event)"
25 [options]="artifactTypesOptions" [testId]="'artifacttype'"></sdc-dropdown>
26 <sdc-validation [validateElement]="artifactType">
27 <sdc-required-validator
28 [message]="'ADD_ARTIFACT_ERROR_TYPE_REQUIRED' | translate"></sdc-required-validator>
32 <div class="right-form-container">
33 <sdc-textarea #artifactDescription
34 [(value)]="artifact.description"
39 [disabled]="isViewOnly"
40 (keyup)="verifyTypeAndFileWereFilled()">
42 <sdc-validation [validateElement]="artifactDescription" (validityChanged)="onDescriptionChange($event)">
43 <sdc-required-validator
44 [message]="'ADD_ARTIFACT_ERROR_DESCRIPTION_REQUIRED' | translate:{'field': 'Message' }"></sdc-required-validator>
45 <sdc-regex-validator [message]="'VALIDATION_ERROR_SPECIAL_CHARS_NOT_ALLOWED' | translate"
46 [pattern]="validationPatterns['comment']"></sdc-regex-validator>
52 <div *ngIf="artifact && artifact.esId">
53 <div>UUID: {{artifact.artifactUUID}}</div>
54 <div>Version: {{artifact.artifactVersion}}</div>