IDEMPIERE-3760 Implement Virtual UI Column
This commit is contained in:
parent
fed84e92e1
commit
8c30a6c6cd
|
@ -0,0 +1,173 @@
|
||||||
|
SET SQLBLANKLINES ON
|
||||||
|
SET DEFINE OFF
|
||||||
|
|
||||||
|
-- IDEMPIERE-3760 Implement Virtual UI Column
|
||||||
|
-- Jul 25, 2018 6:02:03 PM CEST
|
||||||
|
UPDATE AD_Column SET FieldLength=4000,Updated=TO_DATE('2018-07-25 18:02:03','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=13448
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:02:05 PM CEST
|
||||||
|
ALTER TABLE AD_Column MODIFY ColumnSQL VARCHAR2(4000) DEFAULT NULL
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:02:36 PM CEST
|
||||||
|
UPDATE AD_Field SET AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, NumLines=2, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:02:36','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=11264
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:05:35 PM CEST
|
||||||
|
UPDATE AD_Field SET Help='You can define virtual columns (not stored in the database). If defined, the Column name is the synonym of the SQL expression defined here. The SQL expression must be valid.<br>
|
||||||
|
Example: "Updated-Created" would list the age of the entry in days.
|
||||||
|
You can also use the syntax @SQL= to define a UI virtual column - this is calculated on the fly and can use context variables in the query, virtual UI columns are not searchable, and they are not shown in reports.', IsCentrallyMaintained='N', AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:05:35','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=11264
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=140, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=170
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=150, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=172
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=160, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=1, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=158
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=170, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=5, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=205668
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=180, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=6, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=56279
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=190, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=56374
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=200, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=310
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=210, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=2526
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=220, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=59619
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=230, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=204220
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=240, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=171
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=250, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=2574
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=260, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=3, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=2573
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=270, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=5, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=161
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=280, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=6, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=162
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=290, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=202518
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=300, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=202519
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=310, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=160
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=320, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=166
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=330, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=3, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=2370
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=340, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=4, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=10128
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=350, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=5122
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=360, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=169
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=370, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=4941
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=380, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=50188
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=390, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=168
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:28 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=400, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, ColumnSpan=2, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:28','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=159
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:28 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=410, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:28','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=4940
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:28 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=420, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:28','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=200288
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:28 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=430, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:28','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=56317
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:28 PM CEST
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=440, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=3, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:28','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=62467
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:28 PM CEST
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=450, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=4, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:28','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=202257
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:28 PM CEST
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=460, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=5, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:28','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=200648
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:28 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=470, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:28','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=167
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:28 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=480, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:28:28','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=825
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:29:46 PM CEST
|
||||||
|
UPDATE AD_Field SET AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, NumLines=1, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:29:46','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=160
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:29:56 PM CEST
|
||||||
|
UPDATE AD_Field SET AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, NumLines=1, IsToolbarButton=NULL,Updated=TO_DATE('2018-07-25 18:29:56','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=4941
|
||||||
|
;
|
||||||
|
|
||||||
|
SELECT register_migration_script('201807251833_IDEMPIERE-3760.sql') FROM dual
|
||||||
|
;
|
||||||
|
|
|
@ -0,0 +1,170 @@
|
||||||
|
-- IDEMPIERE-3760 Implement Virtual UI Column
|
||||||
|
-- Jul 25, 2018 6:02:03 PM CEST
|
||||||
|
UPDATE AD_Column SET FieldLength=4000,Updated=TO_TIMESTAMP('2018-07-25 18:02:03','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=13448
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:02:05 PM CEST
|
||||||
|
INSERT INTO t_alter_column values('ad_column','ColumnSQL','VARCHAR(4000)',null,'NULL')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:02:36 PM CEST
|
||||||
|
UPDATE AD_Field SET AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, NumLines=2, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:02:36','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=11264
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:05:35 PM CEST
|
||||||
|
UPDATE AD_Field SET Help='You can define virtual columns (not stored in the database). If defined, the Column name is the synonym of the SQL expression defined here. The SQL expression must be valid.<br>
|
||||||
|
Example: "Updated-Created" would list the age of the entry in days.
|
||||||
|
You can also use the syntax @SQL= to define a UI virtual column - this is calculated on the fly and can use context variables in the query, virtual UI columns are not searchable, and they are not shown in reports.', IsCentrallyMaintained='N', AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:05:35','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=11264
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=140, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=170
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=150, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=172
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=160, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=1, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=158
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=170, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=5, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=205668
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=180, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=6, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=56279
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=190, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=56374
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=200, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=310
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=210, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=2526
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=220, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=59619
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=230, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=204220
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=240, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=171
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=250, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=2574
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=260, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=3, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=2573
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=270, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=5, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=161
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=280, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=6, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=162
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=290, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=202518
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=300, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=202519
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=310, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=160
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=320, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=166
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=330, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=3, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=2370
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=340, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=4, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=10128
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=350, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=5122
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=360, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=169
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=370, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=4941
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=380, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=50188
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:27 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=390, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=168
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:28 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=400, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, ColumnSpan=2, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:28','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=159
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:28 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=410, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:28','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=4940
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:28 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=420, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:28','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=200288
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:28 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=430, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:28','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=56317
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:28 PM CEST
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=440, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=3, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:28','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=62467
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:28 PM CEST
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=450, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=4, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:28','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=202257
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:28 PM CEST
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=460, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=5, ColumnSpan=1, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:28','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=200648
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:28 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=470, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:28','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=167
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:28:28 PM CEST
|
||||||
|
UPDATE AD_Field SET SeqNo=480, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:28:28','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=825
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:29:46 PM CEST
|
||||||
|
UPDATE AD_Field SET AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, NumLines=1, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:29:46','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=160
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Jul 25, 2018 6:29:56 PM CEST
|
||||||
|
UPDATE AD_Field SET AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, NumLines=1, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2018-07-25 18:29:56','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=4941
|
||||||
|
;
|
||||||
|
|
||||||
|
SELECT register_migration_script('201807251833_IDEMPIERE-3760.sql') FROM dual
|
||||||
|
;
|
||||||
|
|
|
@ -85,7 +85,7 @@ public class GridField
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
private static final long serialVersionUID = 8599010602475684052L;
|
private static final long serialVersionUID = -1871840570764036802L;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Field Constructor.
|
* Field Constructor.
|
||||||
|
@ -307,6 +307,9 @@ public class GridField
|
||||||
Evaluator.parseDepends(list, m_vo.DisplayLogic);
|
Evaluator.parseDepends(list, m_vo.DisplayLogic);
|
||||||
Evaluator.parseDepends(list, m_vo.ReadOnlyLogic);
|
Evaluator.parseDepends(list, m_vo.ReadOnlyLogic);
|
||||||
Evaluator.parseDepends(list, m_vo.MandatoryLogic);
|
Evaluator.parseDepends(list, m_vo.MandatoryLogic);
|
||||||
|
// Virtual UI Column
|
||||||
|
if (m_vo.ColumnSQL != null && m_vo.ColumnSQL.length() > 0 && m_vo.ColumnSQL.startsWith("@SQL="))
|
||||||
|
Evaluator.parseDepends(list, m_vo.ColumnSQL.substring(5));
|
||||||
// Lookup
|
// Lookup
|
||||||
if (m_lookup != null)
|
if (m_lookup != null)
|
||||||
Evaluator.parseDepends(list, m_lookup.getValidation());
|
Evaluator.parseDepends(list, m_lookup.getValidation());
|
||||||
|
@ -1365,10 +1368,15 @@ public class GridField
|
||||||
{
|
{
|
||||||
if (m_vo.ColumnSQL != null && m_vo.ColumnSQL.length() > 0)
|
if (m_vo.ColumnSQL != null && m_vo.ColumnSQL.length() > 0)
|
||||||
{
|
{
|
||||||
if (withAS)
|
String query;
|
||||||
return m_vo.ColumnSQL + " AS " + m_vo.ColumnName;
|
if (m_vo.ColumnSQL.startsWith("@SQL="))
|
||||||
|
query = "NULL";
|
||||||
else
|
else
|
||||||
return m_vo.ColumnSQL;
|
query = m_vo.ColumnSQL;
|
||||||
|
if (withAS)
|
||||||
|
return query + " AS " + m_vo.ColumnName;
|
||||||
|
else
|
||||||
|
return query;
|
||||||
}
|
}
|
||||||
return m_vo.ColumnName;
|
return m_vo.ColumnName;
|
||||||
} // getColumnSQL
|
} // getColumnSQL
|
||||||
|
@ -1379,10 +1387,26 @@ public class GridField
|
||||||
*/
|
*/
|
||||||
public boolean isVirtualColumn()
|
public boolean isVirtualColumn()
|
||||||
{
|
{
|
||||||
if (m_vo.ColumnSQL != null && m_vo.ColumnSQL.length() > 0)
|
return (m_vo.ColumnSQL != null && m_vo.ColumnSQL.length() > 0);
|
||||||
return true;
|
} // isVirtualColumn
|
||||||
return false;
|
|
||||||
} // isColumnVirtual
|
/**
|
||||||
|
* Is Virtual DB Column
|
||||||
|
* @return column is virtual DB
|
||||||
|
*/
|
||||||
|
public boolean isVirtualDBColumn()
|
||||||
|
{
|
||||||
|
return (m_vo.ColumnSQL != null && m_vo.ColumnSQL.length() > 0 && !m_vo.ColumnSQL.startsWith("@SQL="));
|
||||||
|
} // isVirtualDBColumn
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Is Virtual UI Column
|
||||||
|
* @return column is virtual UI
|
||||||
|
*/
|
||||||
|
public boolean isVirtualUIColumn()
|
||||||
|
{
|
||||||
|
return (m_vo.ColumnSQL != null && m_vo.ColumnSQL.length() > 0 && m_vo.ColumnSQL.startsWith("@SQL="));
|
||||||
|
} // isVirtualUIColumn
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get Header
|
* Get Header
|
||||||
|
@ -2587,4 +2611,26 @@ public class GridField
|
||||||
long timestamp;
|
long timestamp;
|
||||||
boolean value;
|
boolean value;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void processUIVirtualColumn() {
|
||||||
|
String sql = m_vo.ColumnSQL.substring(5);
|
||||||
|
sql = Env.parseContext(Env.getCtx(), getWindowNo(), sql, false);
|
||||||
|
if (Util.isEmpty(sql)) {
|
||||||
|
setValue(null, false);
|
||||||
|
} else {
|
||||||
|
if (DisplayType.isDate(m_vo.displayType)) {
|
||||||
|
Timestamp valueTS = DB.getSQLValueTSEx(null, sql, new Object[] {});
|
||||||
|
setValue(valueTS, false);
|
||||||
|
} else if (DisplayType.isNumeric(m_vo.displayType)) {
|
||||||
|
BigDecimal valueBD = DB.getSQLValueBDEx(null, sql, new Object[] {});
|
||||||
|
setValue(valueBD, false);
|
||||||
|
} else if (DisplayType.isID(m_vo.displayType)) {
|
||||||
|
int valueInt = DB.getSQLValueEx(null, sql, new Object[] {});
|
||||||
|
setValue(valueInt, false);
|
||||||
|
} else { // default to String
|
||||||
|
String valueStr = DB.getSQLValueStringEx(null, sql);
|
||||||
|
setValue(valueStr, false);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
} // GridField
|
} // GridField
|
||||||
|
|
|
@ -202,7 +202,7 @@ public class GridFieldVO implements Serializable
|
||||||
vo.ValidationCode = rs.getString(i);
|
vo.ValidationCode = rs.getString(i);
|
||||||
else if (columnName.equalsIgnoreCase("ColumnSQL")) {
|
else if (columnName.equalsIgnoreCase("ColumnSQL")) {
|
||||||
vo.ColumnSQL = rs.getString(i);
|
vo.ColumnSQL = rs.getString(i);
|
||||||
if (vo.ColumnSQL != null && vo.ColumnSQL.contains("@")) {
|
if (vo.ColumnSQL != null && !vo.ColumnSQL.startsWith("@SQL=") && vo.ColumnSQL.contains("@")) {
|
||||||
// NOTE: cannot use window context because this is set globally on the query, not per record
|
// NOTE: cannot use window context because this is set globally on the query, not per record
|
||||||
vo.ColumnSQL = Env.parseContext(ctx, -1, vo.ColumnSQL, false, true);
|
vo.ColumnSQL = Env.parseContext(ctx, -1, vo.ColumnSQL, false, true);
|
||||||
}
|
}
|
||||||
|
|
|
@ -2116,6 +2116,11 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
|
||||||
fFax.setVFormat(phone_frm);
|
fFax.setVFormat(phone_frm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Load virtual UI columns
|
||||||
|
for (GridField field : getFields()) {
|
||||||
|
if (field.isVirtualUIColumn())
|
||||||
|
field.processUIVirtualColumn();
|
||||||
|
}
|
||||||
} // loadDependentInfo
|
} // loadDependentInfo
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -2782,6 +2787,10 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
|
||||||
setValue(dependentField, null);
|
setValue(dependentField, null);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// if the field is a Virtual UI Column
|
||||||
|
if (dependentField.isVirtualUIColumn()) {
|
||||||
|
dependentField.processUIVirtualColumn();
|
||||||
|
}
|
||||||
} // for all dependent fields
|
} // for all dependent fields
|
||||||
} // processDependencies
|
} // processDependencies
|
||||||
|
|
||||||
|
|
|
@ -67,7 +67,10 @@ public class LookupDisplayColumn implements Serializable
|
||||||
IsTranslated = isTranslated;
|
IsTranslated = isTranslated;
|
||||||
DisplayType = ad_Reference_ID;
|
DisplayType = ad_Reference_ID;
|
||||||
AD_Reference_ID = ad_Reference_Value_ID;
|
AD_Reference_ID = ad_Reference_Value_ID;
|
||||||
ColumnSQL = columnSQL;
|
if (columnSQL != null && columnSQL.length() > 0 && columnSQL.startsWith("@SQL="))
|
||||||
|
ColumnSQL = "NULL";
|
||||||
|
else
|
||||||
|
ColumnSQL = columnSQL;
|
||||||
IsVirtual = !Util.isEmpty(ColumnSQL, true);
|
IsVirtual = !Util.isEmpty(ColumnSQL, true);
|
||||||
} //
|
} //
|
||||||
|
|
||||||
|
|
|
@ -51,7 +51,7 @@ public class MColumn extends X_AD_Column
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
private static final long serialVersionUID = -6914331394933196295L;
|
private static final long serialVersionUID = 7215660422231054443L;
|
||||||
|
|
||||||
public static MColumn get (Properties ctx, int AD_Column_ID)
|
public static MColumn get (Properties ctx, int AD_Column_ID)
|
||||||
{
|
{
|
||||||
|
@ -208,6 +208,26 @@ public class MColumn extends X_AD_Column
|
||||||
return s != null && s.length() > 0;
|
return s != null && s.length() > 0;
|
||||||
} // isVirtualColumn
|
} // isVirtualColumn
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Is Virtual DB Column
|
||||||
|
* @return true if virtual DB column
|
||||||
|
*/
|
||||||
|
public boolean isVirtualDBColumn()
|
||||||
|
{
|
||||||
|
String s = getColumnSQL();
|
||||||
|
return s != null && s.length() > 0 && !s.startsWith("@SQL=");
|
||||||
|
} // isVirtualDBColumn
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Is Virtual UI Column
|
||||||
|
* @return true if virtual UI column
|
||||||
|
*/
|
||||||
|
public boolean isVirtualUIColumn()
|
||||||
|
{
|
||||||
|
String s = getColumnSQL();
|
||||||
|
return s != null && s.length() > 0 && s.startsWith("@SQL=");
|
||||||
|
} // isVirtualUIColumn
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Is the Column Encrypted?
|
* Is the Column Encrypted?
|
||||||
* @return true if encrypted
|
* @return true if encrypted
|
||||||
|
@ -305,6 +325,8 @@ public class MColumn extends X_AD_Column
|
||||||
setIsMandatory(false);
|
setIsMandatory(false);
|
||||||
if (isUpdateable())
|
if (isUpdateable())
|
||||||
setIsUpdateable(false);
|
setIsUpdateable(false);
|
||||||
|
if (isVirtualUIColumn() && isIdentifier())
|
||||||
|
setIsIdentifier(false);
|
||||||
}
|
}
|
||||||
// Updateable
|
// Updateable
|
||||||
if (isParent() || isKey())
|
if (isParent() || isKey())
|
||||||
|
@ -1146,4 +1168,13 @@ public class MColumn extends X_AD_Column
|
||||||
return cnt > 0;
|
return cnt > 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public String getColumnSQL(boolean nullForUI) {
|
||||||
|
String query = getColumnSQL();
|
||||||
|
if (query != null && query.length() > 0) {
|
||||||
|
if (query.startsWith("@SQL=") && nullForUI)
|
||||||
|
query = "NULL";
|
||||||
|
}
|
||||||
|
return query;
|
||||||
|
}
|
||||||
|
|
||||||
} // MColumn
|
} // MColumn
|
||||||
|
|
|
@ -434,7 +434,9 @@ public class MLookupFactory
|
||||||
ZoomWindowPO = rs.getInt(9);
|
ZoomWindowPO = rs.getInt(9);
|
||||||
//AD_Table_ID = rs.getInt(10);
|
//AD_Table_ID = rs.getInt(10);
|
||||||
displayColumnSQL = rs.getString(11);
|
displayColumnSQL = rs.getString(11);
|
||||||
if (displayColumnSQL != null && displayColumnSQL.contains("@"))
|
if (displayColumnSQL != null && displayColumnSQL.length() > 0 && displayColumnSQL.startsWith("@SQL="))
|
||||||
|
displayColumnSQL = "NULL";
|
||||||
|
if (displayColumnSQL != null && displayColumnSQL.contains("@") && displayColumnSQL.startsWith("@SQL="))
|
||||||
displayColumnSQL = Env.parseContext(Env.getCtx(), -1, displayColumnSQL, false, true);
|
displayColumnSQL = Env.parseContext(Env.getCtx(), -1, displayColumnSQL, false, true);
|
||||||
overrideZoomWindow = rs.getInt(12);
|
overrideZoomWindow = rs.getInt(12);
|
||||||
infoWindowId = rs.getInt(13);
|
infoWindowId = rs.getInt(13);
|
||||||
|
@ -665,6 +667,11 @@ public class MLookupFactory
|
||||||
embedSQL.append(TableNameAlias).append(".Value||'-'||");
|
embedSQL.append(TableNameAlias).append(".Value||'-'||");
|
||||||
|
|
||||||
MColumn columnDisplay = new MColumn(Env.getCtx(), columnDisplay_ID, null);
|
MColumn columnDisplay = new MColumn(Env.getCtx(), columnDisplay_ID, null);
|
||||||
|
if (columnDisplay.isVirtualUIColumn())
|
||||||
|
{
|
||||||
|
s_log.warning("Virtual UI Column must not be used as display");
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
boolean translated = false;
|
boolean translated = false;
|
||||||
// Translated
|
// Translated
|
||||||
|
@ -678,7 +685,7 @@ public class MLookupFactory
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
embedSQL.append(TableName).append("_Trl.").append(DisplayColumn);
|
embedSQL.append(TableName).append("_Trl.").append(DisplayColumn);
|
||||||
|
|
||||||
embedSQL.append(" FROM ").append(TableName).append(" ").append(TableNameAlias)
|
embedSQL.append(" FROM ").append(TableName).append(" ").append(TableNameAlias)
|
||||||
.append(" INNER JOIN ").append(TableName).append("_TRL ON (")
|
.append(" INNER JOIN ").append(TableName).append("_TRL ON (")
|
||||||
|
@ -691,9 +698,9 @@ public class MLookupFactory
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (columnDisplay.isVirtualColumn())
|
if (columnDisplay.isVirtualColumn())
|
||||||
embedSQL.append(columnDisplay.getColumnSQL()).append(" AS ").append(KeyColumn);
|
embedSQL.append(columnDisplay.getColumnSQL(true)).append(" AS ").append(KeyColumn);
|
||||||
else
|
else
|
||||||
embedSQL.append(TableNameAlias).append(".").append(DisplayColumn);
|
embedSQL.append(TableNameAlias).append(".").append(DisplayColumn);
|
||||||
|
|
||||||
embedSQL.append(" FROM ").append(TableName).append(" ").append(TableNameAlias);
|
embedSQL.append(" FROM ").append(TableName).append(" ").append(TableNameAlias);
|
||||||
}
|
}
|
||||||
|
@ -708,9 +715,9 @@ public class MLookupFactory
|
||||||
embedSQL.append(BaseTable).append(".").append(BaseColumn);
|
embedSQL.append(BaseTable).append(".").append(BaseColumn);
|
||||||
embedSQL.append("=").append(TableNameAlias).append(".").append(KeyColumn);
|
embedSQL.append("=").append(TableNameAlias).append(".").append(KeyColumn);
|
||||||
} else if (translated) {
|
} else if (translated) {
|
||||||
embedSQL.append(TableNameAlias).append(".").append(KeyColumn).append("=").append(column.getColumnSQL());
|
embedSQL.append(TableNameAlias).append(".").append(KeyColumn).append("=").append(column.getColumnSQL(true));
|
||||||
} else {
|
} else {
|
||||||
embedSQL.append(KeyColumn).append("=").append(column.getColumnSQL());
|
embedSQL.append(KeyColumn).append("=").append(column.getColumnSQL(true));
|
||||||
}
|
}
|
||||||
|
|
||||||
return embedSQL.toString();
|
return embedSQL.toString();
|
||||||
|
@ -973,7 +980,7 @@ public class MLookupFactory
|
||||||
MTable table = MTable.get(Env.getCtx(), TableName);
|
MTable table = MTable.get(Env.getCtx(), TableName);
|
||||||
for (String idColumnName : table.getIdentifierColumns()) {
|
for (String idColumnName : table.getIdentifierColumns()) {
|
||||||
MColumn column = table.getColumn(idColumnName);
|
MColumn column = table.getColumn(idColumnName);
|
||||||
LookupDisplayColumn ldc = new LookupDisplayColumn(column.getColumnName(), column.getColumnSQL(), column.isTranslated(), column.getAD_Reference_ID(), column.getAD_Reference_Value_ID());
|
LookupDisplayColumn ldc = new LookupDisplayColumn(column.getColumnName(), column.getColumnSQL(true), column.isTranslated(), column.getAD_Reference_ID(), column.getAD_Reference_Value_ID());
|
||||||
list.add (ldc);
|
list.add (ldc);
|
||||||
}
|
}
|
||||||
return list;
|
return list;
|
||||||
|
|
|
@ -1121,7 +1121,7 @@ class Restriction implements Serializable
|
||||||
MTable table = MTable.get(Env.getCtx(), tableName);
|
MTable table = MTable.get(Env.getCtx(), tableName);
|
||||||
if (table != null) {
|
if (table != null) {
|
||||||
for (MColumn col : table.getColumns(false)) {
|
for (MColumn col : table.getColumns(false)) {
|
||||||
String colSQL = col.getColumnSQL();
|
String colSQL = col.getColumnSQL(true);
|
||||||
if (colSQL != null && colSQL.contains("@"))
|
if (colSQL != null && colSQL.contains("@"))
|
||||||
colSQL = Env.parseContext(Env.getCtx(), -1, colSQL, false, true);
|
colSQL = Env.parseContext(Env.getCtx(), -1, colSQL, false, true);
|
||||||
if (ColumnName.equals(colSQL)) {
|
if (ColumnName.equals(colSQL)) {
|
||||||
|
|
|
@ -199,6 +199,8 @@ public class POInfo implements Serializable
|
||||||
//
|
//
|
||||||
m_AccessLevel = rs.getString(18);
|
m_AccessLevel = rs.getString(18);
|
||||||
String ColumnSQL = rs.getString(19);
|
String ColumnSQL = rs.getString(19);
|
||||||
|
if (ColumnSQL != null && ColumnSQL.length() > 0 && ColumnSQL.startsWith("@SQL="))
|
||||||
|
ColumnSQL = "NULL";
|
||||||
if (ColumnSQL != null && ColumnSQL.contains("@"))
|
if (ColumnSQL != null && ColumnSQL.contains("@"))
|
||||||
ColumnSQL = Env.parseContext(Env.getCtx(), -1, ColumnSQL, false, true);
|
ColumnSQL = Env.parseContext(Env.getCtx(), -1, ColumnSQL, false, true);
|
||||||
boolean IsEncrypted = "Y".equals(rs.getString(20));
|
boolean IsEncrypted = "Y".equals(rs.getString(20));
|
||||||
|
@ -375,8 +377,11 @@ public class POInfo implements Serializable
|
||||||
{
|
{
|
||||||
if (index < 0 || index >= m_columns.length)
|
if (index < 0 || index >= m_columns.length)
|
||||||
return null;
|
return null;
|
||||||
if (m_columns[index].ColumnSQL != null && m_columns[index].ColumnSQL.length() > 0)
|
if (m_columns[index].ColumnSQL != null && m_columns[index].ColumnSQL.length() > 0) {
|
||||||
|
if (m_columns[index].ColumnSQL.startsWith("@SQL="))
|
||||||
|
return "NULL AS " + m_columns[index].ColumnName;
|
||||||
return m_columns[index].ColumnSQL + " AS " + m_columns[index].ColumnName;
|
return m_columns[index].ColumnSQL + " AS " + m_columns[index].ColumnName;
|
||||||
|
}
|
||||||
return m_columns[index].ColumnName;
|
return m_columns[index].ColumnName;
|
||||||
} // getColumnSQL
|
} // getColumnSQL
|
||||||
|
|
||||||
|
@ -393,6 +398,34 @@ public class POInfo implements Serializable
|
||||||
&& m_columns[index].ColumnSQL.length() > 0;
|
&& m_columns[index].ColumnSQL.length() > 0;
|
||||||
} // isVirtualColumn
|
} // isVirtualColumn
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Is Column Virtual DB?
|
||||||
|
* @param index index
|
||||||
|
* @return true if column is virtual DB
|
||||||
|
*/
|
||||||
|
public boolean isVirtualDBColumn (int index)
|
||||||
|
{
|
||||||
|
if (index < 0 || index >= m_columns.length)
|
||||||
|
return true;
|
||||||
|
return m_columns[index].ColumnSQL != null
|
||||||
|
&& m_columns[index].ColumnSQL.length() > 0
|
||||||
|
&& !m_columns[index].ColumnSQL.startsWith("@SQL=");
|
||||||
|
} // isVirtualDBColumn
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Is Column Virtual UI?
|
||||||
|
* @param index index
|
||||||
|
* @return true if column is virtual UI
|
||||||
|
*/
|
||||||
|
public boolean isVirtualUIColumn (int index)
|
||||||
|
{
|
||||||
|
if (index < 0 || index >= m_columns.length)
|
||||||
|
return true;
|
||||||
|
return m_columns[index].ColumnSQL != null
|
||||||
|
&& m_columns[index].ColumnSQL.length() > 0
|
||||||
|
&& m_columns[index].ColumnSQL.startsWith("@SQL=");
|
||||||
|
} // isVirtualUIColumn
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get Column Label
|
* Get Column Label
|
||||||
* @param index index
|
* @param index index
|
||||||
|
|
|
@ -310,6 +310,8 @@ public class DataEngine
|
||||||
int AD_Column_ID = rs.getInt(1);
|
int AD_Column_ID = rs.getInt(1);
|
||||||
String ColumnName = rs.getString(2);
|
String ColumnName = rs.getString(2);
|
||||||
String ColumnSQL = rs.getString(24);
|
String ColumnSQL = rs.getString(24);
|
||||||
|
if (ColumnSQL != null && ColumnSQL.length() > 0 && ColumnSQL.startsWith("@SQL="))
|
||||||
|
ColumnSQL = "NULL";
|
||||||
if (ColumnSQL != null && ColumnSQL.contains("@"))
|
if (ColumnSQL != null && ColumnSQL.contains("@"))
|
||||||
ColumnSQL = Env.parseContext(Env.getCtx(), -1, ColumnSQL, false, true);
|
ColumnSQL = Env.parseContext(Env.getCtx(), -1, ColumnSQL, false, true);
|
||||||
if (ColumnSQL == null)
|
if (ColumnSQL == null)
|
||||||
|
|
|
@ -34,6 +34,7 @@ import org.adempiere.model.MTabCustomization;
|
||||||
import org.compiere.model.GridField;
|
import org.compiere.model.GridField;
|
||||||
import org.compiere.model.GridTab;
|
import org.compiere.model.GridTab;
|
||||||
import org.compiere.model.GridTable;
|
import org.compiere.model.GridTable;
|
||||||
|
import org.compiere.model.MColumn;
|
||||||
import org.compiere.model.MQuery;
|
import org.compiere.model.MQuery;
|
||||||
import org.compiere.model.MRole;
|
import org.compiere.model.MRole;
|
||||||
import org.compiere.model.Query;
|
import org.compiere.model.Query;
|
||||||
|
@ -614,6 +615,8 @@ public class MPrintFormat extends X_AD_PrintFormat
|
||||||
int seqNo = 1;
|
int seqNo = 1;
|
||||||
for (GridField gridField : gridFields)
|
for (GridField gridField : gridFields)
|
||||||
{
|
{
|
||||||
|
if (gridField.isVirtualUIColumn())
|
||||||
|
continue;
|
||||||
MPrintFormatItem pfi = MPrintFormatItem.createFromGridField(pf, gridField, seqNo++);
|
MPrintFormatItem pfi = MPrintFormatItem.createFromGridField(pf, gridField, seqNo++);
|
||||||
if (pfi != null)
|
if (pfi != null)
|
||||||
{
|
{
|
||||||
|
@ -859,7 +862,11 @@ public class MPrintFormat extends X_AD_PrintFormat
|
||||||
int seqNo = 1;
|
int seqNo = 1;
|
||||||
while (rs.next())
|
while (rs.next())
|
||||||
{
|
{
|
||||||
MPrintFormatItem pfi = MPrintFormatItem.createFromColumn (format, rs.getInt(1), seqNo++);
|
int columnID = rs.getInt(1);
|
||||||
|
MColumn column = MColumn.get(ctx, columnID);
|
||||||
|
if (column.isVirtualUIColumn())
|
||||||
|
continue;
|
||||||
|
MPrintFormatItem pfi = MPrintFormatItem.createFromColumn (format, columnID, seqNo++);
|
||||||
if (pfi != null)
|
if (pfi != null)
|
||||||
{
|
{
|
||||||
list.add (pfi);
|
list.add (pfi);
|
||||||
|
@ -897,7 +904,11 @@ public class MPrintFormat extends X_AD_PrintFormat
|
||||||
int seqNo = 1;
|
int seqNo = 1;
|
||||||
while (rs.next())
|
while (rs.next())
|
||||||
{
|
{
|
||||||
MPrintFormatItem pfi = MPrintFormatItem.createFromColumn (format, rs.getInt(1), seqNo++);
|
int columnID = rs.getInt(1);
|
||||||
|
MColumn column = MColumn.get(ctx, columnID);
|
||||||
|
if (column.isVirtualUIColumn())
|
||||||
|
continue;
|
||||||
|
MPrintFormatItem pfi = MPrintFormatItem.createFromColumn (format, columnID, seqNo++);
|
||||||
if (pfi != null)
|
if (pfi != null)
|
||||||
{
|
{
|
||||||
list.add (pfi);
|
list.add (pfi);
|
||||||
|
|
|
@ -1054,6 +1054,8 @@ public final class Find extends CDialog
|
||||||
// globalqss - Carlos Ruiz - 20060711
|
// globalqss - Carlos Ruiz - 20060711
|
||||||
// fix a bug with virtualColumn + isSelectionColumn not yielding results
|
// fix a bug with virtualColumn + isSelectionColumn not yielding results
|
||||||
GridField field = getTargetMField(ColumnName.toString());
|
GridField field = getTargetMField(ColumnName.toString());
|
||||||
|
if (field.isVirtualUIColumn())
|
||||||
|
continue;
|
||||||
boolean isProductCategoryField = isProductCategoryField(field.getAD_Column_ID());
|
boolean isProductCategoryField = isProductCategoryField(field.getAD_Column_ID());
|
||||||
StringBuilder ColumnSQL = new StringBuilder().append(field.getColumnSQL(false));
|
StringBuilder ColumnSQL = new StringBuilder().append(field.getColumnSQL(false));
|
||||||
//
|
//
|
||||||
|
@ -1159,7 +1161,7 @@ public final class Find extends CDialog
|
||||||
String infoName = column.toString();
|
String infoName = column.toString();
|
||||||
//
|
//
|
||||||
GridField field = getTargetMField(ColumnName.toString());
|
GridField field = getTargetMField(ColumnName.toString());
|
||||||
if (field == null)
|
if (field == null || field.isVirtualUIColumn())
|
||||||
continue;
|
continue;
|
||||||
boolean isProductCategoryField = isProductCategoryField(field.getAD_Column_ID());
|
boolean isProductCategoryField = isProductCategoryField(field.getAD_Column_ID());
|
||||||
String ColumnSQL = field.getColumnSQL(false);
|
String ColumnSQL = field.getColumnSQL(false);
|
||||||
|
|
|
@ -256,6 +256,8 @@ public class InfoGeneral extends Info
|
||||||
{
|
{
|
||||||
m_queryColumns.add(rs.getString(1));
|
m_queryColumns.add(rs.getString(1));
|
||||||
String columnSql = rs.getString(4);
|
String columnSql = rs.getString(4);
|
||||||
|
if (columnSql != null && columnSql.length() > 0 && columnSql.contains("@"))
|
||||||
|
columnSql = "NULL";
|
||||||
if (columnSql != null && columnSql.contains("@"))
|
if (columnSql != null && columnSql.contains("@"))
|
||||||
columnSql = Env.parseContext(Env.getCtx(), -1, columnSql, false, true);
|
columnSql = Env.parseContext(Env.getCtx(), -1, columnSql, false, true);
|
||||||
if (columnSql != null && columnSql.length() > 0)
|
if (columnSql != null && columnSql.length() > 0)
|
||||||
|
@ -327,6 +329,8 @@ public class InfoGeneral extends Info
|
||||||
int AD_Reference_Value_ID = rs.getInt(5);
|
int AD_Reference_Value_ID = rs.getInt(5);
|
||||||
// teo_sarca
|
// teo_sarca
|
||||||
String columnSql = rs.getString(6);
|
String columnSql = rs.getString(6);
|
||||||
|
if (columnSql != null && columnSql.length() > 0 && columnSql.contains("@"))
|
||||||
|
columnSql = "NULL";
|
||||||
if (columnSql != null && columnSql.contains("@"))
|
if (columnSql != null && columnSql.contains("@"))
|
||||||
columnSql = Env.parseContext(Env.getCtx(), -1, columnSql, false, true);
|
columnSql = Env.parseContext(Env.getCtx(), -1, columnSql, false, true);
|
||||||
if (columnSql == null || columnSql.length() == 0)
|
if (columnSql == null || columnSql.length() == 0)
|
||||||
|
|
|
@ -383,6 +383,8 @@ public class InfoGeneralPanel extends InfoPanel implements EventListener<Event>
|
||||||
{
|
{
|
||||||
m_queryColumns.add(rs.getString(1));
|
m_queryColumns.add(rs.getString(1));
|
||||||
String columnSql = rs.getString(4);
|
String columnSql = rs.getString(4);
|
||||||
|
if (columnSql != null && columnSql.length() > 0 && columnSql.contains("@"))
|
||||||
|
columnSql = "NULL";
|
||||||
if (columnSql != null && columnSql.contains("@"))
|
if (columnSql != null && columnSql.contains("@"))
|
||||||
columnSql = Env.parseContext(Env.getCtx(), -1, columnSql, false, true);
|
columnSql = Env.parseContext(Env.getCtx(), -1, columnSql, false, true);
|
||||||
String qualified = p_tableName+"."+rs.getString(1);
|
String qualified = p_tableName+"."+rs.getString(1);
|
||||||
|
@ -462,11 +464,13 @@ public class InfoGeneralPanel extends InfoPanel implements EventListener<Event>
|
||||||
boolean isDisplayed = rs.getString(4).equals("Y");
|
boolean isDisplayed = rs.getString(4).equals("Y");
|
||||||
int AD_Reference_Value_ID = rs.getInt(5);
|
int AD_Reference_Value_ID = rs.getInt(5);
|
||||||
String columnSql = rs.getString(6);
|
String columnSql = rs.getString(6);
|
||||||
int AD_Column_ID = rs.getInt(7);
|
if (columnSql != null && columnSql.length() > 0 && columnSql.contains("@"))
|
||||||
|
columnSql = "NULL";
|
||||||
if (columnSql != null && columnSql.contains("@"))
|
if (columnSql != null && columnSql.contains("@"))
|
||||||
columnSql = Env.parseContext(Env.getCtx(), -1, columnSql, false, true);
|
columnSql = Env.parseContext(Env.getCtx(), -1, columnSql, false, true);
|
||||||
if (columnSql == null || columnSql.length() == 0)
|
if (columnSql == null || columnSql.length() == 0)
|
||||||
columnSql = tableName+"."+columnName;
|
columnSql = tableName+"."+columnName;
|
||||||
|
int AD_Column_ID = rs.getInt(7);
|
||||||
|
|
||||||
// Default
|
// Default
|
||||||
StringBuffer colSql = new StringBuffer(columnSql);
|
StringBuffer colSql = new StringBuffer(columnSql);
|
||||||
|
|
|
@ -789,6 +789,8 @@ public class FindWindow extends Window implements EventListener<Event>, ValueCha
|
||||||
List<GridField> excludes = new ArrayList<GridField>();
|
List<GridField> excludes = new ArrayList<GridField>();
|
||||||
// adding sorted columns
|
// adding sorted columns
|
||||||
for(GridField field:gridFieldList){
|
for(GridField field:gridFieldList){
|
||||||
|
if (field.isVirtualUIColumn())
|
||||||
|
continue;
|
||||||
if (!addSelectionColumn (field))
|
if (!addSelectionColumn (field))
|
||||||
excludes.add(field);
|
excludes.add(field);
|
||||||
}
|
}
|
||||||
|
@ -802,6 +804,8 @@ public class FindWindow extends Window implements EventListener<Event>, ValueCha
|
||||||
cell.setColspan(3);
|
cell.setColspan(3);
|
||||||
cell.setAlign("left");
|
cell.setAlign("left");
|
||||||
for(GridField field:moreFieldList){
|
for(GridField field:moreFieldList){
|
||||||
|
if (field.isVirtualUIColumn())
|
||||||
|
continue;
|
||||||
if (!addSelectionColumn (field, rowg))
|
if (!addSelectionColumn (field, rowg))
|
||||||
excludes.add(field);
|
excludes.add(field);
|
||||||
}
|
}
|
||||||
|
@ -1053,7 +1057,8 @@ public class FindWindow extends Window implements EventListener<Event>, ValueCha
|
||||||
for (int c = 0; c < m_findFields.length; c++)
|
for (int c = 0; c < m_findFields.length; c++)
|
||||||
{
|
{
|
||||||
GridField field = m_findFields[c];
|
GridField field = m_findFields[c];
|
||||||
if (field == null) continue;
|
if (field == null || field.isVirtualUIColumn())
|
||||||
|
continue;
|
||||||
|
|
||||||
String columnName = field.getColumnName();
|
String columnName = field.getColumnName();
|
||||||
String header = field.getHeader();
|
String header = field.getHeader();
|
||||||
|
@ -1589,7 +1594,8 @@ public class FindWindow extends Window implements EventListener<Event>, ValueCha
|
||||||
String infoName = column.toString();
|
String infoName = column.toString();
|
||||||
//
|
//
|
||||||
GridField field = getTargetMField(ColumnName);
|
GridField field = getTargetMField(ColumnName);
|
||||||
if(field == null) continue; // Elaine 2008/07/29
|
if (field == null || field.isVirtualUIColumn())
|
||||||
|
continue;
|
||||||
boolean isProductCategoryField = isProductCategoryField(field.getColumnName());
|
boolean isProductCategoryField = isProductCategoryField(field.getColumnName());
|
||||||
String ColumnSQL = field.getColumnSQL(false);
|
String ColumnSQL = field.getColumnSQL(false);
|
||||||
// Left brackets
|
// Left brackets
|
||||||
|
@ -1811,6 +1817,8 @@ public class FindWindow extends Window implements EventListener<Event>, ValueCha
|
||||||
}
|
}
|
||||||
|
|
||||||
GridField field = getTargetMField(ColumnName);
|
GridField field = getTargetMField(ColumnName);
|
||||||
|
if (field.isVirtualUIColumn())
|
||||||
|
continue;
|
||||||
StringBuilder ColumnSQL = new StringBuilder(field.getColumnSQL(false));
|
StringBuilder ColumnSQL = new StringBuilder(field.getColumnSQL(false));
|
||||||
m_query.addRangeRestriction(ColumnSQL.toString(), value, valueTo,
|
m_query.addRangeRestriction(ColumnSQL.toString(), value, valueTo,
|
||||||
ColumnName, wed.getDisplay(), wedTo.getDisplay(), true, 0);
|
ColumnName, wed.getDisplay(), wedTo.getDisplay(), true, 0);
|
||||||
|
|
Loading…
Reference in New Issue