ps-toolkit-ui 1.22.11 → 1.22.12

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.
@@ -4246,6 +4246,7 @@
4246
4246
  if (this.table.hasChildren || this.subTable != null) {
4247
4247
  this.showChildren = new InputClass(this.table.environment, this.table.l, this.table.name + 'SubsetTitle', 'fad fa-angle-left f-s-22', this.row.Data.CountChild > 0 || (!this.table.childrenAutoLoad && this.children.length > 0) || this.subTable != null ? exports.InputType.Icon : exports.InputType.Hidden, 'h-25 m-h-5 d-ib va-m f-u');
4248
4248
  this.showChildren.onClick = function () {
4249
+ var _a, _b;
4249
4250
  if ($(_this.childrenDiv.nativeElement).is(':visible')) {
4250
4251
  $(_this.childrenDiv.nativeElement).slideUp();
4251
4252
  _this.showChildren.icon = 'fad fa-angle-left f-s-22';
@@ -4254,20 +4255,14 @@
4254
4255
  _this.loadChildren(_this.row.Data.Id);
4255
4256
  }
4256
4257
  else if (_this.subTable != null && _this.subTable.permissions == null) {
4257
- var acc = _this.table.permissions.Accesses.find(function (x) { return x.Action === _this.subTable.name; });
4258
- console.log(_this.table.permissions.Accesses);
4259
- console.log(_this.subTable.name);
4260
- console.log(acc);
4258
+ var acc_1 = _this.table.permissions.Accesses.find(function (x) { return x.Action === _this.subTable.name; });
4261
4259
  var ps = new PermissionClass();
4262
4260
  ps.RelatedId = _this.row.Data.Id;
4263
- ps.Area = acc.Area;
4264
- ps.Controller = acc.Controller;
4265
- ps.Action = acc.Action;
4266
- console.log(acc.Id);
4267
- console.log(acc.Accesses);
4268
- ps.Accesses = acc.Accesses;
4261
+ ps.Area = acc_1.Area;
4262
+ ps.Controller = acc_1.Controller;
4263
+ ps.Action = acc_1.Action;
4264
+ ps.Accesses = (_b = (_a = _this.table.permissions.Accesses) === null || _a === void 0 ? void 0 : _a.filter(function (x) { return x.ParentId === acc_1.Id; })) !== null && _b !== void 0 ? _b : [];
4269
4265
  _this.subTable.permissions = ps;
4270
- console.log(ps);
4271
4266
  _this.subTable.set();
4272
4267
  $(_this.childrenDiv.nativeElement).slideDown();
4273
4268
  _this.showChildren.icon = 'fad fa-angle-down f-s-22';