@smartbit4all/ng-client 3.3.88 → 3.3.90
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm2020/lib/smart-form/services/smartform.layout-definition.service.mjs +2 -1
- package/esm2020/lib/smart-form/smartform.component.mjs +20 -18
- package/fesm2015/smartbit4all-ng-client.mjs +20 -17
- package/fesm2015/smartbit4all-ng-client.mjs.map +1 -1
- package/fesm2020/smartbit4all-ng-client.mjs +20 -17
- package/fesm2020/smartbit4all-ng-client.mjs.map +1 -1
- package/package.json +1 -1
- package/smartbit4all-ng-client-3.3.90.tgz +0 -0
- package/smartbit4all-ng-client-3.3.88.tgz +0 -0
|
@@ -5441,22 +5441,24 @@ class SmartformComponent {
|
|
|
5441
5441
|
invalidFieldKeys: [],
|
|
5442
5442
|
invalidFieldNames: [],
|
|
5443
5443
|
};
|
|
5444
|
-
|
|
5445
|
-
|
|
5446
|
-
|
|
5447
|
-
|
|
5448
|
-
widget
|
|
5449
|
-
|
|
5450
|
-
|
|
5451
|
-
|
|
5452
|
-
|
|
5453
|
-
|
|
5454
|
-
|
|
5455
|
-
|
|
5456
|
-
|
|
5457
|
-
|
|
5458
|
-
|
|
5459
|
-
|
|
5444
|
+
if (this.form) {
|
|
5445
|
+
for (const control of Object.keys(this.form.controls)) {
|
|
5446
|
+
if (!this.form.controls[control].valid) {
|
|
5447
|
+
let widget = this.service.getSmartFormWidgetByKey(control);
|
|
5448
|
+
if (widget &&
|
|
5449
|
+
widget.type !== SmartFormWidgetType.CONTAINER &&
|
|
5450
|
+
widget.type !== SmartFormWidgetType.INDICATOR &&
|
|
5451
|
+
widget.type !== SmartFormWidgetType.LABEL &&
|
|
5452
|
+
widget.type !== SmartFormWidgetType.FILE_UPLOADER &&
|
|
5453
|
+
widget.type !== SmartFormWidgetType.IMAGE &&
|
|
5454
|
+
widget.type !== SmartFormWidgetType.DIVIDER &&
|
|
5455
|
+
widget.type !== SmartFormWidgetType.BUTTON &&
|
|
5456
|
+
widget.type !== SmartFormWidgetType.COMPONENT &&
|
|
5457
|
+
widget.type !== SmartFormWidgetType.YOUTUBE_PLAYER &&
|
|
5458
|
+
!widget.isDisabled) {
|
|
5459
|
+
invalidFields.invalidFieldNames.push(widget.label);
|
|
5460
|
+
invalidFields.invalidFieldKeys.push(widget.key);
|
|
5461
|
+
}
|
|
5460
5462
|
}
|
|
5461
5463
|
}
|
|
5462
5464
|
}
|
|
@@ -5465,7 +5467,7 @@ class SmartformComponent {
|
|
|
5465
5467
|
submitForm(validate = true) {
|
|
5466
5468
|
if (validate) {
|
|
5467
5469
|
this.smartForm.invalidFields = undefined;
|
|
5468
|
-
if (this.form.invalid) {
|
|
5470
|
+
if (this.form && this.form.invalid) {
|
|
5469
5471
|
for (const control of Object.keys(this.form.controls)) {
|
|
5470
5472
|
this.form.controls[control].markAsTouched();
|
|
5471
5473
|
this.form.controls[control].markAsDirty();
|
|
@@ -6688,6 +6690,7 @@ class SmartformLayoutDefinitionService {
|
|
|
6688
6690
|
type: SmartFormWidgetType.LABEL,
|
|
6689
6691
|
label: layoutDefinition.label,
|
|
6690
6692
|
widgetDescription: layoutDefinition.widgetDescription,
|
|
6693
|
+
cssClass: layoutDefinition.cssClass,
|
|
6691
6694
|
};
|
|
6692
6695
|
return widget;
|
|
6693
6696
|
}
|