@quadrel-enterprise-ui/framework 21.4.1 → 21.4.2
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.
|
@@ -28874,6 +28874,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.17", ngImpo
|
|
|
28874
28874
|
}] });
|
|
28875
28875
|
|
|
28876
28876
|
// @ts-strict-ignore
|
|
28877
|
+
const RESERVED_ROW_PROPERTIES = ['uid', 'nestedRows', 'expanded', 'full'];
|
|
28877
28878
|
class QdTreeRowsService {
|
|
28878
28879
|
groupService = inject(QdTreeGroupService);
|
|
28879
28880
|
expanderService = inject(QdTreeRowExpanderService, { optional: true });
|
|
@@ -28927,6 +28928,9 @@ class QdTreeRowsService {
|
|
|
28927
28928
|
this.ungroupedColumns.forEach(column => {
|
|
28928
28929
|
lastTreeRow[column.column] = row[column.column];
|
|
28929
28930
|
});
|
|
28931
|
+
this.getMetadataProperties(row).forEach(property => {
|
|
28932
|
+
lastTreeRow[property] = row[property];
|
|
28933
|
+
});
|
|
28930
28934
|
if (row.uid)
|
|
28931
28935
|
lastTreeRow.uid = row.uid;
|
|
28932
28936
|
lastTreeRow.nestedRows = row.nestedRows;
|
|
@@ -28935,6 +28939,13 @@ class QdTreeRowsService {
|
|
|
28935
28939
|
}
|
|
28936
28940
|
return this.nestRowsIntoOneAnother(treeRows);
|
|
28937
28941
|
}
|
|
28942
|
+
getMetadataProperties(row) {
|
|
28943
|
+
const configuredColumns = [
|
|
28944
|
+
...this.groupColumn.groupedColumns.map(column => column.column),
|
|
28945
|
+
...this.ungroupedColumns.map(column => column.column)
|
|
28946
|
+
];
|
|
28947
|
+
return Object.keys(row).filter(property => !configuredColumns.includes(property) && !RESERVED_ROW_PROPERTIES.includes(property));
|
|
28948
|
+
}
|
|
28938
28949
|
nestRowsIntoOneAnother(rows) {
|
|
28939
28950
|
let rootRow = rows[0];
|
|
28940
28951
|
for (let index = 1; index < rows.length; index++) {
|