ps-toolkit-ui 1.17.82 → 1.17.83
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/ps-toolkit-ui.umd.js +15 -26
- package/bundles/ps-toolkit-ui.umd.js.map +1 -1
- package/bundles/ps-toolkit-ui.umd.min.js +1 -1
- package/bundles/ps-toolkit-ui.umd.min.js.map +1 -1
- package/esm2015/lib/components/table/row/table.row.component.js +3 -14
- package/fesm2015/ps-toolkit-ui.js +2 -13
- package/fesm2015/ps-toolkit-ui.js.map +1 -1
- package/package.json +1 -1
|
@@ -3390,7 +3390,7 @@
|
|
|
3390
3390
|
}, 500);
|
|
3391
3391
|
};
|
|
3392
3392
|
TableRowComponent.prototype.setOptions = function () {
|
|
3393
|
-
var e_1,
|
|
3393
|
+
var e_1, _e, e_2, _f;
|
|
3394
3394
|
var _this = this;
|
|
3395
3395
|
var _a, _b, _c, _d;
|
|
3396
3396
|
var opts = [];
|
|
@@ -3409,15 +3409,15 @@
|
|
|
3409
3409
|
};
|
|
3410
3410
|
var this_1 = this;
|
|
3411
3411
|
try {
|
|
3412
|
-
for (var
|
|
3413
|
-
var option =
|
|
3412
|
+
for (var _g = __values(((_b = (_a = this.row.Options) === null || _a === void 0 ? void 0 : _a.filter(function (x) { return x.Type === exports.PermissionTypeEnum.Option && x.InputAction === exports.PermissionInputActionEnum.Input; })) !== null && _b !== void 0 ? _b : [])), _h = _g.next(); !_h.done; _h = _g.next()) {
|
|
3413
|
+
var option = _h.value;
|
|
3414
3414
|
_loop_1(option);
|
|
3415
3415
|
}
|
|
3416
3416
|
}
|
|
3417
3417
|
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
|
3418
3418
|
finally {
|
|
3419
3419
|
try {
|
|
3420
|
-
if (
|
|
3420
|
+
if (_h && !_h.done && (_e = _g.return)) _e.call(_g);
|
|
3421
3421
|
}
|
|
3422
3422
|
finally { if (e_1) throw e_1.error; }
|
|
3423
3423
|
}
|
|
@@ -3500,8 +3500,8 @@
|
|
|
3500
3500
|
else if (option.InputAction === exports.PermissionInputActionEnum.Modal) {
|
|
3501
3501
|
opt.modal = this_2.table.optionsActions.find(function (x) { return x.name === option.Action; });
|
|
3502
3502
|
opt.onClick = function () {
|
|
3503
|
-
var e_3,
|
|
3504
|
-
var _a, _b, _c
|
|
3503
|
+
var e_3, _e;
|
|
3504
|
+
var _a, _b, _c;
|
|
3505
3505
|
if (opt.modal.table) {
|
|
3506
3506
|
var p = new PermissionClass();
|
|
3507
3507
|
p.RelatedId = _this.row.Data.Id;
|
|
@@ -3510,17 +3510,6 @@
|
|
|
3510
3510
|
p.Action = option.Action;
|
|
3511
3511
|
p.Accesses = (_b = (_a = _this.row.Options) === null || _a === void 0 ? void 0 : _a.filter(function (x) { return x.ParentId === option.Id; })) !== null && _b !== void 0 ? _b : [];
|
|
3512
3512
|
opt.modal.table.permissions = p;
|
|
3513
|
-
if (opt.modal.table.subTable) {
|
|
3514
|
-
console.log(_this.row);
|
|
3515
|
-
var acc_1 = _this.row.Options.find(function (x) { return x.Action === opt.modal.table.subTable.name; });
|
|
3516
|
-
var ps = new PermissionClass();
|
|
3517
|
-
ps.Area = acc_1.Area;
|
|
3518
|
-
ps.Controller = acc_1.Controller;
|
|
3519
|
-
ps.Action = acc_1.Action;
|
|
3520
|
-
ps.Accesses = (_d = (_c = _this.row.Options) === null || _c === void 0 ? void 0 : _c.filter(function (x) { return x.ParentId === acc_1.Id; })) !== null && _d !== void 0 ? _d : [];
|
|
3521
|
-
opt.modal.table.subTable.permissions = ps;
|
|
3522
|
-
console.log(ps);
|
|
3523
|
-
}
|
|
3524
3513
|
if (opt.modal.table.form) {
|
|
3525
3514
|
opt.modal.table.form.url = option.Url.replace('{}', _this.row.Data.Id) + '-insert';
|
|
3526
3515
|
opt.modal.table.form.baseUrl = option.Url.replace('{}', _this.row.Data.Id) + '-insert';
|
|
@@ -3539,7 +3528,7 @@
|
|
|
3539
3528
|
if (opt.modal.accordion) {
|
|
3540
3529
|
var _loop_3 = function (r) {
|
|
3541
3530
|
if (r.table) {
|
|
3542
|
-
var options = JSON.parse(JSON.stringify((
|
|
3531
|
+
var options = JSON.parse(JSON.stringify((_c = _this.row.Options) !== null && _c !== void 0 ? _c : []));
|
|
3543
3532
|
var rowOption_1 = options.find(function (x) { return x.ParentId === option.Id && x.Action === r.name; });
|
|
3544
3533
|
if (rowOption_1) {
|
|
3545
3534
|
var p = new PermissionClass();
|
|
@@ -3558,15 +3547,15 @@
|
|
|
3558
3547
|
}
|
|
3559
3548
|
};
|
|
3560
3549
|
try {
|
|
3561
|
-
for (var
|
|
3562
|
-
var r =
|
|
3550
|
+
for (var _f = (e_3 = void 0, __values(opt.modal.accordion.rows)), _g = _f.next(); !_g.done; _g = _f.next()) {
|
|
3551
|
+
var r = _g.value;
|
|
3563
3552
|
_loop_3(r);
|
|
3564
3553
|
}
|
|
3565
3554
|
}
|
|
3566
3555
|
catch (e_3_1) { e_3 = { error: e_3_1 }; }
|
|
3567
3556
|
finally {
|
|
3568
3557
|
try {
|
|
3569
|
-
if (
|
|
3558
|
+
if (_g && !_g.done && (_e = _f.return)) _e.call(_f);
|
|
3570
3559
|
}
|
|
3571
3560
|
finally { if (e_3) throw e_3.error; }
|
|
3572
3561
|
}
|
|
@@ -3603,15 +3592,15 @@
|
|
|
3603
3592
|
};
|
|
3604
3593
|
var this_2 = this;
|
|
3605
3594
|
try {
|
|
3606
|
-
for (var
|
|
3607
|
-
var option =
|
|
3595
|
+
for (var _j = __values(((_d = (_c = this.row.Options) === null || _c === void 0 ? void 0 : _c.filter(function (x) { return x.Type === exports.PermissionTypeEnum.Option && x.InputAction !== exports.PermissionInputActionEnum.Input; })) !== null && _d !== void 0 ? _d : [])), _k = _j.next(); !_k.done; _k = _j.next()) {
|
|
3596
|
+
var option = _k.value;
|
|
3608
3597
|
_loop_2(option);
|
|
3609
3598
|
}
|
|
3610
3599
|
}
|
|
3611
3600
|
catch (e_2_1) { e_2 = { error: e_2_1 }; }
|
|
3612
3601
|
finally {
|
|
3613
3602
|
try {
|
|
3614
|
-
if (
|
|
3603
|
+
if (_k && !_k.done && (_f = _j.return)) _f.call(_j);
|
|
3615
3604
|
}
|
|
3616
3605
|
finally { if (e_2) throw e_2.error; }
|
|
3617
3606
|
}
|
|
@@ -3631,7 +3620,7 @@
|
|
|
3631
3620
|
// .concat(this.table.permissions.hasAccess('Delete') ? [this.optDelete] : []);
|
|
3632
3621
|
};
|
|
3633
3622
|
TableRowComponent.prototype.getCell = function (col) {
|
|
3634
|
-
var e_4,
|
|
3623
|
+
var e_4, _e;
|
|
3635
3624
|
// console.log('getCell');
|
|
3636
3625
|
var cv = _.get(this.row.Data, col.name);
|
|
3637
3626
|
if (cv === null) {
|
|
@@ -3699,7 +3688,7 @@
|
|
|
3699
3688
|
catch (e_4_1) { e_4 = { error: e_4_1 }; }
|
|
3700
3689
|
finally {
|
|
3701
3690
|
try {
|
|
3702
|
-
if (cv_1_1 && !cv_1_1.done && (
|
|
3691
|
+
if (cv_1_1 && !cv_1_1.done && (_e = cv_1.return)) _e.call(cv_1);
|
|
3703
3692
|
}
|
|
3704
3693
|
finally { if (e_4) throw e_4.error; }
|
|
3705
3694
|
}
|