1
1
< div id ="flex-single-view " style ="padding-top: 12px; ">
2
- < div id ="flex-container ">
2
+ < div id ="flex-container " >
3
3
< div class ="card ">
4
4
< mat-card >
5
5
< div class ="item1 ">
6
6
< div class ="profile-img ">
7
7
< img src ="./assets/images/icon_center.svg " alt ="img ">
8
8
</ div >
9
9
< div class ="item2 ">
10
- < h3 > Packet Upload </ h3 >
10
+ < h3 > {{'packet-upload.header' | translate}} </ h3 >
11
11
</ div >
12
12
</ div >
13
13
</ mat-card >
14
14
</ div >
15
- < div id ="myDiv " class ="flex-body ">
15
+ < div id ="myDiv " class ="flex-body ">
16
16
< mat-card >
17
- < mat-card-content class ="forms-container ">
17
+ < mat-card-content class ="forms-container " *ngIf =" dynamicDropDown " >
18
18
< div [formGroup] ="uploadForm " class ="primary-form " *ngIf ="uploadForm ">
19
+ < mat-form-field >
20
+ < mat-label > {{'packet-upload.createView.center' | translate}}</ mat-label >
21
+ < mat-select formControlName ="centerId " id ="centerId ">
22
+ < mat-option
23
+ *ngFor ="let data of dynamicDropDown['centerList'] "
24
+ (onSelectionChange) ="captureDropDownValue($event, 'centerId') "
25
+ [id] ="data.fieldCode "
26
+ [value] ="data.fieldCode "
27
+ >
28
+ {{ data.fieldValue }} ({{data.fieldCode}})
29
+ </ mat-option >
30
+ </ mat-select >
31
+ < mat-error *ngIf ="uploadForm.controls.centerId.touched ">
32
+ {{'genericerror.fieldValidation' | translate}}
33
+ </ mat-error >
34
+ </ mat-form-field >
35
+
36
+
37
+ < mat-form-field >
38
+ < mat-label > {{'packet-upload.createView.sourceLabel' | translate}}</ mat-label >
39
+ < mat-select formControlName ="source " id ="source ">
40
+ < mat-option
41
+ *ngFor ="let data of dynamicDropDown['source'] "
42
+ (onSelectionChange) ="captureDropDownValue($event, 'source') "
43
+ [id] ="data.value "
44
+ [value] ="data.value "
45
+ >
46
+ {{ data.label }}
47
+ </ mat-option >
48
+ </ mat-select >
49
+ < mat-error *ngIf ="uploadForm.controls.source.touched ">
50
+ {{'genericerror.fieldValidation' | translate}}
51
+ </ mat-error >
52
+ </ mat-form-field >
53
+
54
+ < mat-form-field >
55
+ < mat-label > {{'packet-upload.createView.processLabel' | translate}}</ mat-label >
56
+ < mat-select formControlName ="process " id ="process ">
57
+ < mat-option
58
+ *ngFor ="let data of dynamicDropDown['process'] "
59
+ (onSelectionChange) ="captureDropDownValue($event, 'process') "
60
+ [id] ="data.value "
61
+ [value] ="data.value "
62
+ >
63
+ {{ data.label }}
64
+ </ mat-option >
65
+ </ mat-select >
66
+ < mat-error *ngIf ="uploadForm.controls.process.touched ">
67
+ {{'genericerror.fieldValidation' | translate}}
68
+ </ mat-error >
69
+ </ mat-form-field >
70
+
71
+ < mat-form-field >
72
+ < mat-label > {{'packet-upload.createView.supervisorStatusLabel' | translate}}</ mat-label >
73
+ < mat-select formControlName ="supervisorStatus " id ="supervisorStatus ">
74
+ < mat-option
75
+ *ngFor ="let data of dynamicDropDown['supervisorStatus'] "
76
+ (onSelectionChange) ="captureDropDownValue($event, 'supervisorStatus') "
77
+ [id] ="data.value "
78
+ [value] ="data.value "
79
+ >
80
+ {{ data.label }}
81
+ </ mat-option >
82
+ </ mat-select >
83
+ < mat-error *ngIf ="uploadForm.controls.supervisorStatus.touched ">
84
+ {{'genericerror.fieldValidation' | translate}}
85
+ </ mat-error >
86
+ </ mat-form-field >
87
+
19
88
< div class ="custom-file-input ">
20
- < input type ="button " value ="Choose File " class ="browseInput ">
21
- < input type ="file " multiple ="multiple " #fileInput (click) ="onFileClick($event) " (change) ="onFileSelect($event) " placeholder ="Upload file... " />
22
- < input type ="text " [value] ="fileName " placeholder ="Upload Your File ">
89
+ < input type ="button " *ngIf ="buttonalignment === 'rtl' " value ="{{'packet-upload.createView.input-btn-text' | translate}} " class ="browseInput ">
90
+ < input type ="file " multiple ="multiple " #fileInput (click) ="onFileClick($event) " (change) ="onFileSelect($event) " required placeholder ="{{'packet-upload.createView.input-text1' | translate}} " />
91
+ < input type ="text " id ="fileName " [value] ="fileName " placeholder ="{{'packet-upload.createView.input-text2' | translate}} ">
92
+ < input type ="button " *ngIf ="buttonalignment === 'ltr' " value ="{{'packet-upload.createView.input-btn-text' | translate}} " class ="browseInput ">
93
+ < mat-error *ngIf ="fileNameError ">
94
+ {{'genericerror.fieldValidation' | translate}}
95
+ </ mat-error >
23
96
</ div >
24
97
</ div >
25
98
</ mat-card-content >
@@ -29,13 +102,13 @@ <h3>Packet Upload</h3>
29
102
mat-raised-button
30
103
(click) ="submit() "
31
104
>
32
- UPLOAD
105
+ {{'packet-upload.createView.upload-btn' | translate}}
33
106
</ button >
34
107
< button mat-raised-button (click) ="cancel() ">
35
- CANCEL
108
+ {{'packet-upload.createView.cancel-btn' | translate}}
36
109
</ button >
37
110
</ mat-card-actions >
38
111
</ mat-card >
39
112
</ div >
40
113
</ div >
41
- </ div >
114
+ </ div >
0 commit comments