|
@@ -137,6 +137,7 @@ export class AssetsProductManagementComponent implements OnInit {
|
137
|
137
|
name: ['', [Validators.required, Validators.pattern(/\S/)]],
|
138
|
138
|
model: ['', [Validators.required, Validators.pattern(/\S/)]],
|
139
|
139
|
brand: ['', [Validators.required, Validators.pattern(/\S/)]],
|
|
140
|
+ unit: ['', [Validators.required, Validators.pattern(/\S/)]],
|
140
|
141
|
mainType: [null, [Validators.required]],
|
141
|
142
|
subType: [null],
|
142
|
143
|
description: [''],
|
|
@@ -258,6 +259,7 @@ export class AssetsProductManagementComponent implements OnInit {
|
258
|
259
|
name: this.validateForm.value.name,
|
259
|
260
|
model: this.validateForm.value.model,
|
260
|
261
|
brand: this.validateForm.value.brand,
|
|
262
|
+ unit: this.validateForm.value.unit,
|
261
|
263
|
mainType: this.validateForm.value.mainType,
|
262
|
264
|
subType: this.validateForm.value.subType || undefined,
|
263
|
265
|
description: this.validateForm.value.description,
|
|
@@ -275,6 +277,7 @@ export class AssetsProductManagementComponent implements OnInit {
|
275
|
277
|
name: this.validateForm.value.name,
|
276
|
278
|
model: this.validateForm.value.model,
|
277
|
279
|
brand: this.validateForm.value.brand,
|
|
280
|
+ unit: this.validateForm.value.unit,
|
278
|
281
|
mainType: this.validateForm.value.mainType,
|
279
|
282
|
subType: this.validateForm.value.subType || undefined,
|
280
|
283
|
description: this.validateForm.value.description,
|
|
@@ -316,6 +319,7 @@ export class AssetsProductManagementComponent implements OnInit {
|
316
|
319
|
this.validateForm.controls.name.setValue(data.name);
|
317
|
320
|
this.validateForm.controls.model.setValue(data.model);
|
318
|
321
|
this.validateForm.controls.brand.setValue(data.brand);
|
|
322
|
+ this.validateForm.controls.unit.setValue(data.unit);
|
319
|
323
|
this.validateForm.controls.mainType.setValue(data.mainType ? data.mainType.toString() : null);
|
320
|
324
|
this.validateForm.controls.subType.setValue(data.subType ? data.subType.toString() : null);
|
321
|
325
|
this.validateForm.controls.description.setValue(data.description);
|