From d50e43d850a78210339acaba78eac64bf7b08c39 Mon Sep 17 00:00:00 2001 From: Elaine Tan Date: Tue, 29 Jan 2013 14:38:39 +0800 Subject: [PATCH] Ticket #1001569: Move receipts into batch from QS to Idempiere --- .../oracle/201301251920_TICKET-1001569.sql | 2140 +++++++++++++ .../201301251920_TICKET-1001569.sql | 2140 +++++++++++++ .../adempiere/process/DepositBatchClose.java | 91 + .../org/compiere/model/I_C_BankStatement.java | 9 + .../org/compiere/model/I_X_DepositBatch.java | 262 ++ .../compiere/model/I_X_DepositBatchLine.java | 201 ++ .../src/org/compiere/model/MDepositBatch.java | 325 ++ .../org/compiere/model/MDepositBatchLine.java | 189 ++ .../org/compiere/model/X_C_BankStatement.java | 16 +- .../org/compiere/model/X_X_DepositBatch.java | 372 +++ .../compiere/model/X_X_DepositBatchLine.java | 261 ++ .../src/org/compiere/apps/APanel.java | 4 +- .../grid/DefaultCreateFromFactory.java | 38 +- .../grid/VCreateFromBatchStatementUI.java | 335 ++ .../grid/VCreateFromDepositBatchUI.java | 337 ++ .../org/compiere/grid/VCreateFromDialog.java | 2 +- .../org/compiere/grid/VCreateFromFactory.java | 4 +- .../grid/VCreateFromStatementBatchUI.java | 335 ++ .../compiere/grid/VCreateFromStatementUI.java | 27 +- .../adwindow/AbstractADWindowContent.java | 7 +- .../AbstractADWindowContent.java.orig | 2792 +++++++++++++++++ .../apps/form/DefaultCreateFromFactory.java | 38 +- .../form/WCreateFromBatchStatementUI.java | 310 ++ .../apps/form/WCreateFromDepositBatchUI.java | 312 ++ .../webui/apps/form/WCreateFromFactory.java | 4 +- .../form/WCreateFromStatementBatchUI.java | 311 ++ .../apps/form/WCreateFromStatementUI.java | 26 +- .../webui/apps/form/WCreateFromWindow.java | 2 +- .../src/org/compiere/grid/CreateFrom.java | 3 +- .../org/compiere/grid/CreateFromBatch.java | 181 ++ .../grid/CreateFromBatchStatement.java | 218 ++ .../compiere/grid/CreateFromDepositBatch.java | 169 + .../org/compiere/grid/CreateFromInvoice.java | 3 +- .../grid/CreateFromPackageShipment.java | 3 +- .../src/org/compiere/grid/CreateFromRMA.java | 3 +- .../org/compiere/grid/CreateFromShipment.java | 4 +- .../compiere/grid/CreateFromStatement.java | 20 +- .../grid/CreateFromStatementBatch.java | 169 + .../org/compiere/grid/ICreateFromFactory.java | 2 +- 39 files changed, 11571 insertions(+), 94 deletions(-) create mode 100644 migration/i1.0a-release/oracle/201301251920_TICKET-1001569.sql create mode 100644 migration/i1.0a-release/postgresql/201301251920_TICKET-1001569.sql create mode 100644 org.adempiere.base/src/org/adempiere/process/DepositBatchClose.java create mode 100644 org.adempiere.base/src/org/compiere/model/I_X_DepositBatch.java create mode 100644 org.adempiere.base/src/org/compiere/model/I_X_DepositBatchLine.java create mode 100644 org.adempiere.base/src/org/compiere/model/MDepositBatch.java create mode 100644 org.adempiere.base/src/org/compiere/model/MDepositBatchLine.java create mode 100644 org.adempiere.base/src/org/compiere/model/X_X_DepositBatch.java create mode 100644 org.adempiere.base/src/org/compiere/model/X_X_DepositBatchLine.java create mode 100644 org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromBatchStatementUI.java create mode 100644 org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromDepositBatchUI.java create mode 100644 org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromStatementBatchUI.java create mode 100644 org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/AbstractADWindowContent.java.orig create mode 100644 org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromBatchStatementUI.java create mode 100644 org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromDepositBatchUI.java create mode 100644 org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromStatementBatchUI.java create mode 100644 org.adempiere.ui/src/org/compiere/grid/CreateFromBatch.java create mode 100644 org.adempiere.ui/src/org/compiere/grid/CreateFromBatchStatement.java create mode 100644 org.adempiere.ui/src/org/compiere/grid/CreateFromDepositBatch.java create mode 100644 org.adempiere.ui/src/org/compiere/grid/CreateFromStatementBatch.java diff --git a/migration/i1.0a-release/oracle/201301251920_TICKET-1001569.sql b/migration/i1.0a-release/oracle/201301251920_TICKET-1001569.sql new file mode 100644 index 0000000000..f1cb158368 --- /dev/null +++ b/migration/i1.0a-release/oracle/201301251920_TICKET-1001569.sql @@ -0,0 +1,2140 @@ +-- Jan 23, 2013 5:43:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Table (ImportTable,CopyColumnsFromTable,IsSecurityEnabled,AccessLevel,LoadSeq,AD_Table_ID,IsHighVolume,IsView,IsChangeLog,EntityType,ReplicationType,AD_Table_UU,IsCentrallyMaintained,IsDeleteable,TableName,Name,AD_Client_ID,IsActive,AD_Org_ID,Updated,CreatedBy,UpdatedBy,Created) VALUES ('N','N','N','3',0,200056,'N','N','N','D','L','4428e636-52c0-40c7-bfa3-d637dbac1642','Y','Y','X_DepositBatch','Receipts into Batch',0,'Y',0,TO_DATE('2013-01-23 17:43:11','YYYY-MM-DD HH24:MI:SS'),100,100,TO_DATE('2013-01-23 17:43:11','YYYY-MM-DD HH24:MI:SS')) +; + +-- Jan 23, 2013 5:43:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Table_Trl (AD_Language,AD_Table_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Table_Trl_UU ) SELECT l.AD_Language,t.AD_Table_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Table t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Table_ID=200056 AND NOT EXISTS (SELECT * FROM AD_Table_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Table_ID=t.AD_Table_ID) +; + +-- Jan 23, 2013 5:43:15 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Sequence (UpdatedBy,StartNewYear,CurrentNextSys,IsTableID,CurrentNext,IsAudited,IsAutoSequence,AD_Sequence_ID,AD_Sequence_UU,Description,Name,IncrementNo,AD_Org_ID,AD_Client_ID,Created,CreatedBy,Updated,IsActive,StartNo) VALUES (100,'N',200000,'Y',1000000,'N','Y',200051,'225ea2ca-af9e-484e-a64c-a7348c3dd01b','Table X_DepositBatch','X_DepositBatch',1,0,0,TO_DATE('2013-01-23 17:43:14','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2013-01-23 17:43:14','YYYY-MM-DD HH24:MI:SS'),'Y',1000000) +; + +-- Jan 23, 2013 5:44:15 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,DefaultValue,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200056,208398,'D','Y','N','N','N',22,'N',19,'N',102,'N','Y','2d8664be-6fe2-4101-96c1-430ab0239fb1','N','AD_Client_ID','Client/Tenant for this installation.','@#AD_Client_ID@','A Client is a company or a legal entity. You cannot share data between Clients. Tenant is a synonym for Client.','Client','N',100,TO_DATE('2013-01-23 17:44:13','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:44:13','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:44:15 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208398 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:16 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,AD_Val_Rule_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,DefaultValue,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200056,208399,'D','Y','N','N','N',22,'N',19,104,'N',113,'N','Y','0b04414e-898c-443d-920a-861390037ce4','N','AD_Org_ID','Organizational entity within client','@#AD_Org_ID@','An organization is a unit of your client or legal entity - examples are store, department. You can share data between organizations.','Organization','N',100,TO_DATE('2013-01-23 17:44:15','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:44:15','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:44:16 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208399 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:17 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200056,208400,'D','Y','N','N','N',7,'N',16,'N',245,'N','Y','8f0513e9-b931-446f-bd38-1fed5bd4b98a','N','Created','Date this record was created','The Created field indicates the date that this record was created.','Created','N',100,TO_DATE('2013-01-23 17:44:16','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:44:16','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:44:17 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208400 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:18 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,AD_Reference_Value_ID,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200056,208401,'D',110,'Y','N','N','N',22,'N',18,'N',246,'N','Y','74751997-d9b9-459f-a187-58b087f2a241','N','CreatedBy','User who created this records','The Created By field indicates the user who created this record.','Created By','N',100,TO_DATE('2013-01-23 17:44:17','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:44:17','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:44:18 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208401 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:19 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200056,208402,'D','N','N','N','N',255,'Y',10,'N',275,'N','Y','ba56e79b-9cf3-4a2d-9626-c2cf9c6cd4be','Y','Description','Optional short description of the record','A description is limited to 255 characters.','Description','Y',100,TO_DATE('2013-01-23 17:44:18','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:44:18','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:44:19 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208402 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:20 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,DefaultValue,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200056,208403,'D','Y','N','N','N',1,'N',20,'N',348,'N','Y','78523715-b9b6-4fcf-b7dd-8519a6b2c4dd','Y','IsActive','The record is active in the system','Y','There are two methods of making records unavailable in the system: One is to delete the record, the other is to de-activate the record. A de-activated record is not available for selection, but available for reports. +There are two reasons for de-activating and not deleting records: +(1) The system requires the record for audit purposes. +(2) The record is referenced by other records. E.g., you cannot delete a Business Partner, if there are invoices for this partner record existing. You de-activate the Business Partner and prevent that this record is used for future entries.','Active','N',100,TO_DATE('2013-01-23 17:44:19','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:44:19','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:44:20 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208403 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:21 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,DefaultValue,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208404,'D','Y','N','N',0,'N',1,'N',20,'N',1103,'N','Y','129a7fa8-8182-449d-ade5-415a085018d9','Y','IsDefault','Default value','N','The Default Checkbox indicates if this record will be used as a default value.','Default','Y',100,TO_DATE('2013-01-23 17:44:20','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:44:20','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:44:21 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208404 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:22 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200056,208405,'D','Y','N','Y',1,'N',60,'Y',10,'N',469,'N','Y','12270b16-e9dd-4d72-9196-11394805615d','Y','Name','Alphanumeric identifier of the entity','The name of an entity (record) is used as an default search option in addition to the search key. The name is up to 60 characters in length.','Name','Y',100,TO_DATE('2013-01-23 17:44:21','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:44:21','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:44:22 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208405 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:22 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200056,208406,'D','Y','N','N','N',7,'N',16,'N',607,'N','Y','bd1af2c5-5a73-42a1-8d07-6ad158db107a','N','Updated','Date this record was updated','The Updated field indicates the date that this record was updated.','Updated','N',100,TO_DATE('2013-01-23 17:44:22','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:44:22','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:44:22 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208406 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,AD_Reference_Value_ID,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200056,208407,'D',110,'Y','N','N','N',22,'N',18,'N',608,'N','Y','2af94666-4c6c-442a-a4c0-420af1dd36f8','N','UpdatedBy','User who updated this records','The Updated By field indicates the user who updated this record.','Updated By','N',100,TO_DATE('2013-01-23 17:44:23','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:44:23','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:44:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208407 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:24 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208408,'D','Y','N','N',0,'N',40,'N',10,'N',620,'N','Y','4a595470-7566-47f5-ae36-aa02f2f44233','Y','Value','Search key for the record in the format required - must be unique','A search key allows you a fast method of finding a particular record. +If you leave the search key empty, the system automatically creates a numeric number. The document sequence used for this fallback number is defined in the "Maintain Sequence" window with the name "DocumentNo_", where TableName is the actual name of the table (e.g. C_Order).','Search Key','Y',100,TO_DATE('2013-01-23 17:44:23','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:44:23','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:44:24 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208408 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:25 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208409,'D','Y','N','N',0,'Y',10,'N',19,'N',200601,'N','Y','8f84791b-c852-4281-83d9-ddd42eef708a','N','X_Shipper_ID','Shipper','Y',100,TO_DATE('2013-01-23 17:44:24','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:44:24','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:44:25 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208409 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:26 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element (ColumnName,AD_Element_ID,EntityType,Name,PrintName,AD_Element_UU,AD_Client_ID,Created,Updated,AD_Org_ID,CreatedBy,UpdatedBy,IsActive) VALUES ('X_DepositBatch_ID',202195,'D','Receipts into Batch','Receipts into Batch','bfada75f-e83d-4726-8cf3-edf1c771f2cf',0,TO_DATE('2013-01-23 17:44:25','YYYY-MM-DD HH24:MI:SS'),TO_DATE('2013-01-23 17:44:25','YYYY-MM-DD HH24:MI:SS'),0,100,100,'Y') +; + +-- Jan 23, 2013 5:44:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element_Trl (AD_Language,AD_Element_ID, Help,PO_Description,PO_Help,Description,Name,PrintName,PO_Name,PO_PrintName, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Element_Trl_UU ) SELECT l.AD_Language,t.AD_Element_ID, t.Help,t.PO_Description,t.PO_Help,t.Description,t.Name,t.PrintName,t.PO_Name,t.PO_PrintName, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Element t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Element_ID=202195 AND NOT EXISTS (SELECT * FROM AD_Element_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Element_ID=t.AD_Element_ID) +; + +-- Jan 23, 2013 5:44:28 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200056,208410,'D','Y','N','N','N',22,'N',13,'Y',202195,'N','Y','7cc2a164-9cb2-4e1e-890b-7b593750299b','N','X_DepositBatch_ID','Receipts into Batch','N',100,TO_DATE('2013-01-23 17:44:25','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:44:25','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:44:28 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208410 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:29 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element (ColumnName,AD_Element_ID,EntityType,Name,PrintName,AD_Element_UU,AD_Client_ID,Created,Updated,AD_Org_ID,CreatedBy,UpdatedBy,IsActive) VALUES ('X_DepositBatch_UU',202196,'D','X_DepositBatch_UU','X_DepositBatch_UU','683ea13b-9f88-4947-a2ce-237ed9c0ad89',0,TO_DATE('2013-01-23 17:44:28','YYYY-MM-DD HH24:MI:SS'),TO_DATE('2013-01-23 17:44:28','YYYY-MM-DD HH24:MI:SS'),0,100,100,'Y') +; + +-- Jan 23, 2013 5:44:29 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element_Trl (AD_Language,AD_Element_ID, Help,PO_Description,PO_Help,Description,Name,PrintName,PO_Name,PO_PrintName, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Element_Trl_UU ) SELECT l.AD_Language,t.AD_Element_ID, t.Help,t.PO_Description,t.PO_Help,t.Description,t.Name,t.PrintName,t.PO_Name,t.PO_PrintName, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Element t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Element_ID=202196 AND NOT EXISTS (SELECT * FROM AD_Element_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Element_ID=t.AD_Element_ID) +; + +-- Jan 23, 2013 5:44:30 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1.00,'N','N',200056,208411,'D','N','N','N','N',36,'N',10,'N',202196,'N','Y','30e43343-a737-44e5-b281-7ed55be45974','Y','X_DepositBatch_UU','X_DepositBatch_UU','N',100,TO_DATE('2013-01-23 17:44:28','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:44:28','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:44:30 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208411 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:45:00 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column_Trl WHERE AD_Column_ID=208404 +; + +-- Jan 23, 2013 5:45:01 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column WHERE AD_Column_ID=208404 +; + +-- Jan 23, 2013 5:45:04 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column_Trl WHERE AD_Column_ID=208405 +; + +-- Jan 23, 2013 5:45:04 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column WHERE AD_Column_ID=208405 +; + +-- Jan 23, 2013 5:45:04 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column_Trl WHERE AD_Column_ID=208408 +; + +-- Jan 23, 2013 5:45:04 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column WHERE AD_Column_ID=208408 +; + +-- Jan 23, 2013 5:45:04 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column_Trl WHERE AD_Column_ID=208409 +; + +-- Jan 23, 2013 5:45:04 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column WHERE AD_Column_ID=208409 +; + +-- Jan 23, 2013 5:45:35 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208412,'D','Y','N','N',0,'N',10,'N',19,'N',836,'N','Y','6a2370a3-09f8-4d30-81cf-baa821f3bac9','Y','C_BankAccount_ID','Account at the Bank','The Bank Account identifies an account at this Bank.','Bank Account','Y',100,TO_DATE('2013-01-23 17:45:34','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:45:34','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:45:35 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208412 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:46:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208413,'D','Y','N','N',0,'N',10,'N',19,'N',196,'N','Y','14dfbc52-7dcc-40c3-ae5e-ef0bab3512f9','Y','C_DocType_ID','Document type or rules','The Document Type determines document sequence and processing rules','Document Type','Y',100,TO_DATE('2013-01-23 17:46:05','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:46:05','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:46:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208413 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:47:05 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208414,'D','N','N','N',0,'N',1,'N',28,'N',1490,'N','Y','e55e3f8d-28d7-43cb-b369-077017e6b823','Y','CreateFrom','Process which will generate a new document lines based on an existing document','The Create From process will create a new document based on information in an existing document selected by the user.','Create lines from','Y',100,TO_DATE('2013-01-23 17:47:04','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:47:04','YYYY-MM-DD HH24:MI:SS'),100,0,0,'Y','N') +; + +-- Jan 23, 2013 5:47:05 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208414 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:48:01 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element (ColumnName,AD_Element_ID,EntityType,Name,PrintName,AD_Element_UU,AD_Client_ID,Created,Updated,AD_Org_ID,CreatedBy,UpdatedBy,IsActive) VALUES ('DateDeposit',202197,'D','Deposit Date','Deposit Date','d11ff847-d57c-4f51-92e9-c7bed69071cc',0,TO_DATE('2013-01-23 17:48:00','YYYY-MM-DD HH24:MI:SS'),TO_DATE('2013-01-23 17:48:00','YYYY-MM-DD HH24:MI:SS'),0,100,100,'Y') +; + +-- Jan 23, 2013 5:48:01 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element_Trl (AD_Language,AD_Element_ID, Help,PO_Description,PO_Help,Description,Name,PrintName,PO_Name,PO_PrintName, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Element_Trl_UU ) SELECT l.AD_Language,t.AD_Element_ID, t.Help,t.PO_Description,t.PO_Help,t.Description,t.Name,t.PrintName,t.PO_Name,t.PO_PrintName, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Element t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Element_ID=202197 AND NOT EXISTS (SELECT * FROM AD_Element_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Element_ID=t.AD_Element_ID) +; + +-- Jan 23, 2013 5:48:24 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,DefaultValue,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208415,'D','Y','N','Y',0,'N',7,'N',15,'N',202197,'N','Y','b17960ea-1616-47eb-8971-9d5e980f44f4','Y','DateDeposit','@#Date@','Deposit Date','Y',100,TO_DATE('2013-01-23 17:48:23','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:48:23','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:48:24 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208415 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:49:20 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,DefaultValue,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208416,'D','Y','N','N',0,'N',7,'N',15,'N',265,'N','Y','5fc53d1e-3942-44dc-b70d-614efcb82de9','Y','DateDoc','Date of the Document','@#Date@','The Document Date indicates the date the document was generated. It may or may not be the same as the accounting date.','Document Date','Y',100,TO_DATE('2013-01-23 17:49:19','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:49:19','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:49:20 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208416 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:49:50 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element (ColumnName,AD_Element_ID,EntityType,Name,PrintName,AD_Element_UU,AD_Client_ID,Created,Updated,AD_Org_ID,CreatedBy,UpdatedBy,IsActive) VALUES ('DepositAmt',202198,'D','Deposit Amount','Deposit Amount','1c52e614-ae8e-4767-aab1-f6ffe26eadee',0,TO_DATE('2013-01-23 17:49:49','YYYY-MM-DD HH24:MI:SS'),TO_DATE('2013-01-23 17:49:49','YYYY-MM-DD HH24:MI:SS'),0,100,100,'Y') +; + +-- Jan 23, 2013 5:49:50 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element_Trl (AD_Language,AD_Element_ID, Help,PO_Description,PO_Help,Description,Name,PrintName,PO_Name,PO_PrintName, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Element_Trl_UU ) SELECT l.AD_Language,t.AD_Element_ID, t.Help,t.PO_Description,t.PO_Help,t.Description,t.Name,t.PrintName,t.PO_Name,t.PO_PrintName, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Element t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Element_ID=202198 AND NOT EXISTS (SELECT * FROM AD_Element_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Element_ID=t.AD_Element_ID) +; + +-- Jan 23, 2013 5:50:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208417,'D','Y','N','N',0,'N',14,'N',12,'N',202198,'N','Y','6b6f91e3-10ef-4e42-9131-5053e50bd53f','Y','DepositAmt','Deposit Amount','Y',100,TO_DATE('2013-01-23 17:50:45','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:50:45','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:50:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208417 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:51:33 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,AD_Reference_Value_ID,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,DefaultValue,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208418,'D',131,'Y','N','N',0,'N',2,'N',17,'N',289,'N','Y','93912515-ea34-4fcd-b2e3-72eaf5104da7','Y','DocStatus','The current status of the document','DR','The Document Status indicates the status of a document at this time. If you want to change the document status, use the Document Action field','Document Status','Y',100,TO_DATE('2013-01-23 17:51:32','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:51:32','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:51:33 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208418 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:52:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208419,'D','Y','N','Y',1,'N',30,'N',10,'N',290,'N','Y','98986539-7553-48d2-a01c-dce62a2e707a','Y','DocumentNo','Document sequence number of the document','The document number is usually automatically generated by the system and determined by the document type of the document. If the document is not saved, the preliminary number is displayed in "<>". + +If the document type of your document has no automatic document sequence defined, the field is empty if you create a new document. This is for documents which usually have an external number (like vendor invoice). If you leave the field empty, the system will generate a document number for you. The document sequence used for this fallback number is defined in the "Maintain Sequence" window with the name "DocumentNo_", where TableName is the actual name of the table (e.g. C_Order).','Document No','Y',100,TO_DATE('2013-01-23 17:52:12','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:52:12','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:52:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208419 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:52:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208420,'D','Y','N','N',0,'N',1,'N',20,'N',1047,'N','Y','ddb5f7e8-383b-49da-8eec-173a825209fd','Y','Processed','The document has been processed','The Processed checkbox indicates that a document has been processed.','Processed','Y',100,TO_DATE('2013-01-23 17:52:52','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:52:52','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:52:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208420 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:54:12 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Process (CopyFromProcess,AD_Process_ID,IsDirectPrint,IsReport,AD_Process_UU,AccessLevel,IsBetaFunctionality,IsServerProcess,Statistic_Seconds,Statistic_Count,ShowHelp,EntityType,Classname,Name,Value,AD_Org_ID,AD_Client_ID,Created,Updated,UpdatedBy,IsActive,CreatedBy) VALUES ('N',200031,'N','N','204960ea-1515-48ad-be88-93bdd8100f01','3','N','N',0,0,'Y','D','org.adempiere.process.DepositBatchClose','Deposit Batch Close','X_DepositBatch Close',0,0,TO_DATE('2013-01-23 17:54:11','YYYY-MM-DD HH24:MI:SS'),TO_DATE('2013-01-23 17:54:11','YYYY-MM-DD HH24:MI:SS'),100,'Y',100) +; + +-- Jan 23, 2013 5:54:12 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Process_Trl (AD_Language,AD_Process_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Process_Trl_UU ) SELECT l.AD_Language,t.AD_Process_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Process t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Process_ID=200031 AND NOT EXISTS (SELECT * FROM AD_Process_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Process_ID=t.AD_Process_ID) +; + +-- Jan 23, 2013 5:54:25 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,AD_Process_ID,ReadOnlyLogic,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208421,'D','N','N','N',0,'N',1,'N',28,'N',524,200031,'@Processed@=''Y''','N','Y','0625f0a4-093d-4909-87c5-3a36f860b1c3','Y','Processing','Process Now','Y',100,TO_DATE('2013-01-23 17:54:24','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:54:24','YYYY-MM-DD HH24:MI:SS'),100,0,0,'Y','N') +; + +-- Jan 23, 2013 5:54:25 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208421 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:54:52 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +CREATE TABLE X_DepositBatch (AD_Client_ID NUMBER(10) NOT NULL, AD_Org_ID NUMBER(10) NOT NULL, C_BankAccount_ID NUMBER(10) NOT NULL, C_DocType_ID NUMBER(10) NOT NULL, Created DATE NOT NULL, CreatedBy NUMBER(10) NOT NULL, CreateFrom CHAR(1) DEFAULT NULL , DateDeposit DATE NOT NULL, DateDoc DATE NOT NULL, DepositAmt NUMBER NOT NULL, Description NVARCHAR2(255) DEFAULT NULL , DocStatus NVARCHAR2(2) DEFAULT 'DR' NOT NULL, DocumentNo NVARCHAR2(30) NOT NULL, IsActive CHAR(1) DEFAULT 'Y' CHECK (IsActive IN ('Y','N')) NOT NULL, Processed CHAR(1) CHECK (Processed IN ('Y','N')) NOT NULL, Processing CHAR(1) DEFAULT NULL , Updated DATE NOT NULL, UpdatedBy NUMBER(10) NOT NULL, X_DepositBatch_ID NUMBER(10) NOT NULL, X_DepositBatch_UU NVARCHAR2(36) DEFAULT NULL , CONSTRAINT X_DepositBatch_Key PRIMARY KEY (X_DepositBatch_ID)) +; + +-- Jan 23, 2013 5:55:56 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Table (ImportTable,CopyColumnsFromTable,IsSecurityEnabled,AccessLevel,LoadSeq,AD_Table_ID,IsHighVolume,IsView,IsChangeLog,EntityType,ReplicationType,AD_Table_UU,IsCentrallyMaintained,IsDeleteable,TableName,Name,AD_Client_ID,IsActive,AD_Org_ID,Updated,CreatedBy,UpdatedBy,Created) VALUES ('N','N','N','3',0,200057,'N','N','N','D','L','21bd7d26-d60b-4e9a-bcd2-85b95c162aa7','Y','Y','X_DepositBatchLine','Deposit Batch Line',0,'Y',0,TO_DATE('2013-01-23 17:55:55','YYYY-MM-DD HH24:MI:SS'),100,100,TO_DATE('2013-01-23 17:55:55','YYYY-MM-DD HH24:MI:SS')) +; + +-- Jan 23, 2013 5:55:56 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Table_Trl (AD_Language,AD_Table_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Table_Trl_UU ) SELECT l.AD_Language,t.AD_Table_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Table t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Table_ID=200057 AND NOT EXISTS (SELECT * FROM AD_Table_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Table_ID=t.AD_Table_ID) +; + +-- Jan 23, 2013 5:55:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Sequence (UpdatedBy,StartNewYear,CurrentNextSys,IsTableID,CurrentNext,IsAudited,IsAutoSequence,AD_Sequence_ID,AD_Sequence_UU,Description,Name,IncrementNo,AD_Org_ID,AD_Client_ID,Created,CreatedBy,Updated,IsActive,StartNo) VALUES (100,'N',200000,'Y',1000000,'N','Y',200052,'2d30472a-cb6b-4631-b037-a18997bc61b9','Table X_DepositBatchLine','X_DepositBatchLine',1,0,0,TO_DATE('2013-01-23 17:55:56','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2013-01-23 17:55:56','YYYY-MM-DD HH24:MI:SS'),'Y',1000000) +; + +-- Jan 23, 2013 5:56:25 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Table SET Name='Receipts into Batch Line',Updated=TO_DATE('2013-01-23 17:56:25','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Table_ID=200057 +; + +-- Jan 23, 2013 5:56:25 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Table_Trl SET IsTranslated='N' WHERE AD_Table_ID=200057 +; + +-- Jan 23, 2013 5:56:35 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,DefaultValue,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200057,208422,'D','Y','N','N','N',22,'N',19,'N',102,'N','Y','7a4c6365-d057-4041-bf7d-4d65aaae2cc3','N','AD_Client_ID','Client/Tenant for this installation.','@#AD_Client_ID@','A Client is a company or a legal entity. You cannot share data between Clients. Tenant is a synonym for Client.','Client','N',100,TO_DATE('2013-01-23 17:56:34','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:56:34','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:56:35 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208422 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:36 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,AD_Val_Rule_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,DefaultValue,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200057,208423,'D','Y','N','N','N',22,'N',19,104,'N',113,'N','Y','f87bdd5f-d8b2-485b-9e79-89c3a9780a3b','N','AD_Org_ID','Organizational entity within client','@#AD_Org_ID@','An organization is a unit of your client or legal entity - examples are store, department. You can share data between organizations.','Organization','N',100,TO_DATE('2013-01-23 17:56:35','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:56:35','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:56:36 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208423 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:36 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200057,208424,'D','Y','N','N','N',7,'N',16,'N',245,'N','Y','1d931ea9-fc11-4fae-9479-2318c1f61ccb','N','Created','Date this record was created','The Created field indicates the date that this record was created.','Created','N',100,TO_DATE('2013-01-23 17:56:36','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:56:36','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:56:36 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208424 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,AD_Reference_Value_ID,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200057,208425,'D',110,'Y','N','N','N',22,'N',18,'N',246,'N','Y','8d6bbaa6-5f3d-4514-9919-b5fc723eb8cd','N','CreatedBy','User who created this records','The Created By field indicates the user who created this record.','Created By','N',100,TO_DATE('2013-01-23 17:56:36','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:56:36','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:56:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208425 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200057,208426,'D','N','N','N','N',255,'Y',10,'N',275,'N','Y','020e13a1-cf72-49af-9768-5fc575cfc089','Y','Description','Optional short description of the record','A description is limited to 255 characters.','Description','Y',100,TO_DATE('2013-01-23 17:56:37','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:56:37','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:56:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208426 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:39 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,DefaultValue,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200057,208427,'D','Y','N','N','N',1,'N',20,'N',348,'N','Y','f21ce087-fe26-474f-92ac-500d646bebde','Y','IsActive','The record is active in the system','Y','There are two methods of making records unavailable in the system: One is to delete the record, the other is to de-activate the record. A de-activated record is not available for selection, but available for reports. +There are two reasons for de-activating and not deleting records: +(1) The system requires the record for audit purposes. +(2) The record is referenced by other records. E.g., you cannot delete a Business Partner, if there are invoices for this partner record existing. You de-activate the Business Partner and prevent that this record is used for future entries.','Active','N',100,TO_DATE('2013-01-23 17:56:38','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:56:38','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:56:39 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208427 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:40 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,DefaultValue,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200057,208428,'D','Y','N','N',0,'N',1,'N',20,'N',1103,'N','Y','797ba1b9-c4fe-418c-8c9b-12b5572772c9','Y','IsDefault','Default value','N','The Default Checkbox indicates if this record will be used as a default value.','Default','Y',100,TO_DATE('2013-01-23 17:56:39','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:56:39','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:56:40 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208428 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:41 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200057,208429,'D','Y','N','Y',1,'N',60,'Y',10,'N',469,'N','Y','de6545a6-4c1e-4d02-a282-880b428c2686','Y','Name','Alphanumeric identifier of the entity','The name of an entity (record) is used as an default search option in addition to the search key. The name is up to 60 characters in length.','Name','Y',100,TO_DATE('2013-01-23 17:56:40','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:56:40','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:56:41 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208429 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:42 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200057,208430,'D','Y','N','N','N',7,'N',16,'N',607,'N','Y','89f73975-72e0-4094-9247-adc2ac6cb2cc','N','Updated','Date this record was updated','The Updated field indicates the date that this record was updated.','Updated','N',100,TO_DATE('2013-01-23 17:56:41','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:56:41','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:56:42 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208430 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:43 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,AD_Reference_Value_ID,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200057,208431,'D',110,'Y','N','N','N',22,'N',18,'N',608,'N','Y','74593580-daa8-4324-821b-64d630a31439','N','UpdatedBy','User who updated this records','The Updated By field indicates the user who updated this record.','Updated By','N',100,TO_DATE('2013-01-23 17:56:42','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:56:42','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:56:43 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208431 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:44 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200057,208432,'D','Y','N','N',0,'N',40,'N',10,'N',620,'N','Y','ef8ee59d-c878-423b-9596-a70196d6be51','Y','Value','Search key for the record in the format required - must be unique','A search key allows you a fast method of finding a particular record. +If you leave the search key empty, the system automatically creates a numeric number. The document sequence used for this fallback number is defined in the "Maintain Sequence" window with the name "DocumentNo_", where TableName is the actual name of the table (e.g. C_Order).','Search Key','Y',100,TO_DATE('2013-01-23 17:56:43','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:56:43','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:56:44 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208432 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200057,208433,'D','Y','N','N',0,'Y',10,'N',19,'N',200601,'N','Y','565cfc26-2ab6-4902-bf11-39a10ac5090f','N','X_Shipper_ID','Shipper','Y',100,TO_DATE('2013-01-23 17:56:44','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:56:44','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:56:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208433 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:46 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element (ColumnName,AD_Element_ID,EntityType,Name,PrintName,AD_Element_UU,AD_Client_ID,Created,Updated,AD_Org_ID,CreatedBy,UpdatedBy,IsActive) VALUES ('X_DepositBatchLine_ID',202199,'D','Receipts into Batch Line','Receipts into Batch Line','0ecc1c05-ce0d-4668-b037-4cf0bc5e4a6d',0,TO_DATE('2013-01-23 17:56:45','YYYY-MM-DD HH24:MI:SS'),TO_DATE('2013-01-23 17:56:45','YYYY-MM-DD HH24:MI:SS'),0,100,100,'Y') +; + +-- Jan 23, 2013 5:56:46 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element_Trl (AD_Language,AD_Element_ID, Help,PO_Description,PO_Help,Description,Name,PrintName,PO_Name,PO_PrintName, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Element_Trl_UU ) SELECT l.AD_Language,t.AD_Element_ID, t.Help,t.PO_Description,t.PO_Help,t.Description,t.Name,t.PrintName,t.PO_Name,t.PO_PrintName, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Element t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Element_ID=202199 AND NOT EXISTS (SELECT * FROM AD_Element_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Element_ID=t.AD_Element_ID) +; + +-- Jan 23, 2013 5:56:47 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200057,208434,'D','Y','N','N','N',22,'N',13,'Y',202199,'N','Y','5ba3e70b-9087-4a78-ac1d-27da921780f7','N','X_DepositBatchLine_ID','Receipts into Batch Line','N',100,TO_DATE('2013-01-23 17:56:45','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:56:45','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:56:47 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208434 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:51 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element (ColumnName,AD_Element_ID,EntityType,Name,PrintName,AD_Element_UU,AD_Client_ID,Created,Updated,AD_Org_ID,CreatedBy,UpdatedBy,IsActive) VALUES ('X_DepositBatchLine_UU',202200,'D','X_DepositBatchLine_UU','X_DepositBatchLine_UU','7913a3b1-6e32-4764-afe0-24e3fbaf574c',0,TO_DATE('2013-01-23 17:56:47','YYYY-MM-DD HH24:MI:SS'),TO_DATE('2013-01-23 17:56:47','YYYY-MM-DD HH24:MI:SS'),0,100,100,'Y') +; + +-- Jan 23, 2013 5:56:51 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element_Trl (AD_Language,AD_Element_ID, Help,PO_Description,PO_Help,Description,Name,PrintName,PO_Name,PO_PrintName, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Element_Trl_UU ) SELECT l.AD_Language,t.AD_Element_ID, t.Help,t.PO_Description,t.PO_Help,t.Description,t.Name,t.PrintName,t.PO_Name,t.PO_PrintName, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Element t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Element_ID=202200 AND NOT EXISTS (SELECT * FROM AD_Element_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Element_ID=t.AD_Element_ID) +; + +-- Jan 23, 2013 5:56:52 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1.00,'N','N',200057,208435,'D','N','N','N','N',36,'N',10,'N',202200,'N','Y','a01d37de-3836-4f42-a697-e324684966a1','Y','X_DepositBatchLine_UU','X_DepositBatchLine_UU','N',100,TO_DATE('2013-01-23 17:56:47','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:56:47','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:56:52 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208435 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:57:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column_Trl WHERE AD_Column_ID=208426 +; + +-- Jan 23, 2013 5:57:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column WHERE AD_Column_ID=208426 +; + +-- Jan 23, 2013 5:57:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column_Trl WHERE AD_Column_ID=208428 +; + +-- Jan 23, 2013 5:57:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column WHERE AD_Column_ID=208428 +; + +-- Jan 23, 2013 5:57:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column_Trl WHERE AD_Column_ID=208429 +; + +-- Jan 23, 2013 5:57:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column WHERE AD_Column_ID=208429 +; + +-- Jan 23, 2013 5:57:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column_Trl WHERE AD_Column_ID=208432 +; + +-- Jan 23, 2013 5:57:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column WHERE AD_Column_ID=208432 +; + +-- Jan 23, 2013 5:57:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column_Trl WHERE AD_Column_ID=208433 +; + +-- Jan 23, 2013 5:57:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column WHERE AD_Column_ID=208433 +; + +-- Jan 23, 2013 5:57:50 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200057,208436,'D','Y','N','N',0,'N',14,'N',12,'N',1477,'N','Y','e2044592-39c2-416d-8290-347d623d2802','Y','PayAmt','Amount being paid','Indicates the amount this payment is for. The payment amount can be for single or multiple invoices or a partial payment for an invoice.','Payment amount','Y',100,TO_DATE('2013-01-23 17:57:49','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:57:49','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:57:50 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208436 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:58:16 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200057,208437,'D','Y','N','N',0,'N',10,'N',19,'N',1384,'N','Y','139d61a5-2419-4ae7-89ea-29cff433ee6b','Y','C_Payment_ID','Payment identifier','The Payment is a unique identifier of this payment.','Payment','Y',100,TO_DATE('2013-01-23 17:58:15','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:58:15','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:58:16 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208437 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:58:58 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,DefaultValue,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200057,208438,'D','Y','N','Y',0,'N',14,'N',11,'N',439,'N','Y','aa02a955-a0ce-4193-82b2-ef48472a4645','Y','Line','Unique line for this document','@SQL=SELECT NVL(MAX(Line),0)+10 AS DefaultValue FROM X_DepositBatchLine WHERE X_DepositBatch_ID=@X_DepositBatch_ID@','Indicates the unique line for a document. It will also control the display order of the lines within a document.','Line No','Y',100,TO_DATE('2013-01-23 17:58:57','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:58:57','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:58:58 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208438 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:59:26 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200057,208439,'D','Y','N','N',0,'N',1,'N',20,'N',1047,'N','Y','213e0828-2b2b-491e-89d7-8ff1b91513a3','Y','Processed','The document has been processed','The Processed checkbox indicates that a document has been processed.','Processed','Y',100,TO_DATE('2013-01-23 17:59:26','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:59:26','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:59:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208439 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:59:47 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200057,208440,'D','Y','N','N',0,'N',1,'N',20,'N',524,'N','Y','8cbdcd1c-4c89-4149-a67a-db427dae1274','Y','Processing','Process Now','Y',100,TO_DATE('2013-01-23 17:59:47','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 17:59:47','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:59:47 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208440 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 6:00:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200057,208441,'D','Y','N','Y',1,'Y',10,'N',30,'N',202195,'N','Y','ea94bbcc-6e17-4f2e-bf87-9b66e1a839d3','N','X_DepositBatch_ID','Receipts into Batch','Y',100,TO_DATE('2013-01-23 18:00:36','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 18:00:36','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 6:00:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208441 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 6:01:11 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Column SET IsUpdateable='N', Name='Deposit Batch',Updated=TO_DATE('2013-01-23 18:01:11','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=208441 +; + +-- Jan 23, 2013 6:01:11 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Column_Trl SET IsTranslated='N' WHERE AD_Column_ID=208441 +; + +-- Jan 23, 2013 6:01:11 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET Name='Deposit Batch', Description=NULL, Help=NULL WHERE AD_Column_ID=208441 AND IsCentrallyMaintained='Y' +; + +-- Jan 23, 2013 6:01:25 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Element SET PrintName='Deposit Batch',Updated=TO_DATE('2013-01-23 18:01:25','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Element_ID=202195 +; + +-- Jan 23, 2013 6:01:25 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Element_Trl SET IsTranslated='N' WHERE AD_Element_ID=202195 +; + +-- Jan 23, 2013 6:01:25 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_PrintFormatItem pi SET PrintName='Deposit Batch', Name='Receipts into Batch' WHERE IsCentrallyMaintained='Y' AND EXISTS (SELECT * FROM AD_Column c WHERE c.AD_Column_ID=pi.AD_Column_ID AND c.AD_Element_ID=202195) +; + +-- Jan 23, 2013 6:01:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Element SET Name='Deposit Batch Line', PrintName='Deposit Batch Line',Updated=TO_DATE('2013-01-23 18:01:45','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Element_ID=202199 +; + +-- Jan 23, 2013 6:01:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Element_Trl SET IsTranslated='N' WHERE AD_Element_ID=202199 +; + +-- Jan 23, 2013 6:01:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Column SET ColumnName='X_DepositBatchLine_ID', Name='Deposit Batch Line', Description=NULL, Help=NULL WHERE AD_Element_ID=202199 +; + +-- Jan 23, 2013 6:01:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Process_Para SET ColumnName='X_DepositBatchLine_ID', Name='Deposit Batch Line', Description=NULL, Help=NULL, AD_Element_ID=202199 WHERE UPPER(ColumnName)='X_DEPOSITBATCHLINE_ID' AND IsCentrallyMaintained='Y' AND AD_Element_ID IS NULL +; + +-- Jan 23, 2013 6:01:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Process_Para SET ColumnName='X_DepositBatchLine_ID', Name='Deposit Batch Line', Description=NULL, Help=NULL WHERE AD_Element_ID=202199 AND IsCentrallyMaintained='Y' +; + +-- Jan 23, 2013 6:01:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_InfoColumn SET ColumnName='X_DepositBatchLine_ID', Name='Deposit Batch Line', Description=NULL, Help=NULL WHERE AD_Element_ID=202199 AND IsCentrallyMaintained='Y' +; + +-- Jan 23, 2013 6:01:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET Name='Deposit Batch Line', Description=NULL, Help=NULL WHERE AD_Column_ID IN (SELECT AD_Column_ID FROM AD_Column WHERE AD_Element_ID=202199) AND IsCentrallyMaintained='Y' +; + +-- Jan 23, 2013 6:01:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_PrintFormatItem pi SET PrintName='Deposit Batch Line', Name='Deposit Batch Line' WHERE IsCentrallyMaintained='Y' AND EXISTS (SELECT * FROM AD_Column c WHERE c.AD_Column_ID=pi.AD_Column_ID AND c.AD_Element_ID=202199) +; + +-- Jan 23, 2013 6:01:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Element SET Name='Deposit Batch',Updated=TO_DATE('2013-01-23 18:01:57','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Element_ID=202195 +; + +-- Jan 23, 2013 6:01:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Element_Trl SET IsTranslated='N' WHERE AD_Element_ID=202195 +; + +-- Jan 23, 2013 6:01:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Column SET ColumnName='X_DepositBatch_ID', Name='Deposit Batch', Description=NULL, Help=NULL WHERE AD_Element_ID=202195 +; + +-- Jan 23, 2013 6:01:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Process_Para SET ColumnName='X_DepositBatch_ID', Name='Deposit Batch', Description=NULL, Help=NULL, AD_Element_ID=202195 WHERE UPPER(ColumnName)='X_DEPOSITBATCH_ID' AND IsCentrallyMaintained='Y' AND AD_Element_ID IS NULL +; + +-- Jan 23, 2013 6:01:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Process_Para SET ColumnName='X_DepositBatch_ID', Name='Deposit Batch', Description=NULL, Help=NULL WHERE AD_Element_ID=202195 AND IsCentrallyMaintained='Y' +; + +-- Jan 23, 2013 6:01:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_InfoColumn SET ColumnName='X_DepositBatch_ID', Name='Deposit Batch', Description=NULL, Help=NULL WHERE AD_Element_ID=202195 AND IsCentrallyMaintained='Y' +; + +-- Jan 23, 2013 6:01:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET Name='Deposit Batch', Description=NULL, Help=NULL WHERE AD_Column_ID IN (SELECT AD_Column_ID FROM AD_Column WHERE AD_Element_ID=202195) AND IsCentrallyMaintained='Y' +; + +-- Jan 23, 2013 6:01:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_PrintFormatItem pi SET PrintName='Deposit Batch', Name='Deposit Batch' WHERE IsCentrallyMaintained='Y' AND EXISTS (SELECT * FROM AD_Column c WHERE c.AD_Column_ID=pi.AD_Column_ID AND c.AD_Element_ID=202195) +; + +-- Jan 23, 2013 6:02:07 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Table SET Name='Deposit Batch Line',Updated=TO_DATE('2013-01-23 18:02:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Table_ID=200057 +; + +-- Jan 23, 2013 6:02:07 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Table_Trl SET IsTranslated='N' WHERE AD_Table_ID=200057 +; + +-- Jan 23, 2013 6:02:20 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Table SET Name='Deposit Batch',Updated=TO_DATE('2013-01-23 18:02:20','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Table_ID=200056 +; + +-- Jan 23, 2013 6:02:20 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Table_Trl SET IsTranslated='N' WHERE AD_Table_ID=200056 +; + +-- Jan 23, 2013 6:02:29 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +CREATE TABLE X_DepositBatchLine (AD_Client_ID NUMBER(10) NOT NULL, AD_Org_ID NUMBER(10) NOT NULL, C_Payment_ID NUMBER(10) NOT NULL, Created DATE NOT NULL, CreatedBy NUMBER(10) NOT NULL, IsActive CHAR(1) DEFAULT 'Y' CHECK (IsActive IN ('Y','N')) NOT NULL, Line NUMBER(10) NOT NULL, PayAmt NUMBER NOT NULL, Processed CHAR(1) CHECK (Processed IN ('Y','N')) NOT NULL, Processing CHAR(1) CHECK (Processing IN ('Y','N')) NOT NULL, Updated DATE NOT NULL, UpdatedBy NUMBER(10) NOT NULL, X_DepositBatch_ID NUMBER(10) NOT NULL, X_DepositBatchLine_ID NUMBER(10) NOT NULL, X_DepositBatchLine_UU NVARCHAR2(36) DEFAULT NULL , CONSTRAINT X_DepositBatchLine_Key PRIMARY KEY (X_DepositBatchLine_ID)) +; + +-- Jan 23, 2013 6:03:36 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element (ColumnName,AD_Element_ID,EntityType,Name,PrintName,AD_Element_UU,AD_Client_ID,Created,Updated,AD_Org_ID,CreatedBy,UpdatedBy,IsActive) VALUES ('X_CreateFromBatch',202201,'D','Create From Batch','Create From Batch','a56bf24b-a9b0-459b-8db3-17fff6f8d9c1',0,TO_DATE('2013-01-23 18:03:35','YYYY-MM-DD HH24:MI:SS'),TO_DATE('2013-01-23 18:03:35','YYYY-MM-DD HH24:MI:SS'),0,100,100,'Y') +; + +-- Jan 23, 2013 6:03:36 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element_Trl (AD_Language,AD_Element_ID, Help,PO_Description,PO_Help,Description,Name,PrintName,PO_Name,PO_PrintName, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Element_Trl_UU ) SELECT l.AD_Language,t.AD_Element_ID, t.Help,t.PO_Description,t.PO_Help,t.Description,t.Name,t.PrintName,t.PO_Name,t.PO_PrintName, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Element t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Element_ID=202201 AND NOT EXISTS (SELECT * FROM AD_Element_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Element_ID=t.AD_Element_ID) +; + +-- Jan 23, 2013 6:04:09 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',392,208442,'D','N','N','N',0,'N',1,'N',28,'N',202201,'N','Y','b6c3169b-a7c0-422c-bf51-89f9614ddef4','Y','X_CreateFromBatch','Create From Batch','Y',100,TO_DATE('2013-01-23 18:04:08','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 18:04:08','YYYY-MM-DD HH24:MI:SS'),100,0,0,'Y','N') +; + +-- Jan 23, 2013 6:04:09 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208442 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 6:04:10 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +ALTER TABLE C_BankStatement ADD X_CreateFromBatch CHAR(1) DEFAULT NULL +; + +-- Jan 23, 2013 6:06:32 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',335,208443,'D','N','N','N',0,'Y',10,'N',19,'N',202195,'N','Y','622ebed6-d1da-436e-81ab-9283d921d0b4','N','X_DepositBatch_ID','Deposit Batch','Y',100,TO_DATE('2013-01-23 18:06:31','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_DATE('2013-01-23 18:06:31','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 6:06:32 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208443 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 6:06:35 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +ALTER TABLE C_Payment ADD X_DepositBatch_ID NUMBER(10) DEFAULT NULL +; + +-- Jan 23, 2013 6:08:49 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,EntityType,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',328,36,'N','N',60601,'Y',201690,'N','D','C_BankStatement_UU','N','Y','d5f5ce1f-21cb-4b9e-a21f-62822cc17d57',100,0,TO_DATE('2013-01-23 18:08:48','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:08:48','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:08:50 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201690 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:08:51 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,EntityType,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',328,1,'N','N',208442,'Y',201691,'N','D','Create From Batch','N','Y','cdf9b481-ae14-4458-ac87-44afbb2fe155',100,0,TO_DATE('2013-01-23 18:08:50','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:08:50','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:08:51 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201691 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=0,IsDisplayed='N' WHERE AD_Field_ID=201690 +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=120,IsDisplayed='Y' WHERE AD_Field_ID=201691 +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=130,IsDisplayed='Y' WHERE AD_Field_ID=4003 +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=140,IsDisplayed='Y' WHERE AD_Field_ID=8933 +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=150,IsDisplayed='Y' WHERE AD_Field_ID=200599 +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=160,IsDisplayed='Y' WHERE AD_Field_ID=3997 +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=170,IsDisplayed='Y' WHERE AD_Field_ID=8686 +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=180,IsDisplayed='Y' WHERE AD_Field_ID=8687 +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=190,IsDisplayed='Y' WHERE AD_Field_ID=10585 +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=200,IsDisplayed='Y' WHERE AD_Field_ID=10586 +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=210,IsDisplayed='Y' WHERE AD_Field_ID=10587 +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=220,IsDisplayed='Y' WHERE AD_Field_ID=3999 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=61967 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=201690 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=3991 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=200599 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=200600 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=10,IsDisplayedGrid='Y' WHERE AD_Field_ID=3992 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=20,IsDisplayedGrid='Y' WHERE AD_Field_ID=3994 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=30,IsDisplayedGrid='Y' WHERE AD_Field_ID=4120 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=40,IsDisplayedGrid='Y' WHERE AD_Field_ID=4002 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=50,IsDisplayedGrid='Y' WHERE AD_Field_ID=3996 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=60,IsDisplayedGrid='Y' WHERE AD_Field_ID=3998 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=70,IsDisplayedGrid='Y' WHERE AD_Field_ID=4119 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=80,IsDisplayedGrid='Y' WHERE AD_Field_ID=3993 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=90,IsDisplayedGrid='Y' WHERE AD_Field_ID=4365 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=100,IsDisplayedGrid='Y' WHERE AD_Field_ID=201691 +; + +-- Jan 23, 2013 6:11:16 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET XPosition=2, ColumnSpan=2,Updated=TO_DATE('2013-01-23 18:11:16','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201691 +; + +-- Jan 23, 2013 6:12:26 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Window (Processing,WindowType,Help,IsSOTrx,IsDefault,IsBetaFunctionality,WinHeight,WinWidth,EntityType,Name,Description,AD_Window_ID,AD_Image_ID,AD_Window_UU,Created,Updated,AD_Client_ID,AD_Org_ID,IsActive,UpdatedBy,CreatedBy) VALUES ('N','T','The Process Receipts Window allows you to enter receipts for invoices. If the payment is for a single invoice then it can be processed here.','Y','N','N',0,0,'D','Receipts into Batch','Process Receipts',200031,106,'74b265cf-fb73-4715-b926-f2e6e485d992',TO_DATE('2013-01-23 18:12:25','YYYY-MM-DD HH24:MI:SS'),TO_DATE('2013-01-23 18:12:25','YYYY-MM-DD HH24:MI:SS'),0,0,'Y',100,100) +; + +-- Jan 23, 2013 6:12:26 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Window_Trl (AD_Language,AD_Window_ID, Help,Name,Description, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Window_Trl_UU ) SELECT l.AD_Language,t.AD_Window_ID, t.Help,t.Name,t.Description, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Window t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Window_ID=200031 AND NOT EXISTS (SELECT * FROM AD_Window_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Window_ID=t.AD_Window_ID) +; + +-- Jan 23, 2013 6:12:54 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Tab (ImportFields,Processing,IsSingleRow,AD_Window_ID,SeqNo,IsTranslationTab,IsSortTab,AD_Table_ID,HasTree,IsReadOnly,IsInfoTab,AD_Tab_UU,IsInsertRecord,IsAdvancedTab,TabLevel,EntityType,Name,AD_Tab_ID,AD_Client_ID,Updated,AD_Org_ID,Created,CreatedBy,UpdatedBy,IsActive) VALUES ('N','N','N',200031,10,'N','N',200056,'N','N','N','b2b0e8f8-0bbb-47b5-8dce-1accf43ad27c','Y','N',0,'D','Batch',200067,0,TO_DATE('2013-01-23 18:12:53','YYYY-MM-DD HH24:MI:SS'),0,TO_DATE('2013-01-23 18:12:53','YYYY-MM-DD HH24:MI:SS'),100,100,'Y') +; + +-- Jan 23, 2013 6:12:54 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Tab_Trl (AD_Language,AD_Tab_ID, Help,CommitWarning,Name,Description, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Tab_Trl_UU ) SELECT l.AD_Language,t.AD_Tab_ID, t.Help,t.CommitWarning,t.Name,t.Description, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Tab t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Tab_ID=200067 AND NOT EXISTS (SELECT * FROM AD_Tab_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Tab_ID=t.AD_Tab_ID) +; + +-- Jan 23, 2013 6:12:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,1,'N','N',208403,'Y',201692,'N','There are two methods of making records unavailable in the system: One is to delete the record, the other is to de-activate the record. A de-activated record is not available for selection, but available for reports. +There are two reasons for de-activating and not deleting records: +(1) The system requires the record for audit purposes. +(2) The record is referenced by other records. E.g., you cannot delete a Business Partner, if there are invoices for this partner record existing. You de-activate the Business Partner and prevent that this record is used for future entries.','D','The record is active in the system','Active','N','Y','9124887c-0d0c-4985-ab70-e135578d4f13',100,0,TO_DATE('2013-01-23 18:12:56','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:12:56','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:12:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201692 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:12:58 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,10,'N','N',208412,'Y',201693,'N','The Bank Account identifies an account at this Bank.','D','Account at the Bank','Bank Account','N','Y','b93077eb-579f-41d0-9e87-50a20d100a65',100,0,TO_DATE('2013-01-23 18:12:57','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:12:57','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:12:58 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201693 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:12:59 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,22,'N','N',208398,'Y',201694,'N','A Client is a company or a legal entity. You cannot share data between Clients. Tenant is a synonym for Client.','D','Client/Tenant for this installation.','Client','N','Y','d98af125-94ef-4da3-a4c7-6db0e3d27e7e',100,0,TO_DATE('2013-01-23 18:12:58','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:12:58','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:12:59 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201694 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:00 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,1,'N','N',208414,'Y',201695,'N','The Create From process will create a new document based on information in an existing document selected by the user.','D','Process which will generate a new document lines based on an existing document','Create lines from','N','Y','809b4770-3ac7-44ca-883a-403e3fcc99df',100,0,TO_DATE('2013-01-23 18:12:59','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:12:59','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:00 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201695 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:01 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,EntityType,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,14,'N','N',208417,'Y',201696,'N','D','Deposit Amount','N','Y','3d6714d8-e720-4aca-bde7-87a680611ac1',100,0,TO_DATE('2013-01-23 18:13:00','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:13:00','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:01 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201696 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:02 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,EntityType,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive,IsDisplayedGrid) VALUES ('N',200067,22,'N','N',208410,'Y',201697,'N','D','Deposit Batch','N','N','42e24a69-e7f9-4219-b121-5e5a53cf504e',100,0,TO_DATE('2013-01-23 18:13:01','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:13:01','YYYY-MM-DD HH24:MI:SS'),'Y','N') +; + +-- Jan 23, 2013 6:13:02 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201697 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:02 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,EntityType,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,7,'N','N',208415,'Y',201698,'N','D','Deposit Date','N','Y','5afd8215-cc8e-4c10-9191-9ece1df7e760',100,0,TO_DATE('2013-01-23 18:13:02','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:13:02','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:02 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201698 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:03 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,255,'N','N',208402,'Y',201699,'N','A description is limited to 255 characters.','D','Optional short description of the record','Description','N','Y','0836c263-cbd8-4051-98f4-3f389990d6d8',100,0,TO_DATE('2013-01-23 18:13:02','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:13:02','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:03 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201699 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:04 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,7,'N','N',208416,'Y',201700,'N','The Document Date indicates the date the document was generated. It may or may not be the same as the accounting date.','D','Date of the Document','Document Date','N','Y','ae0d05d5-8aa5-409b-a5e2-ddde334ecf06',100,0,TO_DATE('2013-01-23 18:13:03','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:13:03','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:04 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201700 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:05 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,30,'N','N',208419,'Y',201701,'N','The document number is usually automatically generated by the system and determined by the document type of the document. If the document is not saved, the preliminary number is displayed in "<>". + +If the document type of your document has no automatic document sequence defined, the field is empty if you create a new document. This is for documents which usually have an external number (like vendor invoice). If you leave the field empty, the system will generate a document number for you. The document sequence used for this fallback number is defined in the "Maintain Sequence" window with the name "DocumentNo_", where TableName is the actual name of the table (e.g. C_Order).','D','Document sequence number of the document','Document No','N','Y','a9e341f3-f2dd-4ab9-b9f2-d9eebb9745d0',100,0,TO_DATE('2013-01-23 18:13:04','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:13:04','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:05 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201701 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,2,'N','N',208418,'Y',201702,'N','The Document Status indicates the status of a document at this time. If you want to change the document status, use the Document Action field','D','The current status of the document','Document Status','N','Y','4432e795-042a-4a96-80ea-71603e6a4f5a',100,0,TO_DATE('2013-01-23 18:13:05','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:13:05','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201702 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:07 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,10,'N','N',208413,'Y',201703,'N','The Document Type determines document sequence and processing rules','D','Document type or rules','Document Type','N','Y','c14cdcd0-48a6-4f58-81e6-076117137cab',100,0,TO_DATE('2013-01-23 18:13:06','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:13:06','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:07 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201703 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,22,'N','N',208399,'Y',201704,'N','An organization is a unit of your client or legal entity - examples are store, department. You can share data between organizations.','D','Organizational entity within client','Organization','N','Y','41ed507f-b5e8-4b5f-a1a3-9492c34fbffc',100,0,TO_DATE('2013-01-23 18:13:07','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:13:07','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201704 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:09 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,EntityType,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,1,'N','N',208421,'Y',201705,'N','D','Process Now','N','Y','c2172400-027c-4496-a7fd-53a4e94691c3',100,0,TO_DATE('2013-01-23 18:13:08','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:13:08','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:09 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201705 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:10 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,1,'N','N',208420,'Y',201706,'N','The Processed checkbox indicates that a document has been processed.','D','The document has been processed','Processed','N','Y','d6034f0a-77cd-4e51-9f8e-e25d9496094b',100,0,TO_DATE('2013-01-23 18:13:09','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:13:09','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:10 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201706 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:11 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,EntityType,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,36,'N','N',208411,'Y',201707,'N','D','X_DepositBatch_UU','N','Y','097b9034-c40f-484a-89ac-a0ccae0d2363',100,0,TO_DATE('2013-01-23 18:13:10','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:13:10','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:11 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201707 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:14:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=0,IsDisplayed='N' WHERE AD_Field_ID=201702 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=0,IsDisplayed='N' WHERE AD_Field_ID=201707 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=10,IsDisplayed='Y' WHERE AD_Field_ID=201694 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=20,IsDisplayed='Y' WHERE AD_Field_ID=201704 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=30,IsDisplayed='Y' WHERE AD_Field_ID=201693 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=40,IsDisplayed='Y' WHERE AD_Field_ID=201698 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=50,IsDisplayed='Y' WHERE AD_Field_ID=201703 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=60,IsDisplayed='Y' WHERE AD_Field_ID=201701 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=70,IsDisplayed='Y' WHERE AD_Field_ID=201700 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=80,IsDisplayed='Y' WHERE AD_Field_ID=201699 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=90,IsDisplayed='Y' WHERE AD_Field_ID=201696 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=100,IsDisplayed='Y' WHERE AD_Field_ID=201695 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=110,IsDisplayed='Y' WHERE AD_Field_ID=201692 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=120,IsDisplayed='Y' WHERE AD_Field_ID=201705 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=130,IsDisplayed='Y' WHERE AD_Field_ID=201706 +; + +-- Jan 23, 2013 6:15:05 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=201702 +; + +-- Jan 23, 2013 6:15:05 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=201707 +; + +-- Jan 23, 2013 6:15:05 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=10,IsDisplayedGrid='Y' WHERE AD_Field_ID=201694 +; + +-- Jan 23, 2013 6:15:05 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=20,IsDisplayedGrid='Y' WHERE AD_Field_ID=201704 +; + +-- Jan 23, 2013 6:15:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=30,IsDisplayedGrid='Y' WHERE AD_Field_ID=201693 +; + +-- Jan 23, 2013 6:15:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=40,IsDisplayedGrid='Y' WHERE AD_Field_ID=201698 +; + +-- Jan 23, 2013 6:15:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=50,IsDisplayedGrid='Y' WHERE AD_Field_ID=201703 +; + +-- Jan 23, 2013 6:15:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=60,IsDisplayedGrid='Y' WHERE AD_Field_ID=201701 +; + +-- Jan 23, 2013 6:15:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=70,IsDisplayedGrid='Y' WHERE AD_Field_ID=201700 +; + +-- Jan 23, 2013 6:15:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=80,IsDisplayedGrid='Y' WHERE AD_Field_ID=201699 +; + +-- Jan 23, 2013 6:15:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=90,IsDisplayedGrid='Y' WHERE AD_Field_ID=201696 +; + +-- Jan 23, 2013 6:15:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=100,IsDisplayedGrid='Y' WHERE AD_Field_ID=201695 +; + +-- Jan 23, 2013 6:15:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=110,IsDisplayedGrid='Y' WHERE AD_Field_ID=201692 +; + +-- Jan 23, 2013 6:15:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=120,IsDisplayedGrid='Y' WHERE AD_Field_ID=201705 +; + +-- Jan 23, 2013 6:15:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=130,IsDisplayedGrid='Y' WHERE AD_Field_ID=201706 +; + +-- Jan 23, 2013 6:15:58 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET IsSameLine='Y', ColumnSpan=2,Updated=TO_DATE('2013-01-23 18:15:58','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201704 +; + +-- Jan 23, 2013 6:16:04 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET ColumnSpan=2,Updated=TO_DATE('2013-01-23 18:16:04','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201694 +; + +-- Jan 23, 2013 6:16:09 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET XPosition=4,Updated=TO_DATE('2013-01-23 18:16:09','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201704 +; + +-- Jan 23, 2013 6:16:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET ColumnSpan=2,Updated=TO_DATE('2013-01-23 18:16:23','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201693 +; + +-- Jan 23, 2013 6:16:40 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET IsSameLine='Y', XPosition=4, ColumnSpan=2,Updated=TO_DATE('2013-01-23 18:16:40','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201698 +; + +-- Jan 23, 2013 6:16:42 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET ColumnSpan=2,Updated=TO_DATE('2013-01-23 18:16:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201703 +; + +-- Jan 23, 2013 6:17:00 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET IsSameLine='Y', XPosition=4, ColumnSpan=2,Updated=TO_DATE('2013-01-23 18:17:00','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201701 +; + +-- Jan 23, 2013 6:17:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET ColumnSpan=2,Updated=TO_DATE('2013-01-23 18:17:06','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201700 +; + +-- Jan 23, 2013 6:17:12 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET ColumnSpan=5,Updated=TO_DATE('2013-01-23 18:17:12','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201699 +; + +-- Jan 23, 2013 6:17:15 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET ColumnSpan=2,Updated=TO_DATE('2013-01-23 18:17:15','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201696 +; + +-- Jan 23, 2013 6:17:39 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET IsSameLine='Y', XPosition=5, ColumnSpan=2,Updated=TO_DATE('2013-01-23 18:17:39','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201695 +; + +-- Jan 23, 2013 6:18:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET XPosition=2, ColumnSpan=2,Updated=TO_DATE('2013-01-23 18:18:08','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201692 +; + +-- Jan 23, 2013 6:18:49 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET IsSameLine='Y', DisplayLogic='@DepositAmt@!0', XPosition=5, ColumnSpan=2,Updated=TO_DATE('2013-01-23 18:18:49','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201705 +; + +-- Jan 23, 2013 6:19:02 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET IsReadOnly='Y', XPosition=2, ColumnSpan=2,Updated=TO_DATE('2013-01-23 18:19:02','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201706 +; + +-- Jan 23, 2013 6:19:11 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET IsReadOnly='Y',Updated=TO_DATE('2013-01-23 18:19:11','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201696 +; + +-- Jan 23, 2013 6:19:43 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Tab (ImportFields,Processing,IsSingleRow,AD_Window_ID,SeqNo,IsTranslationTab,IsSortTab,AD_Table_ID,HasTree,IsReadOnly,IsInfoTab,AD_Tab_UU,IsInsertRecord,IsAdvancedTab,TabLevel,EntityType,Name,AD_Tab_ID,ReadOnlyLogic,AD_Client_ID,Updated,AD_Org_ID,Created,CreatedBy,UpdatedBy,IsActive) VALUES ('N','N','N',200031,20,'N','N',200057,'N','N','N','3adbb99b-98d8-450f-83a0-87ebc00d2950','Y','N',1,'D','Lines',200068,'@Processed@=''Y''',0,TO_DATE('2013-01-23 18:19:42','YYYY-MM-DD HH24:MI:SS'),0,TO_DATE('2013-01-23 18:19:42','YYYY-MM-DD HH24:MI:SS'),100,100,'Y') +; + +-- Jan 23, 2013 6:19:43 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Tab_Trl (AD_Language,AD_Tab_ID, Help,CommitWarning,Name,Description, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Tab_Trl_UU ) SELECT l.AD_Language,t.AD_Tab_ID, t.Help,t.CommitWarning,t.Name,t.Description, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Tab t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Tab_ID=200068 AND NOT EXISTS (SELECT * FROM AD_Tab_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Tab_ID=t.AD_Tab_ID) +; + +-- Jan 23, 2013 6:19:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200068,1,'N','N',208427,'Y',201708,'N','There are two methods of making records unavailable in the system: One is to delete the record, the other is to de-activate the record. A de-activated record is not available for selection, but available for reports. +There are two reasons for de-activating and not deleting records: +(1) The system requires the record for audit purposes. +(2) The record is referenced by other records. E.g., you cannot delete a Business Partner, if there are invoices for this partner record existing. You de-activate the Business Partner and prevent that this record is used for future entries.','D','The record is active in the system','Active','N','Y','e9fa326b-c53b-4428-a7a3-fd98f9dd68c5',100,0,TO_DATE('2013-01-23 18:19:44','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:19:44','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:19:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201708 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:19:46 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200068,22,'N','N',208422,'Y',201709,'N','A Client is a company or a legal entity. You cannot share data between Clients. Tenant is a synonym for Client.','D','Client/Tenant for this installation.','Client','N','Y','2205a77d-7491-4ae8-8bcb-e2c601d37d4c',100,0,TO_DATE('2013-01-23 18:19:45','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:19:45','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:19:46 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201709 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:19:47 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,EntityType,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200068,10,'N','N',208441,'Y',201710,'N','D','Deposit Batch','N','Y','0c853d59-6d17-4653-b036-ec3a51478185',100,0,TO_DATE('2013-01-23 18:19:46','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:19:46','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:19:47 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201710 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:19:51 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,EntityType,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive,IsDisplayedGrid) VALUES ('N',200068,22,'N','N',208434,'Y',201711,'N','D','Deposit Batch Line','N','N','97d87d68-da47-4d84-9fb7-998fb0757a1b',100,0,TO_DATE('2013-01-23 18:19:47','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:19:47','YYYY-MM-DD HH24:MI:SS'),'Y','N') +; + +-- Jan 23, 2013 6:19:51 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201711 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:19:52 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200068,14,'N','N',208438,'Y',201712,'N','Indicates the unique line for a document. It will also control the display order of the lines within a document.','D','Unique line for this document','Line No','N','Y','8d47a707-97e7-49ef-8db3-3b19a6864f32',100,0,TO_DATE('2013-01-23 18:19:51','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:19:51','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:19:52 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201712 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:19:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200068,22,'N','N',208423,'Y',201713,'N','An organization is a unit of your client or legal entity - examples are store, department. You can share data between organizations.','D','Organizational entity within client','Organization','N','Y','f92541af-e885-426c-af88-c75cf30314fe',100,0,TO_DATE('2013-01-23 18:19:52','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:19:52','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:19:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201713 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:19:54 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200068,10,'N','N',208437,'Y',201714,'N','The Payment is a unique identifier of this payment.','D','Payment identifier','Payment','N','Y','3951ce27-652a-4a11-b1e5-a4d47c56a860',100,0,TO_DATE('2013-01-23 18:19:53','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:19:53','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:19:54 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201714 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:19:55 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200068,14,'N','N',208436,'Y',201715,'N','Indicates the amount this payment is for. The payment amount can be for single or multiple invoices or a partial payment for an invoice.','D','Amount being paid','Payment amount','N','Y','1bba36a4-c629-4d77-9f81-b5483df0997b',100,0,TO_DATE('2013-01-23 18:19:54','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:19:54','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:19:55 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201715 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:19:56 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,EntityType,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200068,1,'N','N',208440,'Y',201716,'N','D','Process Now','N','Y','104eefdd-cc7b-46c6-bb19-18b04b13aff5',100,0,TO_DATE('2013-01-23 18:19:55','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:19:55','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:19:56 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201716 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:19:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200068,1,'N','N',208439,'Y',201717,'N','The Processed checkbox indicates that a document has been processed.','D','The document has been processed','Processed','N','Y','564ec798-4a21-4148-9ec3-1a787b5d33bd',100,0,TO_DATE('2013-01-23 18:19:56','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:19:56','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:19:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201717 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:19:58 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,EntityType,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200068,36,'N','N',208435,'Y',201718,'N','D','X_DepositBatchLine_UU','N','Y','3a4a08ce-5c9e-4eea-9860-a4d121eaa3d3',100,0,TO_DATE('2013-01-23 18:19:57','YYYY-MM-DD HH24:MI:SS'),0,100,TO_DATE('2013-01-23 18:19:57','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:19:58 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201718 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:20:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=0,IsDisplayed='N' WHERE AD_Field_ID=201716 +; + +-- Jan 23, 2013 6:20:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=0,IsDisplayed='N' WHERE AD_Field_ID=201718 +; + +-- Jan 23, 2013 6:20:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=10,IsDisplayed='Y' WHERE AD_Field_ID=201709 +; + +-- Jan 23, 2013 6:20:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=20,IsDisplayed='Y' WHERE AD_Field_ID=201713 +; + +-- Jan 23, 2013 6:20:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=30,IsDisplayed='Y' WHERE AD_Field_ID=201710 +; + +-- Jan 23, 2013 6:20:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=40,IsDisplayed='Y' WHERE AD_Field_ID=201712 +; + +-- Jan 23, 2013 6:20:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=50,IsDisplayed='Y' WHERE AD_Field_ID=201714 +; + +-- Jan 23, 2013 6:20:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=60,IsDisplayed='Y' WHERE AD_Field_ID=201715 +; + +-- Jan 23, 2013 6:20:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=70,IsDisplayed='Y' WHERE AD_Field_ID=201708 +; + +-- Jan 23, 2013 6:20:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=80,IsDisplayed='Y' WHERE AD_Field_ID=201717 +; + +-- Jan 23, 2013 6:20:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=201716 +; + +-- Jan 23, 2013 6:20:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=201718 +; + +-- Jan 23, 2013 6:20:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=10,IsDisplayedGrid='Y' WHERE AD_Field_ID=201709 +; + +-- Jan 23, 2013 6:20:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=20,IsDisplayedGrid='Y' WHERE AD_Field_ID=201713 +; + +-- Jan 23, 2013 6:20:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=30,IsDisplayedGrid='Y' WHERE AD_Field_ID=201710 +; + +-- Jan 23, 2013 6:20:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=40,IsDisplayedGrid='Y' WHERE AD_Field_ID=201712 +; + +-- Jan 23, 2013 6:20:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=50,IsDisplayedGrid='Y' WHERE AD_Field_ID=201714 +; + +-- Jan 23, 2013 6:20:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=60,IsDisplayedGrid='Y' WHERE AD_Field_ID=201715 +; + +-- Jan 23, 2013 6:20:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=70,IsDisplayedGrid='Y' WHERE AD_Field_ID=201708 +; + +-- Jan 23, 2013 6:20:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=80,IsDisplayedGrid='Y' WHERE AD_Field_ID=201717 +; + +-- Jan 23, 2013 6:21:03 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET ColumnSpan=2,Updated=TO_DATE('2013-01-23 18:21:03','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201709 +; + +-- Jan 23, 2013 6:21:22 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET IsSameLine='Y', XPosition=4, ColumnSpan=2,Updated=TO_DATE('2013-01-23 18:21:22','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201713 +; + +-- Jan 23, 2013 6:21:29 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET ColumnSpan=2,Updated=TO_DATE('2013-01-23 18:21:29','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201710 +; + +-- Jan 23, 2013 6:21:40 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET ColumnSpan=2,Updated=TO_DATE('2013-01-23 18:21:40','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201712 +; + +-- Jan 23, 2013 6:21:49 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET ColumnSpan=2,Updated=TO_DATE('2013-01-23 18:21:49','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201714 +; + +-- Jan 23, 2013 6:22:07 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET IsSameLine='Y', IsReadOnly='Y', XPosition=4, ColumnSpan=2,Updated=TO_DATE('2013-01-23 18:22:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201715 +; + +-- Jan 23, 2013 6:22:21 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET XPosition=2, ColumnSpan=2,Updated=TO_DATE('2013-01-23 18:22:21','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201708 +; + +-- Jan 23, 2013 6:22:35 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET IsSameLine='Y', IsReadOnly='Y', XPosition=5, ColumnSpan=2,Updated=TO_DATE('2013-01-23 18:22:35','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201717 +; + +-- Jan 23, 2013 6:23:56 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Menu (AD_Window_ID,AD_Menu_ID,IsSummary,IsSOTrx,IsReadOnly,EntityType,AD_Menu_UU,IsCentrallyMaintained,Name,Action,IsActive,AD_Client_ID,CreatedBy,Updated,AD_Org_ID,Created,UpdatedBy) VALUES (200031,200035,'N','N','N','D','e84239a8-560a-4f7c-ba32-fb2e70f1c616','Y','Receipts Into Batch','W','Y',0,100,TO_DATE('2013-01-23 18:23:55','YYYY-MM-DD HH24:MI:SS'),0,TO_DATE('2013-01-23 18:23:55','YYYY-MM-DD HH24:MI:SS'),100) +; + +-- Jan 23, 2013 6:23:56 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Menu_Trl (AD_Language,AD_Menu_ID, Name,Description, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Menu_Trl_UU ) SELECT l.AD_Language,t.AD_Menu_ID, t.Name,t.Description, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Menu t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Menu_ID=200035 AND NOT EXISTS (SELECT * FROM AD_Menu_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Menu_ID=t.AD_Menu_ID) +; + +-- Jan 23, 2013 6:23:56 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_TreeNodeMM (AD_Client_ID,AD_Org_ID, IsActive,Created,CreatedBy,Updated,UpdatedBy, AD_Tree_ID, Node_ID, Parent_ID, SeqNo, AD_TreeNodeMM_UU) SELECT t.AD_Client_ID, 0, 'Y', SysDate, 100, SysDate, 100,t.AD_Tree_ID, 200035, 0, 999, Generate_UUID() FROM AD_Tree t WHERE t.AD_Client_ID=0 AND t.IsActive='Y' AND t.IsAllNodes='Y' AND t.TreeType='MM' AND NOT EXISTS (SELECT * FROM AD_TreeNodeMM e WHERE e.AD_Tree_ID=t.AD_Tree_ID AND Node_ID=200035) +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=0, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=200035 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=1, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=241 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=2, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=288 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=3, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=432 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=4, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=243 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=5, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=413 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=6, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=538 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=7, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=462 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=8, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=505 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=9, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=200023 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=10, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=235 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=11, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=511 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=12, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=245 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=13, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=251 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=14, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=246 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=15, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=509 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=16, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=510 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=17, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=496 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=18, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=497 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=19, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=304 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=20, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=255 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=21, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=286 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=22, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=287 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=23, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=438 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=24, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=234 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=25, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=244 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=26, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53313 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=27, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53314 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=28, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53190 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=29, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53187 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=0, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=200035 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=1, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=241 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=2, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=288 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=3, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=432 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=4, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=243 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=5, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=413 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=6, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=538 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=7, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=462 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=8, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=505 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=9, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=200023 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=10, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=235 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=11, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=511 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=12, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=245 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=13, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=251 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=14, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=246 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=15, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=509 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=16, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=510 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=17, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=496 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=18, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=497 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=19, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=304 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=20, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=255 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=21, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=286 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=22, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=287 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=23, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=438 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=24, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=200035 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=25, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=234 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=26, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=244 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=27, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53313 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=28, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53314 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=29, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53190 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=30, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53187 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=0, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=241 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=1, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=288 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=2, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=432 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=3, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=243 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=4, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=413 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=5, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=538 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=6, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=462 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=7, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=505 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=8, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=200023 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=9, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=235 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=10, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=511 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=11, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=245 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=12, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=251 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=13, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=246 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=14, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=509 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=15, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=510 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=16, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=496 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=17, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=497 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=18, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=304 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=19, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=255 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=20, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=286 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=21, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=287 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=22, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=438 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=23, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=200035 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=24, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=234 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=25, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=200035 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=26, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=244 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=27, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53313 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=28, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53314 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=29, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53190 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=30, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53187 +; + +SELECT register_migration_script('201301251920_TICKET-1001569.sql') FROM dual +; \ No newline at end of file diff --git a/migration/i1.0a-release/postgresql/201301251920_TICKET-1001569.sql b/migration/i1.0a-release/postgresql/201301251920_TICKET-1001569.sql new file mode 100644 index 0000000000..1d94e42857 --- /dev/null +++ b/migration/i1.0a-release/postgresql/201301251920_TICKET-1001569.sql @@ -0,0 +1,2140 @@ +-- Jan 23, 2013 5:43:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Table (ImportTable,CopyColumnsFromTable,IsSecurityEnabled,AccessLevel,LoadSeq,AD_Table_ID,IsHighVolume,IsView,IsChangeLog,EntityType,ReplicationType,AD_Table_UU,IsCentrallyMaintained,IsDeleteable,TableName,Name,AD_Client_ID,IsActive,AD_Org_ID,Updated,CreatedBy,UpdatedBy,Created) VALUES ('N','N','N','3',0,200056,'N','N','N','D','L','4428e636-52c0-40c7-bfa3-d637dbac1642','Y','Y','X_DepositBatch','Receipts into Batch',0,'Y',0,TO_TIMESTAMP('2013-01-23 17:43:11','YYYY-MM-DD HH24:MI:SS'),100,100,TO_TIMESTAMP('2013-01-23 17:43:11','YYYY-MM-DD HH24:MI:SS')) +; + +-- Jan 23, 2013 5:43:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Table_Trl (AD_Language,AD_Table_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Table_Trl_UU ) SELECT l.AD_Language,t.AD_Table_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Table t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Table_ID=200056 AND NOT EXISTS (SELECT * FROM AD_Table_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Table_ID=t.AD_Table_ID) +; + +-- Jan 23, 2013 5:43:15 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Sequence (UpdatedBy,StartNewYear,CurrentNextSys,IsTableID,CurrentNext,IsAudited,IsAutoSequence,AD_Sequence_ID,AD_Sequence_UU,Description,Name,IncrementNo,AD_Org_ID,AD_Client_ID,Created,CreatedBy,Updated,IsActive,StartNo) VALUES (100,'N',200000,'Y',1000000,'N','Y',200051,'225ea2ca-af9e-484e-a64c-a7348c3dd01b','Table X_DepositBatch','X_DepositBatch',1,0,0,TO_TIMESTAMP('2013-01-23 17:43:14','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2013-01-23 17:43:14','YYYY-MM-DD HH24:MI:SS'),'Y',1000000) +; + +-- Jan 23, 2013 5:44:15 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,DefaultValue,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200056,208398,'D','Y','N','N','N',22,'N',19,'N',102,'N','Y','2d8664be-6fe2-4101-96c1-430ab0239fb1','N','AD_Client_ID','Client/Tenant for this installation.','@#AD_Client_ID@','A Client is a company or a legal entity. You cannot share data between Clients. Tenant is a synonym for Client.','Client','N',100,TO_TIMESTAMP('2013-01-23 17:44:13','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:44:13','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:44:15 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208398 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:16 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,AD_Val_Rule_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,DefaultValue,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200056,208399,'D','Y','N','N','N',22,'N',19,104,'N',113,'N','Y','0b04414e-898c-443d-920a-861390037ce4','N','AD_Org_ID','Organizational entity within client','@#AD_Org_ID@','An organization is a unit of your client or legal entity - examples are store, department. You can share data between organizations.','Organization','N',100,TO_TIMESTAMP('2013-01-23 17:44:15','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:44:15','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:44:16 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208399 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:17 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200056,208400,'D','Y','N','N','N',7,'N',16,'N',245,'N','Y','8f0513e9-b931-446f-bd38-1fed5bd4b98a','N','Created','Date this record was created','The Created field indicates the date that this record was created.','Created','N',100,TO_TIMESTAMP('2013-01-23 17:44:16','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:44:16','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:44:17 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208400 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:18 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,AD_Reference_Value_ID,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200056,208401,'D',110,'Y','N','N','N',22,'N',18,'N',246,'N','Y','74751997-d9b9-459f-a187-58b087f2a241','N','CreatedBy','User who created this records','The Created By field indicates the user who created this record.','Created By','N',100,TO_TIMESTAMP('2013-01-23 17:44:17','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:44:17','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:44:18 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208401 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:19 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200056,208402,'D','N','N','N','N',255,'Y',10,'N',275,'N','Y','ba56e79b-9cf3-4a2d-9626-c2cf9c6cd4be','Y','Description','Optional short description of the record','A description is limited to 255 characters.','Description','Y',100,TO_TIMESTAMP('2013-01-23 17:44:18','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:44:18','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:44:19 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208402 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:20 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,DefaultValue,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200056,208403,'D','Y','N','N','N',1,'N',20,'N',348,'N','Y','78523715-b9b6-4fcf-b7dd-8519a6b2c4dd','Y','IsActive','The record is active in the system','Y','There are two methods of making records unavailable in the system: One is to delete the record, the other is to de-activate the record. A de-activated record is not available for selection, but available for reports. +There are two reasons for de-activating and not deleting records: +(1) The system requires the record for audit purposes. +(2) The record is referenced by other records. E.g., you cannot delete a Business Partner, if there are invoices for this partner record existing. You de-activate the Business Partner and prevent that this record is used for future entries.','Active','N',100,TO_TIMESTAMP('2013-01-23 17:44:19','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:44:19','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:44:20 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208403 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:21 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,DefaultValue,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208404,'D','Y','N','N',0,'N',1,'N',20,'N',1103,'N','Y','129a7fa8-8182-449d-ade5-415a085018d9','Y','IsDefault','Default value','N','The Default Checkbox indicates if this record will be used as a default value.','Default','Y',100,TO_TIMESTAMP('2013-01-23 17:44:20','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:44:20','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:44:21 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208404 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:22 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200056,208405,'D','Y','N','Y',1,'N',60,'Y',10,'N',469,'N','Y','12270b16-e9dd-4d72-9196-11394805615d','Y','Name','Alphanumeric identifier of the entity','The name of an entity (record) is used as an default search option in addition to the search key. The name is up to 60 characters in length.','Name','Y',100,TO_TIMESTAMP('2013-01-23 17:44:21','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:44:21','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:44:22 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208405 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:22 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200056,208406,'D','Y','N','N','N',7,'N',16,'N',607,'N','Y','bd1af2c5-5a73-42a1-8d07-6ad158db107a','N','Updated','Date this record was updated','The Updated field indicates the date that this record was updated.','Updated','N',100,TO_TIMESTAMP('2013-01-23 17:44:22','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:44:22','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:44:22 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208406 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,AD_Reference_Value_ID,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200056,208407,'D',110,'Y','N','N','N',22,'N',18,'N',608,'N','Y','2af94666-4c6c-442a-a4c0-420af1dd36f8','N','UpdatedBy','User who updated this records','The Updated By field indicates the user who updated this record.','Updated By','N',100,TO_TIMESTAMP('2013-01-23 17:44:23','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:44:23','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:44:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208407 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:24 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208408,'D','Y','N','N',0,'N',40,'N',10,'N',620,'N','Y','4a595470-7566-47f5-ae36-aa02f2f44233','Y','Value','Search key for the record in the format required - must be unique','A search key allows you a fast method of finding a particular record. +If you leave the search key empty, the system automatically creates a numeric number. The document sequence used for this fallback number is defined in the "Maintain Sequence" window with the name "DocumentNo_", where TableName is the actual name of the table (e.g. C_Order).','Search Key','Y',100,TO_TIMESTAMP('2013-01-23 17:44:23','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:44:23','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:44:24 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208408 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:25 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208409,'D','Y','N','N',0,'Y',10,'N',19,'N',200601,'N','Y','8f84791b-c852-4281-83d9-ddd42eef708a','N','X_Shipper_ID','Shipper','Y',100,TO_TIMESTAMP('2013-01-23 17:44:24','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:44:24','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:44:25 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208409 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:26 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element (ColumnName,AD_Element_ID,EntityType,Name,PrintName,AD_Element_UU,AD_Client_ID,Created,Updated,AD_Org_ID,CreatedBy,UpdatedBy,IsActive) VALUES ('X_DepositBatch_ID',202195,'D','Receipts into Batch','Receipts into Batch','bfada75f-e83d-4726-8cf3-edf1c771f2cf',0,TO_TIMESTAMP('2013-01-23 17:44:25','YYYY-MM-DD HH24:MI:SS'),TO_TIMESTAMP('2013-01-23 17:44:25','YYYY-MM-DD HH24:MI:SS'),0,100,100,'Y') +; + +-- Jan 23, 2013 5:44:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element_Trl (AD_Language,AD_Element_ID, Help,PO_Description,PO_Help,Description,Name,PrintName,PO_Name,PO_PrintName, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Element_Trl_UU ) SELECT l.AD_Language,t.AD_Element_ID, t.Help,t.PO_Description,t.PO_Help,t.Description,t.Name,t.PrintName,t.PO_Name,t.PO_PrintName, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Element t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Element_ID=202195 AND NOT EXISTS (SELECT * FROM AD_Element_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Element_ID=t.AD_Element_ID) +; + +-- Jan 23, 2013 5:44:28 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200056,208410,'D','Y','N','N','N',22,'N',13,'Y',202195,'N','Y','7cc2a164-9cb2-4e1e-890b-7b593750299b','N','X_DepositBatch_ID','Receipts into Batch','N',100,TO_TIMESTAMP('2013-01-23 17:44:25','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:44:25','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:44:28 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208410 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:44:29 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element (ColumnName,AD_Element_ID,EntityType,Name,PrintName,AD_Element_UU,AD_Client_ID,Created,Updated,AD_Org_ID,CreatedBy,UpdatedBy,IsActive) VALUES ('X_DepositBatch_UU',202196,'D','X_DepositBatch_UU','X_DepositBatch_UU','683ea13b-9f88-4947-a2ce-237ed9c0ad89',0,TO_TIMESTAMP('2013-01-23 17:44:28','YYYY-MM-DD HH24:MI:SS'),TO_TIMESTAMP('2013-01-23 17:44:28','YYYY-MM-DD HH24:MI:SS'),0,100,100,'Y') +; + +-- Jan 23, 2013 5:44:29 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element_Trl (AD_Language,AD_Element_ID, Help,PO_Description,PO_Help,Description,Name,PrintName,PO_Name,PO_PrintName, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Element_Trl_UU ) SELECT l.AD_Language,t.AD_Element_ID, t.Help,t.PO_Description,t.PO_Help,t.Description,t.Name,t.PrintName,t.PO_Name,t.PO_PrintName, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Element t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Element_ID=202196 AND NOT EXISTS (SELECT * FROM AD_Element_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Element_ID=t.AD_Element_ID) +; + +-- Jan 23, 2013 5:44:30 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1.00,'N','N',200056,208411,'D','N','N','N','N',36,'N',10,'N',202196,'N','Y','30e43343-a737-44e5-b281-7ed55be45974','Y','X_DepositBatch_UU','X_DepositBatch_UU','N',100,TO_TIMESTAMP('2013-01-23 17:44:28','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:44:28','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:44:30 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208411 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:45:00 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column_Trl WHERE AD_Column_ID=208404 +; + +-- Jan 23, 2013 5:45:01 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column WHERE AD_Column_ID=208404 +; + +-- Jan 23, 2013 5:45:04 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column_Trl WHERE AD_Column_ID=208405 +; + +-- Jan 23, 2013 5:45:04 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column WHERE AD_Column_ID=208405 +; + +-- Jan 23, 2013 5:45:04 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column_Trl WHERE AD_Column_ID=208408 +; + +-- Jan 23, 2013 5:45:04 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column WHERE AD_Column_ID=208408 +; + +-- Jan 23, 2013 5:45:04 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column_Trl WHERE AD_Column_ID=208409 +; + +-- Jan 23, 2013 5:45:04 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column WHERE AD_Column_ID=208409 +; + +-- Jan 23, 2013 5:45:35 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208412,'D','Y','N','N',0,'N',10,'N',19,'N',836,'N','Y','6a2370a3-09f8-4d30-81cf-baa821f3bac9','Y','C_BankAccount_ID','Account at the Bank','The Bank Account identifies an account at this Bank.','Bank Account','Y',100,TO_TIMESTAMP('2013-01-23 17:45:34','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:45:34','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:45:35 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208412 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:46:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208413,'D','Y','N','N',0,'N',10,'N',19,'N',196,'N','Y','14dfbc52-7dcc-40c3-ae5e-ef0bab3512f9','Y','C_DocType_ID','Document type or rules','The Document Type determines document sequence and processing rules','Document Type','Y',100,TO_TIMESTAMP('2013-01-23 17:46:05','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:46:05','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:46:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208413 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:47:05 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208414,'D','N','N','N',0,'N',1,'N',28,'N',1490,'N','Y','e55e3f8d-28d7-43cb-b369-077017e6b823','Y','CreateFrom','Process which will generate a new document lines based on an existing document','The Create From process will create a new document based on information in an existing document selected by the user.','Create lines from','Y',100,TO_TIMESTAMP('2013-01-23 17:47:04','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:47:04','YYYY-MM-DD HH24:MI:SS'),100,0,0,'Y','N') +; + +-- Jan 23, 2013 5:47:05 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208414 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:48:01 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element (ColumnName,AD_Element_ID,EntityType,Name,PrintName,AD_Element_UU,AD_Client_ID,Created,Updated,AD_Org_ID,CreatedBy,UpdatedBy,IsActive) VALUES ('DateDeposit',202197,'D','Deposit Date','Deposit Date','d11ff847-d57c-4f51-92e9-c7bed69071cc',0,TO_TIMESTAMP('2013-01-23 17:48:00','YYYY-MM-DD HH24:MI:SS'),TO_TIMESTAMP('2013-01-23 17:48:00','YYYY-MM-DD HH24:MI:SS'),0,100,100,'Y') +; + +-- Jan 23, 2013 5:48:01 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element_Trl (AD_Language,AD_Element_ID, Help,PO_Description,PO_Help,Description,Name,PrintName,PO_Name,PO_PrintName, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Element_Trl_UU ) SELECT l.AD_Language,t.AD_Element_ID, t.Help,t.PO_Description,t.PO_Help,t.Description,t.Name,t.PrintName,t.PO_Name,t.PO_PrintName, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Element t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Element_ID=202197 AND NOT EXISTS (SELECT * FROM AD_Element_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Element_ID=t.AD_Element_ID) +; + +-- Jan 23, 2013 5:48:24 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,DefaultValue,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208415,'D','Y','N','Y',0,'N',7,'N',15,'N',202197,'N','Y','b17960ea-1616-47eb-8971-9d5e980f44f4','Y','DateDeposit','@#Date@','Deposit Date','Y',100,TO_TIMESTAMP('2013-01-23 17:48:23','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:48:23','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:48:24 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208415 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:49:20 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,DefaultValue,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208416,'D','Y','N','N',0,'N',7,'N',15,'N',265,'N','Y','5fc53d1e-3942-44dc-b70d-614efcb82de9','Y','DateDoc','Date of the Document','@#Date@','The Document Date indicates the date the document was generated. It may or may not be the same as the accounting date.','Document Date','Y',100,TO_TIMESTAMP('2013-01-23 17:49:19','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:49:19','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:49:20 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208416 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:49:50 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element (ColumnName,AD_Element_ID,EntityType,Name,PrintName,AD_Element_UU,AD_Client_ID,Created,Updated,AD_Org_ID,CreatedBy,UpdatedBy,IsActive) VALUES ('DepositAmt',202198,'D','Deposit Amount','Deposit Amount','1c52e614-ae8e-4767-aab1-f6ffe26eadee',0,TO_TIMESTAMP('2013-01-23 17:49:49','YYYY-MM-DD HH24:MI:SS'),TO_TIMESTAMP('2013-01-23 17:49:49','YYYY-MM-DD HH24:MI:SS'),0,100,100,'Y') +; + +-- Jan 23, 2013 5:49:50 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element_Trl (AD_Language,AD_Element_ID, Help,PO_Description,PO_Help,Description,Name,PrintName,PO_Name,PO_PrintName, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Element_Trl_UU ) SELECT l.AD_Language,t.AD_Element_ID, t.Help,t.PO_Description,t.PO_Help,t.Description,t.Name,t.PrintName,t.PO_Name,t.PO_PrintName, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Element t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Element_ID=202198 AND NOT EXISTS (SELECT * FROM AD_Element_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Element_ID=t.AD_Element_ID) +; + +-- Jan 23, 2013 5:50:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208417,'D','Y','N','N',0,'N',14,'N',12,'N',202198,'N','Y','6b6f91e3-10ef-4e42-9131-5053e50bd53f','Y','DepositAmt','Deposit Amount','Y',100,TO_TIMESTAMP('2013-01-23 17:50:45','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:50:45','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:50:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208417 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:51:33 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,AD_Reference_Value_ID,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,DefaultValue,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208418,'D',131,'Y','N','N',0,'N',2,'N',17,'N',289,'N','Y','93912515-ea34-4fcd-b2e3-72eaf5104da7','Y','DocStatus','The current status of the document','DR','The Document Status indicates the status of a document at this time. If you want to change the document status, use the Document Action field','Document Status','Y',100,TO_TIMESTAMP('2013-01-23 17:51:32','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:51:32','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:51:33 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208418 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:52:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208419,'D','Y','N','Y',1,'N',30,'N',10,'N',290,'N','Y','98986539-7553-48d2-a01c-dce62a2e707a','Y','DocumentNo','Document sequence number of the document','The document number is usually automatically generated by the system and determined by the document type of the document. If the document is not saved, the preliminary number is displayed in "<>". + +If the document type of your document has no automatic document sequence defined, the field is empty if you create a new document. This is for documents which usually have an external number (like vendor invoice). If you leave the field empty, the system will generate a document number for you. The document sequence used for this fallback number is defined in the "Maintain Sequence" window with the name "DocumentNo_", where TableName is the actual name of the table (e.g. C_Order).','Document No','Y',100,TO_TIMESTAMP('2013-01-23 17:52:12','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:52:12','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:52:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208419 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:52:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208420,'D','Y','N','N',0,'N',1,'N',20,'N',1047,'N','Y','ddb5f7e8-383b-49da-8eec-173a825209fd','Y','Processed','The document has been processed','The Processed checkbox indicates that a document has been processed.','Processed','Y',100,TO_TIMESTAMP('2013-01-23 17:52:52','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:52:52','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:52:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208420 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:54:12 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Process (CopyFromProcess,AD_Process_ID,IsDirectPrint,IsReport,AD_Process_UU,AccessLevel,IsBetaFunctionality,IsServerProcess,Statistic_Seconds,Statistic_Count,ShowHelp,EntityType,Classname,Name,Value,AD_Org_ID,AD_Client_ID,Created,Updated,UpdatedBy,IsActive,CreatedBy) VALUES ('N',200031,'N','N','204960ea-1515-48ad-be88-93bdd8100f01','3','N','N',0,0,'Y','D','org.adempiere.process.DepositBatchClose','Deposit Batch Close','X_DepositBatch Close',0,0,TO_TIMESTAMP('2013-01-23 17:54:11','YYYY-MM-DD HH24:MI:SS'),TO_TIMESTAMP('2013-01-23 17:54:11','YYYY-MM-DD HH24:MI:SS'),100,'Y',100) +; + +-- Jan 23, 2013 5:54:12 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Process_Trl (AD_Language,AD_Process_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Process_Trl_UU ) SELECT l.AD_Language,t.AD_Process_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Process t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Process_ID=200031 AND NOT EXISTS (SELECT * FROM AD_Process_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Process_ID=t.AD_Process_ID) +; + +-- Jan 23, 2013 5:54:25 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,AD_Process_ID,ReadOnlyLogic,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200056,208421,'D','N','N','N',0,'N',1,'N',28,'N',524,200031,'@Processed@=''Y''','N','Y','0625f0a4-093d-4909-87c5-3a36f860b1c3','Y','Processing','Process Now','Y',100,TO_TIMESTAMP('2013-01-23 17:54:24','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:54:24','YYYY-MM-DD HH24:MI:SS'),100,0,0,'Y','N') +; + +-- Jan 23, 2013 5:54:25 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208421 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:54:52 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +CREATE TABLE X_DepositBatch (AD_Client_ID NUMERIC(10) NOT NULL, AD_Org_ID NUMERIC(10) NOT NULL, C_BankAccount_ID NUMERIC(10) NOT NULL, C_DocType_ID NUMERIC(10) NOT NULL, Created TIMESTAMP NOT NULL, CreatedBy NUMERIC(10) NOT NULL, CreateFrom CHAR(1) DEFAULT NULL , DateDeposit TIMESTAMP NOT NULL, DateDoc TIMESTAMP NOT NULL, DepositAmt NUMERIC NOT NULL, Description VARCHAR(255) DEFAULT NULL , DocStatus VARCHAR(2) DEFAULT 'DR' NOT NULL, DocumentNo VARCHAR(30) NOT NULL, IsActive CHAR(1) DEFAULT 'Y' CHECK (IsActive IN ('Y','N')) NOT NULL, Processed CHAR(1) CHECK (Processed IN ('Y','N')) NOT NULL, Processing CHAR(1) DEFAULT NULL , Updated TIMESTAMP NOT NULL, UpdatedBy NUMERIC(10) NOT NULL, X_DepositBatch_ID NUMERIC(10) NOT NULL, X_DepositBatch_UU VARCHAR(36) DEFAULT NULL , CONSTRAINT X_DepositBatch_Key PRIMARY KEY (X_DepositBatch_ID)) +; + +-- Jan 23, 2013 5:55:56 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Table (ImportTable,CopyColumnsFromTable,IsSecurityEnabled,AccessLevel,LoadSeq,AD_Table_ID,IsHighVolume,IsView,IsChangeLog,EntityType,ReplicationType,AD_Table_UU,IsCentrallyMaintained,IsDeleteable,TableName,Name,AD_Client_ID,IsActive,AD_Org_ID,Updated,CreatedBy,UpdatedBy,Created) VALUES ('N','N','N','3',0,200057,'N','N','N','D','L','21bd7d26-d60b-4e9a-bcd2-85b95c162aa7','Y','Y','X_DepositBatchLine','Deposit Batch Line',0,'Y',0,TO_TIMESTAMP('2013-01-23 17:55:55','YYYY-MM-DD HH24:MI:SS'),100,100,TO_TIMESTAMP('2013-01-23 17:55:55','YYYY-MM-DD HH24:MI:SS')) +; + +-- Jan 23, 2013 5:55:56 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Table_Trl (AD_Language,AD_Table_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Table_Trl_UU ) SELECT l.AD_Language,t.AD_Table_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Table t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Table_ID=200057 AND NOT EXISTS (SELECT * FROM AD_Table_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Table_ID=t.AD_Table_ID) +; + +-- Jan 23, 2013 5:55:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Sequence (UpdatedBy,StartNewYear,CurrentNextSys,IsTableID,CurrentNext,IsAudited,IsAutoSequence,AD_Sequence_ID,AD_Sequence_UU,Description,Name,IncrementNo,AD_Org_ID,AD_Client_ID,Created,CreatedBy,Updated,IsActive,StartNo) VALUES (100,'N',200000,'Y',1000000,'N','Y',200052,'2d30472a-cb6b-4631-b037-a18997bc61b9','Table X_DepositBatchLine','X_DepositBatchLine',1,0,0,TO_TIMESTAMP('2013-01-23 17:55:56','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2013-01-23 17:55:56','YYYY-MM-DD HH24:MI:SS'),'Y',1000000) +; + +-- Jan 23, 2013 5:56:25 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Table SET Name='Receipts into Batch Line',Updated=TO_TIMESTAMP('2013-01-23 17:56:25','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Table_ID=200057 +; + +-- Jan 23, 2013 5:56:25 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Table_Trl SET IsTranslated='N' WHERE AD_Table_ID=200057 +; + +-- Jan 23, 2013 5:56:35 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,DefaultValue,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200057,208422,'D','Y','N','N','N',22,'N',19,'N',102,'N','Y','7a4c6365-d057-4041-bf7d-4d65aaae2cc3','N','AD_Client_ID','Client/Tenant for this installation.','@#AD_Client_ID@','A Client is a company or a legal entity. You cannot share data between Clients. Tenant is a synonym for Client.','Client','N',100,TO_TIMESTAMP('2013-01-23 17:56:34','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:56:34','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:56:35 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208422 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:36 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,AD_Val_Rule_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,DefaultValue,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200057,208423,'D','Y','N','N','N',22,'N',19,104,'N',113,'N','Y','f87bdd5f-d8b2-485b-9e79-89c3a9780a3b','N','AD_Org_ID','Organizational entity within client','@#AD_Org_ID@','An organization is a unit of your client or legal entity - examples are store, department. You can share data between organizations.','Organization','N',100,TO_TIMESTAMP('2013-01-23 17:56:35','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:56:35','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:56:36 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208423 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:36 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200057,208424,'D','Y','N','N','N',7,'N',16,'N',245,'N','Y','1d931ea9-fc11-4fae-9479-2318c1f61ccb','N','Created','Date this record was created','The Created field indicates the date that this record was created.','Created','N',100,TO_TIMESTAMP('2013-01-23 17:56:36','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:56:36','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:56:36 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208424 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,AD_Reference_Value_ID,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200057,208425,'D',110,'Y','N','N','N',22,'N',18,'N',246,'N','Y','8d6bbaa6-5f3d-4514-9919-b5fc723eb8cd','N','CreatedBy','User who created this records','The Created By field indicates the user who created this record.','Created By','N',100,TO_TIMESTAMP('2013-01-23 17:56:36','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:56:36','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:56:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208425 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200057,208426,'D','N','N','N','N',255,'Y',10,'N',275,'N','Y','020e13a1-cf72-49af-9768-5fc575cfc089','Y','Description','Optional short description of the record','A description is limited to 255 characters.','Description','Y',100,TO_TIMESTAMP('2013-01-23 17:56:37','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:56:37','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:56:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208426 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:39 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,DefaultValue,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200057,208427,'D','Y','N','N','N',1,'N',20,'N',348,'N','Y','f21ce087-fe26-474f-92ac-500d646bebde','Y','IsActive','The record is active in the system','Y','There are two methods of making records unavailable in the system: One is to delete the record, the other is to de-activate the record. A de-activated record is not available for selection, but available for reports. +There are two reasons for de-activating and not deleting records: +(1) The system requires the record for audit purposes. +(2) The record is referenced by other records. E.g., you cannot delete a Business Partner, if there are invoices for this partner record existing. You de-activate the Business Partner and prevent that this record is used for future entries.','Active','N',100,TO_TIMESTAMP('2013-01-23 17:56:38','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:56:38','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:56:39 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208427 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:40 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,DefaultValue,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200057,208428,'D','Y','N','N',0,'N',1,'N',20,'N',1103,'N','Y','797ba1b9-c4fe-418c-8c9b-12b5572772c9','Y','IsDefault','Default value','N','The Default Checkbox indicates if this record will be used as a default value.','Default','Y',100,TO_TIMESTAMP('2013-01-23 17:56:39','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:56:39','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:56:40 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208428 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:41 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200057,208429,'D','Y','N','Y',1,'N',60,'Y',10,'N',469,'N','Y','de6545a6-4c1e-4d02-a282-880b428c2686','Y','Name','Alphanumeric identifier of the entity','The name of an entity (record) is used as an default search option in addition to the search key. The name is up to 60 characters in length.','Name','Y',100,TO_TIMESTAMP('2013-01-23 17:56:40','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:56:40','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:56:41 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208429 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:42 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200057,208430,'D','Y','N','N','N',7,'N',16,'N',607,'N','Y','89f73975-72e0-4094-9247-adc2ac6cb2cc','N','Updated','Date this record was updated','The Updated field indicates the date that this record was updated.','Updated','N',100,TO_TIMESTAMP('2013-01-23 17:56:41','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:56:41','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:56:42 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208430 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:43 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,AD_Reference_Value_ID,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200057,208431,'D',110,'Y','N','N','N',22,'N',18,'N',608,'N','Y','74593580-daa8-4324-821b-64d630a31439','N','UpdatedBy','User who updated this records','The Updated By field indicates the user who updated this record.','Updated By','N',100,TO_TIMESTAMP('2013-01-23 17:56:42','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:56:42','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:56:43 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208431 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:44 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200057,208432,'D','Y','N','N',0,'N',40,'N',10,'N',620,'N','Y','ef8ee59d-c878-423b-9596-a70196d6be51','Y','Value','Search key for the record in the format required - must be unique','A search key allows you a fast method of finding a particular record. +If you leave the search key empty, the system automatically creates a numeric number. The document sequence used for this fallback number is defined in the "Maintain Sequence" window with the name "DocumentNo_", where TableName is the actual name of the table (e.g. C_Order).','Search Key','Y',100,TO_TIMESTAMP('2013-01-23 17:56:43','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:56:43','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:56:44 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208432 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200057,208433,'D','Y','N','N',0,'Y',10,'N',19,'N',200601,'N','Y','565cfc26-2ab6-4902-bf11-39a10ac5090f','N','X_Shipper_ID','Shipper','Y',100,TO_TIMESTAMP('2013-01-23 17:56:44','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:56:44','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:56:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208433 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:46 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element (ColumnName,AD_Element_ID,EntityType,Name,PrintName,AD_Element_UU,AD_Client_ID,Created,Updated,AD_Org_ID,CreatedBy,UpdatedBy,IsActive) VALUES ('X_DepositBatchLine_ID',202199,'D','Receipts into Batch Line','Receipts into Batch Line','0ecc1c05-ce0d-4668-b037-4cf0bc5e4a6d',0,TO_TIMESTAMP('2013-01-23 17:56:45','YYYY-MM-DD HH24:MI:SS'),TO_TIMESTAMP('2013-01-23 17:56:45','YYYY-MM-DD HH24:MI:SS'),0,100,100,'Y') +; + +-- Jan 23, 2013 5:56:46 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element_Trl (AD_Language,AD_Element_ID, Help,PO_Description,PO_Help,Description,Name,PrintName,PO_Name,PO_PrintName, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Element_Trl_UU ) SELECT l.AD_Language,t.AD_Element_ID, t.Help,t.PO_Description,t.PO_Help,t.Description,t.Name,t.PrintName,t.PO_Name,t.PO_PrintName, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Element t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Element_ID=202199 AND NOT EXISTS (SELECT * FROM AD_Element_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Element_ID=t.AD_Element_ID) +; + +-- Jan 23, 2013 5:56:47 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1,'Y','N',200057,208434,'D','Y','N','N','N',22,'N',13,'Y',202199,'N','Y','5ba3e70b-9087-4a78-ac1d-27da921780f7','N','X_DepositBatchLine_ID','Receipts into Batch Line','N',100,TO_TIMESTAMP('2013-01-23 17:56:45','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:56:45','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:56:47 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208434 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:56:51 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element (ColumnName,AD_Element_ID,EntityType,Name,PrintName,AD_Element_UU,AD_Client_ID,Created,Updated,AD_Org_ID,CreatedBy,UpdatedBy,IsActive) VALUES ('X_DepositBatchLine_UU',202200,'D','X_DepositBatchLine_UU','X_DepositBatchLine_UU','7913a3b1-6e32-4764-afe0-24e3fbaf574c',0,TO_TIMESTAMP('2013-01-23 17:56:47','YYYY-MM-DD HH24:MI:SS'),TO_TIMESTAMP('2013-01-23 17:56:47','YYYY-MM-DD HH24:MI:SS'),0,100,100,'Y') +; + +-- Jan 23, 2013 5:56:51 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element_Trl (AD_Language,AD_Element_ID, Help,PO_Description,PO_Help,Description,Name,PrintName,PO_Name,PO_PrintName, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Element_Trl_UU ) SELECT l.AD_Language,t.AD_Element_ID, t.Help,t.PO_Description,t.PO_Help,t.Description,t.Name,t.PrintName,t.PO_Name,t.PO_PrintName, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Element t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Element_ID=202200 AND NOT EXISTS (SELECT * FROM AD_Element_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Element_ID=t.AD_Element_ID) +; + +-- Jan 23, 2013 5:56:52 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton,IsAlwaysUpdateable) VALUES (1.00,'N','N',200057,208435,'D','N','N','N','N',36,'N',10,'N',202200,'N','Y','a01d37de-3836-4f42-a697-e324684966a1','Y','X_DepositBatchLine_UU','X_DepositBatchLine_UU','N',100,TO_TIMESTAMP('2013-01-23 17:56:47','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:56:47','YYYY-MM-DD HH24:MI:SS'),100,0,'N','N') +; + +-- Jan 23, 2013 5:56:52 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208435 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:57:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column_Trl WHERE AD_Column_ID=208426 +; + +-- Jan 23, 2013 5:57:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column WHERE AD_Column_ID=208426 +; + +-- Jan 23, 2013 5:57:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column_Trl WHERE AD_Column_ID=208428 +; + +-- Jan 23, 2013 5:57:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column WHERE AD_Column_ID=208428 +; + +-- Jan 23, 2013 5:57:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column_Trl WHERE AD_Column_ID=208429 +; + +-- Jan 23, 2013 5:57:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column WHERE AD_Column_ID=208429 +; + +-- Jan 23, 2013 5:57:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column_Trl WHERE AD_Column_ID=208432 +; + +-- Jan 23, 2013 5:57:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column WHERE AD_Column_ID=208432 +; + +-- Jan 23, 2013 5:57:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column_Trl WHERE AD_Column_ID=208433 +; + +-- Jan 23, 2013 5:57:13 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +DELETE FROM AD_Column WHERE AD_Column_ID=208433 +; + +-- Jan 23, 2013 5:57:50 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200057,208436,'D','Y','N','N',0,'N',14,'N',12,'N',1477,'N','Y','e2044592-39c2-416d-8290-347d623d2802','Y','PayAmt','Amount being paid','Indicates the amount this payment is for. The payment amount can be for single or multiple invoices or a partial payment for an invoice.','Payment amount','Y',100,TO_TIMESTAMP('2013-01-23 17:57:49','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:57:49','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:57:50 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208436 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:58:16 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200057,208437,'D','Y','N','N',0,'N',10,'N',19,'N',1384,'N','Y','139d61a5-2419-4ae7-89ea-29cff433ee6b','Y','C_Payment_ID','Payment identifier','The Payment is a unique identifier of this payment.','Payment','Y',100,TO_TIMESTAMP('2013-01-23 17:58:15','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:58:15','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:58:16 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208437 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:58:58 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,DefaultValue,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200057,208438,'D','Y','N','Y',0,'N',14,'N',11,'N',439,'N','Y','aa02a955-a0ce-4193-82b2-ef48472a4645','Y','Line','Unique line for this document','@SQL=SELECT NVL(MAX(Line),0)+10 AS DefaultValue FROM X_DepositBatchLine WHERE X_DepositBatch_ID=@X_DepositBatch_ID@','Indicates the unique line for a document. It will also control the display order of the lines within a document.','Line No','Y',100,TO_TIMESTAMP('2013-01-23 17:58:57','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:58:57','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:58:58 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208438 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:59:26 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200057,208439,'D','Y','N','N',0,'N',1,'N',20,'N',1047,'N','Y','213e0828-2b2b-491e-89d7-8ff1b91513a3','Y','Processed','The document has been processed','The Processed checkbox indicates that a document has been processed.','Processed','Y',100,TO_TIMESTAMP('2013-01-23 17:59:26','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:59:26','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:59:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208439 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 5:59:47 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200057,208440,'D','Y','N','N',0,'N',1,'N',20,'N',524,'N','Y','8cbdcd1c-4c89-4149-a67a-db427dae1274','Y','Processing','Process Now','Y',100,TO_TIMESTAMP('2013-01-23 17:59:47','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 17:59:47','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 5:59:47 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208440 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 6:00:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',200057,208441,'D','Y','N','Y',1,'Y',10,'N',30,'N',202195,'N','Y','ea94bbcc-6e17-4f2e-bf87-9b66e1a839d3','N','X_DepositBatch_ID','Receipts into Batch','Y',100,TO_TIMESTAMP('2013-01-23 18:00:36','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 18:00:36','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 6:00:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208441 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 6:01:11 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Column SET IsUpdateable='N', Name='Deposit Batch',Updated=TO_TIMESTAMP('2013-01-23 18:01:11','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=208441 +; + +-- Jan 23, 2013 6:01:11 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Column_Trl SET IsTranslated='N' WHERE AD_Column_ID=208441 +; + +-- Jan 23, 2013 6:01:11 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET Name='Deposit Batch', Description=NULL, Help=NULL WHERE AD_Column_ID=208441 AND IsCentrallyMaintained='Y' +; + +-- Jan 23, 2013 6:01:25 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Element SET PrintName='Deposit Batch',Updated=TO_TIMESTAMP('2013-01-23 18:01:25','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Element_ID=202195 +; + +-- Jan 23, 2013 6:01:25 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Element_Trl SET IsTranslated='N' WHERE AD_Element_ID=202195 +; + +-- Jan 23, 2013 6:01:25 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_PrintFormatItem SET PrintName='Deposit Batch', Name='Receipts into Batch' WHERE IsCentrallyMaintained='Y' AND EXISTS (SELECT * FROM AD_Column c WHERE c.AD_Column_ID=AD_PrintFormatItem.AD_Column_ID AND c.AD_Element_ID=202195) +; + +-- Jan 23, 2013 6:01:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Element SET Name='Deposit Batch Line', PrintName='Deposit Batch Line',Updated=TO_TIMESTAMP('2013-01-23 18:01:45','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Element_ID=202199 +; + +-- Jan 23, 2013 6:01:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Element_Trl SET IsTranslated='N' WHERE AD_Element_ID=202199 +; + +-- Jan 23, 2013 6:01:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Column SET ColumnName='X_DepositBatchLine_ID', Name='Deposit Batch Line', Description=NULL, Help=NULL WHERE AD_Element_ID=202199 +; + +-- Jan 23, 2013 6:01:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Process_Para SET ColumnName='X_DepositBatchLine_ID', Name='Deposit Batch Line', Description=NULL, Help=NULL, AD_Element_ID=202199 WHERE UPPER(ColumnName)='X_DEPOSITBATCHLINE_ID' AND IsCentrallyMaintained='Y' AND AD_Element_ID IS NULL +; + +-- Jan 23, 2013 6:01:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Process_Para SET ColumnName='X_DepositBatchLine_ID', Name='Deposit Batch Line', Description=NULL, Help=NULL WHERE AD_Element_ID=202199 AND IsCentrallyMaintained='Y' +; + +-- Jan 23, 2013 6:01:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_InfoColumn SET ColumnName='X_DepositBatchLine_ID', Name='Deposit Batch Line', Description=NULL, Help=NULL WHERE AD_Element_ID=202199 AND IsCentrallyMaintained='Y' +; + +-- Jan 23, 2013 6:01:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET Name='Deposit Batch Line', Description=NULL, Help=NULL WHERE AD_Column_ID IN (SELECT AD_Column_ID FROM AD_Column WHERE AD_Element_ID=202199) AND IsCentrallyMaintained='Y' +; + +-- Jan 23, 2013 6:01:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_PrintFormatItem SET PrintName='Deposit Batch Line', Name='Deposit Batch Line' WHERE IsCentrallyMaintained='Y' AND EXISTS (SELECT * FROM AD_Column c WHERE c.AD_Column_ID=AD_PrintFormatItem.AD_Column_ID AND c.AD_Element_ID=202199) +; + +-- Jan 23, 2013 6:01:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Element SET Name='Deposit Batch',Updated=TO_TIMESTAMP('2013-01-23 18:01:57','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Element_ID=202195 +; + +-- Jan 23, 2013 6:01:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Element_Trl SET IsTranslated='N' WHERE AD_Element_ID=202195 +; + +-- Jan 23, 2013 6:01:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Column SET ColumnName='X_DepositBatch_ID', Name='Deposit Batch', Description=NULL, Help=NULL WHERE AD_Element_ID=202195 +; + +-- Jan 23, 2013 6:01:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Process_Para SET ColumnName='X_DepositBatch_ID', Name='Deposit Batch', Description=NULL, Help=NULL, AD_Element_ID=202195 WHERE UPPER(ColumnName)='X_DEPOSITBATCH_ID' AND IsCentrallyMaintained='Y' AND AD_Element_ID IS NULL +; + +-- Jan 23, 2013 6:01:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Process_Para SET ColumnName='X_DepositBatch_ID', Name='Deposit Batch', Description=NULL, Help=NULL WHERE AD_Element_ID=202195 AND IsCentrallyMaintained='Y' +; + +-- Jan 23, 2013 6:01:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_InfoColumn SET ColumnName='X_DepositBatch_ID', Name='Deposit Batch', Description=NULL, Help=NULL WHERE AD_Element_ID=202195 AND IsCentrallyMaintained='Y' +; + +-- Jan 23, 2013 6:01:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET Name='Deposit Batch', Description=NULL, Help=NULL WHERE AD_Column_ID IN (SELECT AD_Column_ID FROM AD_Column WHERE AD_Element_ID=202195) AND IsCentrallyMaintained='Y' +; + +-- Jan 23, 2013 6:01:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_PrintFormatItem SET PrintName='Deposit Batch', Name='Deposit Batch' WHERE IsCentrallyMaintained='Y' AND EXISTS (SELECT * FROM AD_Column c WHERE c.AD_Column_ID=AD_PrintFormatItem.AD_Column_ID AND c.AD_Element_ID=202195) +; + +-- Jan 23, 2013 6:02:07 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Table SET Name='Deposit Batch Line',Updated=TO_TIMESTAMP('2013-01-23 18:02:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Table_ID=200057 +; + +-- Jan 23, 2013 6:02:07 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Table_Trl SET IsTranslated='N' WHERE AD_Table_ID=200057 +; + +-- Jan 23, 2013 6:02:20 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Table SET Name='Deposit Batch',Updated=TO_TIMESTAMP('2013-01-23 18:02:20','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Table_ID=200056 +; + +-- Jan 23, 2013 6:02:20 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Table_Trl SET IsTranslated='N' WHERE AD_Table_ID=200056 +; + +-- Jan 23, 2013 6:02:29 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +CREATE TABLE X_DepositBatchLine (AD_Client_ID NUMERIC(10) NOT NULL, AD_Org_ID NUMERIC(10) NOT NULL, C_Payment_ID NUMERIC(10) NOT NULL, Created TIMESTAMP NOT NULL, CreatedBy NUMERIC(10) NOT NULL, IsActive CHAR(1) DEFAULT 'Y' CHECK (IsActive IN ('Y','N')) NOT NULL, Line NUMERIC(10) NOT NULL, PayAmt NUMERIC NOT NULL, Processed CHAR(1) CHECK (Processed IN ('Y','N')) NOT NULL, Processing CHAR(1) CHECK (Processing IN ('Y','N')) NOT NULL, Updated TIMESTAMP NOT NULL, UpdatedBy NUMERIC(10) NOT NULL, X_DepositBatch_ID NUMERIC(10) NOT NULL, X_DepositBatchLine_ID NUMERIC(10) NOT NULL, X_DepositBatchLine_UU VARCHAR(36) DEFAULT NULL , CONSTRAINT X_DepositBatchLine_Key PRIMARY KEY (X_DepositBatchLine_ID)) +; + +-- Jan 23, 2013 6:03:36 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element (ColumnName,AD_Element_ID,EntityType,Name,PrintName,AD_Element_UU,AD_Client_ID,Created,Updated,AD_Org_ID,CreatedBy,UpdatedBy,IsActive) VALUES ('X_CreateFromBatch',202201,'D','Create From Batch','Create From Batch','a56bf24b-a9b0-459b-8db3-17fff6f8d9c1',0,TO_TIMESTAMP('2013-01-23 18:03:35','YYYY-MM-DD HH24:MI:SS'),TO_TIMESTAMP('2013-01-23 18:03:35','YYYY-MM-DD HH24:MI:SS'),0,100,100,'Y') +; + +-- Jan 23, 2013 6:03:36 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Element_Trl (AD_Language,AD_Element_ID, Help,PO_Description,PO_Help,Description,Name,PrintName,PO_Name,PO_PrintName, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Element_Trl_UU ) SELECT l.AD_Language,t.AD_Element_ID, t.Help,t.PO_Description,t.PO_Help,t.Description,t.Name,t.PrintName,t.PO_Name,t.PO_PrintName, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Element t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Element_ID=202201 AND NOT EXISTS (SELECT * FROM AD_Element_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Element_ID=t.AD_Element_ID) +; + +-- Jan 23, 2013 6:04:09 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',392,208442,'D','N','N','N',0,'N',1,'N',28,'N',202201,'N','Y','b6c3169b-a7c0-422c-bf51-89f9614ddef4','Y','X_CreateFromBatch','Create From Batch','Y',100,TO_TIMESTAMP('2013-01-23 18:04:08','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 18:04:08','YYYY-MM-DD HH24:MI:SS'),100,0,0,'Y','N') +; + +-- Jan 23, 2013 6:04:09 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208442 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 6:04:10 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +ALTER TABLE C_BankStatement ADD COLUMN X_CreateFromBatch CHAR(1) DEFAULT NULL +; + +-- Jan 23, 2013 6:06:32 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column (Version,IsSyncDatabase,IsEncrypted,AD_Table_ID,AD_Column_ID,EntityType,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsParent,FieldLength,IsSelectionColumn,AD_Reference_ID,IsKey,AD_Element_ID,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsUpdateable,ColumnName,Name,IsAllowCopy,CreatedBy,Updated,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,SeqNoSelection,IsToolbarButton,IsAlwaysUpdateable) VALUES (0,'N','N',335,208443,'D','N','N','N',0,'Y',10,'N',19,'N',202195,'N','Y','622ebed6-d1da-436e-81ab-9283d921d0b4','N','X_DepositBatch_ID','Deposit Batch','Y',100,TO_TIMESTAMP('2013-01-23 18:06:31','YYYY-MM-DD HH24:MI:SS'),0,'Y',TO_TIMESTAMP('2013-01-23 18:06:31','YYYY-MM-DD HH24:MI:SS'),100,0,0,'N','N') +; + +-- Jan 23, 2013 6:06:32 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Column_Trl_UU ) 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,Generate_UUID() FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=208443 AND NOT EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Column_ID=t.AD_Column_ID) +; + +-- Jan 23, 2013 6:06:35 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +ALTER TABLE C_Payment ADD COLUMN X_DepositBatch_ID NUMERIC(10) DEFAULT NULL +; + +-- Jan 23, 2013 6:08:49 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,EntityType,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',328,36,'N','N',60601,'Y',201690,'N','D','C_BankStatement_UU','N','Y','d5f5ce1f-21cb-4b9e-a21f-62822cc17d57',100,0,TO_TIMESTAMP('2013-01-23 18:08:48','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:08:48','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:08:50 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201690 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:08:51 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,EntityType,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',328,1,'N','N',208442,'Y',201691,'N','D','Create From Batch','N','Y','cdf9b481-ae14-4458-ac87-44afbb2fe155',100,0,TO_TIMESTAMP('2013-01-23 18:08:50','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:08:50','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:08:51 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201691 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=0,IsDisplayed='N' WHERE AD_Field_ID=201690 +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=120,IsDisplayed='Y' WHERE AD_Field_ID=201691 +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=130,IsDisplayed='Y' WHERE AD_Field_ID=4003 +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=140,IsDisplayed='Y' WHERE AD_Field_ID=8933 +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=150,IsDisplayed='Y' WHERE AD_Field_ID=200599 +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=160,IsDisplayed='Y' WHERE AD_Field_ID=3997 +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=170,IsDisplayed='Y' WHERE AD_Field_ID=8686 +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=180,IsDisplayed='Y' WHERE AD_Field_ID=8687 +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=190,IsDisplayed='Y' WHERE AD_Field_ID=10585 +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=200,IsDisplayed='Y' WHERE AD_Field_ID=10586 +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=210,IsDisplayed='Y' WHERE AD_Field_ID=10587 +; + +-- Jan 23, 2013 6:09:27 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=220,IsDisplayed='Y' WHERE AD_Field_ID=3999 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=61967 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=201690 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=3991 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=200599 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=200600 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=10,IsDisplayedGrid='Y' WHERE AD_Field_ID=3992 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=20,IsDisplayedGrid='Y' WHERE AD_Field_ID=3994 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=30,IsDisplayedGrid='Y' WHERE AD_Field_ID=4120 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=40,IsDisplayedGrid='Y' WHERE AD_Field_ID=4002 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=50,IsDisplayedGrid='Y' WHERE AD_Field_ID=3996 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=60,IsDisplayedGrid='Y' WHERE AD_Field_ID=3998 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=70,IsDisplayedGrid='Y' WHERE AD_Field_ID=4119 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=80,IsDisplayedGrid='Y' WHERE AD_Field_ID=3993 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=90,IsDisplayedGrid='Y' WHERE AD_Field_ID=4365 +; + +-- Jan 23, 2013 6:09:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=100,IsDisplayedGrid='Y' WHERE AD_Field_ID=201691 +; + +-- Jan 23, 2013 6:11:16 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET XPosition=2, ColumnSpan=2,Updated=TO_TIMESTAMP('2013-01-23 18:11:16','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201691 +; + +-- Jan 23, 2013 6:12:26 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Window (Processing,WindowType,Help,IsSOTrx,IsDefault,IsBetaFunctionality,WinHeight,WinWidth,EntityType,Name,Description,AD_Window_ID,AD_Image_ID,AD_Window_UU,Created,Updated,AD_Client_ID,AD_Org_ID,IsActive,UpdatedBy,CreatedBy) VALUES ('N','T','The Process Receipts Window allows you to enter receipts for invoices. If the payment is for a single invoice then it can be processed here.','Y','N','N',0,0,'D','Receipts into Batch','Process Receipts',200031,106,'74b265cf-fb73-4715-b926-f2e6e485d992',TO_TIMESTAMP('2013-01-23 18:12:25','YYYY-MM-DD HH24:MI:SS'),TO_TIMESTAMP('2013-01-23 18:12:25','YYYY-MM-DD HH24:MI:SS'),0,0,'Y',100,100) +; + +-- Jan 23, 2013 6:12:26 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Window_Trl (AD_Language,AD_Window_ID, Help,Name,Description, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Window_Trl_UU ) SELECT l.AD_Language,t.AD_Window_ID, t.Help,t.Name,t.Description, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Window t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Window_ID=200031 AND NOT EXISTS (SELECT * FROM AD_Window_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Window_ID=t.AD_Window_ID) +; + +-- Jan 23, 2013 6:12:54 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Tab (ImportFields,Processing,IsSingleRow,AD_Window_ID,SeqNo,IsTranslationTab,IsSortTab,AD_Table_ID,HasTree,IsReadOnly,IsInfoTab,AD_Tab_UU,IsInsertRecord,IsAdvancedTab,TabLevel,EntityType,Name,AD_Tab_ID,AD_Client_ID,Updated,AD_Org_ID,Created,CreatedBy,UpdatedBy,IsActive) VALUES ('N','N','N',200031,10,'N','N',200056,'N','N','N','b2b0e8f8-0bbb-47b5-8dce-1accf43ad27c','Y','N',0,'D','Batch',200067,0,TO_TIMESTAMP('2013-01-23 18:12:53','YYYY-MM-DD HH24:MI:SS'),0,TO_TIMESTAMP('2013-01-23 18:12:53','YYYY-MM-DD HH24:MI:SS'),100,100,'Y') +; + +-- Jan 23, 2013 6:12:54 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Tab_Trl (AD_Language,AD_Tab_ID, Help,CommitWarning,Name,Description, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Tab_Trl_UU ) SELECT l.AD_Language,t.AD_Tab_ID, t.Help,t.CommitWarning,t.Name,t.Description, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Tab t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Tab_ID=200067 AND NOT EXISTS (SELECT * FROM AD_Tab_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Tab_ID=t.AD_Tab_ID) +; + +-- Jan 23, 2013 6:12:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,1,'N','N',208403,'Y',201692,'N','There are two methods of making records unavailable in the system: One is to delete the record, the other is to de-activate the record. A de-activated record is not available for selection, but available for reports. +There are two reasons for de-activating and not deleting records: +(1) The system requires the record for audit purposes. +(2) The record is referenced by other records. E.g., you cannot delete a Business Partner, if there are invoices for this partner record existing. You de-activate the Business Partner and prevent that this record is used for future entries.','D','The record is active in the system','Active','N','Y','9124887c-0d0c-4985-ab70-e135578d4f13',100,0,TO_TIMESTAMP('2013-01-23 18:12:56','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:12:56','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:12:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201692 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:12:58 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,10,'N','N',208412,'Y',201693,'N','The Bank Account identifies an account at this Bank.','D','Account at the Bank','Bank Account','N','Y','b93077eb-579f-41d0-9e87-50a20d100a65',100,0,TO_TIMESTAMP('2013-01-23 18:12:57','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:12:57','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:12:58 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201693 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:12:59 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,22,'N','N',208398,'Y',201694,'N','A Client is a company or a legal entity. You cannot share data between Clients. Tenant is a synonym for Client.','D','Client/Tenant for this installation.','Client','N','Y','d98af125-94ef-4da3-a4c7-6db0e3d27e7e',100,0,TO_TIMESTAMP('2013-01-23 18:12:58','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:12:58','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:12:59 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201694 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:00 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,1,'N','N',208414,'Y',201695,'N','The Create From process will create a new document based on information in an existing document selected by the user.','D','Process which will generate a new document lines based on an existing document','Create lines from','N','Y','809b4770-3ac7-44ca-883a-403e3fcc99df',100,0,TO_TIMESTAMP('2013-01-23 18:12:59','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:12:59','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:00 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201695 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:01 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,EntityType,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,14,'N','N',208417,'Y',201696,'N','D','Deposit Amount','N','Y','3d6714d8-e720-4aca-bde7-87a680611ac1',100,0,TO_TIMESTAMP('2013-01-23 18:13:00','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:13:00','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:01 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201696 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:02 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,EntityType,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive,IsDisplayedGrid) VALUES ('N',200067,22,'N','N',208410,'Y',201697,'N','D','Deposit Batch','N','N','42e24a69-e7f9-4219-b121-5e5a53cf504e',100,0,TO_TIMESTAMP('2013-01-23 18:13:01','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:13:01','YYYY-MM-DD HH24:MI:SS'),'Y','N') +; + +-- Jan 23, 2013 6:13:02 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201697 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:02 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,EntityType,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,7,'N','N',208415,'Y',201698,'N','D','Deposit Date','N','Y','5afd8215-cc8e-4c10-9191-9ece1df7e760',100,0,TO_TIMESTAMP('2013-01-23 18:13:02','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:13:02','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:02 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201698 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:03 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,255,'N','N',208402,'Y',201699,'N','A description is limited to 255 characters.','D','Optional short description of the record','Description','N','Y','0836c263-cbd8-4051-98f4-3f389990d6d8',100,0,TO_TIMESTAMP('2013-01-23 18:13:02','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:13:02','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:03 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201699 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:04 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,7,'N','N',208416,'Y',201700,'N','The Document Date indicates the date the document was generated. It may or may not be the same as the accounting date.','D','Date of the Document','Document Date','N','Y','ae0d05d5-8aa5-409b-a5e2-ddde334ecf06',100,0,TO_TIMESTAMP('2013-01-23 18:13:03','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:13:03','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:04 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201700 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:05 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,30,'N','N',208419,'Y',201701,'N','The document number is usually automatically generated by the system and determined by the document type of the document. If the document is not saved, the preliminary number is displayed in "<>". + +If the document type of your document has no automatic document sequence defined, the field is empty if you create a new document. This is for documents which usually have an external number (like vendor invoice). If you leave the field empty, the system will generate a document number for you. The document sequence used for this fallback number is defined in the "Maintain Sequence" window with the name "DocumentNo_", where TableName is the actual name of the table (e.g. C_Order).','D','Document sequence number of the document','Document No','N','Y','a9e341f3-f2dd-4ab9-b9f2-d9eebb9745d0',100,0,TO_TIMESTAMP('2013-01-23 18:13:04','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:13:04','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:05 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201701 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,2,'N','N',208418,'Y',201702,'N','The Document Status indicates the status of a document at this time. If you want to change the document status, use the Document Action field','D','The current status of the document','Document Status','N','Y','4432e795-042a-4a96-80ea-71603e6a4f5a',100,0,TO_TIMESTAMP('2013-01-23 18:13:05','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:13:05','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201702 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:07 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,10,'N','N',208413,'Y',201703,'N','The Document Type determines document sequence and processing rules','D','Document type or rules','Document Type','N','Y','c14cdcd0-48a6-4f58-81e6-076117137cab',100,0,TO_TIMESTAMP('2013-01-23 18:13:06','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:13:06','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:07 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201703 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,22,'N','N',208399,'Y',201704,'N','An organization is a unit of your client or legal entity - examples are store, department. You can share data between organizations.','D','Organizational entity within client','Organization','N','Y','41ed507f-b5e8-4b5f-a1a3-9492c34fbffc',100,0,TO_TIMESTAMP('2013-01-23 18:13:07','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:13:07','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201704 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:09 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,EntityType,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,1,'N','N',208421,'Y',201705,'N','D','Process Now','N','Y','c2172400-027c-4496-a7fd-53a4e94691c3',100,0,TO_TIMESTAMP('2013-01-23 18:13:08','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:13:08','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:09 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201705 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:10 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,1,'N','N',208420,'Y',201706,'N','The Processed checkbox indicates that a document has been processed.','D','The document has been processed','Processed','N','Y','d6034f0a-77cd-4e51-9f8e-e25d9496094b',100,0,TO_TIMESTAMP('2013-01-23 18:13:09','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:13:09','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:10 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201706 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:13:11 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,EntityType,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200067,36,'N','N',208411,'Y',201707,'N','D','X_DepositBatch_UU','N','Y','097b9034-c40f-484a-89ac-a0ccae0d2363',100,0,TO_TIMESTAMP('2013-01-23 18:13:10','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:13:10','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:13:11 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201707 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=0,IsDisplayed='N' WHERE AD_Field_ID=201702 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=0,IsDisplayed='N' WHERE AD_Field_ID=201707 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=10,IsDisplayed='Y' WHERE AD_Field_ID=201694 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=20,IsDisplayed='Y' WHERE AD_Field_ID=201704 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=30,IsDisplayed='Y' WHERE AD_Field_ID=201693 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=40,IsDisplayed='Y' WHERE AD_Field_ID=201698 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=50,IsDisplayed='Y' WHERE AD_Field_ID=201703 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=60,IsDisplayed='Y' WHERE AD_Field_ID=201701 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=70,IsDisplayed='Y' WHERE AD_Field_ID=201700 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=80,IsDisplayed='Y' WHERE AD_Field_ID=201699 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=90,IsDisplayed='Y' WHERE AD_Field_ID=201696 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=100,IsDisplayed='Y' WHERE AD_Field_ID=201695 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=110,IsDisplayed='Y' WHERE AD_Field_ID=201692 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=120,IsDisplayed='Y' WHERE AD_Field_ID=201705 +; + +-- Jan 23, 2013 6:14:14 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=130,IsDisplayed='Y' WHERE AD_Field_ID=201706 +; + +-- Jan 23, 2013 6:15:05 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=201702 +; + +-- Jan 23, 2013 6:15:05 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=201707 +; + +-- Jan 23, 2013 6:15:05 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=10,IsDisplayedGrid='Y' WHERE AD_Field_ID=201694 +; + +-- Jan 23, 2013 6:15:05 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=20,IsDisplayedGrid='Y' WHERE AD_Field_ID=201704 +; + +-- Jan 23, 2013 6:15:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=30,IsDisplayedGrid='Y' WHERE AD_Field_ID=201693 +; + +-- Jan 23, 2013 6:15:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=40,IsDisplayedGrid='Y' WHERE AD_Field_ID=201698 +; + +-- Jan 23, 2013 6:15:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=50,IsDisplayedGrid='Y' WHERE AD_Field_ID=201703 +; + +-- Jan 23, 2013 6:15:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=60,IsDisplayedGrid='Y' WHERE AD_Field_ID=201701 +; + +-- Jan 23, 2013 6:15:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=70,IsDisplayedGrid='Y' WHERE AD_Field_ID=201700 +; + +-- Jan 23, 2013 6:15:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=80,IsDisplayedGrid='Y' WHERE AD_Field_ID=201699 +; + +-- Jan 23, 2013 6:15:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=90,IsDisplayedGrid='Y' WHERE AD_Field_ID=201696 +; + +-- Jan 23, 2013 6:15:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=100,IsDisplayedGrid='Y' WHERE AD_Field_ID=201695 +; + +-- Jan 23, 2013 6:15:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=110,IsDisplayedGrid='Y' WHERE AD_Field_ID=201692 +; + +-- Jan 23, 2013 6:15:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=120,IsDisplayedGrid='Y' WHERE AD_Field_ID=201705 +; + +-- Jan 23, 2013 6:15:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=130,IsDisplayedGrid='Y' WHERE AD_Field_ID=201706 +; + +-- Jan 23, 2013 6:15:58 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET IsSameLine='Y', ColumnSpan=2,Updated=TO_TIMESTAMP('2013-01-23 18:15:58','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201704 +; + +-- Jan 23, 2013 6:16:04 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET ColumnSpan=2,Updated=TO_TIMESTAMP('2013-01-23 18:16:04','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201694 +; + +-- Jan 23, 2013 6:16:09 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET XPosition=4,Updated=TO_TIMESTAMP('2013-01-23 18:16:09','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201704 +; + +-- Jan 23, 2013 6:16:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET ColumnSpan=2,Updated=TO_TIMESTAMP('2013-01-23 18:16:23','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201693 +; + +-- Jan 23, 2013 6:16:40 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET IsSameLine='Y', XPosition=4, ColumnSpan=2,Updated=TO_TIMESTAMP('2013-01-23 18:16:40','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201698 +; + +-- Jan 23, 2013 6:16:42 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET ColumnSpan=2,Updated=TO_TIMESTAMP('2013-01-23 18:16:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201703 +; + +-- Jan 23, 2013 6:17:00 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET IsSameLine='Y', XPosition=4, ColumnSpan=2,Updated=TO_TIMESTAMP('2013-01-23 18:17:00','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201701 +; + +-- Jan 23, 2013 6:17:06 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET ColumnSpan=2,Updated=TO_TIMESTAMP('2013-01-23 18:17:06','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201700 +; + +-- Jan 23, 2013 6:17:12 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET ColumnSpan=5,Updated=TO_TIMESTAMP('2013-01-23 18:17:12','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201699 +; + +-- Jan 23, 2013 6:17:15 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET ColumnSpan=2,Updated=TO_TIMESTAMP('2013-01-23 18:17:15','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201696 +; + +-- Jan 23, 2013 6:17:39 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET IsSameLine='Y', XPosition=5, ColumnSpan=2,Updated=TO_TIMESTAMP('2013-01-23 18:17:39','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201695 +; + +-- Jan 23, 2013 6:18:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET XPosition=2, ColumnSpan=2,Updated=TO_TIMESTAMP('2013-01-23 18:18:08','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201692 +; + +-- Jan 23, 2013 6:18:49 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET IsSameLine='Y', DisplayLogic='@DepositAmt@!0', XPosition=5, ColumnSpan=2,Updated=TO_TIMESTAMP('2013-01-23 18:18:49','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201705 +; + +-- Jan 23, 2013 6:19:02 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET IsReadOnly='Y', XPosition=2, ColumnSpan=2,Updated=TO_TIMESTAMP('2013-01-23 18:19:02','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201706 +; + +-- Jan 23, 2013 6:19:11 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET IsReadOnly='Y',Updated=TO_TIMESTAMP('2013-01-23 18:19:11','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201696 +; + +-- Jan 23, 2013 6:19:43 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Tab (ImportFields,Processing,IsSingleRow,AD_Window_ID,SeqNo,IsTranslationTab,IsSortTab,AD_Table_ID,HasTree,IsReadOnly,IsInfoTab,AD_Tab_UU,IsInsertRecord,IsAdvancedTab,TabLevel,EntityType,Name,AD_Tab_ID,ReadOnlyLogic,AD_Client_ID,Updated,AD_Org_ID,Created,CreatedBy,UpdatedBy,IsActive) VALUES ('N','N','N',200031,20,'N','N',200057,'N','N','N','3adbb99b-98d8-450f-83a0-87ebc00d2950','Y','N',1,'D','Lines',200068,'@Processed@=''Y''',0,TO_TIMESTAMP('2013-01-23 18:19:42','YYYY-MM-DD HH24:MI:SS'),0,TO_TIMESTAMP('2013-01-23 18:19:42','YYYY-MM-DD HH24:MI:SS'),100,100,'Y') +; + +-- Jan 23, 2013 6:19:43 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Tab_Trl (AD_Language,AD_Tab_ID, Help,CommitWarning,Name,Description, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Tab_Trl_UU ) SELECT l.AD_Language,t.AD_Tab_ID, t.Help,t.CommitWarning,t.Name,t.Description, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Tab t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Tab_ID=200068 AND NOT EXISTS (SELECT * FROM AD_Tab_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Tab_ID=t.AD_Tab_ID) +; + +-- Jan 23, 2013 6:19:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200068,1,'N','N',208427,'Y',201708,'N','There are two methods of making records unavailable in the system: One is to delete the record, the other is to de-activate the record. A de-activated record is not available for selection, but available for reports. +There are two reasons for de-activating and not deleting records: +(1) The system requires the record for audit purposes. +(2) The record is referenced by other records. E.g., you cannot delete a Business Partner, if there are invoices for this partner record existing. You de-activate the Business Partner and prevent that this record is used for future entries.','D','The record is active in the system','Active','N','Y','e9fa326b-c53b-4428-a7a3-fd98f9dd68c5',100,0,TO_TIMESTAMP('2013-01-23 18:19:44','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:19:44','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:19:45 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201708 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:19:46 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200068,22,'N','N',208422,'Y',201709,'N','A Client is a company or a legal entity. You cannot share data between Clients. Tenant is a synonym for Client.','D','Client/Tenant for this installation.','Client','N','Y','2205a77d-7491-4ae8-8bcb-e2c601d37d4c',100,0,TO_TIMESTAMP('2013-01-23 18:19:45','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:19:45','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:19:46 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201709 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:19:47 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,EntityType,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200068,10,'N','N',208441,'Y',201710,'N','D','Deposit Batch','N','Y','0c853d59-6d17-4653-b036-ec3a51478185',100,0,TO_TIMESTAMP('2013-01-23 18:19:46','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:19:46','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:19:47 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201710 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:19:51 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,EntityType,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive,IsDisplayedGrid) VALUES ('N',200068,22,'N','N',208434,'Y',201711,'N','D','Deposit Batch Line','N','N','97d87d68-da47-4d84-9fb7-998fb0757a1b',100,0,TO_TIMESTAMP('2013-01-23 18:19:47','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:19:47','YYYY-MM-DD HH24:MI:SS'),'Y','N') +; + +-- Jan 23, 2013 6:19:51 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201711 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:19:52 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200068,14,'N','N',208438,'Y',201712,'N','Indicates the unique line for a document. It will also control the display order of the lines within a document.','D','Unique line for this document','Line No','N','Y','8d47a707-97e7-49ef-8db3-3b19a6864f32',100,0,TO_TIMESTAMP('2013-01-23 18:19:51','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:19:51','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:19:52 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201712 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:19:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200068,22,'N','N',208423,'Y',201713,'N','An organization is a unit of your client or legal entity - examples are store, department. You can share data between organizations.','D','Organizational entity within client','Organization','N','Y','f92541af-e885-426c-af88-c75cf30314fe',100,0,TO_TIMESTAMP('2013-01-23 18:19:52','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:19:52','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:19:53 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201713 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:19:54 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200068,10,'N','N',208437,'Y',201714,'N','The Payment is a unique identifier of this payment.','D','Payment identifier','Payment','N','Y','3951ce27-652a-4a11-b1e5-a4d47c56a860',100,0,TO_TIMESTAMP('2013-01-23 18:19:53','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:19:53','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:19:54 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201714 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:19:55 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200068,14,'N','N',208436,'Y',201715,'N','Indicates the amount this payment is for. The payment amount can be for single or multiple invoices or a partial payment for an invoice.','D','Amount being paid','Payment amount','N','Y','1bba36a4-c629-4d77-9f81-b5483df0997b',100,0,TO_TIMESTAMP('2013-01-23 18:19:54','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:19:54','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:19:55 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201715 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:19:56 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,EntityType,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200068,1,'N','N',208440,'Y',201716,'N','D','Process Now','N','Y','104eefdd-cc7b-46c6-bb19-18b04b13aff5',100,0,TO_TIMESTAMP('2013-01-23 18:19:55','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:19:55','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:19:56 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201716 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:19:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200068,1,'N','N',208439,'Y',201717,'N','The Processed checkbox indicates that a document has been processed.','D','The document has been processed','Processed','N','Y','564ec798-4a21-4148-9ec3-1a787b5d33bd',100,0,TO_TIMESTAMP('2013-01-23 18:19:56','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:19:56','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:19:57 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201717 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:19:58 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,EntityType,Name,IsFieldOnly,IsDisplayed,AD_Field_UU,UpdatedBy,AD_Org_ID,Created,AD_Client_ID,CreatedBy,Updated,IsActive) VALUES ('N',200068,36,'N','N',208435,'Y',201718,'N','D','X_DepositBatchLine_UU','N','Y','3a4a08ce-5c9e-4eea-9860-a4d121eaa3d3',100,0,TO_TIMESTAMP('2013-01-23 18:19:57','YYYY-MM-DD HH24:MI:SS'),0,100,TO_TIMESTAMP('2013-01-23 18:19:57','YYYY-MM-DD HH24:MI:SS'),'Y') +; + +-- Jan 23, 2013 6:19:58 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=201718 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jan 23, 2013 6:20:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=0,IsDisplayed='N' WHERE AD_Field_ID=201716 +; + +-- Jan 23, 2013 6:20:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=0,IsDisplayed='N' WHERE AD_Field_ID=201718 +; + +-- Jan 23, 2013 6:20:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=10,IsDisplayed='Y' WHERE AD_Field_ID=201709 +; + +-- Jan 23, 2013 6:20:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=20,IsDisplayed='Y' WHERE AD_Field_ID=201713 +; + +-- Jan 23, 2013 6:20:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=30,IsDisplayed='Y' WHERE AD_Field_ID=201710 +; + +-- Jan 23, 2013 6:20:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=40,IsDisplayed='Y' WHERE AD_Field_ID=201712 +; + +-- Jan 23, 2013 6:20:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=50,IsDisplayed='Y' WHERE AD_Field_ID=201714 +; + +-- Jan 23, 2013 6:20:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=60,IsDisplayed='Y' WHERE AD_Field_ID=201715 +; + +-- Jan 23, 2013 6:20:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=70,IsDisplayed='Y' WHERE AD_Field_ID=201708 +; + +-- Jan 23, 2013 6:20:23 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNo=80,IsDisplayed='Y' WHERE AD_Field_ID=201717 +; + +-- Jan 23, 2013 6:20:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=201716 +; + +-- Jan 23, 2013 6:20:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=201718 +; + +-- Jan 23, 2013 6:20:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=10,IsDisplayedGrid='Y' WHERE AD_Field_ID=201709 +; + +-- Jan 23, 2013 6:20:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=20,IsDisplayedGrid='Y' WHERE AD_Field_ID=201713 +; + +-- Jan 23, 2013 6:20:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=30,IsDisplayedGrid='Y' WHERE AD_Field_ID=201710 +; + +-- Jan 23, 2013 6:20:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=40,IsDisplayedGrid='Y' WHERE AD_Field_ID=201712 +; + +-- Jan 23, 2013 6:20:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=50,IsDisplayedGrid='Y' WHERE AD_Field_ID=201714 +; + +-- Jan 23, 2013 6:20:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=60,IsDisplayedGrid='Y' WHERE AD_Field_ID=201715 +; + +-- Jan 23, 2013 6:20:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=70,IsDisplayedGrid='Y' WHERE AD_Field_ID=201708 +; + +-- Jan 23, 2013 6:20:37 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET SeqNoGrid=80,IsDisplayedGrid='Y' WHERE AD_Field_ID=201717 +; + +-- Jan 23, 2013 6:21:03 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET ColumnSpan=2,Updated=TO_TIMESTAMP('2013-01-23 18:21:03','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201709 +; + +-- Jan 23, 2013 6:21:22 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET IsSameLine='Y', XPosition=4, ColumnSpan=2,Updated=TO_TIMESTAMP('2013-01-23 18:21:22','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201713 +; + +-- Jan 23, 2013 6:21:29 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET ColumnSpan=2,Updated=TO_TIMESTAMP('2013-01-23 18:21:29','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201710 +; + +-- Jan 23, 2013 6:21:40 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET ColumnSpan=2,Updated=TO_TIMESTAMP('2013-01-23 18:21:40','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201712 +; + +-- Jan 23, 2013 6:21:49 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET ColumnSpan=2,Updated=TO_TIMESTAMP('2013-01-23 18:21:49','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201714 +; + +-- Jan 23, 2013 6:22:07 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET IsSameLine='Y', IsReadOnly='Y', XPosition=4, ColumnSpan=2,Updated=TO_TIMESTAMP('2013-01-23 18:22:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201715 +; + +-- Jan 23, 2013 6:22:21 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET XPosition=2, ColumnSpan=2,Updated=TO_TIMESTAMP('2013-01-23 18:22:21','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201708 +; + +-- Jan 23, 2013 6:22:35 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_Field SET IsSameLine='Y', IsReadOnly='Y', XPosition=5, ColumnSpan=2,Updated=TO_TIMESTAMP('2013-01-23 18:22:35','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=201717 +; + +-- Jan 23, 2013 6:23:56 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Menu (AD_Window_ID,AD_Menu_ID,IsSummary,IsSOTrx,IsReadOnly,EntityType,AD_Menu_UU,IsCentrallyMaintained,Name,"action",IsActive,AD_Client_ID,CreatedBy,Updated,AD_Org_ID,Created,UpdatedBy) VALUES (200031,200035,'N','N','N','D','e84239a8-560a-4f7c-ba32-fb2e70f1c616','Y','Receipts Into Batch','W','Y',0,100,TO_TIMESTAMP('2013-01-23 18:23:55','YYYY-MM-DD HH24:MI:SS'),0,TO_TIMESTAMP('2013-01-23 18:23:55','YYYY-MM-DD HH24:MI:SS'),100) +; + +-- Jan 23, 2013 6:23:56 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_Menu_Trl (AD_Language,AD_Menu_ID, Name,Description, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Menu_Trl_UU ) SELECT l.AD_Language,t.AD_Menu_ID, t.Name,t.Description, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Menu t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Menu_ID=200035 AND NOT EXISTS (SELECT * FROM AD_Menu_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Menu_ID=t.AD_Menu_ID) +; + +-- Jan 23, 2013 6:23:56 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +INSERT INTO AD_TreeNodeMM (AD_Client_ID,AD_Org_ID, IsActive,Created,CreatedBy,Updated,UpdatedBy, AD_Tree_ID, Node_ID, Parent_ID, SeqNo, AD_TreeNodeMM_UU) SELECT t.AD_Client_ID, 0, 'Y', CURRENT_TIMESTAMP, 100, CURRENT_TIMESTAMP, 100,t.AD_Tree_ID, 200035, 0, 999, Generate_UUID() FROM AD_Tree t WHERE t.AD_Client_ID=0 AND t.IsActive='Y' AND t.IsAllNodes='Y' AND t.TreeType='MM' AND NOT EXISTS (SELECT * FROM AD_TreeNodeMM e WHERE e.AD_Tree_ID=t.AD_Tree_ID AND Node_ID=200035) +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=0, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=200035 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=1, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=241 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=2, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=288 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=3, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=432 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=4, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=243 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=5, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=413 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=6, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=538 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=7, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=462 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=8, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=505 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=9, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=200023 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=10, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=235 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=11, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=511 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=12, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=245 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=13, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=251 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=14, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=246 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=15, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=509 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=16, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=510 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=17, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=496 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=18, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=497 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=19, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=304 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=20, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=255 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=21, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=286 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=22, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=287 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=23, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=438 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=24, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=234 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=25, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=244 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=26, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53313 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=27, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53314 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=28, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53190 +; + +-- Jan 23, 2013 6:24:08 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=29, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53187 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=0, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=200035 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=1, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=241 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=2, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=288 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=3, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=432 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=4, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=243 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=5, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=413 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=6, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=538 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=7, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=462 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=8, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=505 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=9, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=200023 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=10, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=235 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=11, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=511 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=12, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=245 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=13, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=251 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=14, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=246 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=15, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=509 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=16, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=510 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=17, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=496 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=18, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=497 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=19, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=304 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=20, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=255 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=21, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=286 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=22, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=287 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=23, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=438 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=24, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=200035 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=25, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=234 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=26, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=244 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=27, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53313 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=28, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53314 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=29, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53190 +; + +-- Jan 23, 2013 6:24:34 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=30, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53187 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=0, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=241 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=1, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=288 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=2, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=432 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=3, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=243 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=4, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=413 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=5, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=538 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=6, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=462 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=7, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=505 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=8, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=200023 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=9, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=235 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=10, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=511 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=11, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=245 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=12, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=251 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=13, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=246 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=14, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=509 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=15, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=510 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=16, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=496 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=17, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=497 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=18, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=304 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=19, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=255 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=20, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=286 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=21, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=287 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=22, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=438 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=23, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=200035 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=24, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=234 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=25, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=200035 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=26, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=244 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=27, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53313 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=28, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53314 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=29, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53190 +; + +-- Jan 23, 2013 6:24:38 PM SGT +-- Ticket #1001569: Move receipts into batch from QS to Idempiere +UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=30, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53187 +; + +SELECT register_migration_script('201301251920_TICKET-1001569.sql') FROM dual +; \ No newline at end of file diff --git a/org.adempiere.base/src/org/adempiere/process/DepositBatchClose.java b/org.adempiere.base/src/org/adempiere/process/DepositBatchClose.java new file mode 100644 index 0000000000..c79bc3e0b1 --- /dev/null +++ b/org.adempiere.base/src/org/adempiere/process/DepositBatchClose.java @@ -0,0 +1,91 @@ +/********************************************************************** +* This file is part of Adempiere ERP Bazaar * +* http://www.adempiere.org * +* * +* Copyright (C) Alejandro Falcone * +* Copyright (C) Contributors * +* * +* This program is free software; you can redistribute it and/or * +* modify it under the terms of the GNU General Public License * +* as published by the Free Software Foundation; either version 2 * +* of the License, or (at your option) any later version. * +* * +* This program is distributed in the hope that it will be useful, * +* but WITHOUT ANY WARRANTY; without even the implied warranty of * +* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * +* GNU General Public License for more details. * +* * +* You should have received a copy of the GNU General Public License * +* along with this program; if not, write to the Free Software * +* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, * +* MA 02110-1301, USA. * +* * +* Contributors: * +* - Alejandro Falcone (afalcone@users.sourceforge.net) * +* http://www.openbiz.com.ar * +* * +* Sponsors: * +* - Idalica Inc. (http://www.idalica.com) * +***********************************************************************/ +package org.adempiere.process; + + +import java.util.logging.*; +import org.compiere.model.*; +import org.compiere.process.ProcessInfoParameter; +import org.compiere.process.SvrProcess; + +/** + * Close Deposit Batch. + * + * @author Alejandro Falcone + * @version $Id: DepositBatchClose.java,v 1.2 2007/07/03 00:51:01 afalcone Exp $ + */ +public class DepositBatchClose extends SvrProcess +{ + /** Deposit Batch from Record */ + private int m_X_DepositBatch_ID = 0; + + /** + * Prepare - e.g., get Parameters. + */ + protected void prepare() + { + ProcessInfoParameter[] para = getParameter(); + for (int i = 0; i < para.length; i++) + { + String name = para[i].getParameterName(); + if (para[i].getParameter() == null) + ; + else + log.log(Level.SEVERE, "prepare - Unknown Parameter: " + name); + } + m_X_DepositBatch_ID = getRecord_ID(); + } // prepare + + /** + * Perform process. + * @return Message (translated text) + * @throws Exception if not successful + */ + protected String doIt() throws Exception + { + MDepositBatch depositbatch = new MDepositBatch (getCtx(), m_X_DepositBatch_ID, get_TrxName()); + log.info("doIt - " + depositbatch); + + MDepositBatchLine[] depositbatchLines = depositbatch.getLines(); + + // Close lines + for (int line = 0; line < depositbatchLines.length; line++) + { + depositbatchLines[line].setProcessed(true); + depositbatchLines[line].save(); + } + + depositbatch.setProcessed(true); + depositbatch.save(); + + return ""; + } // doIt + +} // DepositBatchClose diff --git a/org.adempiere.base/src/org/compiere/model/I_C_BankStatement.java b/org.adempiere.base/src/org/compiere/model/I_C_BankStatement.java index fa40d567c3..f51ea00510 100644 --- a/org.adempiere.base/src/org/compiere/model/I_C_BankStatement.java +++ b/org.adempiere.base/src/org/compiere/model/I_C_BankStatement.java @@ -395,4 +395,13 @@ public interface I_C_BankStatement * User who updated this records */ public int getUpdatedBy(); + + /** Column name X_CreateFromBatch */ + public static final String COLUMNNAME_X_CreateFromBatch = "X_CreateFromBatch"; + + /** Set Create From Batch */ + public void setX_CreateFromBatch (String X_CreateFromBatch); + + /** Get Create From Batch */ + public String getX_CreateFromBatch(); } diff --git a/org.adempiere.base/src/org/compiere/model/I_X_DepositBatch.java b/org.adempiere.base/src/org/compiere/model/I_X_DepositBatch.java new file mode 100644 index 0000000000..335c3be2b9 --- /dev/null +++ b/org.adempiere.base/src/org/compiere/model/I_X_DepositBatch.java @@ -0,0 +1,262 @@ +/****************************************************************************** + * Product: iDempiere ERP & CRM Smart Business Solution * + * Copyright (C) 1999-2012 ComPiere, Inc. All Rights Reserved. * + * This program is free software, you can redistribute it and/or modify it * + * under the terms version 2 of the GNU General Public License as published * + * by the Free Software Foundation. This program is distributed in the hope * + * that it will be useful, but WITHOUT ANY WARRANTY, without even the implied * + * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * + * See the GNU General Public License for more details. * + * You should have received a copy of the GNU General Public License along * + * with this program, if not, write to the Free Software Foundation, Inc., * + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. * + * For the text or an alternative of this public license, you may reach us * + * ComPiere, Inc., 2620 Augustine Dr. #245, Santa Clara, CA 95054, USA * + * or via info@compiere.org or http://www.compiere.org/license.html * + *****************************************************************************/ +package org.compiere.model; + +import java.math.BigDecimal; +import java.sql.Timestamp; +import org.compiere.util.KeyNamePair; + +/** Generated Interface for X_DepositBatch + * @author iDempiere (generated) + * @version Release 1.0a + */ +public interface I_X_DepositBatch +{ + + /** TableName=X_DepositBatch */ + public static final String Table_Name = "X_DepositBatch"; + + /** AD_Table_ID=200056 */ + public static final int Table_ID = 200056; + + KeyNamePair Model = new KeyNamePair(Table_ID, Table_Name); + + /** AccessLevel = 3 - Client - Org + */ + BigDecimal accessLevel = BigDecimal.valueOf(3); + + /** Load Meta Data */ + + /** Column name AD_Client_ID */ + public static final String COLUMNNAME_AD_Client_ID = "AD_Client_ID"; + + /** Get Client. + * Client/Tenant for this installation. + */ + public int getAD_Client_ID(); + + /** Column name AD_Org_ID */ + public static final String COLUMNNAME_AD_Org_ID = "AD_Org_ID"; + + /** Set Organization. + * Organizational entity within client + */ + public void setAD_Org_ID (int AD_Org_ID); + + /** Get Organization. + * Organizational entity within client + */ + public int getAD_Org_ID(); + + /** Column name C_BankAccount_ID */ + public static final String COLUMNNAME_C_BankAccount_ID = "C_BankAccount_ID"; + + /** Set Bank Account. + * Account at the Bank + */ + public void setC_BankAccount_ID (int C_BankAccount_ID); + + /** Get Bank Account. + * Account at the Bank + */ + public int getC_BankAccount_ID(); + + public org.compiere.model.I_C_BankAccount getC_BankAccount() throws RuntimeException; + + /** Column name C_DocType_ID */ + public static final String COLUMNNAME_C_DocType_ID = "C_DocType_ID"; + + /** Set Document Type. + * Document type or rules + */ + public void setC_DocType_ID (int C_DocType_ID); + + /** Get Document Type. + * Document type or rules + */ + public int getC_DocType_ID(); + + public org.compiere.model.I_C_DocType getC_DocType() throws RuntimeException; + + /** Column name Created */ + public static final String COLUMNNAME_Created = "Created"; + + /** Get Created. + * Date this record was created + */ + public Timestamp getCreated(); + + /** Column name CreatedBy */ + public static final String COLUMNNAME_CreatedBy = "CreatedBy"; + + /** Get Created By. + * User who created this records + */ + public int getCreatedBy(); + + /** Column name CreateFrom */ + public static final String COLUMNNAME_CreateFrom = "CreateFrom"; + + /** Set Create lines from. + * Process which will generate a new document lines based on an existing document + */ + public void setCreateFrom (String CreateFrom); + + /** Get Create lines from. + * Process which will generate a new document lines based on an existing document + */ + public String getCreateFrom(); + + /** Column name DateDeposit */ + public static final String COLUMNNAME_DateDeposit = "DateDeposit"; + + /** Set Deposit Date */ + public void setDateDeposit (Timestamp DateDeposit); + + /** Get Deposit Date */ + public Timestamp getDateDeposit(); + + /** Column name DateDoc */ + public static final String COLUMNNAME_DateDoc = "DateDoc"; + + /** Set Document Date. + * Date of the Document + */ + public void setDateDoc (Timestamp DateDoc); + + /** Get Document Date. + * Date of the Document + */ + public Timestamp getDateDoc(); + + /** Column name DepositAmt */ + public static final String COLUMNNAME_DepositAmt = "DepositAmt"; + + /** Set Deposit Amount */ + public void setDepositAmt (BigDecimal DepositAmt); + + /** Get Deposit Amount */ + public BigDecimal getDepositAmt(); + + /** Column name Description */ + public static final String COLUMNNAME_Description = "Description"; + + /** Set Description. + * Optional short description of the record + */ + public void setDescription (String Description); + + /** Get Description. + * Optional short description of the record + */ + public String getDescription(); + + /** Column name DocStatus */ + public static final String COLUMNNAME_DocStatus = "DocStatus"; + + /** Set Document Status. + * The current status of the document + */ + public void setDocStatus (String DocStatus); + + /** Get Document Status. + * The current status of the document + */ + public String getDocStatus(); + + /** Column name DocumentNo */ + public static final String COLUMNNAME_DocumentNo = "DocumentNo"; + + /** Set Document No. + * Document sequence number of the document + */ + public void setDocumentNo (String DocumentNo); + + /** Get Document No. + * Document sequence number of the document + */ + public String getDocumentNo(); + + /** Column name IsActive */ + public static final String COLUMNNAME_IsActive = "IsActive"; + + /** Set Active. + * The record is active in the system + */ + public void setIsActive (boolean IsActive); + + /** Get Active. + * The record is active in the system + */ + public boolean isActive(); + + /** Column name Processed */ + public static final String COLUMNNAME_Processed = "Processed"; + + /** Set Processed. + * The document has been processed + */ + public void setProcessed (boolean Processed); + + /** Get Processed. + * The document has been processed + */ + public boolean isProcessed(); + + /** Column name Processing */ + public static final String COLUMNNAME_Processing = "Processing"; + + /** Set Process Now */ + public void setProcessing (boolean Processing); + + /** Get Process Now */ + public boolean isProcessing(); + + /** Column name Updated */ + public static final String COLUMNNAME_Updated = "Updated"; + + /** Get Updated. + * Date this record was updated + */ + public Timestamp getUpdated(); + + /** Column name UpdatedBy */ + public static final String COLUMNNAME_UpdatedBy = "UpdatedBy"; + + /** Get Updated By. + * User who updated this records + */ + public int getUpdatedBy(); + + /** Column name X_DepositBatch_ID */ + public static final String COLUMNNAME_X_DepositBatch_ID = "X_DepositBatch_ID"; + + /** Set Deposit Batch */ + public void setX_DepositBatch_ID (int X_DepositBatch_ID); + + /** Get Deposit Batch */ + public int getX_DepositBatch_ID(); + + /** Column name X_DepositBatch_UU */ + public static final String COLUMNNAME_X_DepositBatch_UU = "X_DepositBatch_UU"; + + /** Set X_DepositBatch_UU */ + public void setX_DepositBatch_UU (String X_DepositBatch_UU); + + /** Get X_DepositBatch_UU */ + public String getX_DepositBatch_UU(); +} diff --git a/org.adempiere.base/src/org/compiere/model/I_X_DepositBatchLine.java b/org.adempiere.base/src/org/compiere/model/I_X_DepositBatchLine.java new file mode 100644 index 0000000000..25574f26d5 --- /dev/null +++ b/org.adempiere.base/src/org/compiere/model/I_X_DepositBatchLine.java @@ -0,0 +1,201 @@ +/****************************************************************************** + * Product: iDempiere ERP & CRM Smart Business Solution * + * Copyright (C) 1999-2012 ComPiere, Inc. All Rights Reserved. * + * This program is free software, you can redistribute it and/or modify it * + * under the terms version 2 of the GNU General Public License as published * + * by the Free Software Foundation. This program is distributed in the hope * + * that it will be useful, but WITHOUT ANY WARRANTY, without even the implied * + * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * + * See the GNU General Public License for more details. * + * You should have received a copy of the GNU General Public License along * + * with this program, if not, write to the Free Software Foundation, Inc., * + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. * + * For the text or an alternative of this public license, you may reach us * + * ComPiere, Inc., 2620 Augustine Dr. #245, Santa Clara, CA 95054, USA * + * or via info@compiere.org or http://www.compiere.org/license.html * + *****************************************************************************/ +package org.compiere.model; + +import java.math.BigDecimal; +import java.sql.Timestamp; +import org.compiere.util.KeyNamePair; + +/** Generated Interface for X_DepositBatchLine + * @author iDempiere (generated) + * @version Release 1.0a + */ +public interface I_X_DepositBatchLine +{ + + /** TableName=X_DepositBatchLine */ + public static final String Table_Name = "X_DepositBatchLine"; + + /** AD_Table_ID=200057 */ + public static final int Table_ID = 200057; + + KeyNamePair Model = new KeyNamePair(Table_ID, Table_Name); + + /** AccessLevel = 3 - Client - Org + */ + BigDecimal accessLevel = BigDecimal.valueOf(3); + + /** Load Meta Data */ + + /** Column name AD_Client_ID */ + public static final String COLUMNNAME_AD_Client_ID = "AD_Client_ID"; + + /** Get Client. + * Client/Tenant for this installation. + */ + public int getAD_Client_ID(); + + /** Column name AD_Org_ID */ + public static final String COLUMNNAME_AD_Org_ID = "AD_Org_ID"; + + /** Set Organization. + * Organizational entity within client + */ + public void setAD_Org_ID (int AD_Org_ID); + + /** Get Organization. + * Organizational entity within client + */ + public int getAD_Org_ID(); + + /** Column name C_Payment_ID */ + public static final String COLUMNNAME_C_Payment_ID = "C_Payment_ID"; + + /** Set Payment. + * Payment identifier + */ + public void setC_Payment_ID (int C_Payment_ID); + + /** Get Payment. + * Payment identifier + */ + public int getC_Payment_ID(); + + public org.compiere.model.I_C_Payment getC_Payment() throws RuntimeException; + + /** Column name Created */ + public static final String COLUMNNAME_Created = "Created"; + + /** Get Created. + * Date this record was created + */ + public Timestamp getCreated(); + + /** Column name CreatedBy */ + public static final String COLUMNNAME_CreatedBy = "CreatedBy"; + + /** Get Created By. + * User who created this records + */ + public int getCreatedBy(); + + /** Column name IsActive */ + public static final String COLUMNNAME_IsActive = "IsActive"; + + /** Set Active. + * The record is active in the system + */ + public void setIsActive (boolean IsActive); + + /** Get Active. + * The record is active in the system + */ + public boolean isActive(); + + /** Column name Line */ + public static final String COLUMNNAME_Line = "Line"; + + /** Set Line No. + * Unique line for this document + */ + public void setLine (int Line); + + /** Get Line No. + * Unique line for this document + */ + public int getLine(); + + /** Column name PayAmt */ + public static final String COLUMNNAME_PayAmt = "PayAmt"; + + /** Set Payment amount. + * Amount being paid + */ + public void setPayAmt (BigDecimal PayAmt); + + /** Get Payment amount. + * Amount being paid + */ + public BigDecimal getPayAmt(); + + /** Column name Processed */ + public static final String COLUMNNAME_Processed = "Processed"; + + /** Set Processed. + * The document has been processed + */ + public void setProcessed (boolean Processed); + + /** Get Processed. + * The document has been processed + */ + public boolean isProcessed(); + + /** Column name Processing */ + public static final String COLUMNNAME_Processing = "Processing"; + + /** Set Process Now */ + public void setProcessing (boolean Processing); + + /** Get Process Now */ + public boolean isProcessing(); + + /** Column name Updated */ + public static final String COLUMNNAME_Updated = "Updated"; + + /** Get Updated. + * Date this record was updated + */ + public Timestamp getUpdated(); + + /** Column name UpdatedBy */ + public static final String COLUMNNAME_UpdatedBy = "UpdatedBy"; + + /** Get Updated By. + * User who updated this records + */ + public int getUpdatedBy(); + + /** Column name X_DepositBatch_ID */ + public static final String COLUMNNAME_X_DepositBatch_ID = "X_DepositBatch_ID"; + + /** Set Deposit Batch */ + public void setX_DepositBatch_ID (int X_DepositBatch_ID); + + /** Get Deposit Batch */ + public int getX_DepositBatch_ID(); + + public org.compiere.model.I_X_DepositBatch getX_DepositBatch() throws RuntimeException; + + /** Column name X_DepositBatchLine_ID */ + public static final String COLUMNNAME_X_DepositBatchLine_ID = "X_DepositBatchLine_ID"; + + /** Set Deposit Batch Line */ + public void setX_DepositBatchLine_ID (int X_DepositBatchLine_ID); + + /** Get Deposit Batch Line */ + public int getX_DepositBatchLine_ID(); + + /** Column name X_DepositBatchLine_UU */ + public static final String COLUMNNAME_X_DepositBatchLine_UU = "X_DepositBatchLine_UU"; + + /** Set X_DepositBatchLine_UU */ + public void setX_DepositBatchLine_UU (String X_DepositBatchLine_UU); + + /** Get X_DepositBatchLine_UU */ + public String getX_DepositBatchLine_UU(); +} diff --git a/org.adempiere.base/src/org/compiere/model/MDepositBatch.java b/org.adempiere.base/src/org/compiere/model/MDepositBatch.java new file mode 100644 index 0000000000..fd637c0382 --- /dev/null +++ b/org.adempiere.base/src/org/compiere/model/MDepositBatch.java @@ -0,0 +1,325 @@ +/********************************************************************** +* This file is part of Adempiere ERP Bazaar * +* http://www.adempiere.org * +* * +* Copyright (C) Alejandro Falcone * +* Copyright (C) Contributors * +* * +* This program is free software; you can redistribute it and/or * +* modify it under the terms of the GNU General Public License * +* as published by the Free Software Foundation; either version 2 * +* of the License, or (at your option) any later version. * +* * +* This program is distributed in the hope that it will be useful, * +* but WITHOUT ANY WARRANTY; without even the implied warranty of * +* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * +* GNU General Public License for more details. * +* * +* You should have received a copy of the GNU General Public License * +* along with this program; if not, write to the Free Software * +* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, * +* MA 02110-1301, USA. * +* * +* Contributors: * +* - Alejandro Falcone (afalcone@users.sourceforge.net) * +* http://www.openbiz.com.ar * +* * +* Sponsors: * +* - Idalica Inc. (http://www.idalica.com) * +***********************************************************************/ + +package org.compiere.model; + +import java.io.File; +import java.math.BigDecimal; +import java.sql.PreparedStatement; +import java.sql.ResultSet; +import java.sql.SQLException; +import java.sql.Timestamp; +import java.util.ArrayList; +import java.util.Properties; +import java.util.logging.Level; + +import org.compiere.util.DB; + +/** + * Deposit Batch Model + * + * @author Alejandro Falcone + * @version $Id: MDepositBatch.java,v 1.3 2007/06/28 00:51:03 afalcone Exp $ + */ +public class MDepositBatch extends X_X_DepositBatch +{ + /** + * + */ + private static final long serialVersionUID = -977397802747749777L; + + /** + * Create & Load existing Persistent Object + * @param ctx context + * @param X_DepositBatch_ID The unique ID of the object + * @param trxName transaction name + */ + public MDepositBatch (Properties ctx, int X_DepositBatch_ID, String trxName) + { + super (ctx, X_DepositBatch_ID, trxName); + if (X_DepositBatch_ID == 0) + { + setDocStatus (DOCSTATUS_Drafted); + setProcessed (false); + setProcessing (false); + setDepositAmt(new BigDecimal(0)); + } + } // MDepositBatch + + + /** + * Load Constructor + * @param ctx context + * @param rs result set + * @param trxName transaction + */ + public MDepositBatch (Properties ctx, ResultSet rs, String trxName) + { + super(ctx, rs, trxName); + } // MDepositBatch + + /** + * Copy Constructor. + * Dos not copy: Dates/Period + * @param original original + */ + public MDepositBatch (MDepositBatch original) + { + this (original.getCtx(), 0, original.get_TrxName()); + setClientOrg(original); + setX_DepositBatch_ID(original.getX_DepositBatch_ID()); + + setDescription(original.getDescription()); + setC_DocType_ID(original.getC_DocType_ID()); + + setDateDoc(original.getDateDoc()); + setDateDeposit(original.getDateDeposit()); + setDepositAmt(original.getDepositAmt()); + } // MDepositBatch + + public int getX_DepositBatch_ID() + { + Integer ii = (Integer)get_Value("X_DepositBatch_ID"); + if (ii == null) + return 0; + return ii.intValue(); + } + + public void setX_DepositBatch_ID(int X_DepositBatch_ID) + { + set_Value("X_DepositBatch_ID", Integer.valueOf(X_DepositBatch_ID)); + } + + /** + * Overwrite Client/Org if required + * @param AD_Client_ID client + * @param AD_Org_ID org + */ + public void setClientOrg (int AD_Client_ID, int AD_Org_ID) + { + super.setClientOrg(AD_Client_ID, AD_Org_ID); + } // setClientOrg + + /** + * Set Accounting Date. + * Set also Period if not set earlier + * @param DateAcct date + */ + public void setDateAcct (Timestamp DateAcct) + { + super.setDateDeposit(DateAcct); + if (DateAcct == null) + return; + } // setDateAcct + + + /** Process Message */ + private String m_processMsg = null; + /** Just Prepared Flag */ +// private boolean m_justPrepared = false; + + /** + * Unlock Document. + * @return true if success + */ + public boolean unlockIt() + { + log.info("unlockIt - " + toString()); + setProcessing(false); + return true; + } // unlockIt + + /** + * Invalidate Document + * @return true if success + */ + public boolean invalidateIt() + { + log.info("invalidateIt - " + toString()); + return true; + } // invalidateIt + + + + /** + * Void Document. + * @return false + */ + public boolean voidIt() + { + log.info("voidIt - " + toString()); + // Before Void + m_processMsg = ModelValidationEngine.get().fireDocValidate(this,ModelValidator.TIMING_BEFORE_VOID); + if (m_processMsg != null) + return false; + // After Void + m_processMsg = ModelValidationEngine.get().fireDocValidate(this,ModelValidator.TIMING_AFTER_VOID); + if (m_processMsg != null) + return false; + + return false; + } // voidIt + + + /** + * String Representation + * @return info + */ + public String toString () + { + StringBuffer sb = new StringBuffer ("MDepositBatch["); + sb.append(get_ID()).append(",").append(getDescription()) + .append(",Amount=").append(getDepositAmt()) + .append ("]"); + return sb.toString (); + } // toString + + /** + * Get Document Info + * @return document info (untranslated) + */ + public String getDocumentInfo() + { + MDocType dt = MDocType.get(getCtx(), getC_DocType_ID()); + return dt.getName() + " " + getDocumentNo(); + } // getDocumentInfo + + /** + * Create PDF + * @return File or null + */ + public File createPDF () + { + try + { + File temp = File.createTempFile(get_TableName()+get_ID()+"_", ".pdf"); + return createPDF (temp); + } + catch (Exception e) + { + log.severe("Could not create PDF - " + e.getMessage()); + } + return null; + } // getPDF + + /** + * Create PDF file + * @param file output file + * @return file if success + */ + public File createPDF (File file) + { + // ReportEngine re = ReportEngine.get (getCtx(), ReportEngine.INVOICE, getC_Invoice_ID()); + // if (re == null) + return null; + // return re.getPDF(file); + } // createPDF + + + /** + * Get Process Message + * @return clear text error message + */ + public String getProcessMsg() + { + return m_processMsg; + } // getProcessMsg + + /** + * Get Document Owner (Responsible) + * @return AD_User_ID (Created By) + */ + public int getDoc_User_ID() + { + return getCreatedBy(); + } // getDoc_User_ID + + /** + * Get Document Approval Amount + * @return DR amount + */ + public BigDecimal getApprovalAmt() + { + return getDepositAmt(); + } // getApprovalAmt + + + + /** + * After Delete + * @param success success + * @return success + */ + protected boolean afterDelete (boolean success) + { + if (getX_DepositBatch_ID() != 0 ) + { + String sql = "UPDATE C_Payment p SET X_DepositBatch_ID= 0 WHERE p.X_DepositBatch_ID=?"; + DB.executeUpdate(sql, getX_DepositBatch_ID(), get_TrxName()); + } + + return success; + } // afterDelete + + + /************************************************************************** + * Get Deposit Batch Lines + * @return Array of lines + */ + public MDepositBatchLine[] getLines() + { + ArrayList list = new ArrayList(); + String sql = "SELECT * FROM X_DepositBatchLine WHERE X_DepositBatch_ID=? ORDER BY Line"; + PreparedStatement pstmt = null; + ResultSet rs = null; + try + { + pstmt = DB.prepareStatement(sql, get_TrxName()); + pstmt.setInt(1, getX_DepositBatch_ID()); + rs = pstmt.executeQuery(); + while (rs.next()) + list.add(new MDepositBatchLine (getCtx(), rs, get_TrxName())); + } + catch (SQLException ex) + { + log.log(Level.SEVERE, sql, ex); + } + finally + { + DB.close(rs, pstmt); + } + + // + MDepositBatchLine[] retValue = new MDepositBatchLine[list.size()]; + list.toArray(retValue); + return retValue; + } // getLines + +} // MDepositBatch \ No newline at end of file diff --git a/org.adempiere.base/src/org/compiere/model/MDepositBatchLine.java b/org.adempiere.base/src/org/compiere/model/MDepositBatchLine.java new file mode 100644 index 0000000000..57b42dffd1 --- /dev/null +++ b/org.adempiere.base/src/org/compiere/model/MDepositBatchLine.java @@ -0,0 +1,189 @@ +/********************************************************************** +* This file is part of Adempiere ERP Bazaar * +* http://www.adempiere.org * +* * +* Copyright (C) Alejandro Falcone * +* Copyright (C) Contributors * +* * +* This program is free software; you can redistribute it and/or * +* modify it under the terms of the GNU General Public License * +* as published by the Free Software Foundation; either version 2 * +* of the License, or (at your option) any later version. * +* * +* This program is distributed in the hope that it will be useful, * +* but WITHOUT ANY WARRANTY; without even the implied warranty of * +* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * +* GNU General Public License for more details. * +* * +* You should have received a copy of the GNU General Public License * +* along with this program; if not, write to the Free Software * +* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, * +* MA 02110-1301, USA. * +* * +* Contributors: * +* - Alejandro Falcone (afalcone@users.sourceforge.net) * +* http://www.openbiz.com.ar * +* * +* Sponsors: * +* - Idalica Inc. (http://www.idalica.com) * +***********************************************************************/ + +package org.compiere.model; + +import java.math.BigDecimal; +import java.sql.ResultSet; +import java.util.Properties; + +import org.compiere.util.DB; +import org.compiere.util.Env; + +/** + * Bank Statement Line Model + * + * @author Alejandro Falcone + * @version $Id: MDepositBatchLine.java,v 1.3 2007/07/02 00:51:02 afalcone Exp $ + * + */ + public class MDepositBatchLine extends X_X_DepositBatchLine + { + /** + * + */ + private static final long serialVersionUID = -4461960512392850996L; + + + + /** + * Standard Constructor + * @param ctx context + * @param C_BankStatementLine_ID id + * @param trxName transaction + */ + public MDepositBatchLine (Properties ctx, int X_DepositBatchLine_ID, String trxName) + { + super (ctx, X_DepositBatchLine_ID, trxName); + if (X_DepositBatchLine_ID == 0) + { + setPayAmt(Env.ZERO); + } + } // MDepositBatchLine + + /** + * Load Constructor + * @param ctx context + * @param rs result set + * @param trxName transaction + */ + public MDepositBatchLine (Properties ctx, ResultSet rs, String trxName) + { + super(ctx, rs, trxName); + } // MDepositBatchLine + + /** + * Parent Constructor + * @param statement Bank Statement that the line is part of + */ + public MDepositBatchLine(MDepositBatch statement) + { + this (statement.getCtx(), 0, statement.get_TrxName()); + setClientOrg(statement); + setX_DepositBatch_ID(statement.getX_DepositBatch_ID()); + } // MDepositBatchLine + + /** + * Parent Constructor + * @param statement Deposit Batch that the line is part of + * @param lineNo position of the line within the statement + */ + public MDepositBatchLine(MDepositBatch statement, int lineNo) + { + this (statement); + setLine(lineNo); + } // MDepositBatchLine + + + /** + * Set Payment + * @param payment payment + */ + public void setPayment (MPayment payment) + { + setC_Payment_ID (payment.getC_Payment_ID()); + // + BigDecimal amt = payment.getPayAmt(true); + setPayAmt(amt); + // + } // setPayment + + /** + * Before Save + * @param newRecord new + * @return true + */ + protected boolean beforeSave (boolean newRecord) + { + // Set Line No + if (getLine() == 0) + { + String sql = "SELECT COALESCE(MAX(Line),0)+10 AS DefaultValue FROM X_DepositBatchLine WHERE X_DepositBatch_ID=?"; + int ii = DB.getSQLValue (get_TrxName(), sql, getX_DepositBatch_ID()); + setLine (ii); + } + + // Set DepositBatch_ID into C_Payment table + if (getC_Payment_ID() != 0 ) + { + String sql = "UPDATE C_Payment p SET X_DepositBatch_ID=? WHERE p.C_Payment_ID=?"; + DB.executeUpdate(sql, new Object[] {getX_DepositBatch_ID(), getC_Payment_ID()}, false, get_TrxName()); + } + // + + return true; + } // beforeSave + + + /** + * After Save + * @param newRecord new + * @param success success + * @return success + */ + protected boolean afterSave (boolean newRecord, boolean success) + { + updateHeader(); + return success; + } // afterSave + + /** + * After Delete + * @param success success + * @return success + */ + protected boolean afterDelete (boolean success) + { + updateHeader(); + if (getC_Payment_ID() != 0 ) + { + String sql = "UPDATE C_Payment p SET X_DepositBatch_ID= 0 WHERE p.C_Payment_ID=?"; + DB.executeUpdate(sql, getC_Payment_ID(), get_TrxName()); + } + + return success; + } // afterDelete + + + + /** + * Update Header + */ + private void updateHeader() + { + StringBuilder sql = new StringBuilder(); + sql.append("UPDATE X_DepositBatch dp"); + sql.append(" SET DepositAmt=(SELECT COALESCE(SUM(PayAmt),0) FROM X_DepositBatchLine dpl "); + sql.append("WHERE dpl.X_DepositBatch_ID=dp.X_DepositBatch_ID AND dpl.IsActive='Y') "); + sql.append("WHERE X_DepositBatch_ID=?"); + DB.executeUpdate(sql.toString(), getX_DepositBatch_ID(), get_TrxName()); + } // updateHeader + + } // MDepositBatchLine diff --git a/org.adempiere.base/src/org/compiere/model/X_C_BankStatement.java b/org.adempiere.base/src/org/compiere/model/X_C_BankStatement.java index b23984d113..4b53803df3 100644 --- a/org.adempiere.base/src/org/compiere/model/X_C_BankStatement.java +++ b/org.adempiere.base/src/org/compiere/model/X_C_BankStatement.java @@ -33,7 +33,7 @@ public class X_C_BankStatement extends PO implements I_C_BankStatement, I_Persis /** * */ - private static final long serialVersionUID = 20121212L; + private static final long serialVersionUID = 20130123L; /** Standard Constructor */ public X_C_BankStatement (Properties ctx, int C_BankStatement_ID, String trxName) @@ -602,4 +602,18 @@ public class X_C_BankStatement extends PO implements I_C_BankStatement, I_Persis return Env.ZERO; return bd; } + + /** Set Create From Batch. + @param X_CreateFromBatch Create From Batch */ + public void setX_CreateFromBatch (String X_CreateFromBatch) + { + set_Value (COLUMNNAME_X_CreateFromBatch, X_CreateFromBatch); + } + + /** Get Create From Batch. + @return Create From Batch */ + public String getX_CreateFromBatch () + { + return (String)get_Value(COLUMNNAME_X_CreateFromBatch); + } } \ No newline at end of file diff --git a/org.adempiere.base/src/org/compiere/model/X_X_DepositBatch.java b/org.adempiere.base/src/org/compiere/model/X_X_DepositBatch.java new file mode 100644 index 0000000000..c86cb7a4d3 --- /dev/null +++ b/org.adempiere.base/src/org/compiere/model/X_X_DepositBatch.java @@ -0,0 +1,372 @@ +/****************************************************************************** + * Product: iDempiere ERP & CRM Smart Business Solution * + * Copyright (C) 1999-2012 ComPiere, Inc. All Rights Reserved. * + * This program is free software, you can redistribute it and/or modify it * + * under the terms version 2 of the GNU General Public License as published * + * by the Free Software Foundation. This program is distributed in the hope * + * that it will be useful, but WITHOUT ANY WARRANTY, without even the implied * + * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * + * See the GNU General Public License for more details. * + * You should have received a copy of the GNU General Public License along * + * with this program, if not, write to the Free Software Foundation, Inc., * + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. * + * For the text or an alternative of this public license, you may reach us * + * ComPiere, Inc., 2620 Augustine Dr. #245, Santa Clara, CA 95054, USA * + * or via info@compiere.org or http://www.compiere.org/license.html * + *****************************************************************************/ +/** Generated Model - DO NOT CHANGE */ +package org.compiere.model; + +import java.math.BigDecimal; +import java.sql.ResultSet; +import java.sql.Timestamp; +import java.util.Properties; +import org.compiere.util.Env; +import org.compiere.util.KeyNamePair; + +/** Generated Model for X_DepositBatch + * @author iDempiere (generated) + * @version Release 1.0a - $Id$ */ +public class X_X_DepositBatch extends PO implements I_X_DepositBatch, I_Persistent +{ + + /** + * + */ + private static final long serialVersionUID = 20130123L; + + /** Standard Constructor */ + public X_X_DepositBatch (Properties ctx, int X_DepositBatch_ID, String trxName) + { + super (ctx, X_DepositBatch_ID, trxName); + /** if (X_DepositBatch_ID == 0) + { + setC_BankAccount_ID (0); + setC_DocType_ID (0); + setDateDeposit (new Timestamp( System.currentTimeMillis() )); +// @#Date@ + setDateDoc (new Timestamp( System.currentTimeMillis() )); +// @#Date@ + setDepositAmt (Env.ZERO); + setDocStatus (null); +// DR + setDocumentNo (null); + setProcessed (false); + setX_DepositBatch_ID (0); + } */ + } + + /** Load Constructor */ + public X_X_DepositBatch (Properties ctx, ResultSet rs, String trxName) + { + super (ctx, rs, trxName); + } + + /** AccessLevel + * @return 3 - Client - Org + */ + protected int get_AccessLevel() + { + return accessLevel.intValue(); + } + + /** Load Meta Data */ + protected POInfo initPO (Properties ctx) + { + POInfo poi = POInfo.getPOInfo (ctx, Table_ID, get_TrxName()); + return poi; + } + + public String toString() + { + StringBuffer sb = new StringBuffer ("X_X_DepositBatch[") + .append(get_ID()).append("]"); + return sb.toString(); + } + + public org.compiere.model.I_C_BankAccount getC_BankAccount() throws RuntimeException + { + return (org.compiere.model.I_C_BankAccount)MTable.get(getCtx(), org.compiere.model.I_C_BankAccount.Table_Name) + .getPO(getC_BankAccount_ID(), get_TrxName()); } + + /** Set Bank Account. + @param C_BankAccount_ID + Account at the Bank + */ + public void setC_BankAccount_ID (int C_BankAccount_ID) + { + if (C_BankAccount_ID < 1) + set_Value (COLUMNNAME_C_BankAccount_ID, null); + else + set_Value (COLUMNNAME_C_BankAccount_ID, Integer.valueOf(C_BankAccount_ID)); + } + + /** Get Bank Account. + @return Account at the Bank + */ + public int getC_BankAccount_ID () + { + Integer ii = (Integer)get_Value(COLUMNNAME_C_BankAccount_ID); + if (ii == null) + return 0; + return ii.intValue(); + } + + public org.compiere.model.I_C_DocType getC_DocType() throws RuntimeException + { + return (org.compiere.model.I_C_DocType)MTable.get(getCtx(), org.compiere.model.I_C_DocType.Table_Name) + .getPO(getC_DocType_ID(), get_TrxName()); } + + /** Set Document Type. + @param C_DocType_ID + Document type or rules + */ + public void setC_DocType_ID (int C_DocType_ID) + { + if (C_DocType_ID < 0) + set_Value (COLUMNNAME_C_DocType_ID, null); + else + set_Value (COLUMNNAME_C_DocType_ID, Integer.valueOf(C_DocType_ID)); + } + + /** Get Document Type. + @return Document type or rules + */ + public int getC_DocType_ID () + { + Integer ii = (Integer)get_Value(COLUMNNAME_C_DocType_ID); + if (ii == null) + return 0; + return ii.intValue(); + } + + /** Set Create lines from. + @param CreateFrom + Process which will generate a new document lines based on an existing document + */ + public void setCreateFrom (String CreateFrom) + { + set_Value (COLUMNNAME_CreateFrom, CreateFrom); + } + + /** Get Create lines from. + @return Process which will generate a new document lines based on an existing document + */ + public String getCreateFrom () + { + return (String)get_Value(COLUMNNAME_CreateFrom); + } + + /** Set Deposit Date. + @param DateDeposit Deposit Date */ + public void setDateDeposit (Timestamp DateDeposit) + { + set_Value (COLUMNNAME_DateDeposit, DateDeposit); + } + + /** Get Deposit Date. + @return Deposit Date */ + public Timestamp getDateDeposit () + { + return (Timestamp)get_Value(COLUMNNAME_DateDeposit); + } + + /** Set Document Date. + @param DateDoc + Date of the Document + */ + public void setDateDoc (Timestamp DateDoc) + { + set_Value (COLUMNNAME_DateDoc, DateDoc); + } + + /** Get Document Date. + @return Date of the Document + */ + public Timestamp getDateDoc () + { + return (Timestamp)get_Value(COLUMNNAME_DateDoc); + } + + /** Set Deposit Amount. + @param DepositAmt Deposit Amount */ + public void setDepositAmt (BigDecimal DepositAmt) + { + set_Value (COLUMNNAME_DepositAmt, DepositAmt); + } + + /** Get Deposit Amount. + @return Deposit Amount */ + public BigDecimal getDepositAmt () + { + BigDecimal bd = (BigDecimal)get_Value(COLUMNNAME_DepositAmt); + if (bd == null) + return Env.ZERO; + return bd; + } + + /** Set Description. + @param Description + Optional short description of the record + */ + public void setDescription (String Description) + { + set_Value (COLUMNNAME_Description, Description); + } + + /** Get Description. + @return Optional short description of the record + */ + public String getDescription () + { + return (String)get_Value(COLUMNNAME_Description); + } + + /** DocStatus AD_Reference_ID=131 */ + public static final int DOCSTATUS_AD_Reference_ID=131; + /** Drafted = DR */ + public static final String DOCSTATUS_Drafted = "DR"; + /** Completed = CO */ + public static final String DOCSTATUS_Completed = "CO"; + /** Approved = AP */ + public static final String DOCSTATUS_Approved = "AP"; + /** Not Approved = NA */ + public static final String DOCSTATUS_NotApproved = "NA"; + /** Voided = VO */ + public static final String DOCSTATUS_Voided = "VO"; + /** Invalid = IN */ + public static final String DOCSTATUS_Invalid = "IN"; + /** Reversed = RE */ + public static final String DOCSTATUS_Reversed = "RE"; + /** Closed = CL */ + public static final String DOCSTATUS_Closed = "CL"; + /** Unknown = ?? */ + public static final String DOCSTATUS_Unknown = "??"; + /** In Progress = IP */ + public static final String DOCSTATUS_InProgress = "IP"; + /** Waiting Payment = WP */ + public static final String DOCSTATUS_WaitingPayment = "WP"; + /** Waiting Confirmation = WC */ + public static final String DOCSTATUS_WaitingConfirmation = "WC"; + /** Set Document Status. + @param DocStatus + The current status of the document + */ + public void setDocStatus (String DocStatus) + { + + set_Value (COLUMNNAME_DocStatus, DocStatus); + } + + /** Get Document Status. + @return The current status of the document + */ + public String getDocStatus () + { + return (String)get_Value(COLUMNNAME_DocStatus); + } + + /** Set Document No. + @param DocumentNo + Document sequence number of the document + */ + public void setDocumentNo (String DocumentNo) + { + set_Value (COLUMNNAME_DocumentNo, DocumentNo); + } + + /** Get Document No. + @return Document sequence number of the document + */ + public String getDocumentNo () + { + return (String)get_Value(COLUMNNAME_DocumentNo); + } + + /** Get Record ID/ColumnName + @return ID/ColumnName pair + */ + public KeyNamePair getKeyNamePair() + { + return new KeyNamePair(get_ID(), getDocumentNo()); + } + + /** Set Processed. + @param Processed + The document has been processed + */ + public void setProcessed (boolean Processed) + { + set_Value (COLUMNNAME_Processed, Boolean.valueOf(Processed)); + } + + /** Get Processed. + @return The document has been processed + */ + public boolean isProcessed () + { + Object oo = get_Value(COLUMNNAME_Processed); + if (oo != null) + { + if (oo instanceof Boolean) + return ((Boolean)oo).booleanValue(); + return "Y".equals(oo); + } + return false; + } + + /** Set Process Now. + @param Processing Process Now */ + public void setProcessing (boolean Processing) + { + set_Value (COLUMNNAME_Processing, Boolean.valueOf(Processing)); + } + + /** Get Process Now. + @return Process Now */ + public boolean isProcessing () + { + Object oo = get_Value(COLUMNNAME_Processing); + if (oo != null) + { + if (oo instanceof Boolean) + return ((Boolean)oo).booleanValue(); + return "Y".equals(oo); + } + return false; + } + + /** Set Deposit Batch. + @param X_DepositBatch_ID Deposit Batch */ + public void setX_DepositBatch_ID (int X_DepositBatch_ID) + { + if (X_DepositBatch_ID < 1) + set_ValueNoCheck (COLUMNNAME_X_DepositBatch_ID, null); + else + set_ValueNoCheck (COLUMNNAME_X_DepositBatch_ID, Integer.valueOf(X_DepositBatch_ID)); + } + + /** Get Deposit Batch. + @return Deposit Batch */ + public int getX_DepositBatch_ID () + { + Integer ii = (Integer)get_Value(COLUMNNAME_X_DepositBatch_ID); + if (ii == null) + return 0; + return ii.intValue(); + } + + /** Set X_DepositBatch_UU. + @param X_DepositBatch_UU X_DepositBatch_UU */ + public void setX_DepositBatch_UU (String X_DepositBatch_UU) + { + set_Value (COLUMNNAME_X_DepositBatch_UU, X_DepositBatch_UU); + } + + /** Get X_DepositBatch_UU. + @return X_DepositBatch_UU */ + public String getX_DepositBatch_UU () + { + return (String)get_Value(COLUMNNAME_X_DepositBatch_UU); + } +} \ No newline at end of file diff --git a/org.adempiere.base/src/org/compiere/model/X_X_DepositBatchLine.java b/org.adempiere.base/src/org/compiere/model/X_X_DepositBatchLine.java new file mode 100644 index 0000000000..d64008bb5f --- /dev/null +++ b/org.adempiere.base/src/org/compiere/model/X_X_DepositBatchLine.java @@ -0,0 +1,261 @@ +/****************************************************************************** + * Product: iDempiere ERP & CRM Smart Business Solution * + * Copyright (C) 1999-2012 ComPiere, Inc. All Rights Reserved. * + * This program is free software, you can redistribute it and/or modify it * + * under the terms version 2 of the GNU General Public License as published * + * by the Free Software Foundation. This program is distributed in the hope * + * that it will be useful, but WITHOUT ANY WARRANTY, without even the implied * + * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * + * See the GNU General Public License for more details. * + * You should have received a copy of the GNU General Public License along * + * with this program, if not, write to the Free Software Foundation, Inc., * + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. * + * For the text or an alternative of this public license, you may reach us * + * ComPiere, Inc., 2620 Augustine Dr. #245, Santa Clara, CA 95054, USA * + * or via info@compiere.org or http://www.compiere.org/license.html * + *****************************************************************************/ +/** Generated Model - DO NOT CHANGE */ +package org.compiere.model; + +import java.math.BigDecimal; +import java.sql.ResultSet; +import java.util.Properties; +import org.compiere.util.Env; +import org.compiere.util.KeyNamePair; + +/** Generated Model for X_DepositBatchLine + * @author iDempiere (generated) + * @version Release 1.0a - $Id$ */ +public class X_X_DepositBatchLine extends PO implements I_X_DepositBatchLine, I_Persistent +{ + + /** + * + */ + private static final long serialVersionUID = 20130123L; + + /** Standard Constructor */ + public X_X_DepositBatchLine (Properties ctx, int X_DepositBatchLine_ID, String trxName) + { + super (ctx, X_DepositBatchLine_ID, trxName); + /** if (X_DepositBatchLine_ID == 0) + { + setC_Payment_ID (0); + setLine (0); +// @SQL=SELECT NVL(MAX(Line),0)+10 AS DefaultValue FROM X_DepositBatchLine WHERE X_DepositBatch_ID=@X_DepositBatch_ID@ + setPayAmt (Env.ZERO); + setProcessed (false); + setProcessing (false); + setX_DepositBatch_ID (0); + setX_DepositBatchLine_ID (0); + } */ + } + + /** Load Constructor */ + public X_X_DepositBatchLine (Properties ctx, ResultSet rs, String trxName) + { + super (ctx, rs, trxName); + } + + /** AccessLevel + * @return 3 - Client - Org + */ + protected int get_AccessLevel() + { + return accessLevel.intValue(); + } + + /** Load Meta Data */ + protected POInfo initPO (Properties ctx) + { + POInfo poi = POInfo.getPOInfo (ctx, Table_ID, get_TrxName()); + return poi; + } + + public String toString() + { + StringBuffer sb = new StringBuffer ("X_X_DepositBatchLine[") + .append(get_ID()).append("]"); + return sb.toString(); + } + + public org.compiere.model.I_C_Payment getC_Payment() throws RuntimeException + { + return (org.compiere.model.I_C_Payment)MTable.get(getCtx(), org.compiere.model.I_C_Payment.Table_Name) + .getPO(getC_Payment_ID(), get_TrxName()); } + + /** Set Payment. + @param C_Payment_ID + Payment identifier + */ + public void setC_Payment_ID (int C_Payment_ID) + { + if (C_Payment_ID < 1) + set_Value (COLUMNNAME_C_Payment_ID, null); + else + set_Value (COLUMNNAME_C_Payment_ID, Integer.valueOf(C_Payment_ID)); + } + + /** Get Payment. + @return Payment identifier + */ + public int getC_Payment_ID () + { + Integer ii = (Integer)get_Value(COLUMNNAME_C_Payment_ID); + if (ii == null) + return 0; + return ii.intValue(); + } + + /** Set Line No. + @param Line + Unique line for this document + */ + public void setLine (int Line) + { + set_Value (COLUMNNAME_Line, Integer.valueOf(Line)); + } + + /** Get Line No. + @return Unique line for this document + */ + public int getLine () + { + Integer ii = (Integer)get_Value(COLUMNNAME_Line); + if (ii == null) + return 0; + return ii.intValue(); + } + + /** Set Payment amount. + @param PayAmt + Amount being paid + */ + public void setPayAmt (BigDecimal PayAmt) + { + set_Value (COLUMNNAME_PayAmt, PayAmt); + } + + /** Get Payment amount. + @return Amount being paid + */ + public BigDecimal getPayAmt () + { + BigDecimal bd = (BigDecimal)get_Value(COLUMNNAME_PayAmt); + if (bd == null) + return Env.ZERO; + return bd; + } + + /** Set Processed. + @param Processed + The document has been processed + */ + public void setProcessed (boolean Processed) + { + set_Value (COLUMNNAME_Processed, Boolean.valueOf(Processed)); + } + + /** Get Processed. + @return The document has been processed + */ + public boolean isProcessed () + { + Object oo = get_Value(COLUMNNAME_Processed); + if (oo != null) + { + if (oo instanceof Boolean) + return ((Boolean)oo).booleanValue(); + return "Y".equals(oo); + } + return false; + } + + /** Set Process Now. + @param Processing Process Now */ + public void setProcessing (boolean Processing) + { + set_Value (COLUMNNAME_Processing, Boolean.valueOf(Processing)); + } + + /** Get Process Now. + @return Process Now */ + public boolean isProcessing () + { + Object oo = get_Value(COLUMNNAME_Processing); + if (oo != null) + { + if (oo instanceof Boolean) + return ((Boolean)oo).booleanValue(); + return "Y".equals(oo); + } + return false; + } + + public org.compiere.model.I_X_DepositBatch getX_DepositBatch() throws RuntimeException + { + return (org.compiere.model.I_X_DepositBatch)MTable.get(getCtx(), org.compiere.model.I_X_DepositBatch.Table_Name) + .getPO(getX_DepositBatch_ID(), get_TrxName()); } + + /** Set Deposit Batch. + @param X_DepositBatch_ID Deposit Batch */ + public void setX_DepositBatch_ID (int X_DepositBatch_ID) + { + if (X_DepositBatch_ID < 1) + set_ValueNoCheck (COLUMNNAME_X_DepositBatch_ID, null); + else + set_ValueNoCheck (COLUMNNAME_X_DepositBatch_ID, Integer.valueOf(X_DepositBatch_ID)); + } + + /** Get Deposit Batch. + @return Deposit Batch */ + public int getX_DepositBatch_ID () + { + Integer ii = (Integer)get_Value(COLUMNNAME_X_DepositBatch_ID); + if (ii == null) + return 0; + return ii.intValue(); + } + + /** Get Record ID/ColumnName + @return ID/ColumnName pair + */ + public KeyNamePair getKeyNamePair() + { + return new KeyNamePair(get_ID(), String.valueOf(getX_DepositBatch_ID())); + } + + /** Set Deposit Batch Line. + @param X_DepositBatchLine_ID Deposit Batch Line */ + public void setX_DepositBatchLine_ID (int X_DepositBatchLine_ID) + { + if (X_DepositBatchLine_ID < 1) + set_ValueNoCheck (COLUMNNAME_X_DepositBatchLine_ID, null); + else + set_ValueNoCheck (COLUMNNAME_X_DepositBatchLine_ID, Integer.valueOf(X_DepositBatchLine_ID)); + } + + /** Get Deposit Batch Line. + @return Deposit Batch Line */ + public int getX_DepositBatchLine_ID () + { + Integer ii = (Integer)get_Value(COLUMNNAME_X_DepositBatchLine_ID); + if (ii == null) + return 0; + return ii.intValue(); + } + + /** Set X_DepositBatchLine_UU. + @param X_DepositBatchLine_UU X_DepositBatchLine_UU */ + public void setX_DepositBatchLine_UU (String X_DepositBatchLine_UU) + { + set_Value (COLUMNNAME_X_DepositBatchLine_UU, X_DepositBatchLine_UU); + } + + /** Get X_DepositBatchLine_UU. + @return X_DepositBatchLine_UU */ + public String getX_DepositBatchLine_UU () + { + return (String)get_Value(COLUMNNAME_X_DepositBatchLine_UU); + } +} \ No newline at end of file diff --git a/org.adempiere.ui.swing/src/org/compiere/apps/APanel.java b/org.adempiere.ui.swing/src/org/compiere/apps/APanel.java index 1b4418d0fc..50a0885c8c 100644 --- a/org.adempiere.ui.swing/src/org/compiere/apps/APanel.java +++ b/org.adempiere.ui.swing/src/org/compiere/apps/APanel.java @@ -2549,12 +2549,12 @@ public final class APanel extends CPanel } // DocAction // Pop up Create From - else if (col.equals("CreateFrom")) + else if (col.equals("CreateFrom") || col.equals("X_CreateFromBatch")) { // Run form only if the button has no process defined - teo_sarca [ 1974354 ] if (vButton.getProcess_ID() <= 0) { - ICreateFrom cf = VCreateFromFactory.create(m_curTab); + ICreateFrom cf = VCreateFromFactory.create(m_curTab, col); if(cf != null) { if(cf.isInitOK()) diff --git a/org.adempiere.ui.swing/src/org/compiere/grid/DefaultCreateFromFactory.java b/org.adempiere.ui.swing/src/org/compiere/grid/DefaultCreateFromFactory.java index 94d2f1f5bb..c067a3e7f9 100644 --- a/org.adempiere.ui.swing/src/org/compiere/grid/DefaultCreateFromFactory.java +++ b/org.adempiere.ui.swing/src/org/compiere/grid/DefaultCreateFromFactory.java @@ -19,27 +19,41 @@ import org.compiere.model.I_C_Invoice; import org.compiere.model.I_M_InOut; import org.compiere.model.I_M_PackageMPS; import org.compiere.model.I_M_RMA; +import org.compiere.model.I_X_DepositBatch; /** * * @author Elaine * */ -public class DefaultCreateFromFactory implements ICreateFromFactory { +public class DefaultCreateFromFactory implements ICreateFromFactory +{ @Override - public ICreateFrom create(GridTab mTab) { + public ICreateFrom create(GridTab mTab, String columnName) + { String tableName = mTab.getTableName(); - if (tableName.equals(I_C_Invoice.Table_Name)) - return new VCreateFromInvoiceUI(mTab); - else if (tableName.equals(I_C_BankStatement.Table_Name)) - return new VCreateFromStatementUI(mTab); - else if (tableName.equals(I_M_InOut.Table_Name)) - return new VCreateFromShipmentUI(mTab); - else if (tableName.equals(I_M_RMA.Table_Name)) - return new VCreateFromRMAUI(mTab); - else if (tableName.equals(I_M_PackageMPS.Table_Name)) - return new VCreateFromPackageShipmentUI(mTab); + if (columnName.equals("CreateFrom")) + { + if (tableName.equals(I_C_Invoice.Table_Name)) + return new VCreateFromInvoiceUI(mTab); + else if (tableName.equals(I_C_BankStatement.Table_Name)) +// return new VCreateFromStatementUI(mTab); + return new VCreateFromStatementBatchUI(mTab); + else if (tableName.equals(I_M_InOut.Table_Name)) + return new VCreateFromShipmentUI(mTab); + else if (tableName.equals(I_M_RMA.Table_Name)) + return new VCreateFromRMAUI(mTab); + else if (tableName.equals(I_M_PackageMPS.Table_Name)) + return new VCreateFromPackageShipmentUI(mTab); + else if (tableName.equals(I_X_DepositBatch.Table_Name)) + return new VCreateFromDepositBatchUI(mTab); + } + else if (columnName.equalsIgnoreCase("X_CreateFromBatch")) + { + if (tableName.equals(I_C_BankStatement.Table_Name)) + return new VCreateFromBatchStatementUI(mTab); + } return null; } diff --git a/org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromBatchStatementUI.java b/org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromBatchStatementUI.java new file mode 100644 index 0000000000..d6b144ee78 --- /dev/null +++ b/org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromBatchStatementUI.java @@ -0,0 +1,335 @@ +/****************************************************************************** + * Copyright (C) 2013 Elaine Tan * + * Copyright (C) 2013 Trek Global + * This program is free software; you can redistribute it and/or modify it * + * under the terms version 2 of the GNU General Public License as published * + * by the Free Software Foundation. This program is distributed in the hope * + * that it will be useful, but WITHOUT ANY WARRANTY; without even the implied * + * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * + * See the GNU General Public License for more details. * + * You should have received a copy of the GNU General Public License along * + * with this program; if not, write to the Free Software Foundation, Inc., * + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. * + *****************************************************************************/ +package org.compiere.grid; + +import static org.compiere.model.SystemIDs.COLUMN_C_BANKSTATEMENT_C_BANKACCOUNT_ID; + +import java.awt.BorderLayout; +import java.awt.Cursor; +import java.awt.GridBagConstraints; +import java.awt.GridBagLayout; +import java.awt.Insets; +import java.awt.event.ActionEvent; +import java.awt.event.ActionListener; +import java.sql.Timestamp; +import java.util.Vector; +import java.util.logging.Level; + +import javax.swing.JLabel; +import javax.swing.table.DefaultTableModel; + +import org.compiere.apps.ADialog; +import org.compiere.apps.AEnv; +import org.compiere.apps.ConfirmPanel; +import org.compiere.grid.ed.VDate; +import org.compiere.grid.ed.VLookup; +import org.compiere.grid.ed.VNumber; +import org.compiere.grid.ed.VString; +import org.compiere.model.GridTab; +import org.compiere.model.MBankStatement; +import org.compiere.model.MColumn; +import org.compiere.model.MLookup; +import org.compiere.model.MLookupFactory; +import org.compiere.model.MPayment; +import org.compiere.swing.CButton; +import org.compiere.swing.CLabel; +import org.compiere.swing.CPanel; +import org.compiere.swing.CTextField; +import org.compiere.util.CLogger; +import org.compiere.util.DisplayType; +import org.compiere.util.Env; +import org.compiere.util.Msg; + +/** + * + * @author Elaine + * + */ +public class VCreateFromBatchStatementUI extends CreateFromBatchStatement implements ActionListener +{ + private VCreateFromDialog dialog; + + public VCreateFromBatchStatementUI(GridTab mTab) + { + super(mTab); + log.info(getGridTab().toString()); + + dialog = new VCreateFromDialog(this, getGridTab().getWindowNo(), true); + + p_WindowNo = getGridTab().getWindowNo(); + + try + { + if (!dynInit()) + return; + jbInit(); + + setInitOK(true); + } + catch(Exception e) + { + log.log(Level.SEVERE, "", e); + setInitOK(false); + } + AEnv.positionCenterWindow(AEnv.getWindow(p_WindowNo), dialog); + } // VCreateFrom + + /** Window No */ + private int p_WindowNo; + + /** Logger */ + private CLogger log = CLogger.getCLogger(getClass()); + + private JLabel bankAccountLabel = new JLabel(); + protected VLookup bankAccountField; + + private CLabel documentNoLabel = new CLabel(Msg.translate(Env.getCtx(), "DocumentNo")); + protected CTextField documentNoField = new CTextField(10); + + private JLabel documentTypeLabel = new JLabel(); + protected VLookup documentTypeField; + + private JLabel authorizationLabel = new JLabel(); + protected VString authorizationField = new VString(); + + private JLabel tenderTypeLabel = new JLabel(); + protected VLookup tenderTypeField; + + private CLabel amtFromLabel = new CLabel(Msg.translate(Env.getCtx(), "PayAmt")); + protected VNumber amtFromField = new VNumber("AmtFrom", false, false, true, DisplayType.Amount, Msg.translate(Env.getCtx(), "AmtFrom")); + private CLabel amtToLabel = new CLabel("-"); + protected VNumber amtToField = new VNumber("AmtTo", false, false, true, DisplayType.Amount, Msg.translate(Env.getCtx(), "AmtTo")); + + protected CLabel BPartner_idLabel = new CLabel(Msg.translate(Env.getCtx(), "BPartner")); + protected VLookup bPartnerLookup; + + private CLabel dateFromLabel = new CLabel(Msg.translate(Env.getCtx(), "DateTrx")); + protected VDate dateFromField = new VDate("DateFrom", false, false, true, DisplayType.Date, Msg.translate(Env.getCtx(), "DateFrom")); + private CLabel dateToLabel = new CLabel("-"); + protected VDate dateToField = new VDate("DateTo", false, false, true, DisplayType.Date, Msg.translate(Env.getCtx(), "DateTo")); + + + /** + * Dynamic Init + * @throws Exception if Lookups cannot be initialized + * @return true if initialized + */ + public boolean dynInit() throws Exception + { + log.config(""); + + super.dynInit(); + + //Refresh button + CButton refreshButton = ConfirmPanel.createRefreshButton(false); + refreshButton.setMargin(new Insets (1, 10, 0, 10)); + refreshButton.setDefaultCapable(true); + refreshButton.addActionListener(this); + dialog.getConfirmPanel().addButton(refreshButton); + dialog.getRootPane().setDefaultButton(refreshButton); + + if (getGridTab().getValue("C_BankStatement_ID") == null) + { + ADialog.error(0, dialog, "SaveErrorRowNotFound"); + return false; + } + + dialog.setTitle(getTitle()); + + int AD_Column_ID = COLUMN_C_BANKSTATEMENT_C_BANKACCOUNT_ID; // C_BankStatement.C_BankAccount_ID + MLookup lookup = MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, AD_Column_ID, DisplayType.TableDir); + bankAccountField = new VLookup ("C_BankAccount_ID", true, true, true, lookup); + // Set Default + int C_BankAccount_ID = Env.getContextAsInt(Env.getCtx(), p_WindowNo, "C_BankAccount_ID"); + bankAccountField.setValue(new Integer(C_BankAccount_ID)); + bankAccountField.addActionListener(this); + // initial Loading + authorizationField = new VString ("authorization", false, false, true, 10, 30, null, null); + authorizationField.addActionListener(this); + + MLookup lookupDocument = MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, MColumn.getColumn_ID(MPayment.Table_Name, MPayment.COLUMNNAME_C_DocType_ID), DisplayType.TableDir); + documentTypeField = new VLookup (MPayment.COLUMNNAME_C_DocType_ID,false,false,true,lookupDocument); + documentTypeField.addActionListener(this); + + MLookup lookupTender = MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, MColumn.getColumn_ID(MPayment.Table_Name, MPayment.COLUMNNAME_TenderType), DisplayType.List); + tenderTypeField = new VLookup (MPayment.COLUMNNAME_TenderType,false,false,true,lookupTender); + tenderTypeField.addActionListener(this); + + bPartnerLookup = new VLookup("C_BPartner_ID", false, false, true, + MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, 3499, DisplayType.Search)); + BPartner_idLabel.setLabelFor(bPartnerLookup); + bPartnerLookup.addActionListener(this); + + Timestamp date = Env.getContextAsDate(Env.getCtx(), p_WindowNo, MBankStatement.COLUMNNAME_StatementDate); + dateToField.setValue(date); + + documentNoField.addActionListener(this); + dateFromField.addActionListener(this); + dateToField.addActionListener(this); + amtFromField.addActionListener(this); + amtToField.addActionListener(this); + + loadBankAccount(); + + return true; + } // dynInit + + /** + * Static Init. + *
+	 *  parameterPanel
+	 *      parameterBankPanel
+	 *      parameterStdPanel
+	 *          bPartner/order/invoice/shopment/licator Label/Field
+	 *  dataPane
+	 *  southPanel
+	 *      confirmPanel
+	 *      statusBar
+	 *  
+ * @throws Exception + */ + private void jbInit() throws Exception + { + bankAccountLabel.setText(Msg.translate(Env.getCtx(), "C_BankAccount_ID")); + authorizationLabel.setText(Msg.translate(Env.getCtx(), "R_AuthCode")); + + documentTypeLabel.setText(Msg.translate(Env.getCtx(), "C_DocType_ID")); + tenderTypeLabel.setText(Msg.translate(Env.getCtx(), "TenderType")); + + documentNoLabel.setLabelFor(documentNoField); + dateFromLabel.setLabelFor(dateFromField); + dateFromField.setToolTipText(Msg.translate(Env.getCtx(), "DateFrom")); + dateToLabel.setLabelFor(dateToField); + dateToField.setToolTipText(Msg.translate(Env.getCtx(), "DateTo")); + amtFromLabel.setLabelFor(amtFromField); + amtFromField.setToolTipText(Msg.translate(Env.getCtx(), "AmtFrom")); + amtToLabel.setLabelFor(amtToField); + amtToField.setToolTipText(Msg.translate(Env.getCtx(), "AmtTo")); + + CPanel parameterPanel = dialog.getParameterPanel(); + parameterPanel.setLayout(new BorderLayout()); + + CPanel parameterBankPanel = new CPanel(); + parameterBankPanel.setLayout(new GridBagLayout()); + parameterPanel.add(parameterBankPanel, BorderLayout.CENTER); + + parameterBankPanel.add(bankAccountLabel, new GridBagConstraints(0, 0, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + if (bankAccountField != null) + parameterBankPanel.add(bankAccountField, new GridBagConstraints(1, 0, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + parameterBankPanel.add(documentTypeLabel, new GridBagConstraints(0, 1, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + if(documentTypeField!= null) + parameterBankPanel.add(documentTypeField, new GridBagConstraints(1, 1, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + parameterBankPanel.add(tenderTypeLabel, new GridBagConstraints(0, 2, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + if(tenderTypeField!=null) + parameterBankPanel.add(tenderTypeField, new GridBagConstraints(1, 2, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + parameterBankPanel.add(BPartner_idLabel, new GridBagConstraints(0, 3, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + parameterBankPanel.add(bPartnerLookup, new GridBagConstraints(1, 3, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + parameterBankPanel.add(documentNoLabel, new GridBagConstraints(2, 0, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + parameterBankPanel.add(documentNoField, new GridBagConstraints(3, 0, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + parameterBankPanel.add(authorizationLabel, new GridBagConstraints(2, 1, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + parameterBankPanel.add(authorizationField, new GridBagConstraints(3, 1, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + parameterBankPanel.add(amtFromLabel, new GridBagConstraints(2, 2, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + parameterBankPanel.add(amtFromField, new GridBagConstraints(3, 2, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + parameterBankPanel.add(amtToLabel, new GridBagConstraints(4, 2, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + parameterBankPanel.add(amtToField, new GridBagConstraints(5, 2, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + parameterBankPanel.add(dateFromLabel, new GridBagConstraints(2, 3, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + parameterBankPanel.add(dateFromField, new GridBagConstraints(3, 3, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + parameterBankPanel.add(dateToLabel, new GridBagConstraints(4, 3, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + parameterBankPanel.add(dateToField, new GridBagConstraints(5, 3, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + } // jbInit + + /*************************************************************************/ + + /** + * Action Listener + * @param e event + */ + public void actionPerformed(ActionEvent e) + { + log.config("Action=" + e.getActionCommand()); +// Object source = e.getSource(); + if(e.getActionCommand().equals(ConfirmPanel.A_REFRESH)) + { + Cursor.getPredefinedCursor(Cursor.WAIT_CURSOR); + loadBankAccount(); + dialog.tableChanged(null); + Cursor.getPredefinedCursor(Cursor.DEFAULT_CURSOR); + } + } // actionPerformed + + protected void loadBankAccount() + { + loadTableOIS(getBankAccountData(bankAccountField.getValue(), bPartnerLookup.getValue(), + documentNoField.getText(), dateFromField.getValue(), dateToField.getValue(), + amtFromField.getValue(), amtToField.getValue(), + documentTypeField.getValue(), tenderTypeField.getValue(), authorizationField.getText())); + } + + protected void loadTableOIS (Vector data) + { + // Remove previous listeners + dialog.getMiniTable().getModel().removeTableModelListener(dialog); + // Set Model + DefaultTableModel model = new DefaultTableModel(data, getOISColumnNames()); + model.addTableModelListener(dialog); + dialog.getMiniTable().setModel(model); + // + + configureMiniTable(dialog.getMiniTable()); + } + + public void showWindow() + { + dialog.setVisible(true); + } + + public void closeWindow() + { + dialog.dispose(); + } + + @Override + public Object getWindow() + { + return dialog; + } +} \ No newline at end of file diff --git a/org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromDepositBatchUI.java b/org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromDepositBatchUI.java new file mode 100644 index 0000000000..d4a765cfb9 --- /dev/null +++ b/org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromDepositBatchUI.java @@ -0,0 +1,337 @@ +/****************************************************************************** + * Copyright (C) 2013 Elaine Tan * + * Copyright (C) 2013 Trek Global + * This program is free software; you can redistribute it and/or modify it * + * under the terms version 2 of the GNU General Public License as published * + * by the Free Software Foundation. This program is distributed in the hope * + * that it will be useful, but WITHOUT ANY WARRANTY; without even the implied * + * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * + * See the GNU General Public License for more details. * + * You should have received a copy of the GNU General Public License along * + * with this program; if not, write to the Free Software Foundation, Inc., * + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. * + *****************************************************************************/ +package org.compiere.grid; + +import static org.compiere.model.SystemIDs.COLUMN_C_BANKSTATEMENT_C_BANKACCOUNT_ID; + +import java.awt.BorderLayout; +import java.awt.Cursor; +import java.awt.GridBagConstraints; +import java.awt.GridBagLayout; +import java.awt.Insets; +import java.awt.event.ActionEvent; +import java.awt.event.ActionListener; +import java.sql.Timestamp; +import java.util.Vector; +import java.util.logging.Level; + +import javax.swing.JLabel; +import javax.swing.table.DefaultTableModel; + +import org.compiere.apps.ADialog; +import org.compiere.apps.AEnv; +import org.compiere.apps.ConfirmPanel; +import org.compiere.grid.ed.VDate; +import org.compiere.grid.ed.VLookup; +import org.compiere.grid.ed.VNumber; +import org.compiere.grid.ed.VString; +import org.compiere.model.GridTab; +import org.compiere.model.MBankStatement; +import org.compiere.model.MColumn; +import org.compiere.model.MLookup; +import org.compiere.model.MLookupFactory; +import org.compiere.model.MPayment; +import org.compiere.swing.CButton; +import org.compiere.swing.CLabel; +import org.compiere.swing.CPanel; +import org.compiere.swing.CTextField; +import org.compiere.util.CLogger; +import org.compiere.util.DisplayType; +import org.compiere.util.Env; +import org.compiere.util.Msg; + +/** + * + * @author Elaine + * + */ +public class VCreateFromDepositBatchUI extends CreateFromDepositBatch implements ActionListener +{ + private VCreateFromDialog dialog; + + public VCreateFromDepositBatchUI(GridTab mTab) + { + super(mTab); + log.info(getGridTab().toString()); + + dialog = new VCreateFromDialog(this, getGridTab().getWindowNo(), true); + + p_WindowNo = getGridTab().getWindowNo(); + + try + { + if (!dynInit()) + return; + jbInit(); + + setInitOK(true); + } + catch(Exception e) + { + log.log(Level.SEVERE, "", e); + setInitOK(false); + } + AEnv.positionCenterWindow(AEnv.getWindow(p_WindowNo), dialog); + } // VCreateFrom + + /** Window No */ + private int p_WindowNo; + + /** Logger */ + private CLogger log = CLogger.getCLogger(getClass()); + + private JLabel bankAccountLabel = new JLabel(); + protected VLookup bankAccountField; + + private CLabel documentNoLabel = new CLabel(Msg.translate(Env.getCtx(), "DocumentNo")); + protected CTextField documentNoField = new CTextField(10); + + private JLabel documentTypeLabel = new JLabel(); + protected VLookup documentTypeField; + + private JLabel authorizationLabel = new JLabel(); + protected VString authorizationField = new VString(); + + private JLabel tenderTypeLabel = new JLabel(); + protected VLookup tenderTypeField; + + private CLabel amtFromLabel = new CLabel(Msg.translate(Env.getCtx(), "PayAmt")); + protected VNumber amtFromField = new VNumber("AmtFrom", false, false, true, DisplayType.Amount, Msg.translate(Env.getCtx(), "AmtFrom")); + private CLabel amtToLabel = new CLabel("-"); + protected VNumber amtToField = new VNumber("AmtTo", false, false, true, DisplayType.Amount, Msg.translate(Env.getCtx(), "AmtTo")); + + protected CLabel BPartner_idLabel = new CLabel(Msg.translate(Env.getCtx(), "BPartner")); + protected VLookup bPartnerLookup; + + private CLabel dateFromLabel = new CLabel(Msg.translate(Env.getCtx(), "DateTrx")); + protected VDate dateFromField = new VDate("DateFrom", false, false, true, DisplayType.Date, Msg.translate(Env.getCtx(), "DateFrom")); + private CLabel dateToLabel = new CLabel("-"); + protected VDate dateToField = new VDate("DateTo", false, false, true, DisplayType.Date, Msg.translate(Env.getCtx(), "DateTo")); + + + /** + * Dynamic Init + * @throws Exception if Lookups cannot be initialized + * @return true if initialized + */ + public boolean dynInit() throws Exception + { + log.config(""); + + super.dynInit(); + + //Refresh button + CButton refreshButton = ConfirmPanel.createRefreshButton(false); + refreshButton.setMargin(new Insets (1, 10, 0, 10)); + refreshButton.setDefaultCapable(true); + refreshButton.addActionListener(this); + dialog.getConfirmPanel().addButton(refreshButton); + dialog.getRootPane().setDefaultButton(refreshButton); + + if (getGridTab().getValue("X_DepositBatch_ID") == null) + { + ADialog.error(0, dialog, "SaveErrorRowNotFound"); + return false; + } + + dialog.setTitle(getTitle()); + + int AD_Column_ID = COLUMN_C_BANKSTATEMENT_C_BANKACCOUNT_ID; // C_BankStatement.C_BankAccount_ID + MLookup lookup = MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, AD_Column_ID, DisplayType.TableDir); + bankAccountField = new VLookup ("C_BankAccount_ID", true, true, true, lookup); + // Set Default + int C_BankAccount_ID = Env.getContextAsInt(Env.getCtx(), p_WindowNo, "C_BankAccount_ID"); + bankAccountField.setValue(new Integer(C_BankAccount_ID)); + bankAccountField.addActionListener(this); + // initial Loading + authorizationField = new VString ("authorization", false, false, true, 10, 30, null, null); + authorizationField.addActionListener(this); + + MLookup lookupDocument = MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, MColumn.getColumn_ID(MPayment.Table_Name, MPayment.COLUMNNAME_C_DocType_ID), DisplayType.TableDir); + documentTypeField = new VLookup (MPayment.COLUMNNAME_C_DocType_ID,false,false,true,lookupDocument); + int C_DocType_ID = Env.getContextAsInt(Env.getCtx(), p_WindowNo, "C_DocType_ID"); + documentTypeField.setValue(new Integer(C_DocType_ID)); + documentTypeField.addActionListener(this); + + MLookup lookupTender = MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, MColumn.getColumn_ID(MPayment.Table_Name, MPayment.COLUMNNAME_TenderType), DisplayType.List); + tenderTypeField = new VLookup (MPayment.COLUMNNAME_TenderType,false,false,true,lookupTender); + tenderTypeField.addActionListener(this); + + bPartnerLookup = new VLookup("C_BPartner_ID", false, false, true, + MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, 3499, DisplayType.Search)); + BPartner_idLabel.setLabelFor(bPartnerLookup); + bPartnerLookup.addActionListener(this); + + Timestamp date = Env.getContextAsDate(Env.getCtx(), p_WindowNo, MBankStatement.COLUMNNAME_StatementDate); + dateToField.setValue(date); + + documentNoField.addActionListener(this); + dateFromField.addActionListener(this); + dateToField.addActionListener(this); + amtFromField.addActionListener(this); + amtToField.addActionListener(this); + + loadBankAccount(); + + return true; + } // dynInit + + /** + * Static Init. + *
+	 *  parameterPanel
+	 *      parameterBankPanel
+	 *      parameterStdPanel
+	 *          bPartner/order/invoice/shopment/licator Label/Field
+	 *  dataPane
+	 *  southPanel
+	 *      confirmPanel
+	 *      statusBar
+	 *  
+ * @throws Exception + */ + private void jbInit() throws Exception + { + bankAccountLabel.setText(Msg.translate(Env.getCtx(), "C_BankAccount_ID")); + authorizationLabel.setText(Msg.translate(Env.getCtx(), "R_AuthCode")); + + documentTypeLabel.setText(Msg.translate(Env.getCtx(), "C_DocType_ID")); + tenderTypeLabel.setText(Msg.translate(Env.getCtx(), "TenderType")); + + documentNoLabel.setLabelFor(documentNoField); + dateFromLabel.setLabelFor(dateFromField); + dateFromField.setToolTipText(Msg.translate(Env.getCtx(), "DateFrom")); + dateToLabel.setLabelFor(dateToField); + dateToField.setToolTipText(Msg.translate(Env.getCtx(), "DateTo")); + amtFromLabel.setLabelFor(amtFromField); + amtFromField.setToolTipText(Msg.translate(Env.getCtx(), "AmtFrom")); + amtToLabel.setLabelFor(amtToField); + amtToField.setToolTipText(Msg.translate(Env.getCtx(), "AmtTo")); + + CPanel parameterPanel = dialog.getParameterPanel(); + parameterPanel.setLayout(new BorderLayout()); + + CPanel parameterBankPanel = new CPanel(); + parameterBankPanel.setLayout(new GridBagLayout()); + parameterPanel.add(parameterBankPanel, BorderLayout.CENTER); + + parameterBankPanel.add(bankAccountLabel, new GridBagConstraints(0, 0, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + if (bankAccountField != null) + parameterBankPanel.add(bankAccountField, new GridBagConstraints(1, 0, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + parameterBankPanel.add(documentTypeLabel, new GridBagConstraints(0, 1, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + if(documentTypeField!= null) + parameterBankPanel.add(documentTypeField, new GridBagConstraints(1, 1, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + parameterBankPanel.add(tenderTypeLabel, new GridBagConstraints(0, 2, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + if(tenderTypeField!=null) + parameterBankPanel.add(tenderTypeField, new GridBagConstraints(1, 2, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + parameterBankPanel.add(BPartner_idLabel, new GridBagConstraints(0, 3, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + parameterBankPanel.add(bPartnerLookup, new GridBagConstraints(1, 3, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + parameterBankPanel.add(documentNoLabel, new GridBagConstraints(2, 0, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + parameterBankPanel.add(documentNoField, new GridBagConstraints(3, 0, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + parameterBankPanel.add(authorizationLabel, new GridBagConstraints(2, 1, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + parameterBankPanel.add(authorizationField, new GridBagConstraints(3, 1, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + parameterBankPanel.add(amtFromLabel, new GridBagConstraints(2, 2, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + parameterBankPanel.add(amtFromField, new GridBagConstraints(3, 2, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + parameterBankPanel.add(amtToLabel, new GridBagConstraints(4, 2, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + parameterBankPanel.add(amtToField, new GridBagConstraints(5, 2, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + parameterBankPanel.add(dateFromLabel, new GridBagConstraints(2, 3, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + parameterBankPanel.add(dateFromField, new GridBagConstraints(3, 3, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + parameterBankPanel.add(dateToLabel, new GridBagConstraints(4, 3, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + parameterBankPanel.add(dateToField, new GridBagConstraints(5, 3, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + } // jbInit + + /*************************************************************************/ + + /** + * Action Listener + * @param e event + */ + public void actionPerformed(ActionEvent e) + { + log.config("Action=" + e.getActionCommand()); +// Object source = e.getSource(); + if(e.getActionCommand().equals(ConfirmPanel.A_REFRESH)) + { + Cursor.getPredefinedCursor(Cursor.WAIT_CURSOR); + loadBankAccount(); + dialog.tableChanged(null); + Cursor.getPredefinedCursor(Cursor.DEFAULT_CURSOR); + } + } // actionPerformed + + protected void loadBankAccount() + { + loadTableOIS(getBankAccountData(bankAccountField.getValue(), bPartnerLookup.getValue(), + documentNoField.getText(), dateFromField.getValue(), dateToField.getValue(), + amtFromField.getValue(), amtToField.getValue(), + documentTypeField.getValue(), tenderTypeField.getValue(), authorizationField.getText())); + } + + protected void loadTableOIS (Vector data) + { + // Remove previous listeners + dialog.getMiniTable().getModel().removeTableModelListener(dialog); + // Set Model + DefaultTableModel model = new DefaultTableModel(data, getOISColumnNames()); + model.addTableModelListener(dialog); + dialog.getMiniTable().setModel(model); + // + + configureMiniTable(dialog.getMiniTable()); + } + + public void showWindow() + { + dialog.setVisible(true); + } + + public void closeWindow() + { + dialog.dispose(); + } + + @Override + public Object getWindow() + { + return dialog; + } +} diff --git a/org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromDialog.java b/org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromDialog.java index 50d5945d04..73b8f42026 100644 --- a/org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromDialog.java +++ b/org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromDialog.java @@ -196,7 +196,7 @@ public class VCreateFromDialog extends CDialog implements ActionListener, TableM } setStatusLine(count, null); - createFrom.info(); + createFrom.info(dataTable, statusBar); } public void setStatusLine(int selectedRowCount, String text) diff --git a/org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromFactory.java b/org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromFactory.java index 2eb8f4e4f4..c2f54bc56d 100644 --- a/org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromFactory.java +++ b/org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromFactory.java @@ -20,13 +20,13 @@ import org.compiere.model.GridTab; public class VCreateFromFactory { - public static ICreateFrom create (GridTab mTab) + public static ICreateFrom create (GridTab mTab, String columnName) { ICreateFrom createFrom = null; List factories = Service.locator().list(ICreateFromFactory.class).getServices(); for (ICreateFromFactory factory : factories) { - createFrom = factory.create(mTab); + createFrom = factory.create(mTab, columnName); if (createFrom != null) break; } diff --git a/org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromStatementBatchUI.java b/org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromStatementBatchUI.java new file mode 100644 index 0000000000..2cc5871c20 --- /dev/null +++ b/org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromStatementBatchUI.java @@ -0,0 +1,335 @@ +/****************************************************************************** + * Copyright (C) 2013 Elaine Tan * + * Copyright (C) 2013 Trek Global + * This program is free software; you can redistribute it and/or modify it * + * under the terms version 2 of the GNU General Public License as published * + * by the Free Software Foundation. This program is distributed in the hope * + * that it will be useful, but WITHOUT ANY WARRANTY; without even the implied * + * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * + * See the GNU General Public License for more details. * + * You should have received a copy of the GNU General Public License along * + * with this program; if not, write to the Free Software Foundation, Inc., * + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. * + *****************************************************************************/ +package org.compiere.grid; + +import static org.compiere.model.SystemIDs.COLUMN_C_BANKSTATEMENT_C_BANKACCOUNT_ID; + +import java.awt.BorderLayout; +import java.awt.Cursor; +import java.awt.GridBagConstraints; +import java.awt.GridBagLayout; +import java.awt.Insets; +import java.awt.event.ActionEvent; +import java.awt.event.ActionListener; +import java.sql.Timestamp; +import java.util.Vector; +import java.util.logging.Level; + +import javax.swing.JLabel; +import javax.swing.table.DefaultTableModel; + +import org.compiere.apps.ADialog; +import org.compiere.apps.AEnv; +import org.compiere.apps.ConfirmPanel; +import org.compiere.grid.ed.VDate; +import org.compiere.grid.ed.VLookup; +import org.compiere.grid.ed.VNumber; +import org.compiere.grid.ed.VString; +import org.compiere.model.GridTab; +import org.compiere.model.MBankStatement; +import org.compiere.model.MColumn; +import org.compiere.model.MLookup; +import org.compiere.model.MLookupFactory; +import org.compiere.model.MPayment; +import org.compiere.swing.CButton; +import org.compiere.swing.CLabel; +import org.compiere.swing.CPanel; +import org.compiere.swing.CTextField; +import org.compiere.util.CLogger; +import org.compiere.util.DisplayType; +import org.compiere.util.Env; +import org.compiere.util.Msg; + +/** + * + * @author Elaine + * + */ +public class VCreateFromStatementBatchUI extends CreateFromStatementBatch implements ActionListener +{ + private VCreateFromDialog dialog; + + public VCreateFromStatementBatchUI(GridTab mTab) + { + super(mTab); + log.info(getGridTab().toString()); + + dialog = new VCreateFromDialog(this, getGridTab().getWindowNo(), true); + + p_WindowNo = getGridTab().getWindowNo(); + + try + { + if (!dynInit()) + return; + jbInit(); + + setInitOK(true); + } + catch(Exception e) + { + log.log(Level.SEVERE, "", e); + setInitOK(false); + } + AEnv.positionCenterWindow(AEnv.getWindow(p_WindowNo), dialog); + } // VCreateFrom + + /** Window No */ + private int p_WindowNo; + + /** Logger */ + private CLogger log = CLogger.getCLogger(getClass()); + + private JLabel bankAccountLabel = new JLabel(); + protected VLookup bankAccountField; + + private CLabel documentNoLabel = new CLabel(Msg.translate(Env.getCtx(), "DocumentNo")); + protected CTextField documentNoField = new CTextField(10); + + private JLabel documentTypeLabel = new JLabel(); + protected VLookup documentTypeField; + + private JLabel authorizationLabel = new JLabel(); + protected VString authorizationField = new VString(); + + private JLabel tenderTypeLabel = new JLabel(); + protected VLookup tenderTypeField; + + private CLabel amtFromLabel = new CLabel(Msg.translate(Env.getCtx(), "PayAmt")); + protected VNumber amtFromField = new VNumber("AmtFrom", false, false, true, DisplayType.Amount, Msg.translate(Env.getCtx(), "AmtFrom")); + private CLabel amtToLabel = new CLabel("-"); + protected VNumber amtToField = new VNumber("AmtTo", false, false, true, DisplayType.Amount, Msg.translate(Env.getCtx(), "AmtTo")); + + protected CLabel BPartner_idLabel = new CLabel(Msg.translate(Env.getCtx(), "BPartner")); + protected VLookup bPartnerLookup; + + private CLabel dateFromLabel = new CLabel(Msg.translate(Env.getCtx(), "DateTrx")); + protected VDate dateFromField = new VDate("DateFrom", false, false, true, DisplayType.Date, Msg.translate(Env.getCtx(), "DateFrom")); + private CLabel dateToLabel = new CLabel("-"); + protected VDate dateToField = new VDate("DateTo", false, false, true, DisplayType.Date, Msg.translate(Env.getCtx(), "DateTo")); + + + /** + * Dynamic Init + * @throws Exception if Lookups cannot be initialized + * @return true if initialized + */ + public boolean dynInit() throws Exception + { + log.config(""); + + super.dynInit(); + + //Refresh button + CButton refreshButton = ConfirmPanel.createRefreshButton(false); + refreshButton.setMargin(new Insets (1, 10, 0, 10)); + refreshButton.setDefaultCapable(true); + refreshButton.addActionListener(this); + dialog.getConfirmPanel().addButton(refreshButton); + dialog.getRootPane().setDefaultButton(refreshButton); + + if (getGridTab().getValue("C_BankStatement_ID") == null) + { + ADialog.error(0, dialog, "SaveErrorRowNotFound"); + return false; + } + + dialog.setTitle(getTitle()); + + int AD_Column_ID = COLUMN_C_BANKSTATEMENT_C_BANKACCOUNT_ID; // C_BankStatement.C_BankAccount_ID + MLookup lookup = MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, AD_Column_ID, DisplayType.TableDir); + bankAccountField = new VLookup ("C_BankAccount_ID", true, true, true, lookup); + // Set Default + int C_BankAccount_ID = Env.getContextAsInt(Env.getCtx(), p_WindowNo, "C_BankAccount_ID"); + bankAccountField.setValue(new Integer(C_BankAccount_ID)); + bankAccountField.addActionListener(this); + // initial Loading + authorizationField = new VString ("authorization", false, false, true, 10, 30, null, null); + authorizationField.addActionListener(this); + + MLookup lookupDocument = MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, MColumn.getColumn_ID(MPayment.Table_Name, MPayment.COLUMNNAME_C_DocType_ID), DisplayType.TableDir); + documentTypeField = new VLookup (MPayment.COLUMNNAME_C_DocType_ID,false,false,true,lookupDocument); + documentTypeField.addActionListener(this); + + MLookup lookupTender = MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, MColumn.getColumn_ID(MPayment.Table_Name, MPayment.COLUMNNAME_TenderType), DisplayType.List); + tenderTypeField = new VLookup (MPayment.COLUMNNAME_TenderType,false,false,true,lookupTender); + tenderTypeField.addActionListener(this); + + bPartnerLookup = new VLookup("C_BPartner_ID", false, false, true, + MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, 3499, DisplayType.Search)); + BPartner_idLabel.setLabelFor(bPartnerLookup); + bPartnerLookup.addActionListener(this); + + Timestamp date = Env.getContextAsDate(Env.getCtx(), p_WindowNo, MBankStatement.COLUMNNAME_StatementDate); + dateToField.setValue(date); + + documentNoField.addActionListener(this); + dateFromField.addActionListener(this); + dateToField.addActionListener(this); + amtFromField.addActionListener(this); + amtToField.addActionListener(this); + + loadBankAccount(); + + return true; + } // dynInit + + /** + * Static Init. + *
+	 *  parameterPanel
+	 *      parameterBankPanel
+	 *      parameterStdPanel
+	 *          bPartner/order/invoice/shopment/licator Label/Field
+	 *  dataPane
+	 *  southPanel
+	 *      confirmPanel
+	 *      statusBar
+	 *  
+ * @throws Exception + */ + private void jbInit() throws Exception + { + bankAccountLabel.setText(Msg.translate(Env.getCtx(), "C_BankAccount_ID")); + authorizationLabel.setText(Msg.translate(Env.getCtx(), "R_AuthCode")); + + documentTypeLabel.setText(Msg.translate(Env.getCtx(), "C_DocType_ID")); + tenderTypeLabel.setText(Msg.translate(Env.getCtx(), "TenderType")); + + documentNoLabel.setLabelFor(documentNoField); + dateFromLabel.setLabelFor(dateFromField); + dateFromField.setToolTipText(Msg.translate(Env.getCtx(), "DateFrom")); + dateToLabel.setLabelFor(dateToField); + dateToField.setToolTipText(Msg.translate(Env.getCtx(), "DateTo")); + amtFromLabel.setLabelFor(amtFromField); + amtFromField.setToolTipText(Msg.translate(Env.getCtx(), "AmtFrom")); + amtToLabel.setLabelFor(amtToField); + amtToField.setToolTipText(Msg.translate(Env.getCtx(), "AmtTo")); + + CPanel parameterPanel = dialog.getParameterPanel(); + parameterPanel.setLayout(new BorderLayout()); + + CPanel parameterBankPanel = new CPanel(); + parameterBankPanel.setLayout(new GridBagLayout()); + parameterPanel.add(parameterBankPanel, BorderLayout.CENTER); + + parameterBankPanel.add(bankAccountLabel, new GridBagConstraints(0, 0, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + if (bankAccountField != null) + parameterBankPanel.add(bankAccountField, new GridBagConstraints(1, 0, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + parameterBankPanel.add(documentTypeLabel, new GridBagConstraints(0, 1, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + if(documentTypeField!= null) + parameterBankPanel.add(documentTypeField, new GridBagConstraints(1, 1, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + parameterBankPanel.add(tenderTypeLabel, new GridBagConstraints(0, 2, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + if(tenderTypeField!=null) + parameterBankPanel.add(tenderTypeField, new GridBagConstraints(1, 2, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + parameterBankPanel.add(BPartner_idLabel, new GridBagConstraints(0, 3, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + parameterBankPanel.add(bPartnerLookup, new GridBagConstraints(1, 3, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + parameterBankPanel.add(documentNoLabel, new GridBagConstraints(2, 0, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + parameterBankPanel.add(documentNoField, new GridBagConstraints(3, 0, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + parameterBankPanel.add(authorizationLabel, new GridBagConstraints(2, 1, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + parameterBankPanel.add(authorizationField, new GridBagConstraints(3, 1, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + parameterBankPanel.add(amtFromLabel, new GridBagConstraints(2, 2, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + parameterBankPanel.add(amtFromField, new GridBagConstraints(3, 2, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + parameterBankPanel.add(amtToLabel, new GridBagConstraints(4, 2, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + parameterBankPanel.add(amtToField, new GridBagConstraints(5, 2, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + parameterBankPanel.add(dateFromLabel, new GridBagConstraints(2, 3, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + parameterBankPanel.add(dateFromField, new GridBagConstraints(3, 3, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + parameterBankPanel.add(dateToLabel, new GridBagConstraints(4, 3, 1, 1, 0.0, 0.0 + ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0)); + parameterBankPanel.add(dateToField, new GridBagConstraints(5, 3, 1, 1, 0.0, 0.0 + ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 5), 0, 0)); + + } // jbInit + + /*************************************************************************/ + + /** + * Action Listener + * @param e event + */ + public void actionPerformed(ActionEvent e) + { + log.config("Action=" + e.getActionCommand()); +// Object source = e.getSource(); + if(e.getActionCommand().equals(ConfirmPanel.A_REFRESH)) + { + Cursor.getPredefinedCursor(Cursor.WAIT_CURSOR); + loadBankAccount(); + dialog.tableChanged(null); + Cursor.getPredefinedCursor(Cursor.DEFAULT_CURSOR); + } + } // actionPerformed + + protected void loadBankAccount() + { + loadTableOIS(getBankAccountData(bankAccountField.getValue(), bPartnerLookup.getValue(), + documentNoField.getText(), dateFromField.getValue(), dateToField.getValue(), + amtFromField.getValue(), amtToField.getValue(), + documentTypeField.getValue(), tenderTypeField.getValue(), authorizationField.getText())); + } + + protected void loadTableOIS (Vector data) + { + // Remove previous listeners + dialog.getMiniTable().getModel().removeTableModelListener(dialog); + // Set Model + DefaultTableModel model = new DefaultTableModel(data, getOISColumnNames()); + model.addTableModelListener(dialog); + dialog.getMiniTable().setModel(model); + // + + configureMiniTable(dialog.getMiniTable()); + } + + public void showWindow() + { + dialog.setVisible(true); + } + + public void closeWindow() + { + dialog.dispose(); + } + + @Override + public Object getWindow() + { + return dialog; + } +} \ No newline at end of file diff --git a/org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromStatementUI.java b/org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromStatementUI.java index d41ef431a4..43f7309a5e 100644 --- a/org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromStatementUI.java +++ b/org.adempiere.ui.swing/src/org/compiere/grid/VCreateFromStatementUI.java @@ -13,6 +13,8 @@ *****************************************************************************/ package org.compiere.grid; +import static org.compiere.model.SystemIDs.COLUMN_C_BANKSTATEMENT_C_BANKACCOUNT_ID; + import java.awt.BorderLayout; import java.awt.Cursor; import java.awt.GridBagConstraints; @@ -20,9 +22,7 @@ import java.awt.GridBagLayout; import java.awt.Insets; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; -import java.math.BigDecimal; import java.sql.Timestamp; -import java.text.DecimalFormat; import java.util.Vector; import java.util.logging.Level; @@ -43,7 +43,6 @@ import org.compiere.model.MColumn; import org.compiere.model.MLookup; import org.compiere.model.MLookupFactory; import org.compiere.model.MPayment; -import static org.compiere.model.SystemIDs.*; import org.compiere.swing.CButton; import org.compiere.swing.CLabel; import org.compiere.swing.CPanel; @@ -55,7 +54,6 @@ import org.compiere.util.Msg; public class VCreateFromStatementUI extends CreateFromStatement implements ActionListener { - private VCreateFromDialog dialog; public VCreateFromStatementUI(GridTab mTab) @@ -308,27 +306,6 @@ public class VCreateFromStatementUI extends CreateFromStatement implements Actio configureMiniTable(dialog.getMiniTable()); } - /** - * List total amount - */ - public void info() - { - DecimalFormat format = DisplayType.getNumberFormat(DisplayType.Amount); - - BigDecimal total = new BigDecimal(0.0); - int rows = dialog.getMiniTable().getRowCount(); - int count = 0; - for (int i = 0; i < rows; i++) - { - if (((Boolean)dialog.getMiniTable().getValueAt(i, 0)).booleanValue()) - { - total = total.add((BigDecimal)dialog.getMiniTable().getValueAt(i, 4)); - count++; - } - } - dialog.setStatusLine(count, Msg.getMsg(Env.getCtx(), "Sum") + " " + format.format(total)); - } // infoStatement - public void showWindow() { dialog.setVisible(true); diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/AbstractADWindowContent.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/AbstractADWindowContent.java index a1a5071957..0145c8519e 100644 --- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/AbstractADWindowContent.java +++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/AbstractADWindowContent.java @@ -2385,11 +2385,10 @@ public abstract class AbstractADWindowContent extends AbstractUIPart implements } } // DocAction - // Pop up Create From - - else if (col.equals("CreateFrom")) + // Pop up Create From + else if (col.equals("CreateFrom") || col.equals("X_CreateFromBatch")) { - ICreateFrom cf = WCreateFromFactory.create(adtabPanel.getGridTab()); + ICreateFrom cf = WCreateFromFactory.create(adtabPanel.getGridTab(), col); if(cf != null) { diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/AbstractADWindowContent.java.orig b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/AbstractADWindowContent.java.orig new file mode 100644 index 0000000000..be59c63ca0 --- /dev/null +++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/AbstractADWindowContent.java.orig @@ -0,0 +1,2792 @@ +/****************************************************************************** + * Product: Posterita Ajax UI * + * Copyright (C) 2007 Posterita Ltd. All Rights Reserved. * + * This program is free software; you can redistribute it and/or modify it * + * under the terms version 2 of the GNU General Public License as published * + * by the Free Software Foundation. This program is distributed in the hope * + * that it will be useful, but WITHOUT ANY WARRANTY; without even the implied * + * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * + * See the GNU General Public License for more details. * + * You should have received a copy of the GNU General Public License along * + * with this program; if not, write to the Free Software Foundation, Inc., * + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. * + * For the text or an alternative of this public license, you may reach us * + * Posterita Ltd., 3, Draper Avenue, Quatre Bornes, Mauritius * + * or via info@posterita.org or http://www.posterita.org/ * + *****************************************************************************/ + +package org.adempiere.webui.adwindow; + +import static org.compiere.model.SystemIDs.PROCESS_AD_CHANGELOG_REDO; +import static org.compiere.model.SystemIDs.PROCESS_AD_CHANGELOG_UNDO; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Date; +import java.util.HashMap; +import java.util.Iterator; +import java.util.List; +import java.util.Map; +import java.util.Properties; +import java.util.Set; +import java.util.TreeMap; +import java.util.logging.Level; + +import org.adempiere.util.Callback; +import org.adempiere.webui.AdempiereIdGenerator; +import org.adempiere.webui.AdempiereWebUI; +import org.adempiere.webui.LayoutUtils; +import org.adempiere.webui.WArchive; +import org.adempiere.webui.WRequest; +import org.adempiere.webui.WZoomAcross; +import org.adempiere.webui.apps.AEnv; +import org.adempiere.webui.apps.BusyDialogTemplate; +import org.adempiere.webui.apps.ProcessModalDialog; +import org.adempiere.webui.apps.form.WCreateFromFactory; +import org.adempiere.webui.apps.form.WCreateFromWindow; +import org.adempiere.webui.component.Button; +import org.adempiere.webui.component.Listbox; +import org.adempiere.webui.component.ProcessInfoDialog; +import org.adempiere.webui.component.Window; +import org.adempiere.webui.component.ZkCssHelper; +import org.adempiere.webui.editor.IProcessButton; +import org.adempiere.webui.editor.WEditor; +import org.adempiere.webui.event.ActionEvent; +import org.adempiere.webui.event.ActionListener; +import org.adempiere.webui.event.DialogEvents; +import org.adempiere.webui.event.ToolbarListener; +import org.adempiere.webui.exception.ApplicationException; +import org.adempiere.webui.panel.ADForm; +import org.adempiere.webui.panel.InfoPanel; +import org.adempiere.webui.panel.WAttachment; +import org.adempiere.webui.panel.WDocActionPanel; +import org.adempiere.webui.panel.action.ExportAction; +import org.adempiere.webui.panel.action.FileImportAction; +import org.adempiere.webui.panel.action.ReportAction; +import org.adempiere.webui.part.AbstractUIPart; +import org.adempiere.webui.session.SessionManager; +import org.adempiere.webui.window.CustomizeGridViewDialog; +import org.adempiere.webui.window.FDialog; +import org.adempiere.webui.window.FindWindow; +import org.adempiere.webui.window.WChat; +import org.adempiere.webui.window.WRecordAccessDialog; +import org.compiere.grid.ICreateFrom; +import org.compiere.model.DataStatusEvent; +import org.compiere.model.DataStatusListener; +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.Lookup; +import org.compiere.model.MImage; +import org.compiere.model.MProcess; +import org.compiere.model.MQuery; +import org.compiere.model.MRecentItem; +import org.compiere.model.MRole; +import org.compiere.process.DocAction; +import org.compiere.process.ProcessInfo; +import org.compiere.process.ProcessInfoLog; +import org.compiere.process.ProcessInfoUtil; +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.compiere.util.WebDoc; +import org.zkoss.zk.ui.AbstractComponent; +import org.zkoss.zk.ui.Component; +import org.zkoss.zk.ui.Executions; +import org.zkoss.zk.ui.HtmlBasedComponent; +import org.zkoss.zk.ui.Session; +import org.zkoss.zk.ui.event.Event; +import org.zkoss.zk.ui.event.EventListener; +import org.zkoss.zk.ui.event.Events; +import org.zkoss.zk.ui.sys.ExecutionCtrl; +import org.zkoss.zk.ui.util.Clients; +import org.zkoss.zul.Column; +import org.zkoss.zul.Columns; +import org.zkoss.zul.Div; +import org.zkoss.zul.Hbox; +import org.zkoss.zul.Listitem; +import org.zkoss.zul.Menuitem; +import org.zkoss.zul.Menupopup; +import org.zkoss.zul.Window.Mode; + +/** + * + * This class is based on org.compiere.apps.APanel written by Jorg Janke. + * @author Jorg Janke + * + * @author Ashley G Ramdass + * @author Low Heng Sin + * @date Feb 25, 2007 + * @version $Revision: 0.10 $ + * + * @author Cristina Ghita, www.arhipac.ro + * @see FR [ 2877111 ] See identifiers columns when delete records https://sourceforge.net/tracker/?func=detail&atid=879335&aid=2877111&group_id=176962 + * + * @author hengsin, hengsin.low@idalica.com + * @see FR [2887701] https://sourceforge.net/tracker/?func=detail&atid=879335&aid=2887701&group_id=176962 + * @sponsor www.metas.de + * + * @author Teo Sarca, teo.sarca@gmail.com + *
  • BF [ 2992540 ] Grid/Panel not refreshed after process run + * https://sourceforge.net/tracker/?func=detail&aid=2992540&group_id=176962&atid=955896 + *
  • BF [ 2985892 ] Opening a window using a new record query is not working + * https://sourceforge.net/tracker/?func=detail&aid=2985892&group_id=176962&atid=955896 + */ +public abstract class AbstractADWindowContent extends AbstractUIPart implements ToolbarListener, + EventListener, DataStatusListener, ActionListener +{ + private static final CLogger logger; + + static + { + logger = CLogger.getCLogger(AbstractADWindowContent.class); + } + + private Properties ctx; + + private GridWindow gridWindow; + + protected StatusBar statusBar; + + protected IADTabbox adTabbox; + + private int curWindowNo; + + private boolean m_onlyCurrentRows = true; + + protected ADWindowToolbar toolbar; + + protected String title; + + private boolean newRecord; + + private boolean boolChanges = false; + + private int m_onlyCurrentDays = 0; + + private Component parent; + + private boolean m_findCancelled; + + private boolean m_findCreateNew; + + private boolean m_queryInitiating; + + protected BreadCrumb breadCrumb; + + private int adWindowId; + + private MImage image; + + /** + * Constructor + * @param ctx + * @param windowNo + * @param adWindowId + */ + public AbstractADWindowContent(Properties ctx, int windowNo, int adWindowId) + { + this.ctx = ctx; + this.curWindowNo = windowNo; + this.adWindowId = adWindowId; + + initComponents(); + } + + /** + * @param parent + * @return Component + */ + public Component createPart(Object parent) + { + if (parent instanceof Component) + this.parent = (Component) parent; + + adTabbox = createADTab(); + adTabbox.setSelectionEventListener(this); + adTabbox.setADWindowPanel(this); + + Component comp = super.createPart(parent); + comp.addEventListener(LayoutUtils.ON_REDRAW_EVENT, this); + return comp; + } + + public BreadCrumb getBreadCrumb() + { + return breadCrumb; + } + + /** + * @return StatusBarPanel + */ + public StatusBar getStatusBar() + { + return statusBar; + } + + private void initComponents() + { + /** Initalise toolbar */ + toolbar = new ADWindowToolbar(getWindowNo()); + toolbar.setId("windowToolbar"); + toolbar.addListener(this); + + statusBar = new StatusBar(); + + GridWindowVO gWindowVO = AEnv.getMWindowVO(curWindowNo, adWindowId, 0); + if (gWindowVO == null) + { + throw new ApplicationException(Msg.getMsg(ctx, + "AccessTableNoView") + + "(No Window Model Info)"); + } + gridWindow = new GridWindow(gWindowVO, true); + title = gridWindow.getName(); + image = gridWindow.getMImage(); + } + + /** + * @return IADTab + */ + protected abstract IADTabbox createADTab(); + + private void focusToActivePanel() { + IADTabpanel adTabPanel = adTabbox.getSelectedTabpanel(); + focusToTabpanel(adTabPanel); + } + + private void focusToTabpanel(IADTabpanel adTabPanel ) { + if (adTabPanel != null && adTabPanel instanceof HtmlBasedComponent) { + ((HtmlBasedComponent)adTabPanel).focus(); + } + } + + /** + * @param adWindowId + * @param query + * @return boolean + */ + public boolean initPanel(MQuery query) + { + // This temporary validation code is added to check the reported bug + // [ adempiere-ZK Web Client-2832968 ] User context lost? + // https://sourceforge.net/tracker/?func=detail&atid=955896&aid=2832968&group_id=176962 + // it's harmless, if there is no bug then this must never fail + Session currSess = Executions.getCurrent().getDesktop().getSession(); + int checkad_user_id = -1; + if (currSess != null && currSess.getAttribute("Check_AD_User_ID") != null) + checkad_user_id = (Integer)currSess.getAttribute("Check_AD_User_ID"); + if (checkad_user_id!=Env.getAD_User_ID(ctx)) + { + String msg = "Timestamp=" + new Date() + + ", Bug 2832968 SessionUser=" + + checkad_user_id + + ", ContextUser=" + + Env.getAD_User_ID(ctx) + + ". Please report conditions to your system administrator or in sf tracker 2832968"; + ApplicationException ex = new ApplicationException(msg); + logger.log(Level.SEVERE, msg, ex); + throw ex; + } + // End of temporary code for [ adempiere-ZK Web Client-2832968 ] User context lost? + + // Set AutoCommit for this Window + Env.setAutoCommit(ctx, curWindowNo, Env.isAutoCommit(ctx)); + boolean autoNew = Env.isAutoNew(ctx); + Env.setAutoNew(ctx, curWindowNo, autoNew); + + + + // Set SO/AutoNew for Window + Env.setContext(ctx, curWindowNo, "IsSOTrx", gridWindow.isSOTrx()); + if (!autoNew && gridWindow.isTransaction()) + { + Env.setAutoNew(ctx, curWindowNo, true); + } + + m_onlyCurrentRows = gridWindow.isTransaction(); + + MQuery detailQuery = null; + /** + * Window Tabs + */ + if (query != null && query.getZoomTableName() != null && query.getZoomColumnName() != null + && query.getZoomValue() instanceof Integer && (Integer)query.getZoomValue() > 0) + { + if (!query.getZoomTableName().equalsIgnoreCase(gridWindow.getTab(0).getTableName())) + { + detailQuery = query; + query = new MQuery(); + query.addRestriction("1=2"); + query.setRecordCount(0); + } + } + + int tabSize = gridWindow.getTabCount(); + + GridTab gridTab = null; + for (int tab = 0; tab < tabSize; tab++) + { + gridTab = initTab(query, tab); + if (tab == 0 && gridTab == null && m_findCancelled) + return false; + } + Env.setContext(ctx, curWindowNo, "WindowName", gridWindow.getName()); + Env.setContext(ctx, curWindowNo, "AD_Window_ID", gridWindow.getAD_Window_ID()); + Env.setContext(ctx, curWindowNo, "AD_Window_UU", gridWindow.getAD_Window_UU()); + + if (gridTab != null) + gridTab.getTableModel().setChanged(false); + + adTabbox.setSelectedIndex(0); + // all fields context for window is clear at AbstractADTab.prepareContext, set again IsSOTrx for window + Env.setContext(ctx, curWindowNo, "IsSOTrx", gridWindow.isSOTrx()); + toolbar.enableTabNavigation(adTabbox.getTabCount() > 1); + toolbar.enableFind(true); + adTabbox.evaluate(null); + + if (detailQuery != null && zoomToDetailTab(detailQuery)) + { + return true; + } + + toolbar.updateToolbarAccess(adWindowId); + updateToolbar(); + + return true; + } + + private boolean zoomToDetailTab(MQuery query) { + //zoom to detail + if (query != null && query.getZoomTableName() != null && query.getZoomColumnName() != null) + { + GridTab gTab = gridWindow.getTab(0); + if (!query.getZoomTableName().equalsIgnoreCase(gTab.getTableName())) + { + int tabSize = gridWindow.getTabCount(); + + for (int tab = 0; tab < tabSize; tab++) + { + gTab = gridWindow.getTab(tab); + if (gTab.isSortTab()) + continue; + if (gTab.getTableName().equalsIgnoreCase(query.getZoomTableName())) + { + if (doZoomToDetail(gTab, query, tab)) { + return true; + } + } + } + } + } + return false; + } + + private boolean doZoomToDetail(GridTab gTab, MQuery query, int tabIndex) { + GridField[] fields = gTab.getFields(); + for (GridField field : fields) + { + if (field.getColumnName().equalsIgnoreCase(query.getZoomColumnName())) + { + gridWindow.initTab(tabIndex); + int parentId = DB.getSQLValue(null, "SELECT " + gTab.getLinkColumnName() + " FROM " + gTab.getTableName() + " WHERE " + query.getWhereClause()); + if (parentId > 0) + { + MapparentMap = new TreeMap(); + int index = tabIndex; + int oldpid = parentId; + GridTab currentTab = gTab; + while (index > 0) + { + index--; + GridTab pTab = gridWindow.getTab(index); + if (pTab.getTabLevel() < currentTab.getTabLevel()) + { + gridWindow.initTab(index); + if (index > 0) + { + if (pTab.getLinkColumnName() != null && pTab.getLinkColumnName().trim().length() > 0) + { + int pid = DB.getSQLValue(null, "SELECT " + pTab.getLinkColumnName() + " FROM " + pTab.getTableName() + " WHERE " + currentTab.getLinkColumnName() + " = ?", oldpid); + if (pid > 0) + { + parentMap.put(index, new Object[]{currentTab.getLinkColumnName(), oldpid}); + oldpid = pid; + currentTab = pTab; + } + else + { + parentMap.clear(); + break; + } + } + } + else + { + parentMap.put(index, new Object[]{currentTab.getLinkColumnName(), oldpid}); + } + } + } + + for(Map.Entry entry : parentMap.entrySet()) + { + GridTab pTab = gridWindow.getTab(entry.getKey()); + Object[] value = entry.getValue(); + MQuery pquery = new MQuery(pTab.getAD_Table_ID()); + pquery.addRestriction((String)value[0], "=", value[1]); + IADTabpanel tp = adTabbox.findADTabpanel(pTab); + tp.createUI(); + if (tp.getTabLevel() == 0) + { + pTab.setQuery(pquery); + tp.query(); + } + else + { + tp.query(); + pTab.setQuery(pquery); + tp.query(); + } + } + + MQuery targetQuery = new MQuery(gTab.getAD_Table_ID()); + targetQuery.addRestriction(gTab.getLinkColumnName(), "=", parentId); + gTab.setQuery(targetQuery); + IADTabpanel gc = null; + gc = adTabbox.findADTabpanel(gTab); + gc.createUI(); + gc.query(false, 0, 0); + + GridTable table = gTab.getTableModel(); + int count = table.getRowCount(); + for(int i = 0; i < count; i++) + { + int id = table.getKeyID(i); + if (id == ((Integer)query.getZoomValue()).intValue()) + { + setActiveTab(gridWindow.getTabIndex(gTab), null); + gTab.navigate(i); + return true; + } + } + } + } + } + return false; + } + + private void initQueryOnNew(MQuery result) { + GridTab curTab = adTabbox.getSelectedGridTab(); + boolean onNew = false; + if (curTab.isHighVolume() && m_findCreateNew) + onNew = true; + else if (result == null && curTab.getRowCount() == 0 && Env.isAutoNew(ctx, curWindowNo)) + onNew = true; + else if (!curTab.isReadOnly() && curTab.isQueryNewRecord()) + onNew = true; + if (onNew) { + Executions.schedule(AEnv.getDesktop(), new EventListener() { + @Override + public void onEvent(Event event) throws Exception { + onNew(); + } + }, new Event("onInsert")); + } + } + + /** + * @param query + * @param tabIndex + */ + protected GridTab initTab(MQuery query, int tabIndex) { + gridWindow.initTab(tabIndex); + + final GridTab gTab = gridWindow.getTab(tabIndex); + Env.setContext(ctx, curWindowNo, tabIndex, GridTab.CTX_TabLevel, Integer.toString(gTab.getTabLevel())); + + // Query first tab + if (tabIndex == 0) + { + m_queryInitiating = true; + getComponent().setVisible(false); + initialQuery(query, gTab, new Callback() { + @Override + public void onCallback(MQuery result) { + m_queryInitiating = false; + + if (m_findCancelled) { + SessionManager.getAppDesktop().closeWindow(curWindowNo); + return; + } + + if (!getComponent().isVisible()) + getComponent().setVisible(true); + + // Set initial Query on first tab + if (result != null) + { + m_onlyCurrentRows = false; + gTab.setQuery(result); + } + + if (adTabbox.getSelectedTabpanel() != null) + { + initFirstTabpanel(); + + initQueryOnNew(result); + } + } + + }); + } + + if (gTab.isSortTab()) + { + ADSortTab sortTab = new ADSortTab(curWindowNo, gTab); + adTabbox.addTab(gTab, sortTab); + sortTab.registerAPanel(this); + if (tabIndex == 0) { + sortTab.createUI(); + if (!m_queryInitiating) + { + initFirstTabpanel(); + } + } + gTab.addDataStatusListener(this); + } + else + { + ADTabpanel fTabPanel = new ADTabpanel(); + fTabPanel.addEventListener(ADTabpanel.ON_DYNAMIC_DISPLAY_EVENT, this); + gTab.addDataStatusListener(this); + fTabPanel.init(this, curWindowNo, gTab, gridWindow); + adTabbox.addTab(gTab, fTabPanel); + if (tabIndex == 0) { + fTabPanel.createUI(); + if (!m_queryInitiating) + { + initFirstTabpanel(); + } + } + + if (!m_queryInitiating && tabIndex == 0) + { + initQueryOnNew(query); + } + } + + return gTab; + } + + private void initFirstTabpanel() { + adTabbox.getSelectedTabpanel().query(m_onlyCurrentRows, m_onlyCurrentDays, MRole.getDefault().getMaxQueryRecords()); + adTabbox.getSelectedTabpanel().activate(true); + Events.echoEvent(new Event(ADTabpanel.ON_POST_INIT_EVENT, adTabbox.getSelectedTabpanel())); + } + + /** + * Initial Query + * + * @param query + * initial query + * @param mTab + * tab + * @return query or null + */ + private void initialQuery(final MQuery query, GridTab mTab, final Callback callback) + { + // We have a (Zoom) query + if (query != null && query.isActive() && query.getRecordCount() < 10) + { + callback.onCallback(query); + return; + } + + // + StringBuffer where = new StringBuffer(); + // Query automatically if high volume and no query + boolean require = mTab.isHighVolume(); + if (!require && !m_onlyCurrentRows) // No Trx Window + { + String wh1 = Env.parseContext(ctx, curWindowNo, mTab.getWhereExtended(), false); + if (wh1 == null || wh1.length() == 0) + wh1 = mTab.getWhereClause(); + if (wh1 != null && wh1.length() > 0) + where.append(wh1); + // + if (query != null) + { + String wh2 = query.getWhereClause(); + if (wh2.length() > 0) + { + if (where.length() > 0) + where.append(" AND "); + where.append(wh2); + } + } + // + StringBuffer sql = new StringBuffer("SELECT COUNT(*) FROM ") + .append(mTab.getTableName()); + if (where.length() > 0) + sql.append(" WHERE ").append(where); + // Does not consider security + int no = DB.getSQLValue(null, sql.toString()); + // + require = MRole.getDefault().isQueryRequire(no); + } + // Show Query + if (require) + { + m_findCancelled = false; + m_findCreateNew = false; + GridField[] findFields = mTab.getFields(); + findWindow = new FindWindow(curWindowNo, + mTab.getName(), mTab.getAD_Table_ID(), mTab.getTableName(), + where.toString(), findFields, 10, mTab.getAD_Tab_ID()); // no query below 10 + setupEmbeddedFindwindow(); + if (findWindow.initialize()) + { + findWindow.addEventListener(DialogEvents.ON_WINDOW_CLOSE, new EventListener() { + @Override + public void onEvent(Event event) throws Exception { + if (!findWindow.isCancel()) + { + m_findCreateNew = findWindow.isCreateNew(); + MQuery result = findWindow.getQuery(); + callback.onCallback(result); + EventListener listener = findWindow.getEventListeners(DialogEvents.ON_WINDOW_CLOSE).iterator().next(); + findWindow.removeEventListener(DialogEvents.ON_WINDOW_CLOSE, listener); + } + else + { + m_findCancelled = true; + callback.onCallback(null); + } + } + }); + getComponent().addEventListener("onInitialQuery", new EventListener() { + @Override + public void onEvent(Event event) throws Exception { + getComponent().getParent().appendChild(findWindow); + LayoutUtils.openEmbeddedWindow(getComponent().getParent(), findWindow, "overlap"); + } + }); + Events.echoEvent("onInitialQuery", getComponent(), null); + } + else + { + callback.onCallback(query); + } + } + else + { + callback.onCallback(query); + } + } // initialQuery + + private void setupEmbeddedFindwindow() { + findWindow.setTitle(null); + findWindow.setBorder("none"); + findWindow.setStyle("position: absolute; border-bottom: 2px solid #484848; padding: 2px; background-color: #fff;"); + findWindow.setWidth("100%"); + findWindow.setHeight("60%"); + findWindow.setZindex(1000); + findWindow.setSizable(false); + findWindow.setContentStyle("background-color: #fff; width: 99%; margin: auto;"); + } + + public String getTitle() + { + return title; + } + + public MImage getImage() + { + return image; + } + + /** + * @see ToolbarListener#onDetailRecord() + */ + public void onDetailRecord() + { + adTabbox.onDetailRecord(); + } + + /** + * @see ToolbarListener#onParentRecord() + */ + public void onParentRecord() + { + List parents = breadCrumb.getParentLinks(); + if (!parents.isEmpty()) { + Events.sendEvent(parents.get(parents.size()-1), new Event(Events.ON_CLICK, parents.get(parents.size()-1))); + } + } + + /** + * @see ToolbarListener#onFirst() + */ + public void onFirst() + { + Callback callback = new Callback() { + @Override + public void onCallback(Boolean result) { + if (result) { + adTabbox.getSelectedGridTab().navigate(0); + focusToActivePanel(); + } + } + }; + saveAndNavigate(callback); + } + + /** + * @see ToolbarListener#onLast() + */ + public void onLast() + { + Callback callback = new Callback() { + @Override + public void onCallback(Boolean result) { + if (result) { + adTabbox.getSelectedGridTab().navigate(adTabbox.getSelectedGridTab().getRowCount() - 1); + focusToActivePanel(); + } + } + }; + onSave(false, true, callback); + } + + /** + * @see ToolbarListener#onNext() + */ + public void onNext() + { + Callback callback = new Callback() { + @Override + public void onCallback(Boolean result) { + if (result) { + adTabbox.getSelectedGridTab().navigateRelative(+1); + focusToActivePanel(); + } + } + }; + saveAndNavigate(callback); + } + + /** + * @see ToolbarListener#onPrevious() + */ + public void onPrevious() + { + Callback callback = new Callback() { + @Override + public void onCallback(Boolean result) { + if (result) { + adTabbox.getSelectedGridTab().navigateRelative(-1); + focusToActivePanel(); + } + } + }; + saveAndNavigate(callback); + } + + // Elaine 2008/12/04 + private Menupopup m_popup = null; + private Menuitem m_lock = null; + private Menuitem m_access = null; + + private FindWindow findWindow; + + private Div maskDiv; + + /** + * @see ToolbarListener#onLock() + */ + public void onLock() + { + if (!toolbar.isPersonalLock) + return; + if (adTabbox.getSelectedGridTab().getRecord_ID() == -1) // No Key + return; + + if(m_popup == null) + { + m_popup = new Menupopup(); + + m_lock = new Menuitem(Msg.translate(Env.getCtx(), "Lock")); + m_popup.appendChild(m_lock); + m_lock.addEventListener(Events.ON_CLICK, new EventListener() + { + public void onEvent(Event event) throws Exception + { + adTabbox.getSelectedGridTab().lock(Env.getCtx(), adTabbox.getSelectedGridTab().getRecord_ID(), !toolbar.getButton("Lock").isPressed()); + adTabbox.getSelectedGridTab().loadLocks(); // reload + + toolbar.lock(adTabbox.getSelectedGridTab().isLocked()); + } + }); + + m_access = new Menuitem(Msg.translate(Env.getCtx(), "RecordAccessDialog")); + m_popup.appendChild(m_access); + m_access.addEventListener(Events.ON_CLICK, new EventListener() + { + public void onEvent(Event event) throws Exception + { + WRecordAccessDialog recordAccessDialog = new WRecordAccessDialog(null, adTabbox.getSelectedGridTab().getAD_Table_ID(), adTabbox.getSelectedGridTab().getRecord_ID()); + recordAccessDialog.addEventListener(DialogEvents.ON_WINDOW_CLOSE, new EventListener() { + + @Override + public void onEvent(Event event) throws Exception { + toolbar.lock(adTabbox.getSelectedGridTab().isLocked()); + } + }); + + AEnv.showWindow(recordAccessDialog); + } + }); + + m_popup.setPage(toolbar.getButton("Lock").getPage()); + } + m_popup.open(toolbar.getButton("Lock")); + } // lock + // + + + /** + * @see ToolbarListener#onAttachment() + */ + public void onAttachment() + { + int record_ID = adTabbox.getSelectedGridTab().getRecord_ID(); + logger.info("Record_ID=" + record_ID); + + if (record_ID == -1) // No Key + { + //aAttachment.setEnabled(false); + return; + } + + EventListener listener = new EventListener() { + + @Override + public void onEvent(Event event) throws Exception { + toolbar.getButton("Attachment").setPressed(adTabbox.getSelectedGridTab().hasAttachment()); + focusToActivePanel(); + } + }; + // Attachment va = + WAttachment win = new WAttachment ( curWindowNo, adTabbox.getSelectedGridTab().getAD_AttachmentID(), + adTabbox.getSelectedGridTab().getAD_Table_ID(), record_ID, null, listener); + win.addEventListener(DialogEvents.ON_WINDOW_CLOSE, new EventListener() { + @Override + public void onEvent(Event event) throws Exception { + hideBusyMask(); + } + }); + showBusyMask(); + getComponent().getParent().appendChild(win); + LayoutUtils.openOverlappedWindow(getComponent(), win, "middle_center"); + } + + public void onChat() + { + int recordId = adTabbox.getSelectedGridTab().getRecord_ID(); + logger.info("Record_ID=" + recordId); + + if (recordId== -1) // No Key + { + return; + } + + // Find display + String infoName = null; + String infoDisplay = null; + for (int i = 0; i < adTabbox.getSelectedGridTab().getFieldCount(); i++) + { + GridField field = adTabbox.getSelectedGridTab().getField(i); + if (field.isKey()) + infoName = field.getHeader(); + if ((field.getColumnName().equals("Name") || field.getColumnName().equals("DocumentNo") ) + && field.getValue() != null) + infoDisplay = field.getValue().toString(); + if (infoName != null && infoDisplay != null) + break; + } + String description = infoName + ": " + infoDisplay; + + WChat chat = new WChat(curWindowNo, adTabbox.getSelectedGridTab().getCM_ChatID(), adTabbox.getSelectedGridTab().getAD_Table_ID(), recordId, description, null); + chat.addEventListener(DialogEvents.ON_WINDOW_CLOSE, new EventListener() { + @Override + public void onEvent(Event event) throws Exception { + hideBusyMask(); + toolbar.getButton("Chat").setPressed(adTabbox.getSelectedGridTab().hasChat()); + focusToActivePanel(); + } + }); + showBusyMask(); + getComponent().getParent().appendChild(chat); + LayoutUtils.openOverlappedWindow(getComponent(), chat, "middle_center"); + chat.showWindow(); + } + + /** + * @see ToolbarListener#onToggle() + */ + public void onToggle() + { + adTabbox.getSelectedTabpanel().switchRowPresentation(); + //Deepak-Enabling customize button IDEMPIERE-364 + if(!(adTabbox.getSelectedTabpanel() instanceof ADSortTab)) + toolbar.enableCustomize(((ADTabpanel)adTabbox.getSelectedTabpanel()).isGridView()); + focusToActivePanel(); + } + + /** + * @return boolean + */ + public boolean onExit() + { + if (!boolChanges) + { + return true; + } + else + FDialog.info(this.curWindowNo, null, "SaveBeforeClose"); + + return false; + } + + /** + * @param event + * @see EventListener#onEvent(Event) + */ + public void onEvent(Event event) + { + if (CompositeADTabbox.ON_SELECTION_CHANGED_EVENT.equals(event.getName())) + { + Object eventData = event.getData(); + + if (eventData != null && eventData instanceof Object[] && ((Object[])eventData).length == 2) + { + Object[] indexes = (Object[]) eventData; + int newTabIndex = (Integer)indexes[1]; + + final int originalTabIndex = adTabbox.getSelectedIndex(); + final int originalTabRow = adTabbox.getSelectedGridTab().getCurrentRow(); + setActiveTab(newTabIndex, new Callback() { + + @Override + public void onCallback(Boolean result) { + if (result) + { + adTabbox.setDetailpaneSelection(originalTabIndex, originalTabRow); + } + else + { + //reset to original + adTabbox.setSelectedIndex(originalTabIndex); + } + + } + }); + } + } + else if (event.getTarget() instanceof ProcessModalDialog) + { + hideBusyMask(); + ProcessModalDialog dialog = (ProcessModalDialog) event.getTarget(); + onModalClose(dialog.getProcessInfo()); + String s = breadCrumb.getStatusLine(); + boolean b = breadCrumb.getStatusError(); + ProcessInfoLog[] logs = breadCrumb.getPLogs(); + onRefresh(true, false); + breadCrumb.setStatusLine(s, b, logs); + } + else if (ADTabpanel.ON_DYNAMIC_DISPLAY_EVENT.equals(event.getName())) + { + ADTabpanel adtab = (ADTabpanel) event.getTarget(); + if (adtab == adTabbox.getSelectedTabpanel()) { + toolbar.enableProcessButton(adtab.getToolbarButtons().size() > 0); + toolbar.dynamicDisplay(); + } + } + else if (event.getTarget() == getComponent() && event.getName().equals(LayoutUtils.ON_REDRAW_EVENT)) { + ExecutionCtrl ctrl = (ExecutionCtrl) Executions.getCurrent(); + Event evt = ctrl.getNextEvent(); + if (evt != null) { + Events.sendEvent(evt); + Events.postEvent(new Event(LayoutUtils.ON_REDRAW_EVENT, getComponent())); + return; + } + LayoutUtils.redraw((AbstractComponent) getComponent()); + } + } + + private void setActiveTab(final int newTabIndex, final Callback callback) { + + final int oldTabIndex = adTabbox.getSelectedIndex(); + + if (oldTabIndex == newTabIndex) + { + if (callback != null) + callback.onCallback(true); + } + else + { + Callback command = new Callback() { + + @Override + public void onCallback(Boolean result) { + if (result) { + setActiveTab0(oldTabIndex, newTabIndex, callback); + } else if (callback != null) { + callback.onCallback(false); + } + } + }; + saveAndNavigate(command); + } + + } + + public void saveAndNavigate(final Callback callback) { + if (adTabbox != null) + { + if (adTabbox.isSortTab()) + { + onSave(false, true, callback); + } + else if (adTabbox.needSave(true, false)) + { + if (adTabbox.needSave(true, true)) + { + onSave(false, true, callback); + } + else + { + // new record, but nothing changed + adTabbox.dataIgnore(); + callback.onCallback(true); + } + } // there is a change + else + callback.onCallback(true); + } + else + callback.onCallback(true); + } + + private void setActiveTab0(int oldTabIndex, int newTabIndex, + final Callback callback) { + boolean back = false; + IADTabpanel oldTabpanel = adTabbox.getSelectedTabpanel(); + + if (!adTabbox.updateSelectedIndex(oldTabIndex, newTabIndex)) + { + FDialog.warn(curWindowNo, "TabSwitchJumpGo", title); + if (callback != null) + callback.onCallback(false); + return; + } + + + IADTabpanel newTabpanel = adTabbox.getSelectedTabpanel(); + + boolean activated = newTabpanel.isActive(); + if (oldTabpanel != null) + oldTabpanel.activate(false); + if (activated) + newTabpanel.activate(true); + + back = (newTabIndex < oldTabIndex); + if (back && newTabpanel.getTabLevel() > 0) + { + if (newTabpanel.getTabLevel() >= oldTabpanel.getTabLevel()) + back = false; + else if ((newTabIndex - oldTabIndex) > 1) + { + for (int i = oldTabIndex - 1; i > newTabIndex; i--) + { + IADTabpanel next = adTabbox.getADTabpanel(i); + if (next != null && next.getTabLevel() <= newTabpanel.getTabLevel()) + { + back = false; + break; + } + } + } + } + +// if (!activated) +// { + if (!back) + { + newTabpanel.query(); + } + else + { + newTabpanel.refresh(); + } +// } + + if (adTabbox.getSelectedTabpanel() instanceof ADSortTab) + { + ((ADSortTab)adTabbox.getSelectedTabpanel()).registerAPanel(this); + } + else + { + if (adTabbox.getSelectedGridTab().getRowCount() == 0 && Env.isAutoNew(ctx, getWindowNo())) + { + onNew(); + } + } + + updateToolbar(); + + breadCrumb.setNavigationToolbarVisibility(!adTabbox.getSelectedGridTab().isSortTab()); + + if (callback != null) + callback.onCallback(true); + } + + private void updateToolbar() + { + toolbar.enableTabNavigation(breadCrumb.hasParentLink(), adTabbox.getSelectedDetailADTabpanel() != null); + + toolbar.getButton("Attachment").setPressed(adTabbox.getSelectedGridTab().hasAttachment()); + toolbar.getButton("Chat").setPressed(adTabbox.getSelectedGridTab().hasChat()); + toolbar.getButton("Find").setPressed(adTabbox.getSelectedGridTab().isQueryActive()); + + if (toolbar.isPersonalLock) + { + toolbar.lock(adTabbox.getSelectedGridTab().isLocked()); + } + + toolbar.enablePrint(adTabbox.getSelectedGridTab().isPrinted()); + + //Deepak-Enabling customize button IDEMPIERE-364 + if(!(adTabbox.getSelectedTabpanel() instanceof ADSortTab)) + toolbar.enableCustomize(((ADTabpanel)adTabbox.getSelectedTabpanel()).isGridView()); + else + toolbar.enableCustomize(false); + + } + + /** + * @param e + * @see DataStatusListener#dataStatusChanged(DataStatusEvent) + */ + public void dataStatusChanged(DataStatusEvent e) + { + //ignore non-ui thread event. + if (Executions.getCurrent() == null) + return; + + boolean detailTab = false; + if (e.getSource() instanceof GridTable) + { + GridTable gridTable = (GridTable) e.getSource(); + if (adTabbox.getSelectedGridTab() != null && adTabbox.getSelectedGridTab().getTableModel() != gridTable) { + detailTab = true; + } + } else if (e.getSource() instanceof GridTab) + { + GridTab gridTab = (GridTab)e.getSource(); + if (adTabbox.getSelectedGridTab() != gridTab) detailTab = true; + } + + if (!detailTab) + { + String dbInfo = e.getMessage(); + logger.info(dbInfo); + if (adTabbox.getSelectedGridTab() != null && adTabbox.getSelectedGridTab().isQueryActive()) + dbInfo = "[ " + dbInfo + " ]"; + breadCrumb.setStatusDB(dbInfo, e); + } else if (adTabbox.getSelectedDetailADTabpanel() == null) + { + return; + } + + // Set Message / Info + if (e.getAD_Message() != null || e.getInfo() != null) + { + if (GridTab.DEFAULT_STATUS_MESSAGE.equals(e.getAD_Message())) + { + if (detailTab) { + adTabbox.setDetailPaneStatusMessage("", false); + } else { + breadCrumb.setStatusLine ("", false); + } + } + else + { + StringBuilder sb = new StringBuilder(); + String msg = e.getMessage(); + if (msg != null && msg.length() > 0) + { + sb.append(Msg.getMsg(Env.getCtx(), e.getAD_Message())); + } + String info = e.getInfo(); + if (info != null && info.length() > 0) + { + if (sb.length() > 0 && !sb.toString().trim().endsWith(":")) + sb.append(": "); + sb.append(info); + } + if (sb.length() > 0) + { + int pos = sb.indexOf("\n"); + if (pos != -1 && pos+1 < sb.length()) // replace CR/NL + { + sb.replace(pos, pos+1, " - "); + } + if (detailTab) { + adTabbox.setDetailPaneStatusMessage(sb.toString (), e.isError ()); + } else { + breadCrumb.setStatusLine (sb.toString (), e.isError ()); + } + } + } + } + + IADTabpanel tabPanel = detailTab ? adTabbox.getSelectedDetailADTabpanel() + : getADTab().getSelectedTabpanel(); + + // Confirm Error + if (e.isError() && !e.isConfirmed() && tabPanel instanceof ADTabpanel) + { + //focus to error field + GridField[] fields = tabPanel.getGridTab().getFields(); + for (GridField field : fields) + { + if (field.isError()) + { + ((ADTabpanel)tabPanel).setFocusToField(field.getColumnName()); + break; + } + } + e.setConfirmed(true); // show just once - if MTable.setCurrentRow is involved the status event is re-issued + } + // Confirm Warning + else if (e.isWarning() && !e.isConfirmed()) + { + if (! adTabbox.getSelectedGridTab().getTableModel().isImporting()) { + FDialog.warn(curWindowNo, null, e.getAD_Message(), e.getInfo()); + e.setConfirmed(true); // show just once - if MTable.setCurrentRow is involved the status event is re-issued + } + } + + boolean changed = e.isChanged() || e.isInserting(); + boolean readOnly = adTabbox.getSelectedGridTab().isReadOnly(); + boolean insertRecord = !readOnly; + if (!detailTab) + { + // update Change + boolChanges = changed; + + if (insertRecord) + { + insertRecord = tabPanel.getGridTab().isInsertRecord(); + } + toolbar.enableNew(!changed && insertRecord && !tabPanel.getGridTab().isSortTab()); + toolbar.enableRefresh(!changed); + toolbar.enableDelete(!changed && !readOnly && !tabPanel.getGridTab().isSortTab()); + // + if (readOnly && adTabbox.getSelectedGridTab().isAlwaysUpdateField()) + { + readOnly = false; + } + } + else + { + adTabbox.updateDetailPaneToolbar(changed, readOnly); + } + toolbar.enableIgnore(adTabbox.needSave(true, false) || + adTabbox.getSelectedGridTab().isNew() || + (adTabbox.getSelectedDetailADTabpanel() != null && adTabbox.getSelectedDetailADTabpanel().getGridTab().isNew())); + + if (changed && !readOnly && !toolbar.isSaveEnable() ) { + if (tabPanel.getGridTab().getRecord_ID() > 0) { + if (adTabbox.getSelectedIndex() == 0 && !detailTab) { + MRecentItem.addModifiedField(ctx, adTabbox.getSelectedGridTab().getAD_Table_ID(), + adTabbox.getSelectedGridTab().getRecord_ID(), Env.getAD_User_ID(ctx), + Env.getAD_Role_ID(ctx), adTabbox.getSelectedGridTab().getAD_Window_ID(), + adTabbox.getSelectedGridTab().getAD_Tab_ID()); + } else { + /* when a detail record is modified add header to recent items */ + GridTab mainTab = gridWindow.getTab(0); + if (mainTab != null) { + MRecentItem.addModifiedField(ctx, mainTab.getAD_Table_ID(), + mainTab.getRecord_ID(), Env.getAD_User_ID(ctx), + Env.getAD_Role_ID(ctx), mainTab.getAD_Window_ID(), + mainTab.getAD_Tab_ID()); + } + } + } + } + + toolbar.enableSave(adTabbox.needSave(true, false) || + adTabbox.getSelectedGridTab().isNew() || + (adTabbox.getSelectedDetailADTabpanel() != null && adTabbox.getSelectedDetailADTabpanel().getGridTab().isNew())); + + // + // No Rows + if (e.getTotalRows() == 0 && insertRecord && !detailTab) + { + toolbar.enableNew(true); + toolbar.enableDelete(false); + } + + // Transaction info + if (!detailTab) + { + String trxInfo = adTabbox.getSelectedGridTab().getTrxInfo(); + if (trxInfo != null) + { + statusBar.setInfo(trxInfo); + } + } + + // Check Attachment + boolean canHaveAttachment = adTabbox.getSelectedGridTab().canHaveAttachment(); // not single _ID column + // + if (canHaveAttachment && e.isLoading() && + adTabbox.getSelectedGridTab().getCurrentRow() > e.getLoadedRows()) + { + canHaveAttachment = false; + } + if (canHaveAttachment && adTabbox.getSelectedGridTab().getRecord_ID() == -1) // No Key + { + canHaveAttachment = false; + } + if (canHaveAttachment) + { + toolbar.enableAttachment(true); + toolbar.getButton("Attachment").setPressed(adTabbox.getSelectedGridTab().hasAttachment()); + } + else + { + toolbar.enableAttachment(false); + } + + // Check Chat + boolean canHaveChat = true; + if (e.isLoading() && + adTabbox.getSelectedGridTab().getCurrentRow() > e.getLoadedRows()) + { + canHaveChat = false; + } + if (canHaveChat && adTabbox.getSelectedGridTab().getRecord_ID() == -1) // No Key + { + canHaveChat = false; + } + if (canHaveChat) + { + toolbar.enableChat(true); + toolbar.getButton("Chat").setPressed(adTabbox.getSelectedGridTab().hasChat()); + } + else + { + toolbar.enableChat(false); + } + + toolbar.getButton("Find").setPressed(adTabbox.getSelectedGridTab().isQueryActive()); + + // Elaine 2008/12/05 + // Lock Indicator + if (toolbar.isPersonalLock) + { + toolbar.lock(adTabbox.getSelectedGridTab().isLocked()); + } + // + + if (!detailTab) + { + adTabbox.evaluate(e); + } + + toolbar.enablePrint(adTabbox.getSelectedGridTab().isPrinted()); + toolbar.enableReport(true); + toolbar.enableExport(!adTabbox.getSelectedGridTab().isSortTab()); + toolbar.enableFileImport(!changed && !adTabbox.getSelectedGridTab().isSortTab() && adTabbox.getSelectedGridTab().isInsertRecord()); + + //Deepak-Enabling customize button IDEMPIERE-364 + if(!(adTabbox.getSelectedTabpanel() instanceof ADSortTab)) + toolbar.enableCustomize(((ADTabpanel)adTabbox.getSelectedTabpanel()).isGridView()); + } + + /** + * @return boolean + */ + public boolean isFirstTab() + { + int selTabIndex = adTabbox.getSelectedIndex(); + return (selTabIndex == 0); + } + + /** + * refresh all row + * @param fireEvent + */ + public void onRefresh(final boolean fireEvent) + { + onRefresh(fireEvent, true); + } + + /** + * refresh all row + * @param fireEvent + * @param saveCurrentRow + */ + public void onRefresh(final boolean fireEvent, final boolean saveCurrentRow) + { + if (saveCurrentRow) + { + onSave(false, true, new Callback() { + + @Override + public void onCallback(Boolean result) { + adTabbox.getSelectedGridTab().dataRefreshAll(fireEvent, true); + adTabbox.getSelectedTabpanel().dynamicDisplay(0); + focusToActivePanel(); + } + }); + } + else + { + adTabbox.getSelectedGridTab().dataRefreshAll(fireEvent, true); + adTabbox.getSelectedTabpanel().dynamicDisplay(0); + focusToActivePanel(); + } + } + + /** + * @see ToolbarListener#onRefresh() + */ + public void onRefresh() + { + onRefresh(true); + } + + /** + * @see ToolbarListener#onHelp() + */ + public void onHelp() + { + WebDoc doc = gridWindow.getHelpDoc(true); + SessionManager.getAppDesktop().showURL(doc, "Help", true); + } + + /** + * @see ToolbarListener#onNew() + */ + public void onNew() + { + if (!adTabbox.getSelectedGridTab().isInsertRecord()) + { + logger.warning("Insert Record disabled for Tab"); + return; + } + + saveAndNavigate(new Callback() { + @Override + public void onCallback(Boolean result) { + if (result) + { + newRecord = adTabbox.getSelectedGridTab().dataNew(false); + if (newRecord) + { + adTabbox.getSelectedTabpanel().dynamicDisplay(0); + toolbar.enableNew(false); + toolbar.enableDelete(false); + breadCrumb.enableFirstNavigation(adTabbox.getSelectedGridTab().getCurrentRow() > 0); + breadCrumb.enableLastNavigation(adTabbox.getSelectedGridTab().getCurrentRow() + 1 < adTabbox.getSelectedGridTab().getRowCount()); + toolbar.enableTabNavigation(breadCrumb.hasParentLink(), adTabbox.getSelectedDetailADTabpanel() != null); + toolbar.enableIgnore(true); + toolbar.enablePrint(adTabbox.getSelectedGridTab().isPrinted()); + toolbar.enableReport(true); + } + else + { + logger.severe("Could not create new record"); + } + focusToActivePanel(); + } + } + }); + } + + // Elaine 2008/11/19 + /** + * @see ToolbarListener#onCopy() + */ + public void onCopy() + { + if (!adTabbox.getSelectedGridTab().isInsertRecord()) + { + logger.warning("Insert Record disabled for Tab"); + return; + } + + newRecord = adTabbox.getSelectedGridTab().dataNew(true); + if (newRecord) + { + adTabbox.getSelectedTabpanel().dynamicDisplay(0); + toolbar.enableNew(false); + toolbar.enableDelete(false); + breadCrumb.enableFirstNavigation(adTabbox.getSelectedGridTab().getCurrentRow() > 0); + breadCrumb.enableLastNavigation(adTabbox.getSelectedGridTab().getCurrentRow() + 1 < adTabbox.getSelectedGridTab().getRowCount()); + toolbar.enableTabNavigation(false); + toolbar.enableIgnore(true); + toolbar.enablePrint(adTabbox.getSelectedGridTab().isPrinted()); + toolbar.enableReport(true); + } + else + { + logger.severe("Could not create new record"); + } + focusToActivePanel(); + } + // + + /** + * @see ToolbarListener#onFind() + */ + public void onFind() + { + if (adTabbox.getSelectedGridTab() == null) + return; + + onSave(false, false, new Callback() { + + @Override + public void onCallback(Boolean result) { + if (result) { + doOnFind(); + } + } + }); + } + + private void doOnFind() { + adTabbox.dataIgnore(); + + // Gets Fields from AD_Field_v + GridField[] findFields = adTabbox.getSelectedGridTab().getFields(); + if (findWindow == null || !findWindow.validate(adTabbox.getSelectedGridTab().getWindowNo(), adTabbox.getSelectedGridTab().getName(), + adTabbox.getSelectedGridTab().getAD_Table_ID(), adTabbox.getSelectedGridTab().getTableName(), + adTabbox.getSelectedGridTab().getWhereExtended(), findFields, 1, adTabbox.getSelectedGridTab().getAD_Tab_ID())) { + findWindow = new FindWindow (adTabbox.getSelectedGridTab().getWindowNo(), adTabbox.getSelectedGridTab().getName(), + adTabbox.getSelectedGridTab().getAD_Table_ID(), adTabbox.getSelectedGridTab().getTableName(), + adTabbox.getSelectedGridTab().getWhereExtended(), findFields, 1, adTabbox.getSelectedGridTab().getAD_Tab_ID()); + + setupEmbeddedFindwindow(); + if (!findWindow.initialize()) { + if (findWindow.getTotalRecords() == 0) { + FDialog.info(curWindowNo, getComponent(), "NoRecordsFound"); + } + return; + } + } + + if (!findWindow.getEventListeners(DialogEvents.ON_WINDOW_CLOSE).iterator().hasNext()) { + findWindow.addEventListener(DialogEvents.ON_WINDOW_CLOSE, new EventListener() { + @Override + public void onEvent(Event event) throws Exception { + hideBusyMask(); + if (!findWindow.isCancel()) + { + MQuery query = findWindow.getQuery(); + + // Confirmed query + if (query != null) + { + m_onlyCurrentRows = false; // search history too + adTabbox.getSelectedGridTab().setQuery(query); + adTabbox.getSelectedTabpanel().query(m_onlyCurrentRows, m_onlyCurrentDays, MRole.getDefault().getMaxQueryRecords()); // autoSize + } + + if (findWindow.isCreateNew()) + onNew(); + else + adTabbox.getSelectedGridTab().dataRefresh(false); // Elaine 2008/07/25 + } + else + { + toolbar.getButton("Find").setPressed(adTabbox.getSelectedGridTab().isQueryActive()); + } + focusToActivePanel(); + } + }); + } + + showBusyMask(); + getComponent().getParent().appendChild(findWindow); + LayoutUtils.openEmbeddedWindow(toolbar, findWindow, "after_start"); + } + + /** + * @see ToolbarListener#onIgnore() + */ + public void onIgnore() + { + IADTabpanel dirtyTabpanel = adTabbox.getDirtyADTabpanel(); + boolean newrecod = adTabbox.getSelectedGridTab().isNew(); + if (dirtyTabpanel != null && dirtyTabpanel.getGridTab().isSortTab()) + { + dirtyTabpanel.refresh(); + toolbar.enableIgnore(false); + } + else + { + adTabbox.dataIgnore(); + toolbar.enableIgnore(false); + if (newrecod) { + onRefresh(true); + } else if (dirtyTabpanel != null) { + dirtyTabpanel.getGridTab().dataRefresh(true); // update statusbar & toolbar + dirtyTabpanel.dynamicDisplay(0); + } + + } + if (dirtyTabpanel != null) + focusToTabpanel(dirtyTabpanel); + } + + /** + * @see ToolbarListener#onSave() + */ + public void onSave() + { + final IADTabpanel dirtyTabpanel = adTabbox.getDirtyADTabpanel(); + onSave(true, false, new Callback() { + @Override + public void onCallback(Boolean result) + { + if (result) + { + String statusLine = breadCrumb.getStatusLine(); + adTabbox.getSelectedGridTab().dataRefreshAll(true, true); + breadCrumb.setStatusLine(statusLine); + } + if (dirtyTabpanel != null) { + if (dirtyTabpanel == adTabbox.getSelectedDetailADTabpanel()) + Clients.scrollIntoView(dirtyTabpanel); + focusToTabpanel(dirtyTabpanel); + } else { + focusToActivePanel(); + } + } + }); + } + + public void onSavePayment() + { + onSave(false, false, new Callback() { + + @Override + public void onCallback(Boolean result) { + onRefresh(true, false); + } + + }); + } + + /** + * @param onSaveEvent + */ + private void onSave(final boolean onSaveEvent, final boolean onNavigationEvent, final Callback callback) + { + final boolean wasChanged = toolbar.isSaveEnable(); + IADTabpanel dirtyTabpanel = adTabbox.getDirtyADTabpanel(); + final boolean newRecord = dirtyTabpanel != null ? (dirtyTabpanel.getGridTab().getRecord_ID() <= 0) : false; + if (dirtyTabpanel == null) { + onSave0(onSaveEvent, onNavigationEvent, newRecord, wasChanged, callback); + return; + } + if (dirtyTabpanel instanceof ADSortTab) + { + ADSortTab sortTab = (ADSortTab) dirtyTabpanel; + sortTab.saveData(); + + if (!onNavigationEvent) + { + toolbar.enableSave(sortTab.isChanged()); // set explicitly + toolbar.enableIgnore(sortTab.isChanged()); + } + if (!sortTab.isChanged()) { + if (sortTab == adTabbox.getSelectedTabpanel()) { + breadCrumb.setStatusLine(Msg.getMsg(Env.getCtx(), "Saved")); + } else { + adTabbox.setDetailPaneStatusMessage(Msg.getMsg(Env.getCtx(), "Saved"), false); + } + } + if (callback != null) + callback.onCallback(true); + } + else + { + if (!Util.isEmpty(dirtyTabpanel.getGridTab().getCommitWarning()) || + (!Env.isAutoCommit(ctx, curWindowNo) && onNavigationEvent)) + { + FDialog.ask(curWindowNo, this.getComponent(), "SaveChanges?", dirtyTabpanel.getGridTab().getCommitWarning(), new Callback() { + + @Override + public void onCallback(Boolean result) + { + if (result) + { + onSave0(onSaveEvent, onNavigationEvent, newRecord, wasChanged, callback); + } + else + { + if (callback != null) + callback.onCallback(false); + } + } + }); + } + else + { + onSave0(onSaveEvent, onNavigationEvent, newRecord, wasChanged, callback); + } + } + } + + private void onSave0(boolean onSaveEvent, boolean navigationEvent, + boolean newRecord, boolean wasChanged, Callback callback) { + IADTabpanel dirtyTabpanel = adTabbox.getDirtyADTabpanel(); + boolean retValue = adTabbox.dataSave(onSaveEvent); + + if (!retValue) + { + showLastError(); + if (callback != null) + callback.onCallback(false); + return; + } else if (!onSaveEvent && dirtyTabpanel != null) //need manual refresh + { + dirtyTabpanel.getGridTab().setCurrentRow(dirtyTabpanel.getGridTab().getCurrentRow()); + } + + if (!navigationEvent && dirtyTabpanel != null) { + dirtyTabpanel.dynamicDisplay(0); + dirtyTabpanel.afterSave(onSaveEvent); + } + + IADTabpanel dirtyTabpanel2 = adTabbox.getDirtyADTabpanel(); + if (dirtyTabpanel2 != null && dirtyTabpanel2 != dirtyTabpanel) { + onSave(onSaveEvent, navigationEvent, callback); + return; + } + + if (wasChanged) { + if (newRecord) { + if (adTabbox.getSelectedGridTab().getRecord_ID() > 0) { + if (adTabbox.getSelectedIndex() == 0) { + MRecentItem.addModifiedField(ctx, adTabbox.getSelectedGridTab().getAD_Table_ID(), + adTabbox.getSelectedGridTab().getRecord_ID(), Env.getAD_User_ID(ctx), + Env.getAD_Role_ID(ctx), adTabbox.getSelectedGridTab().getAD_Window_ID(), + adTabbox.getSelectedGridTab().getAD_Tab_ID()); + } else { + /* when a detail record is modified add header to recent items */ + GridTab mainTab = gridWindow.getTab(0); + if (mainTab != null) { + MRecentItem.addModifiedField(ctx, mainTab.getAD_Table_ID(), + mainTab.getRecord_ID(), Env.getAD_User_ID(ctx), + Env.getAD_Role_ID(ctx), mainTab.getAD_Window_ID(), + mainTab.getAD_Tab_ID()); + } + } + } + } else { + if (adTabbox.getSelectedIndex() == 0) { + MRecentItem.touchUpdatedRecord(ctx, adTabbox.getSelectedGridTab().getAD_Table_ID(), + adTabbox.getSelectedGridTab().getRecord_ID(), Env.getAD_User_ID(ctx)); + } else { + GridTab mainTab = gridWindow.getTab(0); + if (mainTab != null) { + MRecentItem.touchUpdatedRecord(ctx, mainTab.getAD_Table_ID(), + mainTab.getRecord_ID(), Env.getAD_User_ID(ctx)); + } + } + } + } + + if (dirtyTabpanel != null && dirtyTabpanel.getGridTab().isDetail()) { + dirtyTabpanel.getGridTab().refreshParentTabs(); + } + + if (callback != null) + callback.onCallback(true); + } + + private void showLastError() { + String msg = CLogger.retrieveErrorString(null); + if (msg != null) + { + breadCrumb.setStatusLine(Msg.getMsg(Env.getCtx(), msg), true); + } + //other error will be catch in the dataStatusChanged event + } + + /** + * @see ToolbarListener#onSaveCreate() + */ + public void onSaveCreate() + { + onSave(true, true, new Callback() { + + @Override + public void onCallback(Boolean result) + { + if(result) + { + adTabbox.getSelectedGridTab().dataRefreshAll(true, true); + onNew(); + } + } + }); + } + + /** + * @see ToolbarListener#onDelete() + */ + public void onDelete() + { + if (adTabbox.getSelectedGridTab().isReadOnly()) + { + return; + } + + FDialog.ask(curWindowNo, null, "DeleteRecord?", new Callback() { + + @Override + public void onCallback(Boolean result) + { + if (result) + { + //error will be catch in the dataStatusChanged event + adTabbox.getSelectedGridTab().dataDelete(); + + adTabbox.getSelectedTabpanel().dynamicDisplay(0); + focusToActivePanel(); + } + } + }); + } + + // Elaine 2008/12/01 + /** + * @see ToolbarListener#onDelete() + */ + public void onDeleteSelection() + { + if (adTabbox.getSelectedGridTab().isReadOnly()) + { + return; + } + + //show table with deletion rows -> value, name... + final Window messagePanel = new Window(); + messagePanel.setBorder("normal"); + messagePanel.setWidth("600px"); + messagePanel.setTitle(Msg.getMsg(Env.getCtx(), "Find").replaceAll("&", "") + ": " + title); + messagePanel.setClosable(true); + messagePanel.setSizable(true); + messagePanel.setWidgetAttribute(AdempiereWebUI.WIDGET_INSTANCE_NAME, "deleteSelection"); + + final Listbox listbox = new Listbox(); + listbox.setHeight("400px"); + + // Display the first 5 fields data exclude Organization, Client and YesNo field data + ArrayList columnNames = new ArrayList(); + GridField[] fields = adTabbox.getSelectedGridTab().getFields(); + if(adTabbox.getSelectedGridTab().getField("DocumentNo")!=null){ + columnNames.add(adTabbox.getSelectedGridTab().getField("DocumentNo").getColumnName()); + } + if(adTabbox.getSelectedGridTab().getField("Line")!=null){ + columnNames.add(adTabbox.getSelectedGridTab().getField("Line").getColumnName()); + } + if(adTabbox.getSelectedGridTab().getField("Value")!=null){ + columnNames.add(adTabbox.getSelectedGridTab().getField("Value").getColumnName()); + } + if(adTabbox.getSelectedGridTab().getField("Name")!=null){ + columnNames.add(adTabbox.getSelectedGridTab().getField("Name").getColumnName()); + } + for(int i = 0; i < fields.length; i++) + { + GridField field = fields[i]; + if(field.getColumnName().equalsIgnoreCase("AD_Org_ID") + || field.getColumnName().equalsIgnoreCase("AD_Client_ID") + || field.getDisplayType() == DisplayType.YesNo) + continue; + if (!columnNames.contains(field.getColumnName())) + { + columnNames.add(field.getColumnName()); + } + } + + ArrayList data = new ArrayList(); + int noOfRows = adTabbox.getSelectedGridTab().getRowCount(); + for(int i=0; i parentColumnNames = adTabbox.getSelectedGridTab().getParentColumnNames(); + for (Iterator iter = parentColumnNames.iterator(); iter.hasNext();) + { + String columnName = iter.next(); + GridField field = adTabbox.getSelectedGridTab().getField(columnName); + if(field.isLookup()){ + Lookup lookup = field.getLookup(); + if (lookup != null){ + displayValue = displayValue.append(lookup.getDisplay(adTabbox.getSelectedGridTab().getValue(i,columnName))).append(" | "); + } else { + displayValue = displayValue.append(adTabbox.getSelectedGridTab().getValue(i,columnName)).append(" | "); + } + } else { + displayValue = displayValue.append(adTabbox.getSelectedGridTab().getValue(i,columnName)).append(" | "); + } + } + } else { + displayValue = displayValue.append(adTabbox.getSelectedGridTab().getValue(i,adTabbox.getSelectedGridTab().getKeyColumnName())); + } + + int count = 0; + for(int j=0; j < columnNames.size() && count < 5; j++) + { + Object value = adTabbox.getSelectedGridTab().getValue(i, columnNames.get(j)); + if(value == null) continue; // skip when value is null + String text = value.toString().trim(); + if(text.length() == 0) continue; // skip when value is empty + GridField field = adTabbox.getSelectedGridTab().getField(columnNames.get(j)); + if(field != null) + { + if (field.isLookup()) + { + Lookup lookup = field.getLookup(); + if (lookup != null) + text = lookup.getDisplay(value); + } + else if (DisplayType.isDate(field.getDisplayType())) + { + text = DisplayType.getDateFormat(field.getDisplayType()).format(value); + } + } + if(text.length() > 30) + text = text.substring(0, 30); // display the first 30 characters + displayValue = displayValue.append(" | ").append(text); + count++; + } + + data.add(displayValue.toString()); + } + + for(int i = 0; i < data.size(); i++) + { + String record = data.get(i); + listbox.appendItem(record, record); + } + + listbox.setMultiple(true); + messagePanel.appendChild(listbox); + + Div div = new Div(); + div.setStyle("text-align: center"); + messagePanel.appendChild(div); + + Hbox hbox = new Hbox(); + div.appendChild(hbox); + + Button btnOk = new Button(); + // Invert - Unify OK/Cancel IDEMPIERE-77 + //btnOk.setLabel(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "OK"))); + btnOk.setImage("/images/Ok16.png"); + btnOk.addEventListener(Events.ON_CLICK, new EventListener() + { + public void onEvent(Event event) throws Exception + { + FDialog.ask(curWindowNo, messagePanel, "DeleteSelection", new Callback() { + + @Override + public void onCallback(Boolean result) + { + if (result) + { + logger.fine("ok"); + Set selectedValues = listbox.getSelectedItems(); + if(selectedValues != null) + { + for(Iterator iter = selectedValues.iterator(); iter.hasNext();) + { + Listitem li = iter.next(); + if(li != null) + logger.fine((String) li.getValue()); + } + } + + int[] indices = listbox.getSelectedIndices(); + Arrays.sort(indices); + int offset = 0; + for (int i = 0; i < indices.length; i++) + { + adTabbox.getSelectedGridTab().navigate(indices[i]-offset); + if (adTabbox.getSelectedGridTab().dataDelete()) + { + offset++; + } + } + adTabbox.getSelectedTabpanel().dynamicDisplay(0); + + messagePanel.dispose(); + } else { + logger.fine("cancel"); + } + } + + }); + } + }); + hbox.appendChild(btnOk); + + Button btnCancel = new Button(); + //btnCancel.setLabel(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "Cancel"))); + btnCancel.setImage("/images/Cancel16.png"); + btnCancel.addEventListener(Events.ON_CLICK, new EventListener() + { + public void onEvent(Event event) throws Exception + { + messagePanel.dispose(); + } + }); + hbox.appendChild(btnCancel); + hbox.setPack("end"); + hbox.setHflex("1"); + + messagePanel.addEventListener(DialogEvents.ON_WINDOW_CLOSE, new EventListener() { + @Override + public void onEvent(Event event) throws Exception { + hideBusyMask(); + focusToActivePanel(); + } + }); + showBusyMask(); + getComponent().getParent().appendChild(messagePanel); + LayoutUtils.openOverlappedWindow(getComponent(), messagePanel, "middle_center"); + } + // + + /** + * @see ToolbarListener#onPrint() + */ + public void onPrint() { + //Get process defined for this tab + final int AD_Process_ID = adTabbox.getSelectedGridTab().getAD_Process_ID(); + //log.info("ID=" + AD_Process_ID); + + // No report defined + if (AD_Process_ID == 0) + { + onReport(); + + return; + } + + Callback callback = new Callback() { + @Override + public void onCallback(Boolean result) { + if (result) { + int table_ID = adTabbox.getSelectedGridTab().getAD_Table_ID(); + int record_ID = adTabbox.getSelectedGridTab().getRecord_ID(); + + ProcessModalDialog dialog = new ProcessModalDialog(AbstractADWindowContent.this, getWindowNo(), AD_Process_ID,table_ID, record_ID, true); + if (dialog.isValid()) { + dialog.setWidth("500px"); + dialog.setBorder("normal"); + showBusyMask(); + getComponent().getParent().appendChild(dialog); + LayoutUtils.openOverlappedWindow(getComponent(), dialog, "middle_center"); + dialog.focus(); + } + } + } + }; + onSave(false, false, callback); + } + + /** + * @see ToolbarListener#onReport() + */ + public void onReport() { + if (!MRole.getDefault().isCanReport(adTabbox.getSelectedGridTab().getAD_Table_ID())) + { + FDialog.error(curWindowNo, parent, "AccessCannotReport"); + return; + } + + Callback callback = new Callback() { + + @Override + public void onCallback(Boolean result) { + if (result) { + onReport0(); + } + } + }; + onSave(false, false, callback); + } + + private void onReport0() { + ReportAction reportAction = new ReportAction(this); + reportAction.show(); + } + + /** + * @see ToolbarListener#onZoomAcross() + */ + public void onZoomAcross() { + if (toolbar.getEvent() != null) + { + int record_ID = adTabbox.getSelectedGridTab().getRecord_ID(); + if (record_ID <= 0) + return; + + // Query + MQuery query = new MQuery(); + // Current row + String link = adTabbox.getSelectedGridTab().getKeyColumnName(); + // Link for detail records + if (link.length() == 0) + link = adTabbox.getSelectedGridTab().getLinkColumnName(); + if (link.length() != 0) + { + if (link.endsWith("_ID")) + query.addRestriction(link, MQuery.EQUAL, + new Integer(Env.getContextAsInt(ctx, curWindowNo, link))); + else + query.addRestriction(link, MQuery.EQUAL, + Env.getContext(ctx, curWindowNo, link)); + } + new WZoomAcross(toolbar.getEvent().getTarget(), adTabbox.getSelectedGridTab() + .getTableName(), adTabbox.getSelectedGridTab().getAD_Window_ID(), query); + } + } + + // Elaine 2008/07/17 + /** + * @see ToolbarListener#onActiveWorkflows() + */ + public void onActiveWorkflows() { + if (toolbar.getEvent() != null) + { + if (adTabbox.getSelectedGridTab().getRecord_ID() <= 0) + return; + else + AEnv.startWorkflowProcess(adTabbox.getSelectedGridTab().getAD_Table_ID(), adTabbox.getSelectedGridTab().getRecord_ID()); + } + } + // + + // Elaine 2008/07/22 + /** + * @see ToolbarListener#onRequests() + */ + public void onRequests() + { + if (toolbar.getEvent() != null) + { + if (adTabbox.getSelectedGridTab().getRecord_ID() <= 0) + return; + + int C_BPartner_ID = 0; + Object bpartner = adTabbox.getSelectedGridTab().getValue("C_BPartner_ID"); + if(bpartner != null) + C_BPartner_ID = Integer.valueOf(bpartner.toString()); + + new WRequest(toolbar.getEvent().getTarget(), adTabbox.getSelectedGridTab().getAD_Table_ID(), adTabbox.getSelectedGridTab().getRecord_ID(), C_BPartner_ID); + } + } + // + + // Elaine 2008/07/22 + /** + * @see ToolbarListener#onProductInfo() + */ + public void onProductInfo() + { + InfoPanel.showProduct(0); + } + // + + + // Elaine 2008/07/28 + /** + * @see ToolbarListener#onArchive() + */ + public void onArchive() + { + if (toolbar.getEvent() != null) + { + if (adTabbox.getSelectedGridTab().getRecord_ID() <= 0) + return; + + new WArchive(toolbar.getEvent().getTarget(), adTabbox.getSelectedGridTab().getAD_Table_ID(), adTabbox.getSelectedGridTab().getRecord_ID()); + } + } + + // + + @Override + public void onExport() { + ExportAction action = new ExportAction(this); + action.export(); + } + + @Override + public void onFileImport() { + FileImportAction action = new FileImportAction(this); + action.fileImport(); + } + + /************************************************************************** + * Start Button Process + * @param vButton button + */ + private void actionButton (final IProcessButton wButton) + { + if (adTabbox.getSelectedGridTab().hasChangedCurrentTabAndParents()) { + String msg = CLogger.retrieveErrorString("Please ReQuery Window"); + FDialog.error(curWindowNo, parent, null, msg); + return; + } + + logger.info(wButton.toString()); + + final String col = wButton.getColumnName(); + + // Zoom + if (col.equals("Record_ID")) + { + int AD_Table_ID = Env.getContextAsInt (ctx, curWindowNo, "AD_Table_ID"); + int Record_ID = Env.getContextAsInt (ctx, curWindowNo, "Record_ID"); + + AEnv.zoom(AD_Table_ID, Record_ID); + return; + } // Zoom + + // save first --------------- + + if (adTabbox.needSave(true, false)) + { + onSave(false, false, new Callback() { + @Override + public void onCallback(Boolean result) { + if (result) { + actionButton0(col, wButton); + } + } + }); + } + else + { + actionButton0(col, wButton); + } + } + + /************************************************************************** + * Start Button Process + * @param col + * @param wButton + */ + private void actionButton0 (String col, final IProcessButton wButton) + { + final IADTabpanel adtabPanel = findADTabpanel(wButton); + boolean startWOasking = false; + final int table_ID = adtabPanel.getGridTab().getAD_Table_ID(); + + // Record_ID + + int record_ID = adtabPanel.getGridTab().getRecord_ID(); + + // Record_ID - Language Handling + + if (record_ID == -1 && adtabPanel.getGridTab().getKeyColumnName().equals("AD_Language")) + record_ID = Env.getContextAsInt (ctx, curWindowNo, "AD_Language_ID"); + + // Record_ID - Change Log ID + + if (record_ID == -1 + && (wButton.getProcess_ID() == PROCESS_AD_CHANGELOG_UNDO || wButton.getProcess_ID() == PROCESS_AD_CHANGELOG_REDO)) + { + Integer id = (Integer)adtabPanel.getGridTab().getValue("AD_ChangeLog_ID"); + record_ID = id.intValue(); + } + + // Ensure it's saved + + if (record_ID == -1 && adtabPanel.getGridTab().getKeyColumnName().endsWith("_ID")) + { + FDialog.error(curWindowNo, parent, "SaveErrorRowNotFound"); + return; + } + + boolean isProcessMandatory = false; + // Pop up Document Action (Workflow) + if (col.equals("DocAction")) + { + final WDocActionPanel win = new WDocActionPanel(adtabPanel.getGridTab()); + if (win.getNumberOfOptions() == 0) + { + logger.info("DocAction - No Options"); + return; + } + else + { + final int recordIdParam = record_ID; + win.addEventListener(DialogEvents.ON_WINDOW_CLOSE, new EventListener() { + public void onEvent(Event event) throws Exception { + hideBusyMask(); + if (!win.isStartProcess()) { + return; + } + boolean startWOasking = true; + boolean isProcessMandatory = true; + executeButtonProcess(wButton, startWOasking, table_ID, recordIdParam, isProcessMandatory); + } + }); + showBusyMask(); + getComponent().getParent().appendChild(win); + LayoutUtils.openOverlappedWindow(getComponent(), win, "middle_center"); + win.focus(); + return; + } + } // DocAction + + // Pop up Create From + else if (col.equals("CreateFrom") || col.equals("X_CreateFromBatch")) + { + ICreateFrom cf = WCreateFromFactory.create(adtabPanel.getGridTab(), col); + + if(cf != null) + { + if(cf.isInitOK()) + { + final WCreateFromWindow window = (WCreateFromWindow) cf.getWindow(); + window.setWidgetAttribute(AdempiereWebUI.WIDGET_INSTANCE_NAME, AdempiereIdGenerator.escapeId(window.getTitle())); + window.addEventListener(DialogEvents.ON_WINDOW_CLOSE, new EventListener() { + @Override + public void onEvent(Event event) throws Exception { + hideBusyMask(); + if (!window.isCancel()) { + onRefresh(true, false); + } + } + }); + window.setZindex(1000); + window.setMaximizable(true); + window.setSizable(true); + ZkCssHelper.appendStyle(window, "position: absolute; "); + showBusyMask(); + getComponent().getParent().appendChild(window); + cf.showWindow(); + LayoutUtils.openOverlappedWindow(getComponent(), window, "middle_center"); + window.focus(); + } + return; + } + // else may start process + } // CreateFrom + + // Posting ----- + + else if (col.equals("Posted") && MRole.getDefault().isShowAcct()) + { + // Check Doc Status + + String processed = Env.getContext(ctx, curWindowNo, "Processed"); + + if (!processed.equals("Y")) + { + String docStatus = Env.getContext(ctx, curWindowNo, "DocStatus"); + + if (DocAction.STATUS_Completed.equals(docStatus) + || DocAction.STATUS_Closed.equals(docStatus) + || DocAction.STATUS_Reversed.equals(docStatus) + || DocAction.STATUS_Voided.equals(docStatus)) + ; + else + { + FDialog.error(curWindowNo, parent, "PostDocNotComplete"); + return; + } + } + + // try to get table and record id from context data (eg for unposted view) + // otherwise use current table/record + int tableId = Env.getContextAsInt(ctx, curWindowNo, "AD_Table_ID", true); + int recordId = Env.getContextAsInt(ctx, curWindowNo, "Record_ID", true); + if ( tableId == 0 || recordId == 0 ) + { + tableId = adtabPanel.getGridTab().getAD_Table_ID(); + recordId = adtabPanel.getGridTab().getRecord_ID(); + } + + // Check Post Status + final Object ps = adtabPanel.getGridTab().getValue("Posted"); + + if (ps != null && ps.equals("Y")) + { + new org.adempiere.webui.acct.WAcctViewer(Env.getContextAsInt (ctx, curWindowNo, "AD_Client_ID"), + tableId, recordId); + } + else + { + final int tableIdRef = tableId; + final int recordIdRef = recordId; + FDialog.ask(curWindowNo, null, "PostImmediate?", new Callback() { + + @Override + public void onCallback(Boolean result) + { + if (result) + { + boolean force = ps != null && !ps.equals ("N"); // force when problems + + String error = AEnv.postImmediate (curWindowNo, Env.getAD_Client_ID(ctx), + tableIdRef, recordIdRef, force); + + if (error != null) + breadCrumb.setStatusLine(error, true); + + onRefresh(true, false); + } + } + }); + } + return; + } // Posted + + executeButtonProcess(wButton, startWOasking, table_ID, record_ID, + isProcessMandatory); + } // actionButton + + private Div getMaskDiv() { + if (maskDiv == null) { + maskDiv = new Div(); + maskDiv.setStyle("position: absolute; width: 100%; height: 100%; border: none; margin: 0; background-color: #e4e4e4; " + + "padding: 0; z-index:999; opacity:0.6; top: 0px; left: 0px;"); + } + return maskDiv; + } + + public void hideBusyMask() { + if (maskDiv != null && maskDiv.getParent() != null) { + maskDiv.detach(); + } + } + + public void showBusyMask() { + getComponent().getParent().appendChild(getMaskDiv()); + } + + private void executeButtonProcess(final IProcessButton wButton, + final boolean startWOasking, final int table_ID, final int record_ID, + boolean isProcessMandatory) { + /** + * Start Process ---- + */ + + logger.config("Process_ID=" + wButton.getProcess_ID() + ", Record_ID=" + record_ID); + + if (wButton.getProcess_ID() == 0) + { + if (isProcessMandatory) + { + FDialog.error(curWindowNo, null, null, Msg.parseTranslation(ctx, "@NotFound@ @AD_Process_ID@")); + } + return; + } + + // Save item changed + + if (adTabbox.needSave(true, false)) + { + onSave(false, false, new Callback() { + + @Override + public void onCallback(Boolean result) { + if (result) { + executeButtonProcess0(wButton, startWOasking, table_ID, record_ID); + } + } + }); + } + else + { + executeButtonProcess0(wButton, startWOasking, table_ID, record_ID); + } + } + + private void executeButtonProcess0(final IProcessButton wButton, + boolean startWOasking, int table_ID, int record_ID) { + // call form + MProcess pr = new MProcess(ctx, wButton.getProcess_ID(), null); + int adFormID = pr.getAD_Form_ID(); + if (adFormID != 0 ) + { + String title = wButton.getDescription(); + if (title == null || title.length() == 0) + title = wButton.getDisplay(); + ProcessInfo pi = new ProcessInfo (title, wButton.getProcess_ID(), table_ID, record_ID); + pi.setAD_User_ID (Env.getAD_User_ID(ctx)); + pi.setAD_Client_ID (Env.getAD_Client_ID(ctx)); + ADForm form = ADForm.openForm(adFormID); + form.setProcessInfo(pi); + Mode mode = form.getWindowMode(); + form.setAttribute(Window.MODE_KEY, form.getWindowMode()); + form.setAttribute(Window.INSERT_POSITION_KEY, Window.INSERT_NEXT); + if (mode == Mode.HIGHLIGHTED || mode == Mode.MODAL) { + form.addEventListener(DialogEvents.ON_WINDOW_CLOSE, new EventListener() { + @Override + public void onEvent(Event event) throws Exception { + hideBusyMask(); + onRefresh(true, false); + } + }); + showBusyMask(); + LayoutUtils.openOverlappedWindow(getComponent(), form, "middle_center"); + form.focus(); + } + else { + SessionManager.getAppDesktop().showWindow(form); + } + } + else + { + ProcessModalDialog dialog = new ProcessModalDialog(this, curWindowNo, wButton.getProcess_ID(), table_ID, record_ID, startWOasking); + + if (dialog.isValid()) + { + dialog.setWidth("500px"); + dialog.setBorder("normal"); + showBusyMask(); + getComponent().getParent().appendChild(dialog); + LayoutUtils.openOverlappedWindow(getComponent(), dialog, "middle_center"); + dialog.focus(); + } + else + { + onRefresh(true, false); + } + } + } + + /** + * @param event + * @see ActionListener#actionPerformed(ActionEvent) + */ + public void actionPerformed(final ActionEvent event) + { + Runnable runnable = new Runnable() { + public void run() { + String error = processButtonCallout((IProcessButton) event.getSource()); + if (error != null && error.trim().length() > 0) + { + breadCrumb.setStatusLine(error, true); + return; + } + actionButton((IProcessButton) event.getSource()); + } + }; + BusyDialogTemplate template = new BusyDialogTemplate(runnable); + template.run(); + } + + /************************************************************************** + * Process Callout(s). + *

    + * The Callout is in the string of + * "class.method;class.method;" + * If there is no class name, i.e. only a method name, the class is regarded + * as CalloutSystem. + * The class needs to comply with the Interface Callout. + * + * @param field field + * @return error message or "" + * @see org.compiere.model.Callout + */ + private String processButtonCallout (IProcessButton button) + { + IADTabpanel adtab = findADTabpanel(button); + if (adtab != null) { + GridField field = adtab.getGridTab().getField(button.getColumnName()); + if (field != null) + return adtab.getGridTab().processCallout(field); + else + return ""; + } else { + return ""; + } + } // processButtonCallout + + public IADTabpanel findADTabpanel(IProcessButton button) { + IADTabpanel adtab = null; + if (button.getADTabpanel() != null) + return button.getADTabpanel(); + + Component c = button instanceof WEditor ? ((WEditor)button).getComponent() : (Component)button; + while (c != null) { + if (c instanceof IADTabpanel) { + adtab = (IADTabpanel) c; + break; + } + c = c.getParent(); + } + return adtab; + } + + /** + * + * @return IADTab + */ + public IADTabbox getADTab() { + return adTabbox; + } + + /** + * @param pi + */ + public void executeASync(ProcessInfo pi) { + } + + /** + * @param pi + */ + private void onModalClose(ProcessInfo pi) { + boolean notPrint = pi != null + && pi.getAD_Process_ID() != adTabbox.getSelectedGridTab().getAD_Process_ID() + && pi.isReportingProcess() == false; + // + // Process Result + + if (Executions.getCurrent() != null) + { + if (notPrint) // refresh if not print + { + updateUI(pi); + } + } + else + { + try { + //acquire desktop, 2 second timeout + Executions.activate(getComponent().getDesktop(), 2000); + try { + if (notPrint) // refresh if not print + { + updateUI(pi); + } + } catch(Error ex){ + throw ex; + } finally{ + //release full control of desktop + Executions.deactivate(getComponent().getDesktop()); + } + } catch (Exception e) { + logger.log(Level.WARNING, "Failed to update UI upon unlock.", e); + } + } + } + + private void updateUI(ProcessInfo pi) { + // Timeout + if (pi.isTimeout()) // set temporarily to R/O + Env.setContext(ctx, curWindowNo, "Processed", "Y"); + // Update Status Line + String summary = pi.getSummary(); + if (summary != null && summary.indexOf('@') != -1) + pi.setSummary(Msg.parseTranslation(Env.getCtx(), summary)); + + // Get Log Info + ProcessInfoUtil.setLogFromDB(pi); + ProcessInfoLog m_logs[] = pi.getLogs(); + breadCrumb.setStatusLine(pi.getSummary(), pi.isError(),m_logs); + if (m_logs != null) { + ProcessInfoDialog dialog = new ProcessInfoDialog(AEnv.getDialogHeader(ctx, curWindowNo),Env.getHeader(ctx, curWindowNo), m_logs); + dialog.addEventListener(DialogEvents.ON_WINDOW_CLOSE, new EventListener() { + @Override + public void onEvent(Event event) throws Exception { + hideBusyMask(); + } + }); + showBusyMask(); + getComponent().getParent().appendChild(dialog); + LayoutUtils.openOverlappedWindow(this.getComponent(),dialog,"middle_center"); + } + + } + + /** + * + * @return toolbar instance + */ + public ADWindowToolbar getToolbar() { + return toolbar; + } + + /** + * @return active grid tab + */ + public GridTab getActiveGridTab() { + return adTabbox.getSelectedGridTab(); + } + + /** + * @return windowNo + */ + public int getWindowNo() { + return curWindowNo; + } + + /** + * @see ToolbarListener#onCustomize() + */ + public void onCustomize() { + ADTabpanel tabPanel = (ADTabpanel) getADTab().getSelectedTabpanel(); + Columns columns = tabPanel.getGridView().getListbox().getColumns(); + List columnList = columns.getChildren(); + GridField[] fields = tabPanel.getGridView().getFields(); + Map columnsWidth = new HashMap(); + ArrayList gridFieldIds = new ArrayList(); + for (int i = 0; i < fields.length; i++) { + Column column = (Column) columnList.get(i+1); + String width = column.getWidth(); + columnsWidth.put(fields[i].getAD_Field_ID(), width); + gridFieldIds.add(fields[i].getAD_Field_ID()); + + } + CustomizeGridViewDialog.showCustomize(0, adTabbox.getSelectedGridTab().getAD_Tab_ID(), columnsWidth,gridFieldIds,tabPanel.getGridView()); + } + + /** + * @see org.adempiere.webui.event.ToolbarListener#onProcess() + */ + @Override + public void onProcess() { + ProcessButtonPopup popup = new ProcessButtonPopup(); + popup.setWidgetAttribute(AdempiereWebUI.WIDGET_INSTANCE_NAME, "processButtonPopup"); + ADTabpanel adtab = (ADTabpanel) adTabbox.getSelectedTabpanel(); + popup.render(adtab.getToolbarButtons()); + + LayoutUtils.openPopupWindow(toolbar.getButton("Process"), popup, "after_start"); + } +} diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/DefaultCreateFromFactory.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/DefaultCreateFromFactory.java index be20ea36d3..d745d5960f 100644 --- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/DefaultCreateFromFactory.java +++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/DefaultCreateFromFactory.java @@ -21,27 +21,41 @@ import org.compiere.model.I_C_Invoice; import org.compiere.model.I_M_InOut; import org.compiere.model.I_M_PackageMPS; import org.compiere.model.I_M_RMA; +import org.compiere.model.I_X_DepositBatch; /** * * @author Elaine * */ -public class DefaultCreateFromFactory implements ICreateFromFactory { +public class DefaultCreateFromFactory implements ICreateFromFactory +{ @Override - public ICreateFrom create(GridTab mTab) { + public ICreateFrom create(GridTab mTab, String columnName) + { String tableName = mTab.getTableName(); - if (tableName.equals(I_C_Invoice.Table_Name)) - return new WCreateFromInvoiceUI(mTab); - else if (tableName.equals(I_C_BankStatement.Table_Name)) - return new WCreateFromStatementUI(mTab); - else if (tableName.equals(I_M_InOut.Table_Name)) - return new WCreateFromShipmentUI(mTab); - else if (tableName.equals(I_M_RMA.Table_Name)) - return new WCreateFromRMAUI(mTab); - else if (tableName.equals(I_M_PackageMPS.Table_Name)) - return new WCreateFromPackageShipmentUI(mTab); + if (columnName.equals("CreateFrom")) + { + if (tableName.equals(I_C_Invoice.Table_Name)) + return new WCreateFromInvoiceUI(mTab); + else if (tableName.equals(I_C_BankStatement.Table_Name)) +// return new WCreateFromStatementUI(mTab); + return new WCreateFromStatementBatchUI(mTab); + else if (tableName.equals(I_M_InOut.Table_Name)) + return new WCreateFromShipmentUI(mTab); + else if (tableName.equals(I_M_RMA.Table_Name)) + return new WCreateFromRMAUI(mTab); + else if (tableName.equals(I_M_PackageMPS.Table_Name)) + return new WCreateFromPackageShipmentUI(mTab); + else if (tableName.equals(I_X_DepositBatch.Table_Name)) + return new WCreateFromDepositBatchUI(mTab); + } + else if (columnName.equalsIgnoreCase("X_CreateFromBatch")) + { + if (tableName.equals(I_C_BankStatement.Table_Name)) + return new WCreateFromBatchStatementUI(mTab); + } return null; } diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromBatchStatementUI.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromBatchStatementUI.java new file mode 100644 index 0000000000..20f2dc3582 --- /dev/null +++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromBatchStatementUI.java @@ -0,0 +1,310 @@ +/****************************************************************************** + * Copyright (C) 2013 Elaine Tan * + * Copyright (C) 2013 Trek Global + * This program is free software; you can redistribute it and/or modify it * + * under the terms version 2 of the GNU General Public License as published * + * by the Free Software Foundation. This program is distributed in the hope * + * that it will be useful, but WITHOUT ANY WARRANTY; without even the implied * + * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * + * See the GNU General Public License for more details. * + * You should have received a copy of the GNU General Public License along * + * with this program; if not, write to the Free Software Foundation, Inc., * + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. * + *****************************************************************************/ +package org.adempiere.webui.apps.form; + +import static org.compiere.model.SystemIDs.COLUMN_C_BANKSTATEMENT_C_BANKACCOUNT_ID; + +import java.sql.Timestamp; +import java.util.Vector; +import java.util.logging.Level; + +import org.adempiere.webui.apps.AEnv; +import org.adempiere.webui.component.Button; +import org.adempiere.webui.component.Column; +import org.adempiere.webui.component.Columns; +import org.adempiere.webui.component.ConfirmPanel; +import org.adempiere.webui.component.Grid; +import org.adempiere.webui.component.GridFactory; +import org.adempiere.webui.component.Label; +import org.adempiere.webui.component.ListModelTable; +import org.adempiere.webui.component.Panel; +import org.adempiere.webui.component.Row; +import org.adempiere.webui.component.Rows; +import org.adempiere.webui.editor.WDateEditor; +import org.adempiere.webui.editor.WEditor; +import org.adempiere.webui.editor.WNumberEditor; +import org.adempiere.webui.editor.WSearchEditor; +import org.adempiere.webui.editor.WStringEditor; +import org.adempiere.webui.editor.WTableDirEditor; +import org.adempiere.webui.window.FDialog; +import org.compiere.grid.CreateFromBatchStatement; +import org.compiere.model.GridTab; +import org.compiere.model.MBankStatement; +import org.compiere.model.MColumn; +import org.compiere.model.MLookup; +import org.compiere.model.MLookupFactory; +import org.compiere.model.MPayment; +import org.compiere.util.CLogger; +import org.compiere.util.DisplayType; +import org.compiere.util.Env; +import org.compiere.util.Msg; +import org.zkoss.zk.ui.event.Event; +import org.zkoss.zk.ui.event.EventListener; +import org.zkoss.zk.ui.event.Events; +import org.zkoss.zul.Borderlayout; +import org.zkoss.zul.Center; +import org.zkoss.zul.Hbox; + +/** + * + * @author Elaine + * + */ +public class WCreateFromBatchStatementUI extends CreateFromBatchStatement implements EventListener +{ + private WCreateFromWindow window; + + public WCreateFromBatchStatementUI(GridTab tab) + { + super(tab); + log.info(getGridTab().toString()); + + window = new WCreateFromWindow(this, getGridTab().getWindowNo()); + + p_WindowNo = getGridTab().getWindowNo(); + + try + { + if (!dynInit()) + return; + zkInit(); + setInitOK(true); + } + catch(Exception e) + { + log.log(Level.SEVERE, "", e); + setInitOK(false); + } + AEnv.showWindow(window); + } + + /** Window No */ + private int p_WindowNo; + + /** Logger */ + private CLogger log = CLogger.getCLogger(getClass()); + + protected Label bankAccountLabel = new Label(); + protected WTableDirEditor bankAccountField; + + protected Label documentNoLabel = new Label(Msg.translate(Env.getCtx(), "DocumentNo")); + protected WStringEditor documentNoField = new WStringEditor(); + + protected Label documentTypeLabel = new Label(); + protected WTableDirEditor documentTypeField; + + protected Label authorizationLabel = new Label(); + protected WStringEditor authorizationField = new WStringEditor(); + + protected Label tenderTypeLabel = new Label(); + protected WTableDirEditor tenderTypeField; + + protected Label amtFromLabel = new Label(Msg.translate(Env.getCtx(), "PayAmt")); + protected WNumberEditor amtFromField = new WNumberEditor("AmtFrom", false, false, true, DisplayType.Amount, Msg.translate(Env.getCtx(), "AmtFrom")); + protected Label amtToLabel = new Label("-"); + protected WNumberEditor amtToField = new WNumberEditor("AmtTo", false, false, true, DisplayType.Amount, Msg.translate(Env.getCtx(), "AmtTo")); + + protected Label BPartner_idLabel = new Label(Msg.translate(Env.getCtx(), "BPartner")); + protected WEditor bPartnerLookup; + + protected Label dateFromLabel = new Label(Msg.translate(Env.getCtx(), "DateTrx")); + protected WDateEditor dateFromField = new WDateEditor("DateFrom", false, false, true, Msg.translate(Env.getCtx(), "DateFrom")); + protected Label dateToLabel = new Label("-"); + protected WDateEditor dateToField = new WDateEditor("DateTo", false, false, true, Msg.translate(Env.getCtx(), "DateTo")); + + /** + * Dynamic Init + * @throws Exception if Lookups cannot be initialized + * @return true if initialized + */ + public boolean dynInit() throws Exception + { + log.config(""); + + super.dynInit(); + + //Refresh button + Button refreshButton = window.getConfirmPanel().createButton(ConfirmPanel.A_REFRESH); + refreshButton.addEventListener(Events.ON_CLICK, this); + window.getConfirmPanel().addButton(refreshButton); + + if (getGridTab().getValue("C_BankStatement_ID") == null) + { + FDialog.error(0, window, "SaveErrorRowNotFound"); + return false; + } + + window.setTitle(getTitle()); + + int AD_Column_ID = COLUMN_C_BANKSTATEMENT_C_BANKACCOUNT_ID; // C_BankStatement.C_BankAccount_ID + MLookup lookup = MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, AD_Column_ID, DisplayType.TableDir); + bankAccountField = new WTableDirEditor ("C_BankAccount_ID", true, false, true, lookup); + // Set Default + int C_BankAccount_ID = Env.getContextAsInt(Env.getCtx(), p_WindowNo, "C_BankAccount_ID"); + bankAccountField.setValue(new Integer(C_BankAccount_ID)); + // initial Loading + authorizationField = new WStringEditor ("authorization", false, false, true, 10, 30, null, null); + authorizationField.getComponent().addEventListener(Events.ON_CHANGE, this); + + lookup = MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, MColumn.getColumn_ID(MPayment.Table_Name, MPayment.COLUMNNAME_C_DocType_ID), DisplayType.TableDir); + documentTypeField = new WTableDirEditor (MPayment.COLUMNNAME_C_DocType_ID,false,false,true,lookup); + documentTypeField.getComponent().addEventListener(Events.ON_CHANGE, this); + + lookup = MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, MColumn.getColumn_ID(MPayment.Table_Name, MPayment.COLUMNNAME_TenderType), DisplayType.List); + tenderTypeField = new WTableDirEditor (MPayment.COLUMNNAME_TenderType,false,false,true,lookup); + tenderTypeField.getComponent().addEventListener(Events.ON_CHANGE, this); + + lookup = MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, 3499, DisplayType.Search); + bPartnerLookup = new WSearchEditor ("C_BPartner_ID", false, false, true, lookup); + + Timestamp date = Env.getContextAsDate(Env.getCtx(), p_WindowNo, MBankStatement.COLUMNNAME_StatementDate); + dateToField.setValue(date); + + loadBankAccount(); + + return true; + } // dynInit + + protected void zkInit() throws Exception + { + bankAccountLabel.setText(Msg.translate(Env.getCtx(), "C_BankAccount_ID")); + authorizationLabel.setText(Msg.translate(Env.getCtx(), "R_AuthCode")); + + documentTypeLabel.setText(Msg.translate(Env.getCtx(), "C_DocType_ID")); + tenderTypeLabel.setText(Msg.translate(Env.getCtx(), "TenderType")); + + dateFromField.getComponent().setTooltiptext(Msg.translate(Env.getCtx(), "DateFrom")); + dateToField.getComponent().setTooltiptext(Msg.translate(Env.getCtx(), "DateTo")); + + amtFromField.getComponent().setTooltiptext(Msg.translate(Env.getCtx(), "AmtFrom")); + amtToField.getComponent().setTooltiptext(Msg.translate(Env.getCtx(), "AmtTo")); + + Borderlayout parameterLayout = new Borderlayout(); + parameterLayout.setHeight("130px"); + parameterLayout.setWidth("100%"); + Panel parameterPanel = window.getParameterPanel(); + parameterPanel.appendChild(parameterLayout); + + Grid parameterBankLayout = GridFactory.newGridLayout(); + Panel parameterBankPanel = new Panel(); + parameterBankPanel.appendChild(parameterBankLayout); + + Center center = new Center(); + parameterLayout.appendChild(center); + center.appendChild(parameterBankPanel); + + Columns columns = new Columns(); + parameterBankLayout.appendChild(columns); + Column column = new Column(); + columns.appendChild(column); + column = new Column(); + column.setWidth("15%"); + columns.appendChild(column); + column.setWidth("35%"); + column = new Column(); + column.setWidth("15%"); + columns.appendChild(column); + column = new Column(); + column.setWidth("35%"); + columns.appendChild(column); + + Rows rows = (Rows) parameterBankLayout.newRows(); + Row row = rows.newRow(); + row.appendChild(bankAccountLabel.rightAlign()); + row.appendChild(bankAccountField.getComponent()); + row.appendChild(documentNoLabel.rightAlign()); + row.appendChild(documentNoField.getComponent()); + + row = rows.newRow(); + row.appendChild(documentTypeLabel.rightAlign()); + row.appendChild(documentTypeField.getComponent()); + row.appendChild(authorizationLabel.rightAlign()); + row.appendChild(authorizationField.getComponent()); + + row = rows.newRow(); + row.appendChild(tenderTypeLabel.rightAlign()); + row.appendChild(tenderTypeField.getComponent()); + + row.appendChild(amtFromLabel.rightAlign()); + Hbox hbox = new Hbox(); + hbox.appendChild(amtFromField.getComponent()); + hbox.appendChild(amtToLabel.rightAlign()); + hbox.appendChild(amtToField.getComponent()); + row.appendChild(hbox); + + row = rows.newRow(); + row.appendChild(BPartner_idLabel.rightAlign()); + row.appendChild(bPartnerLookup.getComponent()); + row.appendChild(dateFromLabel.rightAlign()); + + hbox = new Hbox(); + hbox.appendChild(dateFromField.getComponent()); + hbox.appendChild(dateToLabel.rightAlign()); + hbox.appendChild(dateToField.getComponent()); + row.appendChild(hbox); + } + + /** + * Action Listener + * @param e event + * @throws Exception + */ + public void onEvent(Event e) throws Exception + { + log.config("Action=" + e.getTarget().getId()); + if(e.getTarget().equals(window.getConfirmPanel().getButton(ConfirmPanel.A_REFRESH))) + { + loadBankAccount(); + window.tableChanged(null); + } + } + + protected void loadBankAccount() + { + loadTableOIS(getBankAccountData(bankAccountField.getValue(), bPartnerLookup.getValue(), + documentNoField.getValue().toString(), dateFromField.getValue(), dateToField.getValue(), + amtFromField.getValue(), amtToField.getValue(), + documentTypeField.getValue(), tenderTypeField.getValue(), authorizationField.getValue().toString())); + } + + protected void loadTableOIS (Vector data) + { + window.getWListbox().clear(); + + // Remove previous listeners + window.getWListbox().getModel().removeTableModelListener(window); + // Set Model + ListModelTable model = new ListModelTable(data); + model.addTableModelListener(window); + window.getWListbox().setData(model, getOISColumnNames()); + // + + configureMiniTable(window.getWListbox()); + } + + public void showWindow() + { + window.setVisible(true); + } + + public void closeWindow() + { + window.dispose(); + } + + @Override + public Object getWindow() { + return window; + } +} \ No newline at end of file diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromDepositBatchUI.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromDepositBatchUI.java new file mode 100644 index 0000000000..35c88a0272 --- /dev/null +++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromDepositBatchUI.java @@ -0,0 +1,312 @@ +/****************************************************************************** + * Copyright (C) 2013 Elaine Tan * + * Copyright (C) 2013 Trek Global + * This program is free software; you can redistribute it and/or modify it * + * under the terms version 2 of the GNU General Public License as published * + * by the Free Software Foundation. This program is distributed in the hope * + * that it will be useful, but WITHOUT ANY WARRANTY; without even the implied * + * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * + * See the GNU General Public License for more details. * + * You should have received a copy of the GNU General Public License along * + * with this program; if not, write to the Free Software Foundation, Inc., * + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. * + *****************************************************************************/ +package org.adempiere.webui.apps.form; + +import static org.compiere.model.SystemIDs.COLUMN_C_BANKSTATEMENT_C_BANKACCOUNT_ID; + +import java.sql.Timestamp; +import java.util.Vector; +import java.util.logging.Level; + +import org.adempiere.webui.apps.AEnv; +import org.adempiere.webui.component.Button; +import org.adempiere.webui.component.Column; +import org.adempiere.webui.component.Columns; +import org.adempiere.webui.component.ConfirmPanel; +import org.adempiere.webui.component.Grid; +import org.adempiere.webui.component.GridFactory; +import org.adempiere.webui.component.Label; +import org.adempiere.webui.component.ListModelTable; +import org.adempiere.webui.component.Panel; +import org.adempiere.webui.component.Row; +import org.adempiere.webui.component.Rows; +import org.adempiere.webui.editor.WDateEditor; +import org.adempiere.webui.editor.WEditor; +import org.adempiere.webui.editor.WNumberEditor; +import org.adempiere.webui.editor.WSearchEditor; +import org.adempiere.webui.editor.WStringEditor; +import org.adempiere.webui.editor.WTableDirEditor; +import org.adempiere.webui.window.FDialog; +import org.compiere.grid.CreateFromDepositBatch; +import org.compiere.model.GridTab; +import org.compiere.model.MBankStatement; +import org.compiere.model.MColumn; +import org.compiere.model.MLookup; +import org.compiere.model.MLookupFactory; +import org.compiere.model.MPayment; +import org.compiere.util.CLogger; +import org.compiere.util.DisplayType; +import org.compiere.util.Env; +import org.compiere.util.Msg; +import org.zkoss.zk.ui.event.Event; +import org.zkoss.zk.ui.event.EventListener; +import org.zkoss.zk.ui.event.Events; +import org.zkoss.zul.Borderlayout; +import org.zkoss.zul.Center; +import org.zkoss.zul.Hbox; + +/** + * + * @author Elaine + * + */ +public class WCreateFromDepositBatchUI extends CreateFromDepositBatch implements EventListener +{ + private WCreateFromWindow window; + + public WCreateFromDepositBatchUI(GridTab tab) + { + super(tab); + log.info(getGridTab().toString()); + + window = new WCreateFromWindow(this, getGridTab().getWindowNo()); + + p_WindowNo = getGridTab().getWindowNo(); + + try + { + if (!dynInit()) + return; + zkInit(); + setInitOK(true); + } + catch(Exception e) + { + log.log(Level.SEVERE, "", e); + setInitOK(false); + } + AEnv.showWindow(window); + } + + /** Window No */ + private int p_WindowNo; + + /** Logger */ + private CLogger log = CLogger.getCLogger(getClass()); + + protected Label bankAccountLabel = new Label(); + protected WTableDirEditor bankAccountField; + + protected Label documentNoLabel = new Label(Msg.translate(Env.getCtx(), "DocumentNo")); + protected WStringEditor documentNoField = new WStringEditor(); + + protected Label documentTypeLabel = new Label(); + protected WTableDirEditor documentTypeField; + + protected Label authorizationLabel = new Label(); + protected WStringEditor authorizationField = new WStringEditor(); + + protected Label tenderTypeLabel = new Label(); + protected WTableDirEditor tenderTypeField; + + protected Label amtFromLabel = new Label(Msg.translate(Env.getCtx(), "PayAmt")); + protected WNumberEditor amtFromField = new WNumberEditor("AmtFrom", false, false, true, DisplayType.Amount, Msg.translate(Env.getCtx(), "AmtFrom")); + protected Label amtToLabel = new Label("-"); + protected WNumberEditor amtToField = new WNumberEditor("AmtTo", false, false, true, DisplayType.Amount, Msg.translate(Env.getCtx(), "AmtTo")); + + protected Label BPartner_idLabel = new Label(Msg.translate(Env.getCtx(), "BPartner")); + protected WEditor bPartnerLookup; + + protected Label dateFromLabel = new Label(Msg.translate(Env.getCtx(), "DateTrx")); + protected WDateEditor dateFromField = new WDateEditor("DateFrom", false, false, true, Msg.translate(Env.getCtx(), "DateFrom")); + protected Label dateToLabel = new Label("-"); + protected WDateEditor dateToField = new WDateEditor("DateTo", false, false, true, Msg.translate(Env.getCtx(), "DateTo")); + + /** + * Dynamic Init + * @throws Exception if Lookups cannot be initialized + * @return true if initialized + */ + public boolean dynInit() throws Exception + { + log.config(""); + + super.dynInit(); + + //Refresh button + Button refreshButton = window.getConfirmPanel().createButton(ConfirmPanel.A_REFRESH); + refreshButton.addEventListener(Events.ON_CLICK, this); + window.getConfirmPanel().addButton(refreshButton); + + if (getGridTab().getValue("X_DepositBatch_ID") == null) + { + FDialog.error(0, window, "SaveErrorRowNotFound"); + return false; + } + + window.setTitle(getTitle()); + + int AD_Column_ID = COLUMN_C_BANKSTATEMENT_C_BANKACCOUNT_ID; // C_BankStatement.C_BankAccount_ID + MLookup lookup = MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, AD_Column_ID, DisplayType.TableDir); + bankAccountField = new WTableDirEditor ("C_BankAccount_ID", true, false, true, lookup); + // Set Default + int C_BankAccount_ID = Env.getContextAsInt(Env.getCtx(), p_WindowNo, "C_BankAccount_ID"); + bankAccountField.setValue(new Integer(C_BankAccount_ID)); + // initial Loading + authorizationField = new WStringEditor ("authorization", false, false, true, 10, 30, null, null); +// authorizationField.getComponent().addEventListener(Events.ON_CHANGE, this); + + lookup = MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, MColumn.getColumn_ID(MPayment.Table_Name, MPayment.COLUMNNAME_C_DocType_ID), DisplayType.TableDir); + documentTypeField = new WTableDirEditor (MPayment.COLUMNNAME_C_DocType_ID,false,false,true,lookup); + int C_DocType_ID = Env.getContextAsInt(Env.getCtx(), p_WindowNo, "C_DocType_ID"); + documentTypeField.setValue(new Integer(C_DocType_ID)); +// documentTypeField.getComponent().addEventListener(Events.ON_CHANGE, this); + + lookup = MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, MColumn.getColumn_ID(MPayment.Table_Name, MPayment.COLUMNNAME_TenderType), DisplayType.List); + tenderTypeField = new WTableDirEditor (MPayment.COLUMNNAME_TenderType,false,false,true,lookup); +// tenderTypeField.getComponent().addEventListener(Events.ON_CHANGE, this); + + lookup = MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, 3499, DisplayType.Search); + bPartnerLookup = new WSearchEditor ("C_BPartner_ID", false, false, true, lookup); + + Timestamp date = Env.getContextAsDate(Env.getCtx(), p_WindowNo, MBankStatement.COLUMNNAME_StatementDate); + dateToField.setValue(date); + + loadBankAccount(); + + return true; + } // dynInit + + protected void zkInit() throws Exception + { + bankAccountLabel.setText(Msg.translate(Env.getCtx(), "C_BankAccount_ID")); + authorizationLabel.setText(Msg.translate(Env.getCtx(), "R_AuthCode")); + + documentTypeLabel.setText(Msg.translate(Env.getCtx(), "C_DocType_ID")); + tenderTypeLabel.setText(Msg.translate(Env.getCtx(), "TenderType")); + + dateFromField.getComponent().setTooltiptext(Msg.translate(Env.getCtx(), "DateFrom")); + dateToField.getComponent().setTooltiptext(Msg.translate(Env.getCtx(), "DateTo")); + + amtFromField.getComponent().setTooltiptext(Msg.translate(Env.getCtx(), "AmtFrom")); + amtToField.getComponent().setTooltiptext(Msg.translate(Env.getCtx(), "AmtTo")); + + Borderlayout parameterLayout = new Borderlayout(); + parameterLayout.setHeight("130px"); + parameterLayout.setWidth("100%"); + Panel parameterPanel = window.getParameterPanel(); + parameterPanel.appendChild(parameterLayout); + + Grid parameterBankLayout = GridFactory.newGridLayout(); + Panel parameterBankPanel = new Panel(); + parameterBankPanel.appendChild(parameterBankLayout); + + Center center = new Center(); + parameterLayout.appendChild(center); + center.appendChild(parameterBankPanel); + + Columns columns = new Columns(); + parameterBankLayout.appendChild(columns); + Column column = new Column(); + columns.appendChild(column); + column = new Column(); + column.setWidth("15%"); + columns.appendChild(column); + column.setWidth("35%"); + column = new Column(); + column.setWidth("15%"); + columns.appendChild(column); + column = new Column(); + column.setWidth("35%"); + columns.appendChild(column); + + Rows rows = (Rows) parameterBankLayout.newRows(); + Row row = rows.newRow(); + row.appendChild(bankAccountLabel.rightAlign()); + row.appendChild(bankAccountField.getComponent()); + row.appendChild(documentNoLabel.rightAlign()); + row.appendChild(documentNoField.getComponent()); + + row = rows.newRow(); + row.appendChild(documentTypeLabel.rightAlign()); + row.appendChild(documentTypeField.getComponent()); + row.appendChild(authorizationLabel.rightAlign()); + row.appendChild(authorizationField.getComponent()); + + row = rows.newRow(); + row.appendChild(tenderTypeLabel.rightAlign()); + row.appendChild(tenderTypeField.getComponent()); + + row.appendChild(amtFromLabel.rightAlign()); + Hbox hbox = new Hbox(); + hbox.appendChild(amtFromField.getComponent()); + hbox.appendChild(amtToLabel.rightAlign()); + hbox.appendChild(amtToField.getComponent()); + row.appendChild(hbox); + + row = rows.newRow(); + row.appendChild(BPartner_idLabel.rightAlign()); + row.appendChild(bPartnerLookup.getComponent()); + row.appendChild(dateFromLabel.rightAlign()); + + hbox = new Hbox(); + hbox.appendChild(dateFromField.getComponent()); + hbox.appendChild(dateToLabel.rightAlign()); + hbox.appendChild(dateToField.getComponent()); + row.appendChild(hbox); + } + + /** + * Action Listener + * @param e event + * @throws Exception + */ + public void onEvent(Event e) throws Exception + { + log.config("Action=" + e.getTarget().getId()); + if(e.getTarget().equals(window.getConfirmPanel().getButton(ConfirmPanel.A_REFRESH))) + { + loadBankAccount(); + window.tableChanged(null); + } + } + + protected void loadBankAccount() + { + loadTableOIS(getBankAccountData(bankAccountField.getValue(), bPartnerLookup.getValue(), + documentNoField.getValue().toString(), dateFromField.getValue(), dateToField.getValue(), + amtFromField.getValue(), amtToField.getValue(), + documentTypeField.getValue(), tenderTypeField.getValue(), authorizationField.getValue().toString())); + } + + protected void loadTableOIS (Vector data) + { + window.getWListbox().clear(); + + // Remove previous listeners + window.getWListbox().getModel().removeTableModelListener(window); + // Set Model + ListModelTable model = new ListModelTable(data); + model.addTableModelListener(window); + window.getWListbox().setData(model, getOISColumnNames()); + // + + configureMiniTable(window.getWListbox()); + } + + public void showWindow() + { + window.setVisible(true); + } + + public void closeWindow() + { + window.dispose(); + } + + @Override + public Object getWindow() { + return window; + } +} \ No newline at end of file diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromFactory.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromFactory.java index 6527b5b55c..2b11a32429 100644 --- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromFactory.java +++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromFactory.java @@ -22,13 +22,13 @@ import org.compiere.model.GridTab; public class WCreateFromFactory { - public static ICreateFrom create (GridTab mTab) + public static ICreateFrom create (GridTab mTab, String columnName) { ICreateFrom createFrom = null; List factories = Service.locator().list(ICreateFromFactory.class).getServices(); for (ICreateFromFactory factory : factories) { - createFrom = factory.create(mTab); + createFrom = factory.create(mTab, columnName); if (createFrom != null) break; } diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromStatementBatchUI.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromStatementBatchUI.java new file mode 100644 index 0000000000..e0b9e0d8f7 --- /dev/null +++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromStatementBatchUI.java @@ -0,0 +1,311 @@ +/****************************************************************************** + * Copyright (C) 2013 Elaine Tan * + * Copyright (C) 2013 Trek Global + * This program is free software; you can redistribute it and/or modify it * + * under the terms version 2 of the GNU General Public License as published * + * by the Free Software Foundation. This program is distributed in the hope * + * that it will be useful, but WITHOUT ANY WARRANTY; without even the implied * + * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * + * See the GNU General Public License for more details. * + * You should have received a copy of the GNU General Public License along * + * with this program; if not, write to the Free Software Foundation, Inc., * + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. * + *****************************************************************************/ +package org.adempiere.webui.apps.form; + +import static org.compiere.model.SystemIDs.COLUMN_C_BANKSTATEMENT_C_BANKACCOUNT_ID; + +import java.sql.Timestamp; +import java.util.Vector; +import java.util.logging.Level; + +import org.adempiere.webui.apps.AEnv; +import org.adempiere.webui.component.Button; +import org.adempiere.webui.component.Column; +import org.adempiere.webui.component.Columns; +import org.adempiere.webui.component.ConfirmPanel; +import org.adempiere.webui.component.Grid; +import org.adempiere.webui.component.GridFactory; +import org.adempiere.webui.component.Label; +import org.adempiere.webui.component.ListModelTable; +import org.adempiere.webui.component.Panel; +import org.adempiere.webui.component.Row; +import org.adempiere.webui.component.Rows; +import org.adempiere.webui.editor.WDateEditor; +import org.adempiere.webui.editor.WEditor; +import org.adempiere.webui.editor.WNumberEditor; +import org.adempiere.webui.editor.WSearchEditor; +import org.adempiere.webui.editor.WStringEditor; +import org.adempiere.webui.editor.WTableDirEditor; +import org.adempiere.webui.window.FDialog; +import org.compiere.grid.CreateFromStatementBatch; +import org.compiere.model.GridTab; +import org.compiere.model.MBankStatement; +import org.compiere.model.MColumn; +import org.compiere.model.MLookup; +import org.compiere.model.MLookupFactory; +import org.compiere.model.MPayment; +import org.compiere.util.CLogger; +import org.compiere.util.DisplayType; +import org.compiere.util.Env; +import org.compiere.util.Msg; +import org.zkoss.zk.ui.event.Event; +import org.zkoss.zk.ui.event.EventListener; +import org.zkoss.zk.ui.event.Events; +import org.zkoss.zul.Borderlayout; +import org.zkoss.zul.Center; +import org.zkoss.zul.Hbox; + +/** + * + * @author Elaine + * + */ +public class WCreateFromStatementBatchUI extends CreateFromStatementBatch implements EventListener +{ + private WCreateFromWindow window; + + public WCreateFromStatementBatchUI(GridTab tab) + { + super(tab); + log.info(getGridTab().toString()); + + window = new WCreateFromWindow(this, getGridTab().getWindowNo()); + + p_WindowNo = getGridTab().getWindowNo(); + + try + { + if (!dynInit()) + return; + zkInit(); + setInitOK(true); + } + catch(Exception e) + { + log.log(Level.SEVERE, "", e); + setInitOK(false); + } + AEnv.showWindow(window); + } + + /** Window No */ + private int p_WindowNo; + + /** Logger */ + private CLogger log = CLogger.getCLogger(getClass()); + + protected Label bankAccountLabel = new Label(); + protected WTableDirEditor bankAccountField; + + protected Label documentNoLabel = new Label(Msg.translate(Env.getCtx(), "DocumentNo")); + protected WStringEditor documentNoField = new WStringEditor(); + + protected Label documentTypeLabel = new Label(); + protected WTableDirEditor documentTypeField; + + protected Label authorizationLabel = new Label(); + protected WStringEditor authorizationField = new WStringEditor(); + + protected Label tenderTypeLabel = new Label(); + protected WTableDirEditor tenderTypeField; + + protected Label amtFromLabel = new Label(Msg.translate(Env.getCtx(), "PayAmt")); + protected WNumberEditor amtFromField = new WNumberEditor("AmtFrom", false, false, true, DisplayType.Amount, Msg.translate(Env.getCtx(), "AmtFrom")); + protected Label amtToLabel = new Label("-"); + protected WNumberEditor amtToField = new WNumberEditor("AmtTo", false, false, true, DisplayType.Amount, Msg.translate(Env.getCtx(), "AmtTo")); + + protected Label BPartner_idLabel = new Label(Msg.translate(Env.getCtx(), "BPartner")); + protected WEditor bPartnerLookup; + + protected Label dateFromLabel = new Label(Msg.translate(Env.getCtx(), "DateTrx")); + protected WDateEditor dateFromField = new WDateEditor("DateFrom", false, false, true, Msg.translate(Env.getCtx(), "DateFrom")); + protected Label dateToLabel = new Label("-"); + protected WDateEditor dateToField = new WDateEditor("DateTo", false, false, true, Msg.translate(Env.getCtx(), "DateTo")); + + /** + * Dynamic Init + * @throws Exception if Lookups cannot be initialized + * @return true if initialized + */ + public boolean dynInit() throws Exception + { + log.config(""); + + super.dynInit(); + + //Refresh button + Button refreshButton = window.getConfirmPanel().createButton(ConfirmPanel.A_REFRESH); + refreshButton.addEventListener(Events.ON_CLICK, this); + window.getConfirmPanel().addButton(refreshButton); + + if (getGridTab().getValue("C_BankStatement_ID") == null) + { + FDialog.error(0, window, "SaveErrorRowNotFound"); + return false; + } + + window.setTitle(getTitle()); + + int AD_Column_ID = COLUMN_C_BANKSTATEMENT_C_BANKACCOUNT_ID; // C_BankStatement.C_BankAccount_ID + MLookup lookup = MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, AD_Column_ID, DisplayType.TableDir); + bankAccountField = new WTableDirEditor ("C_BankAccount_ID", true, false, true, lookup); + // Set Default + int C_BankAccount_ID = Env.getContextAsInt(Env.getCtx(), p_WindowNo, "C_BankAccount_ID"); + bankAccountField.setValue(new Integer(C_BankAccount_ID)); + // initial Loading + authorizationField = new WStringEditor ("authorization", false, false, true, 10, 30, null, null); + authorizationField.getComponent().addEventListener(Events.ON_CHANGE, this); + + lookup = MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, MColumn.getColumn_ID(MPayment.Table_Name, MPayment.COLUMNNAME_C_DocType_ID), DisplayType.TableDir); + documentTypeField = new WTableDirEditor (MPayment.COLUMNNAME_C_DocType_ID,false,false,true,lookup); + documentTypeField.getComponent().addEventListener(Events.ON_CHANGE, this); + + lookup = MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, MColumn.getColumn_ID(MPayment.Table_Name, MPayment.COLUMNNAME_TenderType), DisplayType.List); + tenderTypeField = new WTableDirEditor (MPayment.COLUMNNAME_TenderType,false,false,true,lookup); + tenderTypeField.getComponent().addEventListener(Events.ON_CHANGE, this); + + lookup = MLookupFactory.get (Env.getCtx(), p_WindowNo, 0, 3499, DisplayType.Search); + bPartnerLookup = new WSearchEditor ("C_BPartner_ID", false, false, true, lookup); + + Timestamp date = Env.getContextAsDate(Env.getCtx(), p_WindowNo, MBankStatement.COLUMNNAME_StatementDate); + dateToField.setValue(date); + + loadBankAccount(); + + return true; + } // dynInit + + protected void zkInit() throws Exception + { + bankAccountLabel.setText(Msg.translate(Env.getCtx(), "C_BankAccount_ID")); + authorizationLabel.setText(Msg.translate(Env.getCtx(), "R_AuthCode")); + + documentTypeLabel.setText(Msg.translate(Env.getCtx(), "C_DocType_ID")); + tenderTypeLabel.setText(Msg.translate(Env.getCtx(), "TenderType")); + + dateFromField.getComponent().setTooltiptext(Msg.translate(Env.getCtx(), "DateFrom")); + dateToField.getComponent().setTooltiptext(Msg.translate(Env.getCtx(), "DateTo")); + + amtFromField.getComponent().setTooltiptext(Msg.translate(Env.getCtx(), "AmtFrom")); + amtToField.getComponent().setTooltiptext(Msg.translate(Env.getCtx(), "AmtTo")); + + Borderlayout parameterLayout = new Borderlayout(); + parameterLayout.setHeight("130px"); + parameterLayout.setWidth("100%"); + Panel parameterPanel = window.getParameterPanel(); + parameterPanel.appendChild(parameterLayout); + + Grid parameterBankLayout = GridFactory.newGridLayout(); + Panel parameterBankPanel = new Panel(); + parameterBankPanel.appendChild(parameterBankLayout); + + Center center = new Center(); + parameterLayout.appendChild(center); + center.appendChild(parameterBankPanel); + + Columns columns = new Columns(); + parameterBankLayout.appendChild(columns); + Column column = new Column(); + columns.appendChild(column); + column = new Column(); + column.setWidth("15%"); + columns.appendChild(column); + column.setWidth("35%"); + column = new Column(); + column.setWidth("15%"); + columns.appendChild(column); + column = new Column(); + column.setWidth("35%"); + columns.appendChild(column); + + Rows rows = (Rows) parameterBankLayout.newRows(); + Row row = rows.newRow(); + row.appendChild(bankAccountLabel.rightAlign()); + row.appendChild(bankAccountField.getComponent()); + row.appendChild(documentNoLabel.rightAlign()); + row.appendChild(documentNoField.getComponent()); + + row = rows.newRow(); + row.appendChild(documentTypeLabel.rightAlign()); + row.appendChild(documentTypeField.getComponent()); + row.appendChild(authorizationLabel.rightAlign()); + row.appendChild(authorizationField.getComponent()); + + row = rows.newRow(); + row.appendChild(tenderTypeLabel.rightAlign()); + row.appendChild(tenderTypeField.getComponent()); + + row.appendChild(amtFromLabel.rightAlign()); + Hbox hbox = new Hbox(); + hbox.appendChild(amtFromField.getComponent()); + hbox.appendChild(amtToLabel.rightAlign()); + hbox.appendChild(amtToField.getComponent()); + row.appendChild(hbox); + + row = rows.newRow(); + row.appendChild(BPartner_idLabel.rightAlign()); + row.appendChild(bPartnerLookup.getComponent()); + row.appendChild(dateFromLabel.rightAlign()); + + hbox = new Hbox(); + hbox.appendChild(dateFromField.getComponent()); + hbox.appendChild(dateToLabel.rightAlign()); + hbox.appendChild(dateToField.getComponent()); + row.appendChild(hbox); + } + + /** + * Action Listener + * @param e event + * @throws Exception + */ + public void onEvent(Event e) throws Exception + { + log.config("Action=" + e.getTarget().getId()); + if(e.getTarget().equals(window.getConfirmPanel().getButton(ConfirmPanel.A_REFRESH))) + { + loadBankAccount(); + window.tableChanged(null); + } + } + + protected void loadBankAccount() + { + loadTableOIS(getBankAccountData(bankAccountField.getValue(), bPartnerLookup.getValue(), + documentNoField.getValue().toString(), dateFromField.getValue(), dateToField.getValue(), + amtFromField.getValue(), amtToField.getValue(), + documentTypeField.getValue(), tenderTypeField.getValue(), authorizationField.getValue().toString())); + } + + protected void loadTableOIS (Vector data) + { + window.getWListbox().clear(); + + // Remove previous listeners + window.getWListbox().getModel().removeTableModelListener(window); + // Set Model + ListModelTable model = new ListModelTable(data); + model.addTableModelListener(window); + window.getWListbox().setData(model, getOISColumnNames()); + // + + configureMiniTable(window.getWListbox()); + } + + public void showWindow() + { + window.setVisible(true); + } + + public void closeWindow() + { + window.dispose(); + } + + @Override + public Object getWindow() + { + return window; + } +} \ No newline at end of file diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromStatementUI.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromStatementUI.java index a1a67ac907..ec1a025f62 100644 --- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromStatementUI.java +++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromStatementUI.java @@ -13,9 +13,9 @@ *****************************************************************************/ package org.adempiere.webui.apps.form; -import java.math.BigDecimal; +import static org.compiere.model.SystemIDs.COLUMN_C_BANKSTATEMENT_C_BANKACCOUNT_ID; + import java.sql.Timestamp; -import java.text.DecimalFormat; import java.util.Vector; import java.util.logging.Level; @@ -44,7 +44,6 @@ import org.compiere.model.MColumn; import org.compiere.model.MLookup; import org.compiere.model.MLookupFactory; import org.compiere.model.MPayment; -import static org.compiere.model.SystemIDs.*; import org.compiere.util.CLogger; import org.compiere.util.DisplayType; import org.compiere.util.Env; @@ -274,27 +273,6 @@ public class WCreateFromStatementUI extends CreateFromStatement implements Event configureMiniTable(window.getWListbox()); } - /** - * List total amount - */ - public void info() - { - DecimalFormat format = DisplayType.getNumberFormat(DisplayType.Amount); - - BigDecimal total = new BigDecimal(0.0); - int rows = window.getWListbox().getRowCount(); - int count = 0; - for (int i = 0; i < rows; i++) - { - if (((Boolean)window.getWListbox().getValueAt(i, 0)).booleanValue()) - { - total = total.add((BigDecimal)window.getWListbox().getValueAt(i, 4)); - count++; - } - } - window.setStatusLine(count, Msg.getMsg(Env.getCtx(), "Sum") + " " + format.format(total)); - } // infoStatement - public void showWindow() { window.setVisible(true); diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromWindow.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromWindow.java index 0c81d7f616..d2f631cec8 100644 --- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromWindow.java +++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/apps/form/WCreateFromWindow.java @@ -192,7 +192,7 @@ public class WCreateFromWindow extends Window implements EventListener, W } setStatusLine(count, null); - createFrom.info(); + createFrom.info(dataTable, statusBar); } public void setStatusLine(int selectedRowCount, String text) diff --git a/org.adempiere.ui/src/org/compiere/grid/CreateFrom.java b/org.adempiere.ui/src/org/compiere/grid/CreateFrom.java index 3628241f0f..685f6386ed 100644 --- a/org.adempiere.ui/src/org/compiere/grid/CreateFrom.java +++ b/org.adempiere.ui/src/org/compiere/grid/CreateFrom.java @@ -21,6 +21,7 @@ import java.util.ArrayList; import java.util.Vector; import java.util.logging.Level; +import org.compiere.apps.IStatusBar; import org.compiere.minigrid.IMiniTable; import org.compiere.model.GridTab; import org.compiere.model.MOrder; @@ -54,7 +55,7 @@ public abstract class CreateFrom implements ICreateFrom public abstract boolean dynInit() throws Exception; - public abstract void info(); + public abstract void info(IMiniTable miniTable, IStatusBar statusBar); public abstract boolean save(IMiniTable miniTable, String trxName); diff --git a/org.adempiere.ui/src/org/compiere/grid/CreateFromBatch.java b/org.adempiere.ui/src/org/compiere/grid/CreateFromBatch.java new file mode 100644 index 0000000000..544dbd2d04 --- /dev/null +++ b/org.adempiere.ui/src/org/compiere/grid/CreateFromBatch.java @@ -0,0 +1,181 @@ +/****************************************************************************** + * Copyright (C) 2013 Elaine Tan * + * Copyright (C) 2013 Trek Global + * This program is free software; you can redistribute it and/or modify it * + * under the terms version 2 of the GNU General Public License as published * + * by the Free Software Foundation. This program is distributed in the hope * + * that it will be useful, but WITHOUT ANY WARRANTY; without even the implied * + * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * + * See the GNU General Public License for more details. * + * You should have received a copy of the GNU General Public License along * + * with this program; if not, write to the Free Software Foundation, Inc., * + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. * + *****************************************************************************/ +package org.compiere.grid; + +import java.math.BigDecimal; +import java.sql.PreparedStatement; +import java.sql.SQLException; +import java.sql.Timestamp; +import java.text.DecimalFormat; +import java.util.Vector; + +import org.compiere.apps.IStatusBar; +import org.compiere.minigrid.IMiniTable; +import org.compiere.model.GridTab; +import org.compiere.util.DisplayType; +import org.compiere.util.Env; +import org.compiere.util.Msg; + +/** + * + * @author Elaine + * + */ +public abstract class CreateFromBatch extends CreateFrom +{ + public CreateFromBatch(GridTab gridTab) + { + super(gridTab); + } + + public String getSQLWhere(Object BPartner, String DocumentNo, Object DateFrom, Object DateTo, + Object AmtFrom, Object AmtTo, Object DocType, Object TenderType, String AuthCode) + { + StringBuilder sql = new StringBuilder(); + sql.append("WHERE p.Processed='Y' AND p.IsReconciled='N'"); + sql.append(" AND p.DocStatus IN ('CO','CL','RE','VO') AND p.PayAmt<>0"); + sql.append(" AND p.C_BankAccount_ID = ?"); + sql.append(" AND NOT EXISTS (SELECT * FROM C_BankStatementLine l WHERE p.C_Payment_ID=l.C_Payment_ID AND l.StmtAmt <> 0)"); + + if(DocType != null) + sql.append(" AND p.C_DocType_ID=?"); + if(TenderType != null && TenderType.toString().length() > 0) + sql.append(" AND p.TenderType=?"); + if(BPartner != null) + sql.append(" AND p.C_BPartner_ID=?"); + + if(DocumentNo.length() > 0) + sql.append(" AND UPPER(p.DocumentNo) LIKE ?"); + if(AuthCode.length() > 0) + sql.append(" AND p.R_AuthCode LIKE ?"); + + if(AmtFrom != null || AmtTo != null) + { + BigDecimal from = (BigDecimal) AmtFrom; + BigDecimal to = (BigDecimal) AmtTo; + if(from == null && to != null) + sql.append(" AND p.PayAmt <= ?"); + else if(from != null && to == null) + sql.append(" AND p.PayAmt >= ?"); + else if(from != null && to != null) + sql.append(" AND p.PayAmt BETWEEN ? AND ?"); + } + + if(DateFrom != null || DateTo != null) + { + Timestamp from = (Timestamp) DateFrom; + Timestamp to = (Timestamp) DateTo; + if(from == null && to != null) + sql.append(" AND TRUNC(p.DateTrx) <= ?"); + else if(from != null && to == null) + sql.append(" AND TRUNC(p.DateTrx) >= ?"); + else if(from != null && to != null) + sql.append(" AND TRUNC(p.DateTrx) BETWEEN ? AND ?"); + } + + log.fine(sql.toString()); + return sql.toString(); + } + + void setParameters(PreparedStatement pstmt, Object BankAccount, Object BPartner, String DocumentNo, Object DateFrom, Object DateTo, + Object AmtFrom, Object AmtTo, Object DocType, Object TenderType, String AuthCode) + throws SQLException + { + // Get StatementDate + Timestamp ts = (Timestamp) getGridTab().getValue("StatementDate"); + if (ts == null) + ts = new Timestamp(System.currentTimeMillis()); + + int index = 1; + + pstmt.setTimestamp(index++, ts); + pstmt.setInt(index++, BankAccount != null ? (Integer) BankAccount : (Integer) getGridTab().getValue("C_BankAccount_ID")); + + if(DocType != null) + pstmt.setInt(index++, (Integer) DocType); + + if(TenderType != null && TenderType.toString().length() > 0) + pstmt.setString(index++, (String) TenderType); + + if(BPartner != null) + pstmt.setInt(index++, (Integer) BPartner); + + if(DocumentNo.length() > 0) + pstmt.setString(index++, getSQLText(DocumentNo)); + + if(AuthCode.length() > 0) + pstmt.setString(index++, getSQLText(AuthCode)); + + if(AmtFrom != null || AmtTo != null) + { + BigDecimal from = (BigDecimal) AmtFrom; + BigDecimal to = (BigDecimal) AmtTo; + log.fine("Amt From=" + from + ", To=" + to); + if(from == null && to != null) + pstmt.setBigDecimal(index++, to); + else if(from != null && to == null) + pstmt.setBigDecimal(index++, from); + else if(from != null && to != null) + { + pstmt.setBigDecimal(index++, from); + pstmt.setBigDecimal(index++, to); + } + } + + if(DateFrom != null || DateTo != null) + { + Timestamp from = (Timestamp) DateFrom; + Timestamp to = (Timestamp) DateTo; + log.fine("Date From=" + from + ", To=" + to); + if(from == null && to != null) + pstmt.setTimestamp(index++, to); + else if(from != null && to == null) + pstmt.setTimestamp(index++, from); + else if(from != null && to != null) + { + pstmt.setTimestamp(index++, from); + pstmt.setTimestamp(index++, to); + } + } + } + + private String getSQLText(String text) + { + String s = text.toUpperCase(); + if(!s.endsWith("%")) + s += "%"; + log.fine( "String=" + s); + return s; + } + + protected abstract Vector> getBankAccountData(Object BankAccount, Object BPartner, String DocumentNo, + Object DateFrom, Object DateTo, Object AmtFrom, Object AmtTo, Object DocType, Object TenderType, String AuthCode); + + public void info(IMiniTable miniTable, IStatusBar statusBar) + { + DecimalFormat format = DisplayType.getNumberFormat(DisplayType.Amount); + BigDecimal total = new BigDecimal(0); + int rows = miniTable.getRowCount(); + int count = 0; + for(int i = 0; i < rows; i++) + { + if(((Boolean) miniTable.getValueAt(i, 0)).booleanValue()) + { + total = total.add((BigDecimal) miniTable.getValueAt(i, 4)); + count++; + } + } + statusBar.setStatusLine(String.valueOf(count) + " - " + Msg.getMsg(Env.getCtx(), "Sum") + " " + format.format(total)); + } +} \ No newline at end of file diff --git a/org.adempiere.ui/src/org/compiere/grid/CreateFromBatchStatement.java b/org.adempiere.ui/src/org/compiere/grid/CreateFromBatchStatement.java new file mode 100644 index 0000000000..5e7b888362 --- /dev/null +++ b/org.adempiere.ui/src/org/compiere/grid/CreateFromBatchStatement.java @@ -0,0 +1,218 @@ +/****************************************************************************** + * Copyright (C) 2013 Elaine Tan * + * Copyright (C) 2013 Trek Global + * This program is free software; you can redistribute it and/or modify it * + * under the terms version 2 of the GNU General Public License as published * + * by the Free Software Foundation. This program is distributed in the hope * + * that it will be useful, but WITHOUT ANY WARRANTY; without even the implied * + * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * + * See the GNU General Public License for more details. * + * You should have received a copy of the GNU General Public License along * + * with this program; if not, write to the Free Software Foundation, Inc., * + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. * + *****************************************************************************/ +package org.compiere.grid; + +import java.math.BigDecimal; +import java.sql.PreparedStatement; +import java.sql.ResultSet; +import java.sql.SQLException; +import java.sql.Timestamp; +import java.util.Vector; +import java.util.logging.Level; + +import org.compiere.minigrid.IMiniTable; +import org.compiere.model.GridTab; +import org.compiere.model.MBankStatement; +import org.compiere.model.MBankStatementLine; +import org.compiere.model.MPayment; +import org.compiere.util.DB; +import org.compiere.util.Env; +import org.compiere.util.KeyNamePair; +import org.compiere.util.Msg; + +/** + * + * @author Elaine + * + */ +public abstract class CreateFromBatchStatement extends CreateFromBatch +{ + public CreateFromBatchStatement(GridTab mTab) + { + super(mTab); + log.info(mTab.toString()); + } + + public boolean dynInit() throws Exception + { + log.config(""); + setTitle(Msg.getElement(Env.getCtx(), "C_BankStatement_ID") + " .. " + Msg.translate(Env.getCtx(), "X_CreateFromBatch")); + + return true; + } + + protected Vector> getBankAccountData(Object BankAccount, Object BPartner, String DocumentNo, + Object DateFrom, Object DateTo, Object AmtFrom, Object AmtTo, Object DocType, Object TenderType, String AuthCode) + { + log.config ("C_BankAccount_ID=" + BankAccount); + + Vector> data = new Vector>(); + StringBuilder sql = new StringBuilder(); + sql.append("SELECT py.X_DepositBatch_ID, db.DocumentNo, db.DateDeposit, db.C_BankAccount_ID, ba.AccountNo,"); + sql.append("SUM(currencyConvert(p.PayAmt,p.C_Currency_ID,ba.C_Currency_ID,?,null,p.AD_Client_ID,p.AD_Org_ID)) AS amount,"); + sql.append("SUM(p.PayAmt) AS amountoriginal"); + sql.append(" FROM C_BankAccount ba"); + sql.append(" INNER JOIN C_Payment_v p ON (p.C_BankAccount_ID=ba.C_BankAccount_ID)"); + sql.append(" INNER JOIN C_Currency c ON (p.C_Currency_ID=c.C_Currency_ID)"); + sql.append(" INNER JOIN C_Payment py ON (py.C_Payment_ID=p.C_Payment_ID)"); + sql.append(" INNER JOIN X_DepositBatch db ON (py.X_DepositBatch_ID = db.X_DepositBatch_ID) "); + sql.append(getSQLWhere(BPartner, DocumentNo, DateFrom, DateTo, AmtFrom, AmtTo, DocType, TenderType, AuthCode)); + + sql.append(" AND p.IsReceipt = 'Y'"); + sql.append(" AND py.X_DepositBatch_ID <> 0"); + sql.append(" AND db.Processed = 'Y'"); + + sql.append(" GROUP BY py.X_DepositBatch_ID,db.DocumentNo,db.DateDeposit, db.C_BankAccount_ID,ba.AccountNo"); + + PreparedStatement pstmt = null; + ResultSet rs = null; + try + { + pstmt = DB.prepareStatement(sql.toString(), null); + setParameters(pstmt, BankAccount, BPartner, DocumentNo, DateFrom, DateTo, AmtFrom, AmtTo, DocType, TenderType, AuthCode); + rs = pstmt.executeQuery(); + while(rs.next()) + { + Vector line = new Vector(5); + line.add(new Boolean(false)); // 0-Selection + line.add(rs.getTimestamp(3)); // 1-DateDeposit + KeyNamePair pp = new KeyNamePair(rs.getInt(1), rs.getString(2)); + line.add(pp); // 2-X_DepositBatch + line.add(rs.getBigDecimal(7)); // 3-PayAmt + line.add(rs.getBigDecimal(6)); // 4-Conv Amt + pp = new KeyNamePair(rs.getInt(4), rs.getString(5)); + line.add(pp); // 5-Bank Account + data.add(line); + } + } + catch(SQLException e) + { + log.log(Level.SEVERE, sql.toString(), e); + } + finally + { + DB.close(rs, pstmt); + rs = null; pstmt = null; + } + + return data; + } + + protected void configureMiniTable (IMiniTable miniTable) + { + miniTable.setColumnClass(0, Boolean.class, false); // 0-Selection + miniTable.setColumnClass(1, Timestamp.class, true); // 1-TrxDate + miniTable.setColumnClass(2, String.class, true); // 2-DepositBatch + miniTable.setColumnClass(3, BigDecimal.class, true); // 3-Amount + miniTable.setColumnClass(4, BigDecimal.class, true); // 4-ConvAmount + miniTable.setColumnClass(5, String.class, true); // 5-BankAccount + // Table UI + miniTable.autoSize(); + } + + public boolean save(IMiniTable miniTable, String trxName) + { + // fixed values + int C_BankStatement_ID = ((Integer)getGridTab().getValue("C_BankStatement_ID")).intValue(); + MBankStatement bs = new MBankStatement (Env.getCtx(), C_BankStatement_ID, null); + log.config(bs.toString()); + + StringBuilder sql = new StringBuilder(); + sql.append("SELECT p.DateTrx,p.C_Payment_ID,p.DocumentNo, p.C_Currency_ID,c.ISO_Code, p.PayAmt,"); + sql.append("currencyConvert(p.PayAmt,p.C_Currency_ID,ba.C_Currency_ID,?,null,p.AD_Client_ID,p.AD_Org_ID), bp.Name "); + sql.append(" FROM C_BankAccount ba"); + sql.append(" INNER JOIN C_Payment_v p ON (p.C_BankAccount_ID=ba.C_BankAccount_ID)"); + sql.append(" INNER JOIN C_Currency c ON (p.C_Currency_ID=c.C_Currency_ID)"); + sql.append(" INNER JOIN C_Payment py ON (py.C_Payment_ID=p.C_Payment_ID)"); + sql.append(" INNER JOIN X_DepositBatch db ON (py.X_DepositBatch_ID = db.X_DepositBatch_ID)"); + sql.append(" LEFT OUTER JOIN C_BPartner bp ON (p.C_BPartner_ID=bp.C_BPartner_ID)"); + sql.append(" WHERE p.Processed='Y' AND p.IsReconciled='N'"); + sql.append(" AND p.IsReceipt = 'Y'"); + sql.append(" AND py.X_DepositBatch_ID = ?"); + sql.append(" AND p.DocStatus IN ('CO','CL','RE','VO') AND p.PayAmt<>0"); + sql.append(" AND p.C_BankAccount_ID=?"); + sql.append(" AND NOT EXISTS (SELECT * FROM C_BankStatementLine l WHERE p.C_Payment_ID=l.C_Payment_ID AND l.StmtAmt <> 0)"); + + Timestamp ts = (Timestamp) getGridTab().getValue("StatementDate"); + if(ts == null) + ts = new Timestamp(System.currentTimeMillis()); + + // Lines + for(int i = 0; i < miniTable.getRowCount(); i++) + { + if(((Boolean) miniTable.getValueAt(i, 0)).booleanValue()) + { + Timestamp trxDate = (Timestamp) miniTable.getValueAt(i, 1); // 1-DateTrx + KeyNamePair pp = (KeyNamePair) miniTable.getValueAt(i, 2); // 2-X_DepositBatch_ID + int X_DepositBatch_ID = pp.getKey(); + + pp = (KeyNamePair) miniTable.getValueAt(i, 5); // 5- C_BankAccount_ID + int C_BankAccount_ID = pp.getKey(); + + log.fine("Deposit Batch Date=" + trxDate + ", Batch=" + X_DepositBatch_ID + +" , Bank Account" + C_BankAccount_ID); + + PreparedStatement pstmt = null; + ResultSet rs = null; + try + { + pstmt = DB.prepareStatement(sql.toString(), null); + pstmt.setTimestamp(1, ts); + pstmt.setInt(2, X_DepositBatch_ID); + pstmt.setInt(3, C_BankAccount_ID); + rs = pstmt.executeQuery(); + while(rs.next()) + { + int C_Payment_ID = rs.getInt(2); + int C_Currency_ID = rs.getInt(4); + BigDecimal TrxAmt = rs.getBigDecimal(6); // PayAmt + + log.fine("Line Date=" + trxDate + ", Payment=" + C_Payment_ID + ", Currency=" + C_Currency_ID + ", Amt=" + TrxAmt); + // + MBankStatementLine bsl = new MBankStatementLine (bs); + bsl.setStatementLineDate(trxDate); + bsl.setPayment(new MPayment(Env.getCtx(), C_Payment_ID, null)); + if (!bsl.save()) + log.log(Level.SEVERE, "Line not created #" + i); + + } + } + catch(SQLException e) + { + log.log(Level.SEVERE, sql.toString(), e); + } + finally + { + DB.close(rs, pstmt); + rs = null; pstmt = null; + } + } // if selected + } // for all rows + return true; + } + + protected Vector getOISColumnNames() + { + // Header Info + Vector columnNames = new Vector(6); + columnNames.add(Msg.getMsg(Env.getCtx(), "Select")); + columnNames.add(Msg.translate(Env.getCtx(), "Date")); + columnNames.add(Msg.getElement(Env.getCtx(), "X_DepositBatch_ID")); + columnNames.add(Msg.translate(Env.getCtx(), "Amount")); + columnNames.add(Msg.translate(Env.getCtx(), "ConvertedAmount")); + columnNames.add(Msg.translate(Env.getCtx(), "C_BankAccount_ID")); + + return columnNames; + } +} \ No newline at end of file diff --git a/org.adempiere.ui/src/org/compiere/grid/CreateFromDepositBatch.java b/org.adempiere.ui/src/org/compiere/grid/CreateFromDepositBatch.java new file mode 100644 index 0000000000..6e95890e4f --- /dev/null +++ b/org.adempiere.ui/src/org/compiere/grid/CreateFromDepositBatch.java @@ -0,0 +1,169 @@ +/****************************************************************************** + * Copyright (C) 2013 Elaine Tan * + * Copyright (C) 2013 Trek Global + * This program is free software; you can redistribute it and/or modify it * + * under the terms version 2 of the GNU General Public License as published * + * by the Free Software Foundation. This program is distributed in the hope * + * that it will be useful, but WITHOUT ANY WARRANTY; without even the implied * + * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * + * See the GNU General Public License for more details. * + * You should have received a copy of the GNU General Public License along * + * with this program; if not, write to the Free Software Foundation, Inc., * + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. * + *****************************************************************************/ +package org.compiere.grid; + +import java.math.BigDecimal; +import java.sql.PreparedStatement; +import java.sql.ResultSet; +import java.sql.SQLException; +import java.sql.Timestamp; +import java.util.Vector; +import java.util.logging.Level; + +import org.compiere.minigrid.IMiniTable; +import org.compiere.model.GridTab; +import org.compiere.model.MDepositBatch; +import org.compiere.model.MDepositBatchLine; +import org.compiere.model.MPayment; +import org.compiere.util.DB; +import org.compiere.util.Env; +import org.compiere.util.KeyNamePair; +import org.compiere.util.Msg; + +/** + * + * @author Elaine + * + */ +public abstract class CreateFromDepositBatch extends CreateFromBatch +{ + public CreateFromDepositBatch(GridTab mTab) + { + super(mTab); + log.info(mTab.toString()); + } + + public boolean dynInit() throws Exception + { + log.config(""); + setTitle(Msg.getElement(Env.getCtx(), "X_DepositBatch_ID") + " .. " + Msg.translate(Env.getCtx(), "CreateFrom")); + + return true; + } + + protected Vector> getBankAccountData(Object BankAccount, Object BPartner, String DocumentNo, + Object DateFrom, Object DateTo, Object AmtFrom, Object AmtTo, Object DocType, Object TenderType, String AuthCode) + { + Vector> data = new Vector>(); + + StringBuilder sql = new StringBuilder(); + sql.append("SELECT p.DateTrx,p.C_Payment_ID,p.DocumentNo, p.C_Currency_ID,c.ISO_Code, p.PayAmt,"); + sql.append("currencyConvert(p.PayAmt,p.C_Currency_ID,ba.C_Currency_ID,?,null,p.AD_Client_ID,p.AD_Org_ID), bp.Name "); + sql.append("FROM C_BankAccount ba"); + sql.append(" INNER JOIN C_Payment_v p ON (p.C_BankAccount_ID=ba.C_BankAccount_ID)"); + sql.append(" INNER JOIN C_Currency c ON (p.C_Currency_ID=c.C_Currency_ID)"); + sql.append(" INNER JOIN C_Payment py ON (py.C_Payment_ID=p.C_Payment_ID)"); + sql.append(" LEFT OUTER JOIN C_BPartner bp ON (p.C_BPartner_ID=bp.C_BPartner_ID) "); + sql.append(getSQLWhere(BPartner, DocumentNo, DateFrom, DateTo, AmtFrom, AmtTo, DocType, TenderType, AuthCode)); + + sql.append(" AND p.IsReceipt = 'Y'"); + sql.append(" AND (py.X_DepositBatch_ID = 0 OR py.X_DepositBatch_ID IS NULL)"); + + sql.append(" ORDER BY p.DateTrx"); + + PreparedStatement pstmt = null; + ResultSet rs = null; + try + { + pstmt = DB.prepareStatement(sql.toString(), null); + setParameters(pstmt, BankAccount, BPartner, DocumentNo, DateFrom, DateTo, AmtFrom, AmtTo, DocType, TenderType, AuthCode); + rs = pstmt.executeQuery(); + while(rs.next()) + { + Vector line = new Vector(6); + line.add(new Boolean(false)); // 0-Selection + line.add(rs.getTimestamp(1)); // 1-DateTrx + KeyNamePair pp = new KeyNamePair(rs.getInt(2), rs.getString(3)); + line.add(pp); // 2-C_Payment_ID + pp = new KeyNamePair(rs.getInt(4), rs.getString(5)); + line.add(pp); // 3-Currency + line.add(rs.getBigDecimal(6)); // 4-PayAmt + line.add(rs.getBigDecimal(7)); // 5-Conv Amt + line.add(rs.getString(8)); // 6-BParner + data.add(line); + } + } + catch(SQLException e) + { + log.log(Level.SEVERE, sql.toString(), e); + } + finally + { + DB.close(rs, pstmt); + rs = null; pstmt = null; + } + + return data; + } + + protected void configureMiniTable(IMiniTable miniTable) + { + miniTable.setColumnClass(0, Boolean.class, false); // 0-Selection + miniTable.setColumnClass(1, Timestamp.class, true); // 1-TrxDate + miniTable.setColumnClass(2, String.class, true); // 2-Payment + miniTable.setColumnClass(3, String.class, true); // 3-Currency + miniTable.setColumnClass(4, BigDecimal.class, true); // 4-Amount + miniTable.setColumnClass(5, BigDecimal.class, true); // 5-ConvAmount + miniTable.setColumnClass(6, String.class, true); // 6-BPartner + // Table UI + miniTable.autoSize(); + } + + public boolean save(IMiniTable miniTable, String trxName) + { + // fixed values + int X_DepositBatch_ID = ((Integer) getGridTab().getValue("X_DepositBatch_ID")).intValue(); + MDepositBatch db = new MDepositBatch(Env.getCtx(), X_DepositBatch_ID, null); + log.config(db.toString()); + + // Lines + for(int i = 0; i < miniTable.getRowCount(); i++) + { + if(((Boolean) miniTable.getValueAt(i, 0)).booleanValue()) + { + Timestamp trxDate = (Timestamp) miniTable.getValueAt(i, 1); // 1-DateTrx + KeyNamePair pp = (KeyNamePair) miniTable.getValueAt(i, 2); // 2-C_Payment_ID + int C_Payment_ID = pp.getKey(); + pp = (KeyNamePair) miniTable.getValueAt(i, 3); // 3-Currency + int C_Currency_ID = pp.getKey(); + BigDecimal TrxAmt = (BigDecimal) miniTable.getValueAt(i, 4); // 4-PayAmt + // BigDecimal StmtAmt = (BigDecimal) miniTable.getValueAt(i, 5);// 5-Conv Amt + // + log.fine("Line Date=" + trxDate + ", Payment=" + C_Payment_ID + ", Currency=" + C_Currency_ID + ", Amt=" + TrxAmt); + // + MDepositBatchLine dbl = new MDepositBatchLine(db); + // dbl.setStatementLineDate(trxDate); + dbl.setPayment(new MPayment(Env.getCtx(), C_Payment_ID, null)); + if(!dbl.save()) + log.log(Level.SEVERE, "Line not created #" + i); + } // if selected + } // for all rows + return true; + } + + protected Vector getOISColumnNames() + { + // Header Info + Vector columnNames = new Vector(7); + columnNames.add(Msg.getMsg(Env.getCtx(), "Select")); + columnNames.add(Msg.translate(Env.getCtx(), "Date")); + columnNames.add(Msg.getElement(Env.getCtx(), "C_Payment_ID")); + columnNames.add(Msg.translate(Env.getCtx(), "C_Currency_ID")); + columnNames.add(Msg.translate(Env.getCtx(), "Amount")); + columnNames.add(Msg.translate(Env.getCtx(), "ConvertedAmount")); + columnNames.add(Msg.translate(Env.getCtx(), "C_BPartner_ID")); + + return columnNames; + } +} \ No newline at end of file diff --git a/org.adempiere.ui/src/org/compiere/grid/CreateFromInvoice.java b/org.adempiere.ui/src/org/compiere/grid/CreateFromInvoice.java index 6a534ea81b..fd0ba621d1 100644 --- a/org.adempiere.ui/src/org/compiere/grid/CreateFromInvoice.java +++ b/org.adempiere.ui/src/org/compiere/grid/CreateFromInvoice.java @@ -21,6 +21,7 @@ import java.util.ArrayList; import java.util.Vector; import java.util.logging.Level; +import org.compiere.apps.IStatusBar; import org.compiere.minigrid.IMiniTable; import org.compiere.model.GridTab; import org.compiere.model.MCurrency; @@ -327,7 +328,7 @@ public abstract class CreateFromInvoice extends CreateFrom /** * List number of rows selected */ - public void info() + public void info(IMiniTable miniTable, IStatusBar statusBar) { } // infoInvoice diff --git a/org.adempiere.ui/src/org/compiere/grid/CreateFromPackageShipment.java b/org.adempiere.ui/src/org/compiere/grid/CreateFromPackageShipment.java index 4801fc4277..1745137391 100644 --- a/org.adempiere.ui/src/org/compiere/grid/CreateFromPackageShipment.java +++ b/org.adempiere.ui/src/org/compiere/grid/CreateFromPackageShipment.java @@ -21,6 +21,7 @@ import java.util.HashMap; import java.util.Vector; import java.util.logging.Level; +import org.compiere.apps.IStatusBar; import org.compiere.minigrid.IMiniTable; import org.compiere.model.GridTab; import org.compiere.model.MInOut; @@ -94,7 +95,7 @@ public abstract class CreateFromPackageShipment extends CreateFrom return data; } - public void info() + public void info(IMiniTable miniTable, IStatusBar statusBar) { } diff --git a/org.adempiere.ui/src/org/compiere/grid/CreateFromRMA.java b/org.adempiere.ui/src/org/compiere/grid/CreateFromRMA.java index 822fe5a07a..15151dbbaa 100644 --- a/org.adempiere.ui/src/org/compiere/grid/CreateFromRMA.java +++ b/org.adempiere.ui/src/org/compiere/grid/CreateFromRMA.java @@ -20,6 +20,7 @@ import java.sql.SQLException; import java.util.Vector; import java.util.logging.Level; +import org.compiere.apps.IStatusBar; import org.compiere.minigrid.IMiniTable; import org.compiere.model.GridTab; import org.compiere.model.MRMA; @@ -122,7 +123,7 @@ public abstract class CreateFromRMA extends CreateFrom { } @Override - public void info() + public void info(IMiniTable miniTable, IStatusBar statusBar) { } diff --git a/org.adempiere.ui/src/org/compiere/grid/CreateFromShipment.java b/org.adempiere.ui/src/org/compiere/grid/CreateFromShipment.java index bda7fe507b..e99187031c 100644 --- a/org.adempiere.ui/src/org/compiere/grid/CreateFromShipment.java +++ b/org.adempiere.ui/src/org/compiere/grid/CreateFromShipment.java @@ -21,6 +21,8 @@ import java.sql.SQLException; import java.util.ArrayList; import java.util.Vector; import java.util.logging.Level; + +import org.compiere.apps.IStatusBar; import org.compiere.minigrid.IMiniTable; import org.compiere.model.GridTab; import org.compiere.model.MInOut; @@ -501,7 +503,7 @@ public abstract class CreateFromShipment extends CreateFrom /** * List number of rows selected */ - public void info() + public void info(IMiniTable miniTable, IStatusBar statusBar) { } // infoInvoice diff --git a/org.adempiere.ui/src/org/compiere/grid/CreateFromStatement.java b/org.adempiere.ui/src/org/compiere/grid/CreateFromStatement.java index 00a61ee1fe..1e51c91601 100644 --- a/org.adempiere.ui/src/org/compiere/grid/CreateFromStatement.java +++ b/org.adempiere.ui/src/org/compiere/grid/CreateFromStatement.java @@ -18,9 +18,11 @@ import java.sql.PreparedStatement; import java.sql.ResultSet; import java.sql.SQLException; import java.sql.Timestamp; +import java.text.DecimalFormat; import java.util.Vector; import java.util.logging.Level; +import org.compiere.apps.IStatusBar; import org.compiere.minigrid.IMiniTable; import org.compiere.model.GridTab; import org.compiere.model.MBankAccount; @@ -28,6 +30,7 @@ import org.compiere.model.MBankStatement; import org.compiere.model.MBankStatementLine; import org.compiere.model.MPayment; import org.compiere.util.DB; +import org.compiere.util.DisplayType; import org.compiere.util.Env; import org.compiere.util.KeyNamePair; import org.compiere.util.Msg; @@ -257,9 +260,22 @@ public abstract class CreateFromStatement extends CreateFrom return data; } - public void info() + public void info(IMiniTable miniTable, IStatusBar statusBar) { - + DecimalFormat format = DisplayType.getNumberFormat(DisplayType.Amount); + + BigDecimal total = new BigDecimal(0.0); + int rows = miniTable.getRowCount(); + int count = 0; + for(int i = 0; i < rows; i++) + { + if(((Boolean) miniTable.getValueAt(i, 0)).booleanValue()) + { + total = total.add((BigDecimal) miniTable.getValueAt(i, 4)); + count++; + } + } + statusBar.setStatusLine(String.valueOf(count) + " - " + Msg.getMsg(Env.getCtx(), "Sum") + " " + format.format(total)); } protected void configureMiniTable (IMiniTable miniTable) diff --git a/org.adempiere.ui/src/org/compiere/grid/CreateFromStatementBatch.java b/org.adempiere.ui/src/org/compiere/grid/CreateFromStatementBatch.java new file mode 100644 index 0000000000..b99504492c --- /dev/null +++ b/org.adempiere.ui/src/org/compiere/grid/CreateFromStatementBatch.java @@ -0,0 +1,169 @@ +/****************************************************************************** + * Copyright (C) 2013 Elaine Tan * + * Copyright (C) 2013 Trek Global + * This program is free software; you can redistribute it and/or modify it * + * under the terms version 2 of the GNU General Public License as published * + * by the Free Software Foundation. This program is distributed in the hope * + * that it will be useful, but WITHOUT ANY WARRANTY; without even the implied * + * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * + * See the GNU General Public License for more details. * + * You should have received a copy of the GNU General Public License along * + * with this program; if not, write to the Free Software Foundation, Inc., * + * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. * + *****************************************************************************/ +package org.compiere.grid; + +import java.math.BigDecimal; +import java.sql.PreparedStatement; +import java.sql.ResultSet; +import java.sql.SQLException; +import java.sql.Timestamp; +import java.util.Vector; +import java.util.logging.Level; + +import org.compiere.minigrid.IMiniTable; +import org.compiere.model.GridTab; +import org.compiere.model.MBankStatement; +import org.compiere.model.MBankStatementLine; +import org.compiere.model.MPayment; +import org.compiere.util.DB; +import org.compiere.util.Env; +import org.compiere.util.KeyNamePair; +import org.compiere.util.Msg; + +/** + * + * @author Elaine + * + */ +public abstract class CreateFromStatementBatch extends CreateFromBatch +{ + public CreateFromStatementBatch(GridTab mTab) + { + super(mTab); + log.info(mTab.toString()); + } + + public boolean dynInit() throws Exception + { + log.config(""); + setTitle(Msg.getElement(Env.getCtx(), "C_BankStatement_ID") + " .. " + Msg.translate(Env.getCtx(), "CreateFrom")); + + return true; + } + + protected Vector> getBankAccountData(Object BankAccount, Object BPartner, String DocumentNo, + Object DateFrom, Object DateTo, Object AmtFrom, Object AmtTo, Object DocType, Object TenderType, String AuthCode) + { + Vector> data = new Vector>(); + + StringBuilder sql = new StringBuilder(); + sql.append("SELECT p.DateTrx,p.C_Payment_ID,p.DocumentNo, p.C_Currency_ID,c.ISO_Code, p.PayAmt,"); + sql.append("currencyConvert(p.PayAmt,p.C_Currency_ID,ba.C_Currency_ID,?,null,p.AD_Client_ID,p.AD_Org_ID), bp.Name "); + sql.append("FROM C_BankAccount ba"); + sql.append(" INNER JOIN C_Payment_v p ON (p.C_BankAccount_ID=ba.C_BankAccount_ID)"); + sql.append(" INNER JOIN C_Currency c ON (p.C_Currency_ID=c.C_Currency_ID)"); + sql.append(" LEFT OUTER JOIN C_BPartner bp ON (p.C_BPartner_ID=bp.C_BPartner_ID) "); + sql.append(getSQLWhere(BPartner, DocumentNo, DateFrom, DateTo, AmtFrom, AmtTo, DocType, TenderType, AuthCode)); + sql.append(" ORDER BY p.DateTrx"); + + PreparedStatement pstmt = null; + ResultSet rs = null; + try + { + pstmt = DB.prepareStatement(sql.toString(), null); + setParameters(pstmt, BankAccount, BPartner, DocumentNo, DateFrom, DateTo, AmtFrom, AmtTo, DocType, TenderType, AuthCode); + rs = pstmt.executeQuery(); + while(rs.next()) + { + Vector line = new Vector(6); + line.add(new Boolean(false)); // 0-Selection + line.add(rs.getTimestamp(1)); // 1-DateTrx + KeyNamePair pp = new KeyNamePair(rs.getInt(2), rs.getString(3)); + line.add(pp); // 2-C_Payment_ID + pp = new KeyNamePair(rs.getInt(4), rs.getString(5)); + line.add(pp); // 3-Currency + line.add(rs.getBigDecimal(6)); // 4-PayAmt + line.add(rs.getBigDecimal(7)); // 5-Conv Amt + line.add(rs.getString(8)); // 6-BParner + data.add(line); + } + } + catch (SQLException e) + { + log.log(Level.SEVERE, sql.toString(), e); + } + finally + { + DB.close(rs, pstmt); + rs = null; pstmt = null; + } + + return data; + } + + protected void configureMiniTable(IMiniTable miniTable) + { + miniTable.setColumnClass(0, Boolean.class, false); // 0-Selection + miniTable.setColumnClass(1, Timestamp.class, false); // 1-TrxDate / nmicoud - idempiere 240 Let user choose the 'Statement Line Date' + miniTable.setColumnClass(2, String.class, true); // 2-Payment + miniTable.setColumnClass(3, String.class, true); // 3-Currency + miniTable.setColumnClass(4, BigDecimal.class, true); // 4-Amount + miniTable.setColumnClass(5, BigDecimal.class, true); // 5-ConvAmount + miniTable.setColumnClass(6, String.class, true); // 6-BPartner + // Table UI + miniTable.autoSize(); + } + + public boolean save(IMiniTable miniTable, String trxName) + { + // fixed values + int C_BankStatement_ID = ((Integer) getGridTab().getValue("C_BankStatement_ID")).intValue(); + MBankStatement bs = new MBankStatement (Env.getCtx(), C_BankStatement_ID, trxName); + log.config(bs.toString()); + + // Lines + for(int i = 0; i < miniTable.getRowCount(); i++) + { + if(((Boolean) miniTable.getValueAt(i, 0)).booleanValue()) + { + Timestamp trxDate = (Timestamp) miniTable.getValueAt(i, 1); // 1-DateTrx + KeyNamePair pp = (KeyNamePair) miniTable.getValueAt(i, 2); // 2-C_Payment_ID + int C_Payment_ID = pp.getKey(); + pp = (KeyNamePair) miniTable.getValueAt(i, 3); // 3-Currency + int C_Currency_ID = pp.getKey(); + BigDecimal TrxAmt = (BigDecimal) miniTable.getValueAt(i, 5); // 5- Conv Amt + + log.fine("Line Date=" + trxDate + + ", Payment=" + C_Payment_ID + ", Currency=" + C_Currency_ID + ", Amt=" + TrxAmt); + // + MBankStatementLine bsl = new MBankStatementLine (bs); + bsl.setStatementLineDate(trxDate); + bsl.setPayment(new MPayment(Env.getCtx(), C_Payment_ID, trxName)); + + bsl.setTrxAmt(TrxAmt); + bsl.setStmtAmt(TrxAmt); + bsl.setC_Currency_ID(C_Currency_ID); + + if (!bsl.save()) + log.log(Level.SEVERE, "Line not created #" + i); + } // if selected + } // for all rows + return true; + } // save + + protected Vector getOISColumnNames() + { + // Header Info + Vector columnNames = new Vector(7); + columnNames.add(Msg.getMsg(Env.getCtx(), "Select")); + columnNames.add(Msg.translate(Env.getCtx(), "Date")); + columnNames.add(Msg.getElement(Env.getCtx(), "C_Payment_ID")); + columnNames.add(Msg.translate(Env.getCtx(), "C_Currency_ID")); + columnNames.add(Msg.translate(Env.getCtx(), "Amount")); + columnNames.add(Msg.translate(Env.getCtx(), "ConvertedAmount")); + columnNames.add(Msg.translate(Env.getCtx(), "C_BPartner_ID")); + + return columnNames; + } +} \ No newline at end of file diff --git a/org.adempiere.ui/src/org/compiere/grid/ICreateFromFactory.java b/org.adempiere.ui/src/org/compiere/grid/ICreateFromFactory.java index 28796205e7..3480f1e84b 100644 --- a/org.adempiere.ui/src/org/compiere/grid/ICreateFromFactory.java +++ b/org.adempiere.ui/src/org/compiere/grid/ICreateFromFactory.java @@ -22,6 +22,6 @@ import org.compiere.model.GridTab; */ public interface ICreateFromFactory { - public ICreateFrom create(GridTab mTab); + public ICreateFrom create(GridTab mTab, String columnName); }