diff --git a/eda/eda_app/src/app/module/components/eda-panels/eda-blank-panel/eda-blank-panel.component.html b/eda/eda_app/src/app/module/components/eda-panels/eda-blank-panel/eda-blank-panel.component.html
index b39f67084..291ed5d99 100644
--- a/eda/eda_app/src/app/module/components/eda-panels/eda-blank-panel/eda-blank-panel.component.html
+++ b/eda/eda_app/src/app/module/components/eda-panels/eda-blank-panel/eda-blank-panel.component.html
@@ -433,17 +433,21 @@
Resumen de atributos
-
-
{{ getColumnJoins(column) }}
-
-
{{ getNiceTableName(column.table_id) }} → {{column.display_name.default}}
+
+
+
+
+
+ {{ getNiceTableName(column.table_id) }}
+
+ {{column.display_name.default}}
+
-
-
+
+
( {{aggregation.display_name}} )
-
+
@@ -454,9 +458,12 @@
Resumen de filtros del panel
-
-
{{filter.filter_table}} . {{filter.filter_column}} (
- {{filter.filter_type}} )
+
+
+
+
+
+
@@ -465,9 +472,10 @@
Resumen de filtros del informe
-
-
{{filter.filter_table}} . {{filter.filter_column}} (
- {{filter.filter_type}} )
+
+
+
+
diff --git a/eda/eda_app/src/app/module/components/eda-panels/eda-blank-panel/eda-blank-panel.component.ts b/eda/eda_app/src/app/module/components/eda-panels/eda-blank-panel/eda-blank-panel.component.ts
index 1901f35bf..a48556e7e 100644
--- a/eda/eda_app/src/app/module/components/eda-panels/eda-blank-panel/eda-blank-panel.component.ts
+++ b/eda/eda_app/src/app/module/components/eda-panels/eda-blank-panel/eda-blank-panel.component.ts
@@ -827,9 +827,10 @@ export class EdaBlankPanelComponent implements OnInit {
this.display_v.saved_panel = false;
this.columns = [];
this.currentQuery = [];
- if (this.panelDeepCopy.query) {
+ if (this.panelDeepCopy.query) {
this.panelDeepCopy.query.query.filters = this.mergeFilters(this.panelDeepCopy.query.query.filters, this.globalFilters);
+
this.filtredColumns = [];
//Reassing sqlQuery -if exists
this.currentSQLQuery = this.panelDeepCopy.query.query.SQLexpression;
@@ -1176,7 +1177,7 @@ export class EdaBlankPanelComponent implements OnInit {
let tableName = this.getNiceTableName(table);
if (!tableName) tableName = this.getNiceTableName(table.split('.')[0]);
- pathStr += ` ${tableName} → `;
+ pathStr += ` ${tableName} `;
}
} else if (column.valueListSource) {
const tableName = this.getNiceTableName(column.valueListSource.target_table);
@@ -1186,6 +1187,63 @@ export class EdaBlankPanelComponent implements OnInit {
return pathStr
}
+ public getFilterJoins(filter: any) {
+ let pathStr = '';
+ if (filter.joins?.length > 0) {
+
+ for (const path of filter.joins) {
+ const table = (path[0]||'');
+ let tableName = this.getNiceTableName(table);
+ if (!tableName) tableName = this.getNiceTableName(table.split('.')[0]);
+
+ pathStr += ` ${tableName} `;
+ }
+ } else if (filter.valueListSource) {
+ const tableName = this.getNiceTableName(filter.valueListSource.target_table);
+ if (tableName) pathStr += ` ${tableName} → `;
+ }
+
+ return pathStr
+ }
+
+ public getDisplayFilterStr(filter: any) {
+ let str = '';
+
+ const table = this.findTable(filter.filter_table.split('.')[0]);
+
+ if (table.table_name) {
+ const tableName = table.display_name?.default;
+ const columnName = table.columns.find((c) => c.column_name == filter.filter_column)?.display_name?.default;
+
+ const values = filter.filter_elements[0]?.value1;
+ const values2 = filter.filter_elements[1]?.value2;
+ let valueStr = '';
+
+ if (values) {
+ if (values.length == 1 && !['in', 'not_in'].includes(filter.filter_type)) {
+ valueStr = `"${values[0]}"`;
+ } else if (values.length > 1 || ['in', 'not_in'].includes(filter.filter_type)) {
+ valueStr = `[${values.map((v: string) => (`"${v}"`) ).join(', ')}]`;
+ }
+
+ if (values2) {
+ if (values2.length == 1) {
+ valueStr = `AND "${values2[0]}"`;
+ } else if (values2.length > 1) {
+ valueStr = `AND [${values2.map((v: string) => (`"${v}"`) ).join(', ')}]`;
+ }
+ }
+
+ }
+
+
+ str = `${tableName} [${columnName}] ${filter.filter_type} ${valueStr}`;
+ }
+
+
+ return str;
+ }
+
/* SDA CUSTOM */ public showIdForHiddenMode() {
/* SDA CUSTOM */ if (this.inject.dataSource._id == "111111111111111111111111") {
/* SDA CUSTOM */ this.showHiddId = true;
diff --git a/eda/eda_app/src/app/module/pages/dashboard/global-filter-dialog/global-filter-dialog.component.html b/eda/eda_app/src/app/module/pages/dashboard/global-filter-dialog/global-filter-dialog.component.html
index d33a0d334..c02ec413b 100644
--- a/eda/eda_app/src/app/module/pages/dashboard/global-filter-dialog/global-filter-dialog.component.html
+++ b/eda/eda_app/src/app/module/pages/dashboard/global-filter-dialog/global-filter-dialog.component.html
@@ -82,6 +82,18 @@
(onNodeExpand)="onNodeExpand(panel, $event)"
(onNodeSelect)="onNodeSelect(panel, $event)" appendTo="body"
[disabled]="!panel.active || !panel.avaliable">
+
+
+
+
+
+
+ {{node.label}}
+
+
+
+ {{node.label}}
+
diff --git a/eda/eda_app/src/app/module/pages/dashboard/global-filter-dialog/global-filter-dialog.component.ts b/eda/eda_app/src/app/module/pages/dashboard/global-filter-dialog/global-filter-dialog.component.ts
index 30b9bee34..7bbb7aa7f 100644
--- a/eda/eda_app/src/app/module/pages/dashboard/global-filter-dialog/global-filter-dialog.component.ts
+++ b/eda/eda_app/src/app/module/pages/dashboard/global-filter-dialog/global-filter-dialog.component.ts
@@ -411,6 +411,44 @@ export class GlobalFilterDialogComponent implements OnInit, OnDestroy {
}
}
+ public checkNodeSelected(selectedPath: any, node: any) {
+ if (node?.child_id) {
+ let selected = false;
+ for (const join of selectedPath.joins) {
+ if (join[1] == node.child_id) {
+ selected = true;
+ }
+ }
+ return selected;
+ } else {
+ return false;
+ }
+ }
+
+ private findTable(tableName: string) {
+ return this.modelTables.find((table: any) => table.table_name === tableName);
+ }
+
+ public getDisplayPathStr(node: any) {
+ let str = '';
+
+ if ((node.joins||[]).length > 0) {
+ for (const join of node.joins) {
+ const table = this.findTable(join[0]?.split('.')[0]);
+
+ if (table) {
+ str += `${table.display_name.default}  `
+ }
+ }
+
+ str += `${node.label}`;
+ } else {
+ str = `${node.label}`;
+ }
+
+ return str;
+ }
+
public onApply(): void {
if (this.validateGlobalFilter()) {
this.globalFilterChange.emit(this.globalFilter);