From a004acbaebb119cf7ad9a9e463141b4ec688e60d Mon Sep 17 00:00:00 2001 From: EdwinBetanc0urt Date: Wed, 24 Apr 2024 15:58:47 -0400 Subject: [PATCH] feat: Add default displayed on vue. --- .../spin/eca56/util/support/documents/Browser.java | 12 ++++++++++-- .../spin/eca56/util/support/documents/Process.java | 2 ++ .../spin/eca56/util/support/documents/Window.java | 3 +++ 3 files changed, 15 insertions(+), 2 deletions(-) diff --git a/src/main/java/org/spin/eca56/util/support/documents/Browser.java b/src/main/java/org/spin/eca56/util/support/documents/Browser.java index 4860013..d982770 100644 --- a/src/main/java/org/spin/eca56/util/support/documents/Browser.java +++ b/src/main/java/org/spin/eca56/util/support/documents/Browser.java @@ -167,7 +167,10 @@ private Map parseField(MBrowseField field) { detail.put("display_logic", field.getDisplayLogic()); detail.put("sequence", field.getSeqNo()); detail.put("grid_sequence", field.getSeqNoGrid()); - + // Custom display + detail.put("is_displayed_as_panel", field.isQueryCriteria() ? "Y" : "N"); + detail.put("is_displayed_as_table", field.isDisplayed() ? 'Y' : 'N'); + // Editable Properties detail.put("is_read_only", field.isReadOnly()); detail.put("read_only_logic", field.getReadOnlyLogic()); @@ -186,7 +189,12 @@ private Map parseField(MBrowseField field) { elementName = field.getAD_Element().getColumnName(); } detail.put("element_name", elementName); - ReferenceValues referenceValues = ReferenceUtil.getReferenceDefinition(columnName, field.getAD_Reference_ID(), field.getAD_Reference_Value_ID(), field.getAD_Val_Rule_ID()); + ReferenceValues referenceValues = ReferenceUtil.getReferenceDefinition( + elementName, + field.getAD_Reference_ID(), + field.getAD_Reference_Value_ID(), + field.getAD_Val_Rule_ID() + ); if(referenceValues != null) { Map referenceDetail = new HashMap<>(); // referenceDetail.put("id", referenceValues.getReferenceId()); diff --git a/src/main/java/org/spin/eca56/util/support/documents/Process.java b/src/main/java/org/spin/eca56/util/support/documents/Process.java index 56011a4..91a985b 100644 --- a/src/main/java/org/spin/eca56/util/support/documents/Process.java +++ b/src/main/java/org/spin/eca56/util/support/documents/Process.java @@ -148,6 +148,8 @@ Map parseProcessParameter(MProcessPara parameter) { // Display Properties detail.put("display_logic", parameter.getDisplayLogic()); detail.put("sequence", parameter.getSeqNo()); + // Custom display + detail.put("is_displayed_as_panel", "Y"); // Mandatory Properties detail.put("is_mandatory", parameter.isMandatory()); diff --git a/src/main/java/org/spin/eca56/util/support/documents/Window.java b/src/main/java/org/spin/eca56/util/support/documents/Window.java index c50f648..c157398 100644 --- a/src/main/java/org/spin/eca56/util/support/documents/Window.java +++ b/src/main/java/org/spin/eca56/util/support/documents/Window.java @@ -346,6 +346,9 @@ private Map parseField(MField field) { detail.put("sequence", field.getSeqNo()); detail.put("is_displayed_grid", field.isDisplayedGrid()); detail.put("grid_sequence", field.getSeqNoGrid()); + // Custom display + detail.put("is_displayed_as_panel", field.isDisplayed() ? "Y" : "N"); + detail.put("is_displayed_as_table", field.isDisplayedGrid() ? 'Y' : 'N'); // Editable Properties detail.put("is_read_only", field.isReadOnly());