@churchillliving/se-ui-toolkit 6.53.72 → 6.53.73
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/bundles/churchillliving-se-ui-toolkit.umd.js +4 -16
- package/bundles/churchillliving-se-ui-toolkit.umd.js.map +1 -1
- package/esm2015/lib/components/base/form/form.component.js +3 -9
- package/esm2015/lib/components/base/grid/grid.component.js +3 -9
- package/fesm2015/churchillliving-se-ui-toolkit.js +4 -16
- package/fesm2015/churchillliving-se-ui-toolkit.js.map +1 -1
- package/package.json +1 -1
|
@@ -4586,18 +4586,12 @@
|
|
|
4586
4586
|
// check the validation of the field
|
|
4587
4587
|
GridComponent.prototype.gridValidation = function (columns, row) {
|
|
4588
4588
|
if (!this.gridService.checkValidity(columns, row)) {
|
|
4589
|
-
var errorMessageDetails_1 = '';
|
|
4590
|
-
columns === null || columns === void 0 ? void 0 : columns.forEach(function (column) {
|
|
4591
|
-
if (column.errorMessage) {
|
|
4592
|
-
errorMessageDetails_1 = errorMessageDetails_1 ? errorMessageDetails_1 + ' , ' + column.errorMessage : column.errorMessage;
|
|
4593
|
-
}
|
|
4594
|
-
});
|
|
4595
4589
|
var isRequired = columns.some(function (column) { return column.errorMessage && !row[column.field]; });
|
|
4596
4590
|
if (isRequired) {
|
|
4597
|
-
this.alertService.error(
|
|
4591
|
+
this.alertService.error('Required fields are missing', 'REQUIRED FIELD');
|
|
4598
4592
|
}
|
|
4599
4593
|
else {
|
|
4600
|
-
this.alertService.error(
|
|
4594
|
+
this.alertService.error('Some fields are invalid', 'INVALID FIELD');
|
|
4601
4595
|
}
|
|
4602
4596
|
return false;
|
|
4603
4597
|
}
|
|
@@ -6458,20 +6452,14 @@
|
|
|
6458
6452
|
var validity = true;
|
|
6459
6453
|
var errorMessageDetails = '';
|
|
6460
6454
|
(_a = this.form.formSections) === null || _a === void 0 ? void 0 : _a.forEach(function (formSection) {
|
|
6461
|
-
var _a;
|
|
6462
6455
|
if (formSection.fields) {
|
|
6463
6456
|
if (!_this.formService.checkValidity(formSection.fields)) {
|
|
6464
|
-
(_a = formSection.fields) === null || _a === void 0 ? void 0 : _a.forEach(function (formField) {
|
|
6465
|
-
if (formField.errorMessage) {
|
|
6466
|
-
errorMessageDetails = errorMessageDetails ? errorMessageDetails + " , " + formField.errorMessage : formField.errorMessage;
|
|
6467
|
-
}
|
|
6468
|
-
});
|
|
6469
6457
|
var field = formSection.fields.some(function (field) { return field.requiredField && field.errorMessage && !field.value; });
|
|
6470
6458
|
if (validity && field) {
|
|
6471
|
-
_this.alertService.error(
|
|
6459
|
+
_this.alertService.error('Required fields are missing', 'REQUIRED FIELD');
|
|
6472
6460
|
}
|
|
6473
6461
|
else {
|
|
6474
|
-
_this.alertService.error(
|
|
6462
|
+
_this.alertService.error('Some fields are invalid', 'INVALID FIELD');
|
|
6475
6463
|
}
|
|
6476
6464
|
validity = false;
|
|
6477
6465
|
}
|