ps-toolkit-ui 0.0.55 → 0.0.59
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 +19 -19
- 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/classes/form.class.js +1 -2
- package/esm2015/lib/components/form/tree/form.tree.component.js +6 -11
- package/fesm2015/ps-toolkit-ui.js +5 -11
- package/fesm2015/ps-toolkit-ui.js.map +1 -1
- package/lib/components/form/tree/form.tree.component.d.ts +1 -1
- package/package.json +1 -1
- package/ps-toolkit-ui.metadata.json +1 -1
|
@@ -1879,7 +1879,6 @@
|
|
|
1879
1879
|
TreeRowClass.prototype.check = function (onlyChild, c) {
|
|
1880
1880
|
if (c === void 0) { c = this; }
|
|
1881
1881
|
c.selected = true;
|
|
1882
|
-
c.checkChildren(onlyChild);
|
|
1883
1882
|
if (onlyChild) {
|
|
1884
1883
|
c.checkChildren(onlyChild);
|
|
1885
1884
|
}
|
|
@@ -5741,43 +5740,44 @@
|
|
|
5741
5740
|
});
|
|
5742
5741
|
return l;
|
|
5743
5742
|
};
|
|
5744
|
-
FormTreeComponent.prototype.check = function (ids) {
|
|
5743
|
+
FormTreeComponent.prototype.check = function (ids, chs) {
|
|
5745
5744
|
var e_2, _a;
|
|
5746
|
-
|
|
5747
|
-
console.log(this.inp.rows);
|
|
5745
|
+
if (chs === void 0) { chs = this.inp.rows; }
|
|
5748
5746
|
try {
|
|
5749
|
-
for (var
|
|
5750
|
-
var r =
|
|
5751
|
-
r.
|
|
5752
|
-
|
|
5753
|
-
r.toggle(this.inp.onlyChild);
|
|
5754
|
-
}
|
|
5755
|
-
this.checkChildren(r.children, ids);
|
|
5747
|
+
for (var chs_1 = __values(chs), chs_1_1 = chs_1.next(); !chs_1_1.done; chs_1_1 = chs_1.next()) {
|
|
5748
|
+
var r = chs_1_1.value;
|
|
5749
|
+
r.selected = ids.includes(r.value);
|
|
5750
|
+
this.check(ids, r.children);
|
|
5756
5751
|
}
|
|
5757
5752
|
}
|
|
5758
5753
|
catch (e_2_1) { e_2 = { error: e_2_1 }; }
|
|
5759
5754
|
finally {
|
|
5760
5755
|
try {
|
|
5761
|
-
if (
|
|
5756
|
+
if (chs_1_1 && !chs_1_1.done && (_a = chs_1.return)) _a.call(chs_1);
|
|
5762
5757
|
}
|
|
5763
5758
|
finally { if (e_2) throw e_2.error; }
|
|
5764
5759
|
}
|
|
5765
5760
|
};
|
|
5766
5761
|
FormTreeComponent.prototype.checkChildren = function (chs, ids) {
|
|
5767
5762
|
var e_3, _a;
|
|
5763
|
+
var _this = this;
|
|
5764
|
+
var _loop_1 = function (r) {
|
|
5765
|
+
if (ids.includes(r.value)) {
|
|
5766
|
+
r.toggle(this_1.inp.onlyChild);
|
|
5767
|
+
}
|
|
5768
|
+
setTimeout(function () { _this.checkChildren(r.children, ids); });
|
|
5769
|
+
};
|
|
5770
|
+
var this_1 = this;
|
|
5768
5771
|
try {
|
|
5769
|
-
for (var
|
|
5770
|
-
var r =
|
|
5771
|
-
|
|
5772
|
-
r.toggle(this.inp.onlyChild);
|
|
5773
|
-
}
|
|
5774
|
-
this.checkChildren(r.children, ids);
|
|
5772
|
+
for (var chs_2 = __values(chs), chs_2_1 = chs_2.next(); !chs_2_1.done; chs_2_1 = chs_2.next()) {
|
|
5773
|
+
var r = chs_2_1.value;
|
|
5774
|
+
_loop_1(r);
|
|
5775
5775
|
}
|
|
5776
5776
|
}
|
|
5777
5777
|
catch (e_3_1) { e_3 = { error: e_3_1 }; }
|
|
5778
5778
|
finally {
|
|
5779
5779
|
try {
|
|
5780
|
-
if (
|
|
5780
|
+
if (chs_2_1 && !chs_2_1.done && (_a = chs_2.return)) _a.call(chs_2);
|
|
5781
5781
|
}
|
|
5782
5782
|
finally { if (e_3) throw e_3.error; }
|
|
5783
5783
|
}
|