@churchillliving/se-ui-toolkit 6.53.63 → 6.53.68

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.
@@ -2735,7 +2735,6 @@
2735
2735
  }
2736
2736
  if (res) {
2737
2737
  (_a = document.getElementById('lookUp_filter')) === null || _a === void 0 ? void 0 : _a.focus();
2738
- localStorage.setItem('applyFilter', JSON.stringify(false));
2739
2738
  var field = column.field;
2740
2739
  var value = setDialogResponse(column, column === null || column === void 0 ? void 0 : column.lookupControl, res);
2741
2740
  column.value = (value === null || value === void 0 ? void 0 : value.value) ? value.value : res[field.toLowerCase()];
@@ -4587,12 +4586,18 @@
4587
4586
  // check the validation of the field
4588
4587
  GridComponent.prototype.gridValidation = function (columns, row) {
4589
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
+ });
4590
4595
  var isRequired = columns.some(function (column) { return column.errorMessage && !row[column.field]; });
4591
4596
  if (isRequired) {
4592
- this.alertService.error('Required fields are missing', 'REQUIRED FIELD');
4597
+ this.alertService.error(errorMessageDetails_1, 'REQUIRED FIELD');
4593
4598
  }
4594
4599
  else {
4595
- this.alertService.error('Some fields are invalid', 'INVALID FIELD');
4600
+ this.alertService.error(errorMessageDetails_1, 'INVALID FIELD');
4596
4601
  }
4597
4602
  return false;
4598
4603
  }
@@ -5067,17 +5072,14 @@
5067
5072
  };
5068
5073
  GridComponent.prototype.setFilterFocusOut = function (col, filter, event) {
5069
5074
  var _this = this;
5070
- console.log('col:package ', col);
5071
5075
  this.gridFilterObj = { column: col, filter: filter, event: event };
5072
- console.log('gridFilterObj: package ', this.gridFilterObj);
5073
5076
  var newColumn = Object.assign({}, col);
5074
- console.log('newColumn: ', newColumn);
5075
5077
  //change filter calender format
5076
5078
  if (newColumn.type === 'date' && newColumn.value) {
5077
5079
  newColumn.value = this.datePipe.transform(col.value.toString().trim(), 'yyyy-MM-dd');
5078
5080
  }
5079
5081
  setTimeout(function () {
5080
- _this.filterObj(col);
5082
+ _this.filterObj(newColumn);
5081
5083
  }, newColumn.type === exports.EGridColumnType.LOOKUP_INPUT ? 250 : 0);
5082
5084
  localStorage.setItem('applyFilter', JSON.stringify(false));
5083
5085
  };
@@ -6454,15 +6456,22 @@
6454
6456
  var _this = this;
6455
6457
  var _a, _b, _c, _d, _e;
6456
6458
  var validity = true;
6459
+ var errorMessageDetails = '';
6457
6460
  (_a = this.form.formSections) === null || _a === void 0 ? void 0 : _a.forEach(function (formSection) {
6461
+ var _a;
6458
6462
  if (formSection.fields) {
6459
6463
  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
+ });
6460
6469
  var field = formSection.fields.some(function (field) { return field.requiredField && field.errorMessage && !field.value; });
6461
6470
  if (validity && field) {
6462
- _this.alertService.error('Required fields are missing', 'REQUIRED FIELD');
6471
+ _this.alertService.error(errorMessageDetails, 'REQUIRED FIELD');
6463
6472
  }
6464
6473
  else {
6465
- _this.alertService.error('Some fields are invalid', 'INVALID FIELD');
6474
+ _this.alertService.error(errorMessageDetails, 'INVALID FIELD');
6466
6475
  }
6467
6476
  validity = false;
6468
6477
  }