From a2c0c89af926684826f3e7f23579c8fd20c25328 Mon Sep 17 00:00:00 2001 From: vpj-cd Date: Sun, 30 Aug 2009 05:26:10 +0000 Subject: [PATCH] The Include_Tab_ID in the AD_Field do not found in AD http://sourceforge.net/tracker/?func=detail&atid=879332&aid=2847157&group_id=176962 --- base/src/org/compiere/model/I_AD_Field.java | 13 +++++++++++ base/src/org/compiere/model/X_AD_Field.java | 23 +++++++++++++++++++ .../oracle/547_BF2847157_Include_Tab_ID.sql | 17 ++++++++++++++ .../547_BF2847157_Include_Tab_ID.sql | 17 ++++++++++++++ 4 files changed, 70 insertions(+) create mode 100644 migration/353a-trunk/oracle/547_BF2847157_Include_Tab_ID.sql create mode 100644 migration/353a-trunk/postgresql/547_BF2847157_Include_Tab_ID.sql diff --git a/base/src/org/compiere/model/I_AD_Field.java b/base/src/org/compiere/model/I_AD_Field.java index db542ee144..9eccb5539c 100644 --- a/base/src/org/compiere/model/I_AD_Field.java +++ b/base/src/org/compiere/model/I_AD_Field.java @@ -259,6 +259,19 @@ public interface I_AD_Field */ public String getHelp(); + /** Column name Included_Tab_ID */ + public static final String COLUMNNAME_Included_Tab_ID = "Included_Tab_ID"; + + /** Set Included Tab. + * Included Tab in this Tab (Master Dateail) + */ + public void setIncluded_Tab_ID (int Included_Tab_ID); + + /** Get Included Tab. + * Included Tab in this Tab (Master Dateail) + */ + public int getIncluded_Tab_ID(); + /** Column name InfoFactoryClass */ public static final String COLUMNNAME_InfoFactoryClass = "InfoFactoryClass"; diff --git a/base/src/org/compiere/model/X_AD_Field.java b/base/src/org/compiere/model/X_AD_Field.java index 382929bfb3..15cd2655d0 100644 --- a/base/src/org/compiere/model/X_AD_Field.java +++ b/base/src/org/compiere/model/X_AD_Field.java @@ -421,6 +421,29 @@ public class X_AD_Field extends PO implements I_AD_Field, I_Persistent return (String)get_Value(COLUMNNAME_Help); } + /** Set Included Tab. + @param Included_Tab_ID + Included Tab in this Tab (Master Dateail) + */ + public void setIncluded_Tab_ID (int Included_Tab_ID) + { + if (Included_Tab_ID < 1) + set_Value (COLUMNNAME_Included_Tab_ID, null); + else + set_Value (COLUMNNAME_Included_Tab_ID, Integer.valueOf(Included_Tab_ID)); + } + + /** Get Included Tab. + @return Included Tab in this Tab (Master Dateail) + */ + public int getIncluded_Tab_ID () + { + Integer ii = (Integer)get_Value(COLUMNNAME_Included_Tab_ID); + if (ii == null) + return 0; + return ii.intValue(); + } + /** Set Info Factory Class. @param InfoFactoryClass Fully qualified class name that implements the InfoFactory interface diff --git a/migration/353a-trunk/oracle/547_BF2847157_Include_Tab_ID.sql b/migration/353a-trunk/oracle/547_BF2847157_Include_Tab_ID.sql new file mode 100644 index 0000000000..d05c25040d --- /dev/null +++ b/migration/353a-trunk/oracle/547_BF2847157_Include_Tab_ID.sql @@ -0,0 +1,17 @@ +-- Aug 29, 2009 11:55:21 PM ECT +-- Create Field IncludeTab_ID +INSERT INTO AD_Column (AD_Client_ID,AD_Column_ID,AD_Element_ID,AD_Org_ID,AD_Reference_ID,AD_Table_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsAlwaysUpdateable,IsEncrypted,IsIdentifier,IsKey,IsMandatory,IsParent,IsSelectionColumn,IsTranslated,IsUpdateable,Name,Updated,UpdatedBy,Version) VALUES (0,57957,2026,0,19,107,'Included_Tab_ID',TO_DATE('2009-08-29 23:55:18','YYYY-MM-DD HH24:MI:SS'),100,'Included Tab in this Tab (Master Dateail)','D',10,'You can include a Tab in a Tab. If displayed in single row record, the included tab is displayed as multi-row table.','Y','N','N','N','N','N','N','N','N','Y','Included Tab',TO_DATE('2009-08-29 23:55:18','YYYY-MM-DD HH24:MI:SS'),100,0) +; + +-- Aug 29, 2009 11:55:21 PM ECT +-- Create Field IncludeTab_ID +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Column_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=57957 AND EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Column_ID!=t.AD_Column_ID) +; + +-- Aug 29, 2009 11:55:59 PM ECT +-- Create Field IncludeTab_ID +UPDATE AD_Column SET AD_Reference_ID=18, AD_Reference_Value_ID=278,Updated=TO_DATE('2009-08-29 23:55:59','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=57957 +; +-- Create Field IncludeTab_ID +UPDATE AD_Field SET AD_Column_ID =57957 WHERE AD_Field_ID=6432 +; \ No newline at end of file diff --git a/migration/353a-trunk/postgresql/547_BF2847157_Include_Tab_ID.sql b/migration/353a-trunk/postgresql/547_BF2847157_Include_Tab_ID.sql new file mode 100644 index 0000000000..92154681c4 --- /dev/null +++ b/migration/353a-trunk/postgresql/547_BF2847157_Include_Tab_ID.sql @@ -0,0 +1,17 @@ +-- Aug 29, 2009 11:55:21 PM ECT +-- Create Field IncludeTab_ID +INSERT INTO AD_Column (AD_Client_ID,AD_Column_ID,AD_Element_ID,AD_Org_ID,AD_Reference_ID,AD_Table_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsAlwaysUpdateable,IsEncrypted,IsIdentifier,IsKey,IsMandatory,IsParent,IsSelectionColumn,IsTranslated,IsUpdateable,Name,Updated,UpdatedBy,Version) VALUES (0,57957,2026,0,19,107,'Included_Tab_ID',TO_TIMESTAMP('2009-08-29 23:55:18','YYYY-MM-DD HH24:MI:SS'),100,'Included Tab in this Tab (Master Dateail)','D',10,'You can include a Tab in a Tab. If displayed in single row record, the included tab is displayed as multi-row table.','Y','N','N','N','N','N','N','N','N','Y','Included Tab',TO_TIMESTAMP('2009-08-29 23:55:18','YYYY-MM-DD HH24:MI:SS'),100,0) +; + +-- Aug 29, 2009 11:55:21 PM ECT +-- Create Field IncludeTab_ID +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Column_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=57957 AND EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Column_ID!=t.AD_Column_ID) +; + +-- Aug 29, 2009 11:55:59 PM ECT +-- Create Field IncludeTab_ID +UPDATE AD_Column SET AD_Reference_ID=18, AD_Reference_Value_ID=278,Updated=TO_TIMESTAMP('2009-08-29 23:55:59','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=57957 +; +-- Create Field IncludeTab_ID +UPDATE AD_Field SET AD_Column_ID =57957 WHERE AD_Field_ID=6432 +;