@acorex/components 3.0.36 → 3.0.40
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/acorex-components.metadata.json +1 -1
- package/bundles/acorex-components.umd.js +39 -3
- package/bundles/acorex-components.umd.js.map +1 -1
- package/bundles/acorex-components.umd.min.js +1 -1
- package/bundles/acorex-components.umd.min.js.map +1 -1
- package/esm2015/lib/checkbox/checkbox.component.js +2 -2
- package/esm2015/lib/tree-view/tree-view.component.js +39 -3
- package/esm5/lib/checkbox/checkbox.component.js +2 -2
- package/esm5/lib/tree-view/tree-view.component.js +39 -3
- package/fesm2015/acorex-components.js +39 -3
- package/fesm2015/acorex-components.js.map +1 -1
- package/fesm5/acorex-components.js +39 -3
- package/fesm5/acorex-components.js.map +1 -1
- package/lib/tree-view/tree-view.component.d.ts +1 -0
- package/package.json +1 -1
|
@@ -3822,7 +3822,7 @@
|
|
|
3822
3822
|
AXCheckBoxComponent = __decorate([
|
|
3823
3823
|
core.Component({
|
|
3824
3824
|
selector: 'ax-check-box',
|
|
3825
|
-
template: "<!-- <label class=\"ax checkbox {{size}}\" for=\"{{uid}}\" [ngClass]=\"{ 'disabled': disabled, 'readonly': readonly }\"\r\n (click)=\"handleClick($event)\">\r\n {{ label }}\r\n <input #input type=\"checkbox\" id=\"{{uid}}\" [readonly]=\"readonly\" [checked]=\"value\"\r\n [disabled]=\"disabled || readonly\" />\r\n <span class=\"checkmark\" [ngClass]=\"{'indeterminate': indeterminate && value == null}\"></span>\r\n\r\n</label> -->\r\n\r\n<label for=\"{{uid}}\" class=\"ax-checkbox-container\" (click)=\"handleClick($event)\">\r\n <input #input type=\"checkbox\" class=\"ax-checkbox\" [ngClass]=\"{'indeterminate': indeterminate && value == null}\"\r\n id=\"{{uid}}\" [readonly]=\"readonly\" [checked]=\"value\" [(ngModel)]=\"value\" [disabled]=\"disabled || readonly\" />\r\n <span>{{ label ? label : ' ' }}</span>\r\n</label>",
|
|
3825
|
+
template: "<!-- <label class=\"ax checkbox {{size}}\" for=\"{{uid}}\" [ngClass]=\"{ 'disabled': disabled, 'readonly': readonly }\"\r\n (click)=\"handleClick($event)\">\r\n {{ label }}\r\n <input #input type=\"checkbox\" id=\"{{uid}}\" [readonly]=\"readonly\" [checked]=\"value\"\r\n [disabled]=\"disabled || readonly\" />\r\n <span class=\"checkmark\" [ngClass]=\"{'indeterminate': indeterminate && value == null}\"></span>\r\n\r\n</label> -->\r\n\r\n<label for=\"{{uid}}\" class=\"ax-checkbox-container\" [ngClass]=\"{ 'disabled': disabled, 'readonly': readonly }\"\r\n (click)=\"handleClick($event)\">\r\n <input #input type=\"checkbox\" class=\"ax-checkbox\" [ngClass]=\"{'indeterminate': indeterminate && value == null}\"\r\n id=\"{{uid}}\" [readonly]=\"readonly\" [checked]=\"value\" [(ngModel)]=\"value\" [disabled]=\"disabled || readonly\" />\r\n <span>{{ label ? label : ' ' }}</span>\r\n</label>",
|
|
3826
3826
|
encapsulation: core.ViewEncapsulation.None,
|
|
3827
3827
|
changeDetection: core.ChangeDetectionStrategy.OnPush
|
|
3828
3828
|
}),
|
|
@@ -13930,6 +13930,7 @@
|
|
|
13930
13930
|
_this.onItemClosing = new core.EventEmitter();
|
|
13931
13931
|
_this.onItemDrag = new core.EventEmitter();
|
|
13932
13932
|
_this.onItemMoved = new core.EventEmitter();
|
|
13933
|
+
_this.selectableField = '';
|
|
13933
13934
|
_this.onContextMenuItemClick = new core.EventEmitter();
|
|
13934
13935
|
_this.showSelectBox = false;
|
|
13935
13936
|
_this.loading = false;
|
|
@@ -14045,6 +14046,34 @@
|
|
|
14045
14046
|
node.itemData.indeterminate = item.select === null ? true : false;
|
|
14046
14047
|
node.itemData.hasChild = item[this.hasChildField];
|
|
14047
14048
|
node.parent = item.parentNode === undefined ? null : this.makeNode(item.parentNode, false);
|
|
14049
|
+
if (node.parent != null) {
|
|
14050
|
+
node.parent.selectParent = function () {
|
|
14051
|
+
if (item.parentNode['select'] != true) {
|
|
14052
|
+
_this.internalSelectItem(item.parentNode, true);
|
|
14053
|
+
}
|
|
14054
|
+
};
|
|
14055
|
+
node.parent.unSelectParent = function () {
|
|
14056
|
+
if (item.parentNode['select'] == true) {
|
|
14057
|
+
_this.internalSelectItem(item.parentNode, true);
|
|
14058
|
+
}
|
|
14059
|
+
};
|
|
14060
|
+
}
|
|
14061
|
+
if (node.children != null && node.children.length > 0) {
|
|
14062
|
+
node.children.selectChilds = function () {
|
|
14063
|
+
item.childeren.forEach(function (element) {
|
|
14064
|
+
if (element['select'] != true) {
|
|
14065
|
+
_this.internalSelectItem(element, true);
|
|
14066
|
+
}
|
|
14067
|
+
});
|
|
14068
|
+
};
|
|
14069
|
+
node.children.unSelectChilds = function () {
|
|
14070
|
+
item.childeren.forEach(function (element) {
|
|
14071
|
+
if (element['select'] == true) {
|
|
14072
|
+
_this.internalSelectItem(element, true);
|
|
14073
|
+
}
|
|
14074
|
+
});
|
|
14075
|
+
};
|
|
14076
|
+
}
|
|
14048
14077
|
return node;
|
|
14049
14078
|
};
|
|
14050
14079
|
AXTreeViewComponent.prototype.changeChildSelect = function (item, s) {
|
|
@@ -14193,7 +14222,7 @@
|
|
|
14193
14222
|
_this.hideLoading(null);
|
|
14194
14223
|
_this.list = _data.data.result;
|
|
14195
14224
|
_this.list.forEach(function (el) {
|
|
14196
|
-
el.disabledCheckBox = false;
|
|
14225
|
+
el.disabledCheckBox = _this.selectableField != '' ? (el[_this.selectableField] ? el[_this.selectableField] : false) : false;
|
|
14197
14226
|
el.select = false;
|
|
14198
14227
|
if (_this.selectionLevel == 'nodes' && el[_this.hasChildField] == true) {
|
|
14199
14228
|
el.disabledCheckBox = true;
|
|
@@ -14243,7 +14272,8 @@
|
|
|
14243
14272
|
if (_this.list.length !== 0) {
|
|
14244
14273
|
if (_this.itemRow[_this.childField] && _this.itemRow[_this.childField].length > 0) {
|
|
14245
14274
|
result_1.forEach(function (el) {
|
|
14246
|
-
el.disabledCheckBox = false;
|
|
14275
|
+
el.disabledCheckBox = _this.selectableField != '' ? (el[_this.selectableField] ? el[_this.selectableField] : false) : false;
|
|
14276
|
+
// el.disabledCheckBox = this.selectableField != '' ? el[this.selectableField] : false;
|
|
14247
14277
|
_this.itemRow[_this.childField][_this.itemRow[_this.childField].length] = el;
|
|
14248
14278
|
});
|
|
14249
14279
|
}
|
|
@@ -14251,6 +14281,8 @@
|
|
|
14251
14281
|
_this.itemRow[_this.childField] = result_1;
|
|
14252
14282
|
}
|
|
14253
14283
|
var _loop_1 = function (i) {
|
|
14284
|
+
result_1[i].disabledCheckBox =
|
|
14285
|
+
_this.selectableField != '' ? (result_1[i][_this.selectableField] ? result_1[i][_this.selectableField] : false) : false;
|
|
14254
14286
|
if (_this.selectionLevel == 'nodes' && result_1[i][_this.hasChildField] == true) {
|
|
14255
14287
|
result_1[i].disabledCheckBox = true;
|
|
14256
14288
|
}
|
|
@@ -14614,6 +14646,10 @@
|
|
|
14614
14646
|
core.Output(),
|
|
14615
14647
|
__metadata("design:type", core.EventEmitter)
|
|
14616
14648
|
], AXTreeViewComponent.prototype, "onItemMoved", void 0);
|
|
14649
|
+
__decorate([
|
|
14650
|
+
core.Input(),
|
|
14651
|
+
__metadata("design:type", String)
|
|
14652
|
+
], AXTreeViewComponent.prototype, "selectableField", void 0);
|
|
14617
14653
|
__decorate([
|
|
14618
14654
|
core.Output(),
|
|
14619
14655
|
__metadata("design:type", core.EventEmitter)
|