@one-paragon/angular-utilities 0.0.22 → 0.0.23
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/esm2020/table-builder/components/generic-table/generic-table.component.mjs +15 -1
- package/esm2020/table-builder/components/table-container/table-container.mjs +2 -1
- package/fesm2015/one-paragon-angular-utilities.mjs +16 -0
- package/fesm2015/one-paragon-angular-utilities.mjs.map +1 -1
- package/fesm2020/one-paragon-angular-utilities.mjs +15 -0
- package/fesm2020/one-paragon-angular-utilities.mjs.map +1 -1
- package/package.json +1 -1
- package/table-builder/components/generic-table/generic-table.component.d.ts +3 -1
|
@@ -1693,6 +1693,20 @@ class GenericTableComponent {
|
|
|
1693
1693
|
drop(event) {
|
|
1694
1694
|
this.state.setUserDefinedOrder({ newOrder: event.currentIndex, oldOrder: event.previousIndex });
|
|
1695
1695
|
}
|
|
1696
|
+
set disableSort(val) {
|
|
1697
|
+
this._disableSort = val;
|
|
1698
|
+
if (val) {
|
|
1699
|
+
if (this.dataSource?.sort) {
|
|
1700
|
+
this.dataSource.sort = null;
|
|
1701
|
+
}
|
|
1702
|
+
}
|
|
1703
|
+
else {
|
|
1704
|
+
if (this.dataSource && !this.dataSource.sort) {
|
|
1705
|
+
this.dataSource.sort = this.sort;
|
|
1706
|
+
}
|
|
1707
|
+
}
|
|
1708
|
+
}
|
|
1709
|
+
get disableSort() { return this._disableSort; }
|
|
1696
1710
|
ngOnChanges(changes) {
|
|
1697
1711
|
if (changes.rows && this.rows && this.myColumns.length) {
|
|
1698
1712
|
this.initializeRowDefs([...this.rows]);
|
|
@@ -3037,6 +3051,7 @@ class TableContainerComponent {
|
|
|
3037
3051
|
getData(data, metaData) {
|
|
3038
3052
|
const meta = metaData.find(m => m.additional?.grouping?.groupBy);
|
|
3039
3053
|
if (!meta) {
|
|
3054
|
+
this.disableSort = false;
|
|
3040
3055
|
return data;
|
|
3041
3056
|
}
|
|
3042
3057
|
this.disableSort = true;
|