perspectives WIP

This commit is contained in:
Jan Prochazka
2022-06-23 16:50:56 +02:00
parent aca92f3889
commit b6b75f0743
3 changed files with 39 additions and 4 deletions

View File

@@ -53,6 +53,9 @@ export abstract class PerspectiveTreeNode {
get fieldName() {
return this.codeName;
}
get dataField() {
return this.codeName;
}
abstract getNodeLoadProps(parentRows: any[]): PerspectiveDataLoadProps;
get isRoot() {
return this.parentNode == null;
@@ -75,6 +78,9 @@ export abstract class PerspectiveTreeNode {
get isChecked() {
return this.config.checkedColumns.includes(this.uniqueName);
}
get columnTitle() {
return this.title;
}
toggleExpanded(value?: boolean) {
this.includeInColumnSet('expandedColumns', this.uniqueName, value == null ? !this.isExpanded : value);
@@ -233,6 +239,10 @@ export class PerspectiveTableReferenceNode extends PerspectiveTableNode {
dataColumns: null,
};
}
get columnTitle() {
return this.table.pureName;
}
}
export function getTableChildPerspectiveNodes(