Merge c1e2deccf768

This commit is contained in:
Heng Sin Low 2013-03-12 16:23:48 +08:00
commit 784b7c39dc
13 changed files with 1119 additions and 349 deletions

View File

@ -0,0 +1,73 @@
-- Feb 11, 2013 5:42:41 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message (MsgType,MsgText,AD_Message_ID,EntityType,AD_Message_UU,Value,IsActive,Updated,CreatedBy,UpdatedBy,AD_Client_ID,AD_Org_ID,Created) VALUES ('E','Table name {0} does not correspond to the parent''s table name {1}',200146,'D','18535f25-f9d7-47c0-9c21-de68afa04444','DiffTableName','Y',TO_DATE('2013-02-11 17:42:40','YYYY-MM-DD HH24:MI:SS'),100,100,0,0,TO_DATE('2013-02-11 17:42:40','YYYY-MM-DD HH24:MI:SS'))
;
-- Feb 11, 2013 5:42:41 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message_Trl (AD_Language,AD_Message_ID, MsgText,MsgTip, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Message_Trl_UU ) SELECT l.AD_Language,t.AD_Message_ID, t.MsgText,t.MsgTip, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Message t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Message_ID=200146 AND NOT EXISTS (SELECT * FROM AD_Message_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Message_ID=t.AD_Message_ID)
;
-- Feb 11, 2013 5:43:20 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message (MsgType,MsgText,AD_Message_ID,EntityType,AD_Message_UU,Value,IsActive,Updated,CreatedBy,UpdatedBy,AD_Client_ID,AD_Org_ID,Created) VALUES ('I','Record not processed, due to master record failure',200147,'D','ffc51041-2111-4944-9ac5-35d7688194ef','NotProcessed','Y',TO_DATE('2013-02-11 17:43:20','YYYY-MM-DD HH24:MI:SS'),100,100,0,0,TO_DATE('2013-02-11 17:43:20','YYYY-MM-DD HH24:MI:SS'))
;
-- Feb 11, 2013 5:43:20 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message_Trl (AD_Language,AD_Message_ID, MsgText,MsgTip, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Message_Trl_UU ) SELECT l.AD_Language,t.AD_Message_ID, t.MsgText,t.MsgTip, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Message t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Message_ID=200147 AND NOT EXISTS (SELECT * FROM AD_Message_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Message_ID=t.AD_Message_ID)
;
-- Feb 11, 2013 5:45:35 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message (MsgType,MsgText,AD_Message_ID,EntityType,AD_Message_UU,Value,IsActive,Updated,CreatedBy,UpdatedBy,AD_Client_ID,AD_Org_ID,Created) VALUES ('I','Different parent value: Master value {0} Detail value {1}',200148,'D','3516b3e0-6f8c-458d-af58-b6e22e6f0156','DiffParentValue','Y',TO_DATE('2013-02-11 17:45:35','YYYY-MM-DD HH24:MI:SS'),100,100,0,0,TO_DATE('2013-02-11 17:45:35','YYYY-MM-DD HH24:MI:SS'))
;
-- Feb 11, 2013 5:45:35 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message_Trl (AD_Language,AD_Message_ID, MsgText,MsgTip, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Message_Trl_UU ) SELECT l.AD_Language,t.AD_Message_ID, t.MsgText,t.MsgTip, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Message t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Message_ID=200148 AND NOT EXISTS (SELECT * FROM AD_Message_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Message_ID=t.AD_Message_ID)
;
-- Mar 11, 2013 3:58:04 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message (MsgType,MsgText,AD_Message_ID,EntityType,AD_Message_UU,Value,IsActive,Updated,CreatedBy,UpdatedBy,AD_Client_ID,AD_Org_ID,Created) VALUES ('E','Csv file must not contain ''>'' in header record {0}. ',200152,'D','1d9054fa-48d7-4e65-b74a-3164eaa156b8','WrongHeader','Y',TO_DATE('2013-03-11 15:58:02','YYYY-MM-DD HH24:MI:SS'),100,100,0,0,TO_DATE('2013-03-11 15:58:02','YYYY-MM-DD HH24:MI:SS'))
;
-- Mar 11, 2013 3:58:04 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message_Trl (AD_Language,AD_Message_ID, MsgText,MsgTip, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Message_Trl_UU ) SELECT l.AD_Language,t.AD_Message_ID, t.MsgText,t.MsgTip, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Message t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Message_ID=200152 AND NOT EXISTS (SELECT * FROM AD_Message_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Message_ID=t.AD_Message_ID)
;
-- Mar 11, 2013 3:59:21 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message (MsgType,MsgText,AD_Message_ID,EntityType,AD_Message_UU,Value,IsActive,Updated,CreatedBy,UpdatedBy,AD_Client_ID,AD_Org_ID,Created) VALUES ('E','No child tab was found with such table {0}. ',200153,'D','027a1bdf-7b45-4afc-93c5-a6113b5f1acb','NoChildTab','Y',TO_DATE('2013-03-11 15:59:20','YYYY-MM-DD HH24:MI:SS'),100,100,0,0,TO_DATE('2013-03-11 15:59:20','YYYY-MM-DD HH24:MI:SS'))
;
-- Mar 11, 2013 3:59:21 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message_Trl (AD_Language,AD_Message_ID, MsgText,MsgTip, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Message_Trl_UU ) SELECT l.AD_Language,t.AD_Message_ID, t.MsgText,t.MsgTip, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Message t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Message_ID=200153 AND NOT EXISTS (SELECT * FROM AD_Message_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Message_ID=t.AD_Message_ID)
;
-- Mar 11, 2013 4:10:39 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message (MsgType,MsgText,AD_Message_ID,EntityType,AD_Message_UU,Value,IsActive,Updated,CreatedBy,UpdatedBy,AD_Client_ID,AD_Org_ID,Created) VALUES ('E','Wrong detail name{0}, it must contain the character ''>'':{1} ',200154,'D','b82cafbc-f6d0-4002-b358-a4a9783f77c2','WrongDetailName','Y',TO_DATE('2013-03-11 16:10:38','YYYY-MM-DD HH24:MI:SS'),100,100,0,0,TO_DATE('2013-03-11 16:10:38','YYYY-MM-DD HH24:MI:SS'))
;
-- Mar 11, 2013 4:10:39 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message_Trl (AD_Language,AD_Message_ID, MsgText,MsgTip, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Message_Trl_UU ) SELECT l.AD_Language,t.AD_Message_ID, t.MsgText,t.MsgTip, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Message t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Message_ID=200154 AND NOT EXISTS (SELECT * FROM AD_Message_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Message_ID=t.AD_Message_ID)
;
-- Mar 11, 2013 4:12:48 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message (MsgType,MsgText,AD_Message_ID,EntityType,AD_Message_UU,Value,IsActive,Updated,CreatedBy,UpdatedBy,AD_Client_ID,AD_Org_ID,Created) VALUES ('E','Parent value cannot be deleted {0}!',200155,'D','31e87e31-75b2-4555-8251-5d5d7dfe7ada','NoParentDelete','Y',TO_DATE('2013-03-11 16:12:47','YYYY-MM-DD HH24:MI:SS'),100,100,0,0,TO_DATE('2013-03-11 16:12:47','YYYY-MM-DD HH24:MI:SS'))
;
-- Mar 11, 2013 4:12:48 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message_Trl (AD_Language,AD_Message_ID, MsgText,MsgTip, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Message_Trl_UU ) SELECT l.AD_Language,t.AD_Message_ID, t.MsgText,t.MsgTip, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Message t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Message_ID=200155 AND NOT EXISTS (SELECT * FROM AD_Message_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Message_ID=t.AD_Message_ID)
;
SELECT register_migration_script('201302110600_IDEMPIERE-454.sql') FROM dual
;

