ps-toolkit-ui 1.4.26 → 1.4.29

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.
@@ -2654,14 +2654,19 @@
2654
2654
  _this.changeRows.emit(_this.row.Data);
2655
2655
  }
2656
2656
  else {
2657
- _this.confirmShow.emit({ url: _this.getOptionUrl(option.Url, _this.table.permissions.RelatedId, _this.row.Data.Id), accept: function () {
2657
+ console.log(_this.table.permissions, 'this.table.permissions');
2658
+ _this.confirmShow.emit({
2659
+ action: _this.table.permissions.Action,
2660
+ url: _this.getOptionUrl(option.Url, _this.table.permissions.RelatedId, _this.row.Data.Id),
2661
+ accept: function () {
2658
2662
  if (_this.table.hasChildren && _this.table.childrenAutoLoad && _this.row.Data.ParentId != null) {
2659
2663
  _this.loadParent.emit(_this.row.Data.ParentId);
2660
2664
  }
2661
2665
  else {
2662
2666
  _this.table.load();
2663
2667
  }
2664
- } });
2668
+ }
2669
+ });
2665
2670
  }
2666
2671
  };
2667
2672
  }
@@ -3112,7 +3117,7 @@
3112
3117
  return this.changeRows.emit(e);
3113
3118
  };
3114
3119
  TableComponent.prototype.onConfirmShow = function (e) {
3115
- this.confirm.show(this.table.l('DeleteConfirm'), e.url, null, e.accept);
3120
+ this.confirm.show(this.table.l(e.action + 'Confirm'), e.url, null, e.accept);
3116
3121
  };
3117
3122
  TableComponent.prototype.changeSort = function (e, s) {
3118
3123
  if ($__namespace(e.target).closest('.header-search').hasClass('header-search')) {
@@ -7424,7 +7429,7 @@
7424
7429
  TableClass.prototype.showInsertModal = function (cId) {
7425
7430
  if (cId === void 0) { cId = null; }
7426
7431
  var insertAccess = this.permissions.getAccess(exports.PermissionAccessTypeEnum.Insert);
7427
- this.form.url = this.form.baseUrl = insertAccess.Url + (cId ? '/' + cId : '');
7432
+ this.form.url = this.form.baseUrl = insertAccess.Url.replace('{}', this.permissions.RelatedId) + (cId ? '/' + cId : '');
7428
7433
  this.form.name = insertAccess.Name;
7429
7434
  this.form.method = exports.Method.Post;
7430
7435
  this.form.inputs.filter(function (x) { return x.inEditDisabled; }).forEach(function (x) { return x.disabled = false; });
@@ -7461,7 +7466,6 @@
7461
7466
  if (access.AccessType === exports.PermissionAccessTypeEnum.Insert) {
7462
7467
  accessInp.class = accessInp.class.replace('blue', 'green');
7463
7468
  if (this_1.form) {
7464
- console.log(access.Url.replace('{}', this_1.permissions.RelatedId), access);
7465
7469
  this_1.form.url = this_1.form.baseUrl = access.Url.replace('{}', this_1.permissions.RelatedId);
7466
7470
  if (!this_1.form.onTop) {
7467
7471
  accessInp.onClick = function () {