@churchillliving/se-ui-toolkit 6.53.108 → 6.53.109

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.
@@ -513,17 +513,21 @@
513
513
  this.dialogService = dialogService;
514
514
  this.confirmationService = confirmationService;
515
515
  }
516
- AlertService.prototype.success = function (message) {
517
- this.toastr.success(message, "", { closeButton: true });
516
+ AlertService.prototype.success = function (message, time) {
517
+ if (time === void 0) { time = 5000; }
518
+ this.toastr.success(message, "", { closeButton: true, timeOut: time });
518
519
  };
519
- AlertService.prototype.info = function (message) {
520
- this.toastr.info(message, "", { closeButton: true });
520
+ AlertService.prototype.info = function (message, time) {
521
+ if (time === void 0) { time = 5000; }
522
+ this.toastr.info(message, "", { closeButton: true, timeOut: time });
521
523
  };
522
- AlertService.prototype.warning = function (message) {
523
- this.toastr.warning(message, "", { closeButton: true });
524
+ AlertService.prototype.warning = function (message, time) {
525
+ if (time === void 0) { time = 5000; }
526
+ this.toastr.warning(message, "", { closeButton: true, timeOut: time });
524
527
  };
525
- AlertService.prototype.error = function (error, message) {
526
- this.toastr.error(error, message, { closeButton: true });
528
+ AlertService.prototype.error = function (error, time, message) {
529
+ if (time === void 0) { time = 5000; }
530
+ this.toastr.error(error, message, { closeButton: true, timeOut: time });
527
531
  };
528
532
  AlertService.prototype.apiError = function (error) {
529
533
  if (typeof error === 'string' || typeof error.error === 'string') {
@@ -4617,10 +4621,10 @@
4617
4621
  });
4618
4622
  var isRequired = columns.some(function (column) { return column.errorMessage && !row[column.field]; });
4619
4623
  if (isRequired) {
4620
- this.alertService.error(errorMessageDetails_1, 'REQUIRED FIELD');
4624
+ this.alertService.error(errorMessageDetails_1, 5000, 'REQUIRED FIELD');
4621
4625
  }
4622
4626
  else {
4623
- this.alertService.error(errorMessageDetails_1, 'INVALID FIELD');
4627
+ this.alertService.error(errorMessageDetails_1, 5000, 'INVALID FIELD');
4624
4628
  }
4625
4629
  return false;
4626
4630
  }
@@ -6537,10 +6541,10 @@
6537
6541
  });
6538
6542
  var field = formSection.fields.some(function (field) { return field.requiredField && field.errorMessage && !field.value; });
6539
6543
  if (validity && field) {
6540
- _this.alertService.error(errorMessageDetails, 'REQUIRED FIELD');
6544
+ _this.alertService.error(errorMessageDetails, 5000, 'REQUIRED FIELD');
6541
6545
  }
6542
6546
  else {
6543
- _this.alertService.error(errorMessageDetails, 'INVALID FIELD');
6547
+ _this.alertService.error(errorMessageDetails, 5000, 'INVALID FIELD');
6544
6548
  }
6545
6549
  validity = false;
6546
6550
  }