View File

@ -0,0 +1,42 @@
-- Mar 8, 2013 11:17:42 AM COT
UPDATE AD_Field SET SeqNo=10, IsDisplayed='Y', XPosition=1,Updated=TO_DATE('2013-03-08 11:17:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=59414
;
-- Mar 8, 2013 11:17:42 AM COT
UPDATE AD_Field SET SeqNo=40, IsDisplayed='Y', XPosition=4,Updated=TO_DATE('2013-03-08 11:17:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=59416
;
-- Mar 8, 2013 11:17:42 AM COT
UPDATE AD_Field SET SeqNo=50,Updated=TO_DATE('2013-03-08 11:17:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=59448
;
-- Mar 8, 2013 11:17:42 AM COT
UPDATE AD_Field SET ColumnSpan=2, SeqNo=60, IsDisplayed='Y', XPosition=1,Updated=TO_DATE('2013-03-08 11:17:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=59418
;
-- Mar 8, 2013 11:17:42 AM COT
UPDATE AD_Field SET SeqNo=70,Updated=TO_DATE('2013-03-08 11:17:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=59415
;
-- Mar 8, 2013 11:17:42 AM COT
UPDATE AD_Field SET SeqNo=80, IsDisplayed='Y', XPosition=4,Updated=TO_DATE('2013-03-08 11:17:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=59417
;
-- Mar 8, 2013 11:17:42 AM COT
UPDATE AD_Field SET SeqNo=350,Updated=TO_DATE('2013-03-08 11:17:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=59446
;
-- Mar 8, 2013 11:17:42 AM COT
UPDATE AD_Field SET SeqNo=360,Updated=TO_DATE('2013-03-08 11:17:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=59447
;
-- Mar 8, 2013 11:17:42 AM COT
UPDATE AD_Field SET SeqNo=370,Updated=TO_DATE('2013-03-08 11:17:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=59449
;
-- Mar 8, 2013 11:17:42 AM COT
UPDATE AD_Field SET SeqNo=0,Updated=TO_DATE('2013-03-08 11:17:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=59445
;
SELECT register_migration_script('201303081134_IDEMPIERE-714.sql') FROM dual
;

View File

@ -0,0 +1,73 @@
-- Feb 11, 2013 5:42:41 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message (MsgType,MsgText,AD_Message_ID,EntityType,AD_Message_UU,Value,IsActive,Updated,CreatedBy,UpdatedBy,AD_Client_ID,AD_Org_ID,Created) VALUES ('E','Table name {0} does not correspond to the parent''s table name {1}',200146,'D','18535f25-f9d7-47c0-9c21-de68afa04444','DiffTableName','Y',TO_TIMESTAMP('2013-02-11 17:42:40','YYYY-MM-DD HH24:MI:SS'),100,100,0,0,TO_TIMESTAMP('2013-02-11 17:42:40','YYYY-MM-DD HH24:MI:SS'))
;
-- Feb 11, 2013 5:42:41 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message_Trl (AD_Language,AD_Message_ID, MsgText,MsgTip, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Message_Trl_UU ) SELECT l.AD_Language,t.AD_Message_ID, t.MsgText,t.MsgTip, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Message t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Message_ID=200146 AND NOT EXISTS (SELECT * FROM AD_Message_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Message_ID=t.AD_Message_ID)
;
-- Feb 11, 2013 5:43:20 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message (MsgType,MsgText,AD_Message_ID,EntityType,AD_Message_UU,Value,IsActive,Updated,CreatedBy,UpdatedBy,AD_Client_ID,AD_Org_ID,Created) VALUES ('I','Record not processed, due to master record failure',200147,'D','ffc51041-2111-4944-9ac5-35d7688194ef','NotProcessed','Y',TO_TIMESTAMP('2013-02-11 17:43:20','YYYY-MM-DD HH24:MI:SS'),100,100,0,0,TO_TIMESTAMP('2013-02-11 17:43:20','YYYY-MM-DD HH24:MI:SS'))
;
-- Feb 11, 2013 5:43:20 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message_Trl (AD_Language,AD_Message_ID, MsgText,MsgTip, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Message_Trl_UU ) SELECT l.AD_Language,t.AD_Message_ID, t.MsgText,t.MsgTip, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Message t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Message_ID=200147 AND NOT EXISTS (SELECT * FROM AD_Message_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Message_ID=t.AD_Message_ID)
;
-- Feb 11, 2013 5:45:35 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message (MsgType,MsgText,AD_Message_ID,EntityType,AD_Message_UU,Value,IsActive,Updated,CreatedBy,UpdatedBy,AD_Client_ID,AD_Org_ID,Created) VALUES ('I','Different parent value: Master value {0} Detail value {1}',200148,'D','3516b3e0-6f8c-458d-af58-b6e22e6f0156','DiffParentValue','Y',TO_TIMESTAMP('2013-02-11 17:45:35','YYYY-MM-DD HH24:MI:SS'),100,100,0,0,TO_TIMESTAMP('2013-02-11 17:45:35','YYYY-MM-DD HH24:MI:SS'))
;
-- Feb 11, 2013 5:45:35 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message_Trl (AD_Language,AD_Message_ID, MsgText,MsgTip, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Message_Trl_UU ) SELECT l.AD_Language,t.AD_Message_ID, t.MsgText,t.MsgTip, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Message t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Message_ID=200148 AND NOT EXISTS (SELECT * FROM AD_Message_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Message_ID=t.AD_Message_ID)
;
-- Mar 11, 2013 3:58:04 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message (MsgType,MsgText,AD_Message_ID,EntityType,AD_Message_UU,Value,IsActive,Updated,CreatedBy,UpdatedBy,AD_Client_ID,AD_Org_ID,Created) VALUES ('E','Csv file must not contain ''>'' in header record {0}. ',200152,'D','1d9054fa-48d7-4e65-b74a-3164eaa156b8','WrongHeader','Y',TO_TIMESTAMP('2013-03-11 15:58:02','YYYY-MM-DD HH24:MI:SS'),100,100,0,0,TO_TIMESTAMP('2013-03-11 15:58:02','YYYY-MM-DD HH24:MI:SS'))
;
-- Mar 11, 2013 3:58:04 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message_Trl (AD_Language,AD_Message_ID, MsgText,MsgTip, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Message_Trl_UU ) SELECT l.AD_Language,t.AD_Message_ID, t.MsgText,t.MsgTip, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Message t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Message_ID=200152 AND NOT EXISTS (SELECT * FROM AD_Message_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Message_ID=t.AD_Message_ID)
;
-- Mar 11, 2013 3:59:21 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message (MsgType,MsgText,AD_Message_ID,EntityType,AD_Message_UU,Value,IsActive,Updated,CreatedBy,UpdatedBy,AD_Client_ID,AD_Org_ID,Created) VALUES ('E','No child tab was found with such table {0}. ',200153,'D','027a1bdf-7b45-4afc-93c5-a6113b5f1acb','NoChildTab','Y',TO_TIMESTAMP('2013-03-11 15:59:20','YYYY-MM-DD HH24:MI:SS'),100,100,0,0,TO_TIMESTAMP('2013-03-11 15:59:20','YYYY-MM-DD HH24:MI:SS'))
;
-- Mar 11, 2013 3:59:21 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message_Trl (AD_Language,AD_Message_ID, MsgText,MsgTip, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Message_Trl_UU ) SELECT l.AD_Language,t.AD_Message_ID, t.MsgText,t.MsgTip, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Message t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Message_ID=200153 AND NOT EXISTS (SELECT * FROM AD_Message_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Message_ID=t.AD_Message_ID)
;
-- Mar 11, 2013 4:10:39 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message (MsgType,MsgText,AD_Message_ID,EntityType,AD_Message_UU,Value,IsActive,Updated,CreatedBy,UpdatedBy,AD_Client_ID,AD_Org_ID,Created) VALUES ('E','Wrong detail name{0}, it must contain the character ''>'':{1} ',200154,'D','b82cafbc-f6d0-4002-b358-a4a9783f77c2','WrongDetailName','Y',TO_TIMESTAMP('2013-03-11 16:10:38','YYYY-MM-DD HH24:MI:SS'),100,100,0,0,TO_TIMESTAMP('2013-03-11 16:10:38','YYYY-MM-DD HH24:MI:SS'))
;
-- Mar 11, 2013 4:10:39 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message_Trl (AD_Language,AD_Message_ID, MsgText,MsgTip, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Message_Trl_UU ) SELECT l.AD_Language,t.AD_Message_ID, t.MsgText,t.MsgTip, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Message t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Message_ID=200154 AND NOT EXISTS (SELECT * FROM AD_Message_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Message_ID=t.AD_Message_ID)
;
-- Mar 11, 2013 4:12:48 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message (MsgType,MsgText,AD_Message_ID,EntityType,AD_Message_UU,Value,IsActive,Updated,CreatedBy,UpdatedBy,AD_Client_ID,AD_Org_ID,Created) VALUES ('E','Parent value cannot be deleted {0}!',200155,'D','31e87e31-75b2-4555-8251-5d5d7dfe7ada','NoParentDelete','Y',TO_TIMESTAMP('2013-03-11 16:12:47','YYYY-MM-DD HH24:MI:SS'),100,100,0,0,TO_TIMESTAMP('2013-03-11 16:12:47','YYYY-MM-DD HH24:MI:SS'))
;
-- Mar 11, 2013 4:12:48 PM COT
-- IDEMPIERE-454 Easy import
INSERT INTO AD_Message_Trl (AD_Language,AD_Message_ID, MsgText,MsgTip, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Message_Trl_UU ) SELECT l.AD_Language,t.AD_Message_ID, t.MsgText,t.MsgTip, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Message t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Message_ID=200155 AND NOT EXISTS (SELECT * FROM AD_Message_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Message_ID=t.AD_Message_ID)
;
SELECT register_migration_script('201302110600_IDEMPIERE-454.sql') FROM dual
;

View File

@ -0,0 +1,42 @@
-- Mar 8, 2013 11:17:42 AM COT
UPDATE AD_Field SET SeqNo=10, IsDisplayed='Y', XPosition=1,Updated=TO_TIMESTAMP('2013-03-08 11:17:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=59414
;
-- Mar 8, 2013 11:17:42 AM COT
UPDATE AD_Field SET SeqNo=40, IsDisplayed='Y', XPosition=4,Updated=TO_TIMESTAMP('2013-03-08 11:17:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=59416
;
-- Mar 8, 2013 11:17:42 AM COT
UPDATE AD_Field SET SeqNo=50,Updated=TO_TIMESTAMP('2013-03-08 11:17:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=59448
;
-- Mar 8, 2013 11:17:42 AM COT
UPDATE AD_Field SET ColumnSpan=2, SeqNo=60, IsDisplayed='Y', XPosition=1,Updated=TO_TIMESTAMP('2013-03-08 11:17:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=59418
;
-- Mar 8, 2013 11:17:42 AM COT
UPDATE AD_Field SET SeqNo=70,Updated=TO_TIMESTAMP('2013-03-08 11:17:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=59415
;
-- Mar 8, 2013 11:17:42 AM COT
UPDATE AD_Field SET SeqNo=80, IsDisplayed='Y', XPosition=4,Updated=TO_TIMESTAMP('2013-03-08 11:17:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=59417
;
-- Mar 8, 2013 11:17:42 AM COT
UPDATE AD_Field SET SeqNo=350,Updated=TO_TIMESTAMP('2013-03-08 11:17:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=59446
;
-- Mar 8, 2013 11:17:42 AM COT
UPDATE AD_Field SET SeqNo=360,Updated=TO_TIMESTAMP('2013-03-08 11:17:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=59447
;
-- Mar 8, 2013 11:17:42 AM COT
UPDATE AD_Field SET SeqNo=370,Updated=TO_TIMESTAMP('2013-03-08 11:17:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=59449
;
-- Mar 8, 2013 11:17:42 AM COT
UPDATE AD_Field SET SeqNo=0,Updated=TO_TIMESTAMP('2013-03-08 11:17:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=59445
;
SELECT register_migration_script('201303081134_IDEMPIERE-714.sql') FROM dual
;

View File

@ -24,6 +24,7 @@ import java.util.Comparator;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.logging.Level;
import org.adempiere.base.IGridTabExporter;
import org.adempiere.exceptions.AdempiereException;
@ -31,16 +32,20 @@ import org.adempiere.model.MTabCustomization;
import org.compiere.model.GridField;
import org.compiere.model.GridTab;
import org.compiere.model.GridTable;
import org.compiere.model.GridWindow;
import org.compiere.model.GridWindowVO;
import org.compiere.model.MColumn;
import org.compiere.model.MLocation;
import org.compiere.model.MQuery;
import org.compiere.model.MRefList;
import org.compiere.model.MTab;
import org.compiere.model.MTable;
import org.compiere.util.CLogger;
import org.compiere.util.DB;
import org.compiere.util.DisplayType;
import org.compiere.util.Env;
import org.compiere.util.Msg;
import org.compiere.util.Util;
import org.jfree.util.Log;
import org.supercsv.cellprocessor.FmtBool;
import org.supercsv.cellprocessor.FmtDate;
import org.supercsv.cellprocessor.FmtNumber;
@ -57,6 +62,9 @@ import org.supercsv.prefs.CsvPreference;
*/
public class GridTabCSVExporter implements IGridTabExporter
{
/** Logger */
private static CLogger log = CLogger.getCLogger(GridTabCSVExporter.class);
@Override
public void export(GridTab gridTab, List<GridTab> childs, boolean currentRowOnly, File file) {
@ -66,9 +74,9 @@ public class GridTabCSVExporter implements IGridTabExporter
MTable tableDetail = null;
try {
mapWriter = new CsvMapWriter(new FileWriter(file), CsvPreference.STANDARD_PREFERENCE);
String IsValidTab = IsValidTabToExport(gridTab);
if (IsValidTab!=null){
Log.info(IsValidTab);
String isValidTab = isValidTabToExport(gridTab);
if (isValidTab!=null){
if (log.isLoggable(Level.INFO)) log.info(isValidTab);
return;
}
GridTable gt = gridTab.getTableModel();
@ -76,10 +84,16 @@ public class GridTabCSVExporter implements IGridTabExporter
List<String> headArray = new ArrayList<String>();
List<CellProcessor> procArray = new ArrayList<CellProcessor>();
table = MTable.get(Env.getCtx(), gridTab.getTableName());
int specialHDispayType = 0;
//master tab
for (int idxfld = 0; idxfld < gridFields.length; idxfld++) {
GridField field = gridFields[idxfld];
MColumn column = MColumn.get(Env.getCtx(), field.getAD_Column_ID());
//Special Columns
if(DisplayType.Location == column.getAD_Reference_ID()){
specialHDispayType = DisplayType.Location;
continue;
}
String headName = resolveColumnName(table, column);
headArray.add(headName);
if (DisplayType.Date == column.getAD_Reference_ID()) {
@ -94,26 +108,41 @@ public class GridTabCSVExporter implements IGridTabExporter
procArray.add(new Optional(new FmtNumber(nf)));
} else if (DisplayType.YesNo == column.getAD_Reference_ID()) {
procArray.add(new Optional(new FmtBool("Y", "N")));
} else { // lookups and text
} else { // lookups
procArray.add(new Optional());
}
}
if(specialHDispayType > 0){
for(String specialHeader:resolveSpecialColumnName(specialHDispayType)){
headArray.add(specialHeader);
procArray.add(null);
}
}
//Details up to tab level 1
if(childs.size() > 0){
int specialDetDispayType = 0;
for(GridTab detail: childs){
//comment this line if you want to export all tabs
if(detail.getTabNo()>1)
break;
if(detail.getTabLevel()>1)
continue;
IsValidTab = IsValidTabToExport(detail);
if (IsValidTab!=null){
Log.info(IsValidTab);
isValidTab = isValidTabToExport(detail);
if (isValidTab!=null){
if (log.isLoggable(Level.INFO)) log.info(isValidTab);
continue;
}
tableDetail = MTable.get(Env.getCtx(), detail.getTableName());
gridFields = getFields(detail);
for(GridField field : gridFields){
MColumn columnDetail = MColumn.get(Env.getCtx(), field.getAD_Column_ID());
if(DisplayType.Location == columnDetail.getAD_Reference_ID()){
specialDetDispayType = DisplayType.Location;
continue;
}
String headNameDetail= detail.getTableName()+">"+resolveColumnName(tableDetail, columnDetail);
headArray.add(headNameDetail);
if (DisplayType.Date == columnDetail.getAD_Reference_ID()) {
@ -129,6 +158,12 @@ public class GridTabCSVExporter implements IGridTabExporter
} else if (DisplayType.YesNo == columnDetail.getAD_Reference_ID()) {
procArray.add(new Optional(new FmtBool("Y", "N")));
} else { // lookups and text
procArray.add(new Optional());
}
}
if(specialDetDispayType > 0){
for(String specialHeader:resolveSpecialColumnName(specialDetDispayType)){
headArray.add(specialHeader);
procArray.add(null);
}
}
@ -156,9 +191,20 @@ public class GridTabCSVExporter implements IGridTabExporter
int idxfld = 0;
int index =0;
int rowDetail=0;
int record_Id = 0;
for(GridField field : getFields(gridTab)){
MColumn column = MColumn.get(Env.getCtx(), field.getAD_Column_ID());
if(DisplayType.Location == column.getAD_Reference_ID()){
Object fResolved =resolveValue(gridTab, table, column, idxrow, column.getColumnName());
if (fResolved!=null)
record_Id= Integer.parseInt(fResolved.toString());
continue;
}
String headName = header[idxfld];
Object value = resolveValue(gridTab, table, column, idxrow, headName);
row.put(headName,value);
@ -166,6 +212,31 @@ public class GridTabCSVExporter implements IGridTabExporter
index++;
}
if(specialHDispayType > 0 && record_Id > 0){
switch(specialHDispayType) {
case DisplayType.Location:
MLocation address = new MLocation (Env.getCtx(),record_Id,null);
for(String specialHeader:resolveSpecialColumnName(specialHDispayType)){
String columnName = specialHeader.substring(specialHeader.indexOf(">")+1,specialHeader.length());
Object sValue = null;
if (columnName.indexOf("[") >= 0 && columnName .endsWith("]")){
int indx = columnName.indexOf("[");
String columnRef= columnName.substring(indx+1,columnName.length()-1);
String tableRef = columnName.substring(0,indx);
Object record_id= address.get_Value(tableRef);
if (record_id!=null)
sValue = queryExecute(columnRef,tableRef,record_id);
}else{
sValue = address.get_Value(columnName);
}
row.put(specialHeader, sValue);
idxfld++;
index++;
}
break;
}
}
while(true){
if(childs.size()>0){
Map<String, Object> tmpRow = resolveMasterDetailRow(rowDetail,tabMapDetails,headArray,index,gridTab.getKeyID(idxrow), gridTab.getKeyColumnName());
@ -201,18 +272,19 @@ public class GridTabCSVExporter implements IGridTabExporter
}
}
}
}
//add constraints to not allow certain tabs
private String IsValidTabToExport(GridTab gridTab){
private String isValidTabToExport(GridTab gridTab){
String result=null;
if(gridTab.isReadOnly())
MTab tab = new MTab(Env.getCtx(), gridTab.getAD_Tab_ID(), null);
if (tab.isReadOnly())
result = Msg.getMsg(Env.getCtx(),"FieldIsReadOnly", new Object[] {gridTab.getName()});
if (gridTab.getTableName().endsWith("_Acct"))
result = "Accounting Tab cannot be exported "+ gridTab.getName();
result = "Accounting Tab are not exported by default: "+ gridTab.getName();
return result;
}
@ -221,6 +293,7 @@ public class GridTabCSVExporter implements IGridTabExporter
Map<String, Object> row = new HashMap<String, Object>();
Object value = null;
boolean hasDetails = false;
int specialDetDispayType = 0;
if (currentDetRow > 0 )
for(int j =0;j<idxfld;j++)
@ -231,8 +304,17 @@ public class GridTabCSVExporter implements IGridTabExporter
String whereCla = getWhereClause (childTab ,record_Id ,keyColumnParent);
childTab.getTableModel().dataRequery(whereCla, false, 0);
if (childTab.getRowCount() > 0) {
int specialRecordId = 0;
for(GridField field : childTabDetail.getValue()){
MColumn column = MColumn.get(Env.getCtx(), field.getAD_Column_ID());
if(DisplayType.Location == column.getAD_Reference_ID()){
specialDetDispayType = DisplayType.Location;
Object fResolved = resolveValue(childTab, MTable.get(Env.getCtx(),childTab.getTableName()), column, currentDetRow,column.getColumnName());
if(fResolved!=null)
specialRecordId = Integer.parseInt(fResolved.toString());
continue;
}
MTable tableDetail = MTable.get(Env.getCtx(), childTab.getTableName());
String headName = headArray.get(headArray.indexOf(childTab.getTableName()+">"+resolveColumnName(tableDetail,column)));
value = resolveValue(childTab, MTable.get(Env.getCtx(),childTab.getTableName()), column, currentDetRow, headName.substring(headName.indexOf(">")+ 1,headName.length()));
@ -241,6 +323,24 @@ public class GridTabCSVExporter implements IGridTabExporter
hasDetails = true;
}
if(specialDetDispayType > 0 && specialRecordId > 0){
MLocation address = new MLocation (Env.getCtx(),specialRecordId,null);
for(String specialHeader:resolveSpecialColumnName(specialDetDispayType)){
String columnName = specialHeader.substring(specialHeader.indexOf(">")+1,specialHeader.length());
Object sValue = null;
if (columnName.indexOf("[") >= 0 && columnName .endsWith("]")){
int indx = columnName.indexOf("[");
String columnRef= columnName.substring(indx+1,columnName.length()-1);
String tableRef = columnName.substring(0,indx);
Object record_id= address.get_Value(tableRef);
if(record_id!=null)
sValue = queryExecute(columnRef,tableRef,record_id);
}else{
sValue = address.get_Value(columnName);
}
row.put(specialHeader, sValue);
}
}
}
}
if (hasDetails)
@ -285,6 +385,16 @@ public class GridTabCSVExporter implements IGridTabExporter
return value;
}
private Object queryExecute(String selectColumn,String tableName,Object record_id){
StringBuilder select = new StringBuilder("SELECT ")
.append(selectColumn).append(" FROM ")
.append(tableName.substring(0,tableName.length()-3)).append(" WHERE ")
.append(tableName).append("=?");
return DB.getSQLValueStringEx(null, select.toString(),record_id);
}
private String resolveColumnName(MTable table, MColumn column) {
StringBuilder name = new StringBuilder(column.getColumnName());
if (DisplayType.isLookup(column.getAD_Reference_ID())) {
@ -306,6 +416,32 @@ public class GridTabCSVExporter implements IGridTabExporter
return name.toString();
}
private ArrayList<String> resolveSpecialColumnName(int displayType){
ArrayList<String> specialColumnNames = new ArrayList<String>();
if (DisplayType.Location == displayType ){
GridWindowVO gWindowVO = Env.getMWindowVO(0,121,0);
GridWindow m_mWindow = new GridWindow (gWindowVO);
GridTab m_mTab = m_mWindow.getTab(0);
m_mWindow.initTab(0);
for(GridField locField:m_mTab.getFields()){
if("AD_Client_ID".equals(locField.getColumnName()))
continue;
if("AD_Org_ID".equals(locField.getColumnName()))
continue;
if("IsActive".equals(locField.getColumnName()))
continue;
if(!locField.isDisplayed())
continue;
String fName = resolveColumnName(MTable.get(Env.getCtx(), m_mTab.getTableName()),MColumn.get(Env.getCtx(), locField.getAD_Column_ID()));
specialColumnNames.add(m_mTab.getTableName()+">"+ fName);
}
}
return specialColumnNames;
}
@Override
public String getFileExtension() {
return "csv";

View File

@ -649,6 +649,21 @@ public class MLocation extends X_C_Location implements Comparator<Object>
return false;
}
//check city id
if (m_c != null && !m_c.isAllowCitiesOutOfList() && getC_City_ID() > 0) {
int city_id = DB.getSQLValue(get_TrxName(),
"SELECT C_City_ID "+
" FROM C_City "+
" WHERE C_Country_ID=? "+
" AND COALESCE(C_Region_ID,0)=? " +
" AND C_City_ID =?",
new Object[] {getC_Country_ID(), getC_Region_ID(), getC_City_ID()});
if (city_id<0){
log.saveError("CityNotFound",Msg.translate(getCtx(), "CityNotFound")+" C_City_ID["+getC_City_ID()+"]");
return false;
}
}
return true;
} // beforeSave

View File

@ -1361,6 +1361,7 @@ public class Login
.append(" INNER JOIN AD_Client cli on (ur.AD_Client_ID=cli.AD_Client_ID)")
.append(" WHERE ur.IsActive='Y'")
.append(" AND u.IsActive='Y'")
.append(" AND cli.IsActive='Y'")
.append(" AND ur.AD_User_ID=?");
PreparedStatement pstmt=null;
ResultSet rs=null;
@ -1561,6 +1562,7 @@ public class Login
.append(" INNER JOIN AD_User u on (ur.AD_User_ID=u.AD_User_ID)")
.append(" INNER JOIN AD_Client cli on (ur.AD_Client_ID=cli.AD_Client_ID)")
.append(" WHERE ur.IsActive='Y'")
.append(" AND cli.IsActive='Y'")
.append(" AND u.IsActive='Y'")
.append(" AND u.AD_User_ID=?");
PreparedStatement pstmt = null;

View File

@ -321,7 +321,7 @@ public class RolePanel extends Window implements EventListener<Event>, Deferrabl
{
ComboItem ci = new ComboItem(m_clientKNPairs[i].getName(), m_clientKNPairs[i].getID());
String id = AdempiereIdGenerator.escapeId(ci.getLabel());
if (ci.getFellowIfAny(id) == null)
if (lstClient.getFellowIfAny(id) == null)
ci.setId(id);
lstClient.appendChild(ci);
if (m_clientKNPairs[i].getID().equals(initDefault))
@ -369,9 +369,8 @@ public class RolePanel extends Window implements EventListener<Event>, Deferrabl
{
ComboItem ci = new ComboItem(roleKNPairs[i].getName(), roleKNPairs[i].getID());
String id = AdempiereIdGenerator.escapeId(ci.getLabel());
if (lstRole.getFellowIfAny(id) == null) {
if (lstRole.getFellowIfAny(id) == null)
ci.setId(id);
}
lstRole.appendChild(ci);
if (roleKNPairs[i].getID().equals(initDefault))
lstRole.setSelectedItem(ci);
@ -425,7 +424,7 @@ public class RolePanel extends Window implements EventListener<Event>, Deferrabl
{
ComboItem ci = new ComboItem(orgKNPairs[i].getName(), orgKNPairs[i].getID());
String id = AdempiereIdGenerator.escapeId(ci.getLabel());
if (ci.getFellowIfAny(id) == null)
if (lstOrganisation.getFellowIfAny(id) == null)
ci.setId(id);
lstOrganisation.appendChild(ci);
if(orgKNPairs[i].getID().equals(initDefault))

View File

@ -282,8 +282,8 @@ public class WRC2FieldOrderPanel extends WRCTabPanel implements EventListener<Ev
} // down
if (change) {
sortList.setSelectedIndices(indices);
refresh();
sortList.setSelectedIndices(indices);
wc.setIsChanged(true);
if ( sortList.getSelectedItem() != null)
{

View File

@ -205,7 +205,7 @@ public class ExportAction implements EventListener<Event>
winExportFile = null;
AMedia media = null;
media = new AMedia(exporter.getSuggestedFileName(panel.getActiveGridTab()), null, exporter.getContentType(), file, true);
Filedownload.save(media, panel.getActiveGridTab().getName() + "." + ext);
Filedownload.save(media);
} catch (Exception e) {
throw new AdempiereException(e);
} finally {

View File

@ -313,7 +313,7 @@ public class FileImportAction implements EventListener<Event>
AMedia media = null;
media = new AMedia(importer.getSuggestedFileName(panel.getActiveGridTab()), null, importer.getContentType(), outFile, true);
Filedownload.save(media, panel.getActiveGridTab().getName() + "." + ext);
Filedownload.save(media);
} catch (Exception e) {
throw new AdempiereException(e);

View File

@ -302,7 +302,7 @@ public class WLocationDialog extends Window implements EventListener<Event>
if (MLocation.LOCATION_MAPS_URL_PREFIX == null)
toLink.setVisible(false);
pnlLinks.appendChild(toRoute);
if (MLocation.LOCATION_MAPS_ROUTE_PREFIX == null)
if (MLocation.LOCATION_MAPS_ROUTE_PREFIX == null || Env.getAD_Org_ID(Env.getCtx()) <= 0)
toRoute.setVisible(false);
pnlLinks.setWidth("100%");
pnlLinks.setStyle("text-align:left");