Merge c088cbe26368

This commit is contained in:
Heng Sin Low 2012-11-30 01:19:15 +08:00
commit 36b39ddf9f
39 changed files with 5076 additions and 334 deletions

View File

@ -1,4 +1,4 @@
|||14:59:04 Tue, Nov 27, 2012| |||01:35:08 mié, nov 28, 2012|
|CommonTests.CreateMaterialReceipt||01:36:56 mar, abr 03, 2012| |CommonTests.CreateMaterialReceipt||01:36:56 mar, abr 03, 2012|
|CommonTests.CreateProductPrice||01:29:57 mar, abr 03, 2012| |CommonTests.CreateProductPrice||01:29:57 mar, abr 03, 2012|
|AvgCostSuite.BasicTest||01:18:34 mar, abr 03, 2012| |AvgCostSuite.BasicTest||01:18:34 mar, abr 03, 2012|

View File

@ -2,7 +2,7 @@ Define the global path:
Where to find the fixtures classes: ( i.e. /home/hengsin/workspace/idempiere/fitnesse/bin ) Where to find the fixtures classes: ( i.e. /home/hengsin/workspace/idempiere/fitnesse/bin )
!define fitnesse_home {/home/hengsin/workspace/idempiere/fitnesse} !define fitnesse_home {/home/carlos/hgAdempiere/localosgi/fitnesse}
!path ${fitnesse_home}/fitnesse.jar:${fitnesse_home}/lib/*.jar:${fitnesse_home}/bin !path ${fitnesse_home}/fitnesse.jar:${fitnesse_home}/lib/*.jar:${fitnesse_home}/bin
@ -16,7 +16,7 @@ There are some important variables here:
This variables can be redefined specifically at page level. This variables can be redefined specifically at page level.
!define TEST_RUNNER {fitnesse.client.FitServerServletInvoker} !define TEST_RUNNER {fitnesse.client.FitServerServletInvoker}
!define COMMAND_PATTERN {java -Xms32m -Xmx512m -DLOG4J_LEVEL=CONFIG -cp %p %m http://localhost:8080/fitnesse/FitServlet} !define COMMAND_PATTERN {java -Xms32m -Xmx512m -DLOG4J_LEVEL=CONFIG -cp %p %m http://localhost:8082/fitnesse/FitServlet}
To enable remote debugging the tests will stop until you connect remotely via eclipse using RemoteADempiereFitnesse.launch To enable remote debugging the tests will stop until you connect remotely via eclipse using RemoteADempiereFitnesse.launch

View File

@ -0,0 +1,640 @@
-- 201211201820_SetupWizard
--Nov 22, 2012 3:39:39 PM COT
-- IDEMPIERE-393 Setup wizards
ALTER TABLE AD_WizardProcess ADD (AD_User_ID NUMERIC(10) DEFAULT NULL)
;
-- Nov 15, 2012 5:07:01 PM COT
INSERT INTO AD_Column (SeqNoSelection,IsSyncDatabase,IsEncrypted,Version,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,IsAlwaysUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,Updated,CreatedBy,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton) VALUES (0,'N','N',0,200012,200913,'D','N','N','N',0,'N',30,'N',17,'N',138,'N','Y','286ad460-4317-40f1-afd5-582000e5fe0f','Y','N','AD_User_ID','User within the system - Internal or Business Partner Contact','The User identifies a unique user in the system. This could be an internal user or a business partner contact','User/Contact','Y',TO_DATE('2012-11-15 17:07:00','YYYY-MM-DD HH24:MI:SS'),0,0,'Y',TO_DATE('2012-11-15 17:07:00','YYYY-MM-DD HH24:MI:SS'),0,0,'N')
;
-- Nov 15, 2012 5:07:01 PM COT
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=200913 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)
;
-- Nov 20, 2012 11:01:13 AM COT
INSERT INTO AD_Window
(AD_Window_ID, AD_Client_ID, AD_Org_ID, IsActive, Created, Createdby, Updated, UpdatedBy, Name, Description, WindowType, Issotrx, entitytype, processing, isdefault, winheight, winwidth, isbetafunctionality, ad_window_uu)
VALUES (200020,0,0,'Y',TO_DATE('2012-11-20 11:01:13','YYYY-MM-DD HH24:MI:SS'),0,TO_DATE('2012-11-20 11:34:06','YYYY-MM-DD HH24:MI:SS'),0,'Setup Wizard Maintenance','Maintenance Setup Wizard window','M','N','D','N','N',0,0,'N','ed26f18e-c8d2-4c3c-9a7a-a292429fd1e0')
;
-- Nov 20, 2012 11:04:49
INSERT INTO AD_Tab (AD_Client_ID,AD_Org_ID,AD_Tab_ID,AD_Table_ID,AD_Window_ID,Created,CreatedBy,Description,EntityType,HasTree,IsActive,IsAdvancedTab,IsInfoTab,IsInsertRecord,IsReadOnly,IsSingleRow,IsSortTab,IsTranslationTab,Name,Processing,SeqNo,TabLevel,Updated,UpdatedBy) VALUES (0,0,200031,200012,200020,TO_DATE('2012-11-20 11:04:49','YYYY-MM-DD HH24:MI:SS'),0,'Setup Wizard','D','N','Y','N','N','Y','N','N','N','N','Setup Wizard','N',10,0,TO_DATE('2012-11-20 11:04:49','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Nov 20, 2012 11:05:56
INSERT INTO AD_Field
(AD_Client_ID,AD_Column_ID,AD_Field_ID,AD_Org_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,
IsReadOnly,IsSameLine,Name,Updated,UpdatedBy)
VALUES ( 0,200315,200842,0,200031,TO_DATE('2012-11-20 11:05:56','YYYY-MM-DD HH24:MI:SS'),0,'Workflow Node (activity), step or process',10,'D','The Workflow Node indicates a unique step or process in a Workflow.','Y','Y','Y','N','N','N','Y','N','Node',TO_DATE('2012-11-20 15:26:20','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Nov 20, 2012 11:05:57
INSERT INTO AD_Field
(AD_Client_ID,AD_Column_ID,AD_Field_ID,AD_Org_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,
IsReadOnly,IsSameLine,Name,Updated,UpdatedBy)
VALUES ( 0,200913,200845,0,200031,TO_DATE('2012-11-20 11:05:57','YYYY-MM-DD HH24:MI:SS'),0,'User within the system - Internal or Business Partner Contact',10,'D','The User identifies a unique user in the system. This could be an internal user or a business partner contact','Y','Y','Y','N','N','N','N','N','User/Contact',TO_DATE('2012-11-20 15:26:37','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Nov 20, 2012 11:05:58
INSERT INTO AD_Field
(AD_Client_ID,AD_Column_ID,AD_Field_ID,AD_Org_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,
IsReadOnly,IsSameLine,Name,Updated,UpdatedBy)
VALUES ( 0,200310,200847,0,200031,TO_DATE('2012-11-20 11:05:58','YYYY-MM-DD HH24:MI:SS'),0,'',1,'D','','Y','Y','Y','N','N','N','N','N','Wizard Status',TO_DATE('2012-11-20 15:27:05','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Nov 20, 2012 11:05:57
INSERT INTO AD_Field
(AD_Client_ID,AD_Column_ID,AD_Field_ID,AD_Org_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,
IsReadOnly,IsSameLine,Name,Updated,UpdatedBy)
VALUES ( 0,200307,200844,0,200031,TO_DATE('2012-11-20 11:05:57','YYYY-MM-DD HH24:MI:SS'),0,'Organizational entity within client',22,'D','An organization is a unit of your client or legal entity - examples are store, department. You can share data between organizations.','Y','Y','Y','N','N','N','Y','N','Organization',TO_DATE('2012-11-20 15:27:45','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Nov 20, 2012 11:05:58
INSERT INTO AD_Field
(AD_Client_ID,AD_Column_ID,AD_Field_ID,AD_Org_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,
IsReadOnly,IsSameLine,Name,Updated,UpdatedBy)
VALUES ( 0,200313,200846,0,200031,TO_DATE('2012-11-20 11:05:58','YYYY-MM-DD HH24:MI:SS'),0,'',22,'D','','Y','Y','Y','N','N','N','Y','N','Wizard Process',TO_DATE('2012-11-20 15:29:04','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Nov 20, 2012 11:05:55
INSERT INTO AD_Field
(AD_Client_ID,AD_Column_ID,AD_Field_ID,AD_Org_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,
IsReadOnly,IsSameLine,Name,Updated,UpdatedBy)
VALUES ( 0,200314,200840,0,200031,TO_DATE('2012-11-20 11:05:55','YYYY-MM-DD HH24:MI:SS'),0,'',36,'D','','Y','Y','Y','N','N','N','Y','N','AD_WizardProcess_UU',TO_DATE('2012-11-20 15:29:04','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Nov 20, 2012 11:05:55
INSERT INTO AD_Field
(AD_Client_ID,AD_Column_ID,AD_Field_ID,AD_Org_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,
IsReadOnly,IsSameLine,Name,Updated,UpdatedBy)
VALUES ( 0,200306,200841,0,200031,TO_DATE('2012-11-20 11:05:55','YYYY-MM-DD HH24:MI:SS'),0,'Client/Tenant for this installation.',22,'D','A Client is a company or a legal entity. You cannot share data between Clients. Tenant is a synonym for Client.','Y','Y','Y','N','N','N','N','N','Client',TO_DATE('2012-11-20 15:29:04','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Nov 20, 2012 11:05:54
INSERT INTO AD_Field
(AD_Client_ID,AD_Column_ID,AD_Field_ID,AD_Org_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,
IsReadOnly,IsSameLine,Name,Updated,UpdatedBy)
VALUES ( 0,200312,200839,0,200031,TO_DATE('2012-11-20 11:05:54','YYYY-MM-DD HH24:MI:SS'),0,'The record is active in the system',1,'D','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.','Y','Y','Y','N','N','N','Y','N','Active',TO_DATE('2012-11-20 15:29:04','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Nov 20, 2012 11:05:56
INSERT INTO AD_Field
(AD_Client_ID,AD_Column_ID,AD_Field_ID,AD_Org_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,
IsReadOnly,IsSameLine,Name,Updated,UpdatedBy)
VALUES ( 0,200311,200843,0,200031,TO_DATE('2012-11-20 11:05:56','YYYY-MM-DD HH24:MI:SS'),0,'Optional additional user defined information',2000,'D','The Note field allows for optional entry of user defined information regarding this record','Y','Y','Y','N','N','N','N','N','Note',TO_DATE('2012-11-20 15:29:04','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Nov 20, 2012 12:09:23 PM COT
INSERT INTO AD_Menu (AD_Window_ID,AD_Menu_ID,IsSummary,IsSOTrx,IsReadOnly,EntityType,IsCentrallyMaintained,Name,action,AD_Menu_UU,IsActive,AD_Client_ID,CreatedBy,Updated,AD_Org_ID,Created,UpdatedBy) VALUES (200020,200026,'N','N','N','D','Y','Setup Wizard Maintenance','W','866bfc16-4543-43ea-856d-85e0c9be6463','Y',0,0,TO_DATE('2012-11-20 12:09:22','YYYY-MM-DD HH24:MI:SS'),0,TO_DATE('2012-11-20 12:09:22','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Nov 20, 2012 12:09:23 PM COT
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=200026 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)
;
-- Nov 20, 2012 12:09:23 PM COT
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, 0, SysDate, 0,t.AD_Tree_ID, 200026, 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=200026)
;
-- Nov 20, 2012 12:13:06 PM COT
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=10, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53083
;
-- Nov 20, 2012 12:18:55 PM COT
UPDATE AD_Field SET IsReadOnly='Y',Updated=TO_DATE('2012-11-20 12:18:55','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0, SeqNo=10 WHERE AD_Field_ID=200842
;
-- Nov 20, 2012 12:19:56 PM COT
UPDATE AD_Field SET IsReadOnly='Y',Updated=TO_DATE('2012-11-20 12:19:56','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0, XPosition=3, SeqNo=40 WHERE AD_Field_ID=200844
;
-- Nov 20, 2012 12:21:33 PM COT
UPDATE AD_Field SET IsReadOnly='Y',Updated=TO_DATE('2012-11-20 12:21:33','YYYY-MM-DD HH24:MI:SS'),SeqNo=50, UpdatedBy=0 WHERE AD_Field_ID=200846
;
-- Nov 20, 2012 12:22:02 PM COT
UPDATE AD_Field SET IsReadOnly='Y',Updated=TO_DATE('2012-11-20 12:22:02','YYYY-MM-DD HH24:MI:SS'),SeqNo=60, XPosition=3, UpdatedBy=0 WHERE AD_Field_ID=200840
;
-- Nov 20, 2012 12:22:48 PM COT
UPDATE AD_Field SET IsReadOnly='Y',Updated=TO_DATE('2012-11-20 12:22:48','YYYY-MM-DD HH24:MI:SS'),SeqNo=80, XPosition=4, UpdatedBy=0 WHERE AD_Field_ID=200839
;
-- Nov 20, 2012 2:52:50 PM COT
UPDATE AD_Field SET SeqNo=90,NumLines=2, ColumnSpan=3, XPosition=3,Updated=TO_DATE('2012-11-20 14:52:50','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Field_ID=200843
;
-- Nov 20, 2012 2:55:17 PM COT
UPDATE AD_Field SET SeqNo=20, XPosition=3,Updated=TO_DATE('2012-11-20 14:55:17','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Field_ID=200845
;
-- Nov 20, 2012 2:55:17 PM COT
UPDATE AD_Field SET SeqNo=70,Updated=TO_DATE('2012-11-20 14:55:17','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Field_ID=200841
;
-- Nov 20, 2012 2:55:17 PM COT
UPDATE AD_Field SET SeqNo=30,Updated=TO_DATE('2012-11-20 14:55:17','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Field_ID=200847
;
-- Nov 20, 2012 3:04:03 PM COT
INSERT INTO AD_TreeBar (AD_Tree_ID,AD_User_ID,Node_ID, AD_Client_ID,AD_Org_ID, IsActive,Created,CreatedBy,Updated,UpdatedBy)VALUES (10,0,495,0,0,'Y',SysDate,0,SysDate,0)
;
-- Nov 27, 2012 10:58:07 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Tab SET IsSingleRow='Y', IsInsertRecord='N',Updated=TO_DATE('2012-11-27 22:58:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=200031
;
-- Nov 27, 2012 11:01:07 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET ColumnSpan=2, SeqNo=10, IsDisplayed='Y', XPosition=1,Updated=TO_DATE('2012-11-27 23:01:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=200841
;
-- Nov 27, 2012 11:01:07 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET ColumnSpan=2, SeqNo=20, IsDisplayed='Y', XPosition=4,Updated=TO_DATE('2012-11-27 23:01:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=200844
;
-- Nov 27, 2012 11:01:07 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET ColumnSpan=2, SeqNo=30,Updated=TO_DATE('2012-11-27 23:01:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=200842
;
-- Nov 27, 2012 11:01:07 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET SeqNo=40, IsDisplayed='Y', XPosition=5,Updated=TO_DATE('2012-11-27 23:01:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=200839
;
-- Nov 27, 2012 11:01:07 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET ColumnSpan=2, SeqNo=50, IsDisplayed='Y', XPosition=1,Updated=TO_DATE('2012-11-27 23:01:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=200847
;
-- Nov 27, 2012 11:01:07 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET ColumnSpan=2, SeqNo=60, IsDisplayed='Y', XPosition=4,Updated=TO_DATE('2012-11-27 23:01:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=200845
;
-- Nov 27, 2012 11:01:07 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET ColumnSpan=5, NumLines=5, SeqNo=70, IsDisplayed='Y', XPosition=1,Updated=TO_DATE('2012-11-27 23:01:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=200843
;
-- Nov 27, 2012 11:01:07 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET SeqNo=0, IsDisplayed='N', XPosition=1,Updated=TO_DATE('2012-11-27 23:01:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=200840
;
-- Nov 27, 2012 11:01:07 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET ColumnSpan=2, SeqNo=0, IsDisplayed='N', XPosition=1,Updated=TO_DATE('2012-11-27 23:01:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=200846
;
-- Nov 27, 2012 11:02:42 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Column SET AD_Reference_Value_ID=286, AD_Reference_ID=30,Updated=TO_DATE('2012-11-27 23:02:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=200913
;
-- Nov 27, 2012 11:04:10 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=200840
;
-- Nov 27, 2012 11:04:10 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=200841
;
-- Nov 27, 2012 11:04:10 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=200844
;
-- Nov 27, 2012 11:04:10 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=200846
;
-- Nov 27, 2012 11:04:10 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET SeqNoGrid=10,IsDisplayedGrid='Y' WHERE AD_Field_ID=200842
;
-- Nov 27, 2012 11:04:10 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET SeqNoGrid=20,IsDisplayedGrid='Y' WHERE AD_Field_ID=200847
;
-- Nov 27, 2012 11:04:10 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET SeqNoGrid=30,IsDisplayedGrid='Y' WHERE AD_Field_ID=200845
;
-- Nov 27, 2012 11:04:10 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET SeqNoGrid=40,IsDisplayedGrid='Y' WHERE AD_Field_ID=200843
;
-- Nov 27, 2012 11:04:10 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET SeqNoGrid=50,IsDisplayedGrid='Y' WHERE AD_Field_ID=200839
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=0, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=218
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=1, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=153
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=2, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=263
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=3, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=166
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=4, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=203
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=5, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53242
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=6, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=236
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=7, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=183
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=8, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=160
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=9, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=278
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=10, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=345
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=11, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53296
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=12, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=519
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=13, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53014
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=14, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53108
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=15, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=518
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=16, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=200024
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=0, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=261
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=1, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53202
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=2, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=225
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=3, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=200009
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=4, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=200026
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=5, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=148
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=6, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=529
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=7, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=397
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=8, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=532
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=9, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53084
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=10, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53083
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=0, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=218
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=1, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=153
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=2, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=263
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=3, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=166
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=4, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=203
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=5, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53242
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=6, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=236
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=7, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=183
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=8, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=160
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=9, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=278
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=10, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=345
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=11, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53296
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=12, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=519
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=13, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53014
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=14, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53108
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=15, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=518
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=0, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=241
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=1, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=288
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=2, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=432
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=3, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=243
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=4, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=413
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=5, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=538
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=6, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=462
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=7, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=505
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=8, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=200023
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=9, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=235
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=10, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=511
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=11, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=245
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=12, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=251
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=13, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=246
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=14, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=509
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=15, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=510
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=16, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=496
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=17, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=497
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=18, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=304
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=19, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=255
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=20, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=286
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=21, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=287
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=22, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=438
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=23, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=234
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=24, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=244
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=25, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53313
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=26, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53314
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=27, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53190
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=28, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=53187
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=29, Updated=SysDate WHERE AD_Tree_ID=10 AND Node_ID=200024
;
-- Nov 28, 2012 1:11:04 AM COT
-- IDEMPIERE-393 Setup wizards
INSERT INTO AD_Message (MsgType,MsgText,AD_Message_ID,EntityType,AD_Message_UU,Value,IsActive,Updated,CreatedBy,UpdatedBy,AD_Client_ID,AD_Org_ID,Created) VALUES ('I','Just Mine',200117,'D','0c220c5c-719f-4b8f-82d6-a21b0c123e66','JustMine','Y',TO_DATE('2012-11-28 01:11:03','YYYY-MM-DD HH24:MI:SS'),100,100,0,0,TO_DATE('2012-11-28 01:11:03','YYYY-MM-DD HH24:MI:SS'))
;
-- Nov 28, 2012 1:11:04 AM COT
-- IDEMPIERE-393 Setup wizards
INSERT INTO AD_Message_Trl (AD_Language,AD_Message_ID, MsgText,MsgTip, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Message_Trl_UU ) SELECT l.AD_Language,t.AD_Message_ID, t.MsgText,t.MsgTip, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Message t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Message_ID=200117 AND NOT EXISTS (SELECT * FROM AD_Message_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Message_ID=t.AD_Message_ID)
;
-- Nov 28, 2012 1:11:20 AM COT
-- IDEMPIERE-393 Setup wizards
INSERT INTO AD_Message (MsgType,MsgText,AD_Message_ID,EntityType,AD_Message_UU,Value,IsActive,Updated,CreatedBy,UpdatedBy,AD_Client_ID,AD_Org_ID,Created) VALUES ('I','Show Colors',200118,'D','4f917ca8-a515-4038-add0-a3bd5d4b2907','ShowColors','Y',TO_DATE('2012-11-28 01:11:20','YYYY-MM-DD HH24:MI:SS'),100,100,0,0,TO_DATE('2012-11-28 01:11:20','YYYY-MM-DD HH24:MI:SS'))
;
-- Nov 28, 2012 1:11:20 AM COT
-- IDEMPIERE-393 Setup wizards
INSERT INTO AD_Message_Trl (AD_Language,AD_Message_ID, MsgText,MsgTip, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Message_Trl_UU ) SELECT l.AD_Language,t.AD_Message_ID, t.MsgText,t.MsgTip, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Message t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Message_ID=200118 AND NOT EXISTS (SELECT * FROM AD_Message_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Message_ID=t.AD_Message_ID)
;
SELECT register_migration_script('201211201820_SetupWizard.sql') FROM dual
;

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,640 @@
-- 201211201820_SetupWizard
--Nov 22, 2012 3:39:39 PM COT
-- IDEMPIERE-393 Setup wizards
ALTER TABLE AD_WizardProcess ADD COLUMN AD_User_ID NUMERIC(10) DEFAULT NULL
;
-- Nov 15, 2012 5:07:01 PM COT
INSERT INTO AD_Column (SeqNoSelection,IsSyncDatabase,IsEncrypted,Version,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,IsAlwaysUpdateable,ColumnName,Description,Help,Name,IsAllowCopy,Updated,CreatedBy,AD_Org_ID,IsActive,Created,UpdatedBy,AD_Client_ID,IsToolbarButton) VALUES (0,'N','N',0,200012,200913,'D','N','N','N',0,'N',30,'N',17,'N',138,'N','Y','286ad460-4317-40f1-afd5-582000e5fe0f','Y','N','AD_User_ID','User within the system - Internal or Business Partner Contact','The User identifies a unique user in the system. This could be an internal user or a business partner contact','User/Contact','Y',TO_TIMESTAMP('2012-11-15 17:07:00','YYYY-MM-DD HH24:MI:SS'),0,0,'Y',TO_TIMESTAMP('2012-11-15 17:07:00','YYYY-MM-DD HH24:MI:SS'),0,0,'N')
;
-- Nov 15, 2012 5:07:01 PM COT
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=200913 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)
;
-- Nov 20, 2012 11:01:13 AM COT
INSERT INTO AD_Window
(AD_Window_ID, AD_Client_ID, AD_Org_ID, IsActive, Created, Createdby, Updated, UpdatedBy, Name, Description, WindowType, Issotrx, entitytype, processing, isdefault, winheight, winwidth, isbetafunctionality, ad_window_uu)
VALUES (200020,0,0,'Y',TO_TIMESTAMP('2012-11-20 11:01:13','YYYY-MM-DD HH24:MI:SS'),0,TO_TIMESTAMP('2012-11-20 11:34:06','YYYY-MM-DD HH24:MI:SS'),0,'Setup Wizard Maintenance','Maintenance Setup Wizard window','M','N','D','N','N',0,0,'N','ed26f18e-c8d2-4c3c-9a7a-a292429fd1e0')
;
-- Nov 20, 2012 11:04:49
INSERT INTO AD_Tab (AD_Client_ID,AD_Org_ID,AD_Tab_ID,AD_Table_ID,AD_Window_ID,Created,CreatedBy,Description,EntityType,HasTree,IsActive,IsAdvancedTab,IsInfoTab,IsInsertRecord,IsReadOnly,IsSingleRow,IsSortTab,IsTranslationTab,Name,Processing,SeqNo,TabLevel,Updated,UpdatedBy) VALUES (0,0,200031,200012,200020,TO_TIMESTAMP('2012-11-20 11:04:49','YYYY-MM-DD HH24:MI:SS'),0,'Setup Wizard','D','N','Y','N','N','Y','N','N','N','N','Setup Wizard','N',10,0,TO_TIMESTAMP('2012-11-20 11:04:49','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Nov 20, 2012 11:05:56
INSERT INTO AD_Field
(AD_Client_ID,AD_Column_ID,AD_Field_ID,AD_Org_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,
IsReadOnly,IsSameLine,Name,Updated,UpdatedBy)
VALUES ( 0,200315,200842,0,200031,TO_TIMESTAMP('2012-11-20 11:05:56','YYYY-MM-DD HH24:MI:SS'),0,'Workflow Node (activity), step or process',10,'D','The Workflow Node indicates a unique step or process in a Workflow.','Y','Y','Y','N','N','N','Y','N','Node',TO_TIMESTAMP('2012-11-20 15:26:20','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Nov 20, 2012 11:05:57
INSERT INTO AD_Field
(AD_Client_ID,AD_Column_ID,AD_Field_ID,AD_Org_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,
IsReadOnly,IsSameLine,Name,Updated,UpdatedBy)
VALUES ( 0,200913,200845,0,200031,TO_TIMESTAMP('2012-11-20 11:05:57','YYYY-MM-DD HH24:MI:SS'),0,'User within the system - Internal or Business Partner Contact',10,'D','The User identifies a unique user in the system. This could be an internal user or a business partner contact','Y','Y','Y','N','N','N','N','N','User/Contact',TO_TIMESTAMP('2012-11-20 15:26:37','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Nov 20, 2012 11:05:58
INSERT INTO AD_Field
(AD_Client_ID,AD_Column_ID,AD_Field_ID,AD_Org_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,
IsReadOnly,IsSameLine,Name,Updated,UpdatedBy)
VALUES ( 0,200310,200847,0,200031,TO_TIMESTAMP('2012-11-20 11:05:58','YYYY-MM-DD HH24:MI:SS'),0,'',1,'D','','Y','Y','Y','N','N','N','N','N','Wizard Status',TO_TIMESTAMP('2012-11-20 15:27:05','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Nov 20, 2012 11:05:57
INSERT INTO AD_Field
(AD_Client_ID,AD_Column_ID,AD_Field_ID,AD_Org_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,
IsReadOnly,IsSameLine,Name,Updated,UpdatedBy)
VALUES ( 0,200307,200844,0,200031,TO_TIMESTAMP('2012-11-20 11:05:57','YYYY-MM-DD HH24:MI:SS'),0,'Organizational entity within client',22,'D','An organization is a unit of your client or legal entity - examples are store, department. You can share data between organizations.','Y','Y','Y','N','N','N','Y','N','Organization',TO_TIMESTAMP('2012-11-20 15:27:45','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Nov 20, 2012 11:05:58
INSERT INTO AD_Field
(AD_Client_ID,AD_Column_ID,AD_Field_ID,AD_Org_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,
IsReadOnly,IsSameLine,Name,Updated,UpdatedBy)
VALUES ( 0,200313,200846,0,200031,TO_TIMESTAMP('2012-11-20 11:05:58','YYYY-MM-DD HH24:MI:SS'),0,'',22,'D','','Y','Y','Y','N','N','N','Y','N','Wizard Process',TO_TIMESTAMP('2012-11-20 15:29:04','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Nov 20, 2012 11:05:55
INSERT INTO AD_Field
(AD_Client_ID,AD_Column_ID,AD_Field_ID,AD_Org_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,
IsReadOnly,IsSameLine,Name,Updated,UpdatedBy)
VALUES ( 0,200314,200840,0,200031,TO_TIMESTAMP('2012-11-20 11:05:55','YYYY-MM-DD HH24:MI:SS'),0,'',36,'D','','Y','Y','Y','N','N','N','Y','N','AD_WizardProcess_UU',TO_TIMESTAMP('2012-11-20 15:29:04','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Nov 20, 2012 11:05:55
INSERT INTO AD_Field
(AD_Client_ID,AD_Column_ID,AD_Field_ID,AD_Org_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,
IsReadOnly,IsSameLine,Name,Updated,UpdatedBy)
VALUES ( 0,200306,200841,0,200031,TO_TIMESTAMP('2012-11-20 11:05:55','YYYY-MM-DD HH24:MI:SS'),0,'Client/Tenant for this installation.',22,'D','A Client is a company or a legal entity. You cannot share data between Clients. Tenant is a synonym for Client.','Y','Y','Y','N','N','N','N','N','Client',TO_TIMESTAMP('2012-11-20 15:29:04','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Nov 20, 2012 11:05:54
INSERT INTO AD_Field
(AD_Client_ID,AD_Column_ID,AD_Field_ID,AD_Org_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,
IsReadOnly,IsSameLine,Name,Updated,UpdatedBy)
VALUES ( 0,200312,200839,0,200031,TO_TIMESTAMP('2012-11-20 11:05:54','YYYY-MM-DD HH24:MI:SS'),0,'The record is active in the system',1,'D','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.','Y','Y','Y','N','N','N','Y','N','Active',TO_TIMESTAMP('2012-11-20 15:29:04','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Nov 20, 2012 11:05:56
INSERT INTO AD_Field
(AD_Client_ID,AD_Column_ID,AD_Field_ID,AD_Org_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,
IsReadOnly,IsSameLine,Name,Updated,UpdatedBy)
VALUES ( 0,200311,200843,0,200031,TO_TIMESTAMP('2012-11-20 11:05:56','YYYY-MM-DD HH24:MI:SS'),0,'Optional additional user defined information',2000,'D','The Note field allows for optional entry of user defined information regarding this record','Y','Y','Y','N','N','N','N','N','Note',TO_TIMESTAMP('2012-11-20 15:29:04','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Nov 20, 2012 12:09:23 PM COT
INSERT INTO AD_Menu (AD_Window_ID,AD_Menu_ID,IsSummary,IsSOTrx,IsReadOnly,EntityType,IsCentrallyMaintained,Name,action,AD_Menu_UU,IsActive,AD_Client_ID,CreatedBy,Updated,AD_Org_ID,Created,UpdatedBy) VALUES (200020,200026,'N','N','N','D','Y','Setup Wizard Maintenance','W','866bfc16-4543-43ea-856d-85e0c9be6463','Y',0,0,TO_TIMESTAMP('2012-11-20 12:09:22','YYYY-MM-DD HH24:MI:SS'),0,TO_TIMESTAMP('2012-11-20 12:09:22','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Nov 20, 2012 12:09:23 PM COT
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=200026 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)
;
-- Nov 20, 2012 12:09:23 PM COT
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, 0, CURRENT_TIMESTAMP, 0,t.AD_Tree_ID, 200026, 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=200026)
;
-- Nov 20, 2012 12:13:06 PM COT
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=10, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53083
;
-- Nov 20, 2012 12:18:55 PM COT
UPDATE AD_Field SET IsReadOnly='Y',Updated=TO_TIMESTAMP('2012-11-20 12:18:55','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0, SeqNo=10 WHERE AD_Field_ID=200842
;
-- Nov 20, 2012 12:19:56 PM COT
UPDATE AD_Field SET IsReadOnly='Y',Updated=TO_TIMESTAMP('2012-11-20 12:19:56','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0, XPosition=3, SeqNo=40 WHERE AD_Field_ID=200844
;
-- Nov 20, 2012 12:21:33 PM COT
UPDATE AD_Field SET IsReadOnly='Y',Updated=TO_TIMESTAMP('2012-11-20 12:21:33','YYYY-MM-DD HH24:MI:SS'),SeqNo=50, UpdatedBy=0 WHERE AD_Field_ID=200846
;
-- Nov 20, 2012 12:22:02 PM COT
UPDATE AD_Field SET IsReadOnly='Y',Updated=TO_TIMESTAMP('2012-11-20 12:22:02','YYYY-MM-DD HH24:MI:SS'),SeqNo=60, XPosition=3, UpdatedBy=0 WHERE AD_Field_ID=200840
;
-- Nov 20, 2012 12:22:48 PM COT
UPDATE AD_Field SET IsReadOnly='Y',Updated=TO_TIMESTAMP('2012-11-20 12:22:48','YYYY-MM-DD HH24:MI:SS'),SeqNo=80, XPosition=4, UpdatedBy=0 WHERE AD_Field_ID=200839
;
-- Nov 20, 2012 2:52:50 PM COT
UPDATE AD_Field SET SeqNo=90,NumLines=2, ColumnSpan=3, XPosition=3,Updated=TO_TIMESTAMP('2012-11-20 14:52:50','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Field_ID=200843
;
-- Nov 20, 2012 2:55:17 PM COT
UPDATE AD_Field SET SeqNo=20, XPosition=3,Updated=TO_TIMESTAMP('2012-11-20 14:55:17','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Field_ID=200845
;
-- Nov 20, 2012 2:55:17 PM COT
UPDATE AD_Field SET SeqNo=70,Updated=TO_TIMESTAMP('2012-11-20 14:55:17','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Field_ID=200841
;
-- Nov 20, 2012 2:55:17 PM COT
UPDATE AD_Field SET SeqNo=30,Updated=TO_TIMESTAMP('2012-11-20 14:55:17','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Field_ID=200847
;
-- Nov 20, 2012 3:04:03 PM COT
INSERT INTO AD_TreeBar (AD_Tree_ID,AD_User_ID,Node_ID, AD_Client_ID,AD_Org_ID, IsActive,Created,CreatedBy,Updated,UpdatedBy)VALUES (10,0,495,0,0,'Y',CURRENT_TIMESTAMP,0,CURRENT_TIMESTAMP,0)
;
-- Nov 27, 2012 10:58:07 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Tab SET IsSingleRow='Y', IsInsertRecord='N',Updated=TO_TIMESTAMP('2012-11-27 22:58:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=200031
;
-- Nov 27, 2012 11:01:07 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET ColumnSpan=2, SeqNo=10, IsDisplayed='Y', XPosition=1,Updated=TO_TIMESTAMP('2012-11-27 23:01:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=200841
;
-- Nov 27, 2012 11:01:07 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET ColumnSpan=2, SeqNo=20, IsDisplayed='Y', XPosition=4,Updated=TO_TIMESTAMP('2012-11-27 23:01:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=200844
;
-- Nov 27, 2012 11:01:07 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET ColumnSpan=2, SeqNo=30,Updated=TO_TIMESTAMP('2012-11-27 23:01:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=200842
;
-- Nov 27, 2012 11:01:07 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET SeqNo=40, IsDisplayed='Y', XPosition=5,Updated=TO_TIMESTAMP('2012-11-27 23:01:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=200839
;
-- Nov 27, 2012 11:01:07 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET ColumnSpan=2, SeqNo=50, IsDisplayed='Y', XPosition=1,Updated=TO_TIMESTAMP('2012-11-27 23:01:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=200847
;
-- Nov 27, 2012 11:01:07 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET ColumnSpan=2, SeqNo=60, IsDisplayed='Y', XPosition=4,Updated=TO_TIMESTAMP('2012-11-27 23:01:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=200845
;
-- Nov 27, 2012 11:01:07 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET ColumnSpan=5, NumLines=5, SeqNo=70, IsDisplayed='Y', XPosition=1,Updated=TO_TIMESTAMP('2012-11-27 23:01:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=200843
;
-- Nov 27, 2012 11:01:07 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET SeqNo=0, IsDisplayed='N', XPosition=1,Updated=TO_TIMESTAMP('2012-11-27 23:01:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=200840
;
-- Nov 27, 2012 11:01:07 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET ColumnSpan=2, SeqNo=0, IsDisplayed='N', XPosition=1,Updated=TO_TIMESTAMP('2012-11-27 23:01:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=200846
;
-- Nov 27, 2012 11:02:42 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Column SET AD_Reference_Value_ID=286, AD_Reference_ID=30,Updated=TO_TIMESTAMP('2012-11-27 23:02:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=200913
;
-- Nov 27, 2012 11:04:10 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=200840
;
-- Nov 27, 2012 11:04:10 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=200841
;
-- Nov 27, 2012 11:04:10 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=200844
;
-- Nov 27, 2012 11:04:10 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=200846
;
-- Nov 27, 2012 11:04:10 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET SeqNoGrid=10,IsDisplayedGrid='Y' WHERE AD_Field_ID=200842
;
-- Nov 27, 2012 11:04:10 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET SeqNoGrid=20,IsDisplayedGrid='Y' WHERE AD_Field_ID=200847
;
-- Nov 27, 2012 11:04:10 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET SeqNoGrid=30,IsDisplayedGrid='Y' WHERE AD_Field_ID=200845
;
-- Nov 27, 2012 11:04:10 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET SeqNoGrid=40,IsDisplayedGrid='Y' WHERE AD_Field_ID=200843
;
-- Nov 27, 2012 11:04:10 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_Field SET SeqNoGrid=50,IsDisplayedGrid='Y' WHERE AD_Field_ID=200839
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=0, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=218
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=1, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=153
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=2, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=263
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=3, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=166
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=4, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=203
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=5, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53242
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=6, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=236
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=7, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=183
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=8, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=160
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=9, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=278
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=10, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=345
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=11, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53296
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=12, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=519
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=13, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53014
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=14, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53108
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=15, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=518
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=16, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=200024
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=0, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=261
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=1, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53202
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=2, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=225
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=3, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=200009
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=4, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=200026
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=5, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=148
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=6, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=529
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=7, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=397
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=8, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=532
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=9, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53084
;
-- Nov 27, 2012 11:08:18 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=156, SeqNo=10, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53083
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=0, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=218
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=1, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=153
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=2, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=263
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=3, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=166
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=4, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=203
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=5, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53242
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=6, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=236
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=7, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=183
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=8, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=160
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=9, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=278
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=10, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=345
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=11, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53296
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=12, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=519
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=13, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53014
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=14, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53108
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=0, SeqNo=15, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=518
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=0, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=241
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=1, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=288
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=2, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=432
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=3, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=243
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=4, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=413
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=5, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=538
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=6, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=462
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=7, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=505
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=8, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=200023
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=9, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=235
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=10, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=511
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=11, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=245
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=12, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=251
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=13, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=246
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=14, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=509
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=15, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=510
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=16, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=496
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=17, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=497
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=18, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=304
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=19, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=255
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=20, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=286
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=21, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=287
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=22, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=438
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=23, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=234
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=24, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=244
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=25, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53313
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=26, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53314
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=27, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53190
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=28, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=53187
;
-- Nov 27, 2012 11:08:49 PM COT
-- IDEMPIERE-393 Setup wizards
UPDATE AD_TreeNodeMM SET Parent_ID=236, SeqNo=29, Updated=CURRENT_TIMESTAMP WHERE AD_Tree_ID=10 AND Node_ID=200024
;
-- Nov 28, 2012 1:11:04 AM COT
-- IDEMPIERE-393 Setup wizards
INSERT INTO AD_Message (MsgType,MsgText,AD_Message_ID,EntityType,AD_Message_UU,Value,IsActive,Updated,CreatedBy,UpdatedBy,AD_Client_ID,AD_Org_ID,Created) VALUES ('I','Just Mine',200117,'D','0c220c5c-719f-4b8f-82d6-a21b0c123e66','JustMine','Y',TO_DATE('2012-11-28 01:11:03','YYYY-MM-DD HH24:MI:SS'),100,100,0,0,TO_DATE('2012-11-28 01:11:03','YYYY-MM-DD HH24:MI:SS'))
;
-- Nov 28, 2012 1:11:04 AM COT
-- IDEMPIERE-393 Setup wizards
INSERT INTO AD_Message_Trl (AD_Language,AD_Message_ID, MsgText,MsgTip, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Message_Trl_UU ) SELECT l.AD_Language,t.AD_Message_ID, t.MsgText,t.MsgTip, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Message t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Message_ID=200117 AND NOT EXISTS (SELECT * FROM AD_Message_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Message_ID=t.AD_Message_ID)
;
-- Nov 28, 2012 1:11:20 AM COT
-- IDEMPIERE-393 Setup wizards
INSERT INTO AD_Message (MsgType,MsgText,AD_Message_ID,EntityType,AD_Message_UU,Value,IsActive,Updated,CreatedBy,UpdatedBy,AD_Client_ID,AD_Org_ID,Created) VALUES ('I','Show Colors',200118,'D','4f917ca8-a515-4038-add0-a3bd5d4b2907','ShowColors','Y',TO_DATE('2012-11-28 01:11:20','YYYY-MM-DD HH24:MI:SS'),100,100,0,0,TO_DATE('2012-11-28 01:11:20','YYYY-MM-DD HH24:MI:SS'))
;
-- Nov 28, 2012 1:11:20 AM COT
-- IDEMPIERE-393 Setup wizards
INSERT INTO AD_Message_Trl (AD_Language,AD_Message_ID, MsgText,MsgTip, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Message_Trl_UU ) SELECT l.AD_Language,t.AD_Message_ID, t.MsgText,t.MsgTip, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Message t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Message_ID=200118 AND NOT EXISTS (SELECT * FROM AD_Message_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Message_ID=t.AD_Message_ID)
;
SELECT register_migration_script('201211201820_SetupWizard.sql') FROM dual
;

File diff suppressed because it is too large Load Diff

View File

@ -158,7 +158,7 @@ public class M_Production_Run extends SvrProcess {
if (!MStorageOnHand.add(getCtx(), locator.getM_Warehouse_ID(), if (!MStorageOnHand.add(getCtx(), locator.getM_Warehouse_ID(),
locator.getM_Locator_ID(), locator.getM_Locator_ID(),
pline.getM_Product_ID(), pline.getM_Product_ID(),
pline.getM_AttributeSetInstance_ID(), 0 , pline.getM_AttributeSetInstance_ID(),
MovementQty, MovementQty,
get_TrxName())) get_TrxName()))
{ {

View File

@ -290,6 +290,6 @@ Import-Package: com.sun.mail.auth;version="1.4.5",
Eclipse-BuddyPolicy: registered Eclipse-BuddyPolicy: registered
Eclipse-ExtensibleAPI: true Eclipse-ExtensibleAPI: true
Bundle-Activator: org.adempiere.base.BaseActivator Bundle-Activator: org.adempiere.base.BaseActivator
Service-Component: OSGI-INF/eventmanager.xml, OSGI-INF/dslocator.xml, OSGI-INF/extensionlocator.xml, OSGI-INF/serverbean.xml, OSGI-INF/statusbean.xml, OSGI-INF/defaultmodelfactory.xml, OSGI-INF/defaultdocfactory.xml Service-Component: OSGI-INF/eventmanager.xml, OSGI-INF/dslocator.xml, OSGI-INF/extensionlocator.xml, OSGI-INF/serverbean.xml, OSGI-INF/statusbean.xml, OSGI-INF/defaultmodelfactory.xml, OSGI-INF/defaultdocfactory.xml, OSGI-INF/AttachmentFile.xml, OSGI-INF/AttachmentDB.xml
Bundle-ActivationPolicy: lazy Bundle-ActivationPolicy: lazy
Require-Bundle: org.eclipse.equinox.app;bundle-version="1.3.1" Require-Bundle: org.eclipse.equinox.app;bundle-version="1.3.1"

View File

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<scr:component xmlns:scr="http://www.osgi.org/xmlns/scr/v1.1.0" name="org.adempiere.base.AttachmentDB">
<implementation class="org.compiere.model.AttachmentDBSystem"/>
<service>
<provide interface="org.compiere.model.IAttachmentStore"/>
</service>
<property name="method" type="String" value="DB"/>
</scr:component>

View File

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<scr:component xmlns:scr="http://www.osgi.org/xmlns/scr/v1.1.0" name="org.adempiere.base.AttachmentFile">
<implementation class="org.compiere.model.AttachmentFileSystem"/>
<service>
<provide interface="org.compiere.model.IAttachmentStore"/>
</service>
<property name="method" type="String" value="FileSystem"/>
</scr:component>

View File

@ -0,0 +1,135 @@
/******************************************************************************
* Product: iDempiere ERP & CRM Smart Business Solution *
* Copyright (C) 2012 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.model;
import java.io.ByteArrayInputStream;
import java.io.ByteArrayOutputStream;
import java.util.ArrayList;
import java.util.logging.Level;
import java.util.zip.Deflater;
import java.util.zip.ZipEntry;
import java.util.zip.ZipInputStream;
import java.util.zip.ZipOutputStream;
import org.compiere.util.CLogger;
public class AttachmentDBSystem implements IAttachmentStore
{
/** Indicator for zip data */
public static final String ZIP = "zip";
private final CLogger log = CLogger.getCLogger(getClass());
@Override
public boolean loadLOBData(MAttachment attach, MStorageProvider prov) {
// Reset
attach.m_items = new ArrayList<MAttachmentEntry>();
//
byte[] data = attach.getBinaryData();
if (data == null)
return true;
log.fine("ZipSize=" + data.length);
if (data.length == 0)
return true;
// Old Format - single file
if (!ZIP.equals(attach.getTitle()))
{
attach.m_items.add (new MAttachmentEntry(attach.getTitle(), data, 1));
return true;
}
try
{
ByteArrayInputStream in = new ByteArrayInputStream(data);
ZipInputStream zip = new ZipInputStream (in);
ZipEntry entry = zip.getNextEntry();
while (entry != null)
{
String name = entry.getName();
ByteArrayOutputStream out = new ByteArrayOutputStream();
byte[] buffer = new byte[2048];
int length = zip.read(buffer);
while (length != -1)
{
out.write(buffer, 0, length);
length = zip.read(buffer);
}
//
byte[] dataEntry = out.toByteArray();
log.fine(name
+ " - size=" + dataEntry.length + " - zip="
+ entry.getCompressedSize() + "(" + entry.getSize() + ") "
+ (entry.getCompressedSize()*100/entry.getSize())+ "%");
//
attach.m_items.add (new MAttachmentEntry (name, dataEntry, attach.m_items.size()+1));
entry = zip.getNextEntry();
}
}
catch (Exception e)
{
log.log(Level.SEVERE, "loadLOBData", e);
attach.m_items = null;
return false;
}
return true;
}
@Override
public boolean save(MAttachment attach, MStorageProvider prov) {
if (attach.m_items == null || attach.m_items.size() == 0)
{
attach.setBinaryData(null);
return true;
}
ByteArrayOutputStream out = new ByteArrayOutputStream();
ZipOutputStream zip = new ZipOutputStream(out);
zip.setMethod(ZipOutputStream.DEFLATED);
zip.setLevel(Deflater.BEST_COMPRESSION);
zip.setComment("adempiere");
//
try
{
for (int i = 0; i < attach.m_items.size(); i++)
{
MAttachmentEntry item = attach.getEntry(i);
ZipEntry entry = new ZipEntry(item.getName());
entry.setTime(System.currentTimeMillis());
entry.setMethod(ZipEntry.DEFLATED);
zip.putNextEntry(entry);
byte[] data = item.getData();
zip.write (data, 0, data.length);
zip.closeEntry();
log.fine(entry.getName() + " - "
+ entry.getCompressedSize() + " (" + entry.getSize() + ") "
+ (entry.getCompressedSize()*100/entry.getSize())+ "%");
}
// zip.finish();
zip.close();
byte[] zipData = out.toByteArray();
log.fine("Length=" + zipData.length);
attach.setBinaryData(zipData);
return true;
}
catch (Exception e)
{
log.log(Level.SEVERE, "saveLOBData", e);
}
attach.setBinaryData(null);
return false;
}
}

View File

@ -0,0 +1,250 @@
/******************************************************************************
* Product: iDempiere ERP & CRM Smart Business Solution *
* Copyright (C) 2012 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.model;
import java.io.ByteArrayInputStream;
import java.io.ByteArrayOutputStream;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.FileNotFoundException;
import java.nio.channels.FileChannel;
import java.util.ArrayList;
import java.util.logging.Level;
import javax.xml.parsers.DocumentBuilder;
import javax.xml.parsers.DocumentBuilderFactory;
import javax.xml.transform.Result;
import javax.xml.transform.Source;
import javax.xml.transform.Transformer;
import javax.xml.transform.TransformerFactory;
import javax.xml.transform.dom.DOMSource;
import javax.xml.transform.stream.StreamResult;
import javax.xml.parsers.ParserConfigurationException;
import org.compiere.util.CLogger;
import org.w3c.dom.Document;
import org.w3c.dom.Element;
import org.w3c.dom.Node;
import org.w3c.dom.NodeList;
import org.w3c.dom.NamedNodeMap;
import org.xml.sax.SAXException;
/**
* @author juliana
*
*/
public class AttachmentFileSystem implements IAttachmentStore {
private final CLogger log = CLogger.getCLogger(getClass());
public String m_attachmentPathRoot;
@Override
public boolean save(MAttachment attach,MStorageProvider prov) {
/*if(File.separatorChar == '\\'){
m_attachmentPathRoot = prov.getWi;
} else {
m_attachmentPathRoot = prov.getUnixAttachmentPath();
}*/
m_attachmentPathRoot=prov.getFolder();
if("".equals(m_attachmentPathRoot)){
log.severe("no attachmentPath defined");
} else if (!m_attachmentPathRoot.endsWith(File.separator)){
m_attachmentPathRoot = m_attachmentPathRoot + File.separator;
log.fine(m_attachmentPathRoot);
}
if (attach.m_items == null || attach.m_items.size() == 0) {
attach.setBinaryData(null);
return true;
}
final DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
try {
final DocumentBuilder builder = factory.newDocumentBuilder();
final Document document = builder.newDocument();
final Element root = document.createElement("attachments");
document.appendChild(root);
document.setXmlStandalone(true);
// create xml entries
for (int i = 0; i < attach.m_items.size(); i++) {
log.fine(attach.m_items.get(i).toString());
File entryFile = attach.m_items.get(i).getFile();
final String path = entryFile.getAbsolutePath();
// if local file - copy to central attachment folder
log.fine(path + " - " + attach.m_attachmentPathRoot);
if (!path.startsWith(attach.m_attachmentPathRoot)) {
log.fine("move file: " + path);
FileChannel in = null;
FileChannel out = null;
try {
//create destination folder
StringBuilder msgfile = new StringBuilder().append(attach.m_attachmentPathRoot).append(File.separator).append(attach.getAttachmentPathSnippet());
final File destFolder = new File(msgfile.toString());
if(!destFolder.exists()){
if(!destFolder.mkdirs()){
log.warning("unable to create folder: " + destFolder.getPath());
}
}
msgfile = new StringBuilder().append(attach.m_attachmentPathRoot).append(File.separator)
.append(attach.getAttachmentPathSnippet()).append(File.separator).append(entryFile.getName());
final File destFile = new File(msgfile.toString());
in = new FileInputStream(entryFile).getChannel();
out = new FileOutputStream(destFile).getChannel();
in.transferTo(0, in.size(), out);
in.close();
out.close();
if(entryFile.exists()){
if(!entryFile.delete()){
entryFile.deleteOnExit();
}
}
entryFile = destFile;
} catch (IOException e) {
e.printStackTrace();
log.severe("unable to copy file " + entryFile.getAbsolutePath() + " to "
+ attach.m_attachmentPathRoot + File.separator +
attach.getAttachmentPathSnippet() + File.separator + entryFile.getName());
} finally {
if (in != null && in.isOpen()) {
in.close();
}
if (out != null && out.isOpen()) {
out.close();
}
}
}
final Element entry = document.createElement("entry");
//entry.setAttribute("name", m_items.get(i).getName());
entry.setAttribute("name", attach.getEntryName(i));
String filePathToStore = entryFile.getAbsolutePath();
filePathToStore = filePathToStore.replaceFirst(attach.m_attachmentPathRoot.replaceAll("\\\\","\\\\\\\\"), attach.ATTACHMENT_FOLDER_PLACEHOLDER);
log.fine(filePathToStore);
entry.setAttribute("file", filePathToStore);
root.appendChild(entry);
}
final Source source = new DOMSource(document);
final ByteArrayOutputStream bos = new ByteArrayOutputStream();
final Result result = new StreamResult(bos);
final Transformer xformer = TransformerFactory.newInstance().newTransformer();
xformer.transform(source, result);
final byte[] xmlData = bos.toByteArray();
log.fine(bos.toString());
attach.setBinaryData(xmlData);
return true;
} catch (Exception e) {
log.log(Level.SEVERE, "saveLOBData", e);
}
attach.setBinaryData(null);
return false;
}
@Override
public boolean loadLOBData(MAttachment attach,MStorageProvider prov) {
if("".equals(attach.m_attachmentPathRoot)){
log.severe("no attachmentPath defined");
return false;
}
// Reset
attach.m_items = new ArrayList<MAttachmentEntry>();
//
byte[] data = attach.getBinaryData();
if (data == null)
return true;
log.fine("TextFileSize=" + data.length);
if (data.length == 0)
return true;
DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
try {
final DocumentBuilder builder = factory.newDocumentBuilder();
final Document document = builder.parse(new ByteArrayInputStream(data));
final NodeList entries = document.getElementsByTagName("entry");
for (int i = 0; i < entries.getLength(); i++) {
final Node entryNode = entries.item(i);
final NamedNodeMap attributes = entryNode.getAttributes();
final Node fileNode = attributes.getNamedItem("file");
final Node nameNode = attributes.getNamedItem("name");
if(fileNode==null || nameNode==null){
log.severe("no filename for entry " + i);
attach.m_items = null;
return false;
}
log.fine("name: " + nameNode.getNodeValue());
String filePath = fileNode.getNodeValue();
log.fine("filePath: " + filePath);
if(filePath!=null){
filePath = filePath.replaceFirst(attach.ATTACHMENT_FOLDER_PLACEHOLDER, attach.m_attachmentPathRoot.replaceAll("\\\\","\\\\\\\\"));
//just to be shure...
String replaceSeparator = File.separator;
if(!replaceSeparator.equals("/")){
replaceSeparator = "\\\\";
}
filePath = filePath.replaceAll("/", replaceSeparator);
filePath = filePath.replaceAll("\\\\", replaceSeparator);
}
log.fine("filePath: " + filePath);
final File file = new File(filePath);
if (file.exists()) {
// read files into byte[]
final byte[] dataEntry = new byte[(int) file.length()];
try {
final FileInputStream fileInputStream = new FileInputStream(file);
fileInputStream.read(dataEntry);
fileInputStream.close();
} catch (FileNotFoundException e) {
log.severe("File Not Found.");
e.printStackTrace();
} catch (IOException e1) {
log.severe("Error Reading The File.");
e1.printStackTrace();
}
final MAttachmentEntry entry = new MAttachmentEntry(filePath,
dataEntry, attach.m_items.size() + 1);
attach.m_items.add(entry);
} else {
log.severe("file not found: " + file.getAbsolutePath());
}
}
} catch (SAXException sxe) {
// Error generated during parsing)
Exception x = sxe;
if (sxe.getException() != null)
x = sxe.getException();
x.printStackTrace();
log.severe(x.getMessage());
} catch (ParserConfigurationException pce) {
// Parser with specified options can't be built
pce.printStackTrace();
log.severe(pce.getMessage());
} catch (IOException ioe) {
// I/O error
ioe.printStackTrace();
log.severe(ioe.getMessage());
}
return true;
}
}

View File

@ -0,0 +1,26 @@
/******************************************************************************
* 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;
public interface IAttachmentStore {
public boolean loadLOBData(MAttachment attach,MStorageProvider prov);
boolean save(MAttachment attach, MStorageProvider prov);
}

View File

@ -408,15 +408,6 @@ public interface I_AD_Client
/** Get Store Archive On File System */ /** Get Store Archive On File System */
public boolean isStoreArchiveOnFileSystem(); public boolean isStoreArchiveOnFileSystem();
/** Column name StoreAttachmentsOnFileSystem */
public static final String COLUMNNAME_StoreAttachmentsOnFileSystem = "StoreAttachmentsOnFileSystem";
/** Set Store Attachments On File System */
public void setStoreAttachmentsOnFileSystem (boolean StoreAttachmentsOnFileSystem);
/** Get Store Attachments On File System */
public boolean isStoreAttachmentsOnFileSystem();
/** Column name UnixArchivePath */ /** Column name UnixArchivePath */
public static final String COLUMNNAME_UnixArchivePath = "UnixArchivePath"; public static final String COLUMNNAME_UnixArchivePath = "UnixArchivePath";
@ -426,15 +417,6 @@ public interface I_AD_Client
/** Get Unix Archive Path */ /** Get Unix Archive Path */
public String getUnixArchivePath(); public String getUnixArchivePath();
/** Column name UnixAttachmentPath */
public static final String COLUMNNAME_UnixAttachmentPath = "UnixAttachmentPath";
/** Set Unix Attachment Path */
public void setUnixAttachmentPath (String UnixAttachmentPath);
/** Get Unix Attachment Path */
public String getUnixAttachmentPath();
/** Column name Updated */ /** Column name Updated */
public static final String COLUMNNAME_Updated = "Updated"; public static final String COLUMNNAME_Updated = "Updated";
@ -472,13 +454,4 @@ public interface I_AD_Client
/** Get Windows Archive Path */ /** Get Windows Archive Path */
public String getWindowsArchivePath(); public String getWindowsArchivePath();
/** Column name WindowsAttachmentPath */
public static final String COLUMNNAME_WindowsAttachmentPath = "WindowsAttachmentPath";
/** Set Windows Attachment Path */
public void setWindowsAttachmentPath (String WindowsAttachmentPath);
/** Get Windows Attachment Path */
public String getWindowsAttachmentPath();
} }

View File

@ -71,6 +71,17 @@ public interface I_AD_ClientInfo
*/ */
public int getAD_Org_ID(); public int getAD_Org_ID();
/** Column name AD_StorageProvider_ID */
public static final String COLUMNNAME_AD_StorageProvider_ID = "AD_StorageProvider_ID";
/** Set AD_StorageProvider_ID */
public void setAD_StorageProvider_ID (int AD_StorageProvider_ID);
/** Get AD_StorageProvider_ID */
public int getAD_StorageProvider_ID();
public org.compiere.model.I_AD_StorageProvider getAD_StorageProvider() throws RuntimeException;
/** Column name AD_Tree_Activity_ID */ /** Column name AD_Tree_Activity_ID */
public static final String COLUMNNAME_AD_Tree_Activity_ID = "AD_Tree_Activity_ID"; public static final String COLUMNNAME_AD_Tree_Activity_ID = "AD_Tree_Activity_ID";

View File

@ -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 AD_StorageProvider
* @author iDempiere (generated)
* @version Release 1.0a
*/
public interface I_AD_StorageProvider
{
/** TableName=AD_StorageProvider */
public static final String Table_Name = "AD_StorageProvider";
/** AD_Table_ID=200037 */
public static final int Table_ID = 200037;
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 AD_StorageProvider_ID */
public static final String COLUMNNAME_AD_StorageProvider_ID = "AD_StorageProvider_ID";
/** Set AD_StorageProvider_ID */
public void setAD_StorageProvider_ID (int AD_StorageProvider_ID);
/** Get AD_StorageProvider_ID */
public int getAD_StorageProvider_ID();
/** Column name AD_StorageProvider_UU */
public static final String COLUMNNAME_AD_StorageProvider_UU = "AD_StorageProvider_UU";
/** Set AD_StorageProvider_UU */
public void setAD_StorageProvider_UU (String AD_StorageProvider_UU);
/** Get AD_StorageProvider_UU */
public String getAD_StorageProvider_UU();
/** 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 Folder */
public static final String COLUMNNAME_Folder = "Folder";
/** Set Folder.
* A folder on a local or remote system to store data into
*/
public void setFolder (String Folder);
/** Get Folder.
* A folder on a local or remote system to store data into
*/
public String getFolder();
/** 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 Method */
public static final String COLUMNNAME_Method = "Method";
/** Set Method */
public void setMethod (String Method);
/** Get Method */
public String getMethod();
/** Column name Name */
public static final String COLUMNNAME_Name = "Name";
/** Set Name.
* Alphanumeric identifier of the entity
*/
public void setName (String Name);
/** Get Name.
* Alphanumeric identifier of the entity
*/
public String getName();
/** Column name Password */
public static final String COLUMNNAME_Password = "Password";
/** Set Password.
* Password of any length (case sensitive)
*/
public void setPassword (String Password);
/** Get Password.
* Password of any length (case sensitive)
*/
public String getPassword();
/** 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 URL */
public static final String COLUMNNAME_URL = "URL";
/** Set URL.
* Full URL address - e.g. http://www.idempiere.org
*/
public void setURL (String URL);
/** Get URL.
* Full URL address - e.g. http://www.idempiere.org
*/
public String getURL();
/** Column name UserName */
public static final String COLUMNNAME_UserName = "UserName";
/** Set Registered EMail.
* Email of the responsible for the System
*/
public void setUserName (String UserName);
/** Get Registered EMail.
* Email of the responsible for the System
*/
public String getUserName();
}

View File

@ -62,6 +62,21 @@ public interface I_AD_WizardProcess
*/ */
public int getAD_Org_ID(); public int getAD_Org_ID();
/** Column name AD_User_ID */
public static final String COLUMNNAME_AD_User_ID = "AD_User_ID";
/** Set User/Contact.
* User within the system - Internal or Business Partner Contact
*/
public void setAD_User_ID (int AD_User_ID);
/** Get User/Contact.
* User within the system - Internal or Business Partner Contact
*/
public int getAD_User_ID();
public org.compiere.model.I_AD_User getAD_User() throws RuntimeException;
/** Column name AD_WF_Node_ID */ /** Column name AD_WF_Node_ID */
public static final String COLUMNNAME_AD_WF_Node_ID = "AD_WF_Node_ID"; public static final String COLUMNNAME_AD_WF_Node_ID = "AD_WF_Node_ID";

View File

@ -26,6 +26,7 @@ import java.io.IOException;
import java.nio.channels.FileChannel; import java.nio.channels.FileChannel;
import java.sql.ResultSet; import java.sql.ResultSet;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List;
import java.util.Properties; import java.util.Properties;
import java.util.logging.Level; import java.util.logging.Level;
import java.util.zip.Deflater; import java.util.zip.Deflater;
@ -43,6 +44,8 @@ import javax.xml.transform.TransformerFactory;
import javax.xml.transform.dom.DOMSource; import javax.xml.transform.dom.DOMSource;
import javax.xml.transform.stream.StreamResult; import javax.xml.transform.stream.StreamResult;
import org.adempiere.base.Service;
import org.adempiere.base.ServiceQuery;
import org.compiere.util.CLogger; import org.compiere.util.CLogger;
import org.compiere.util.Env; import org.compiere.util.Env;
import org.compiere.util.MimeType; import org.compiere.util.MimeType;
@ -71,8 +74,7 @@ public class MAttachment extends X_AD_Attachment
/** /**
* *
*/ */
private static final long serialVersionUID = -1948066627503677516L; private static final long serialVersionUID = 1415801644995116959L;
/** /**
* Get Attachment (if there are more than one attachment it gets the first in no specific order) * Get Attachment (if there are more than one attachment it gets the first in no specific order)
@ -93,6 +95,8 @@ public class MAttachment extends X_AD_Attachment
/** Static Logger */ /** Static Logger */
private static CLogger s_log = CLogger.getCLogger (MAttachment.class); private static CLogger s_log = CLogger.getCLogger (MAttachment.class);
public MStorageProvider provider;
/************************************************************************** /**************************************************************************
* Standard Constructor * Standard Constructor
@ -145,25 +149,38 @@ public class MAttachment extends X_AD_Attachment
public static final String XML = "xml"; public static final String XML = "xml";
/** List of Entry Data */ /** List of Entry Data */
private ArrayList<MAttachmentEntry> m_items = null; public ArrayList<MAttachmentEntry> m_items = null;
/** is this client using the file system for attachments */ /** is this client using the file system for attachments */
private boolean isStoreAttachmentsOnFileSystem = false; private boolean isStoreAttachmentsOnFileSystem = false;
/** attachment (root) path - if file system is used */ /** attachment (root) path - if file system is used */
private String m_attachmentPathRoot = ""; public String m_attachmentPathRoot = "";
/** string replaces the attachment root in stored xml file /** string replaces the attachment root in stored xml file
* to allow the changing of the attachment root. */ * to allow the changing of the attachment root. */
private final String ATTACHMENT_FOLDER_PLACEHOLDER = "%ATTACHMENT_FOLDER%"; public final String ATTACHMENT_FOLDER_PLACEHOLDER = "%ATTACHMENT_FOLDER%";
/** /**
* Get the isStoreAttachmentsOnFileSystem and attachmentPath for the client. * Get the isStoreAttachmentsOnFileSystem and attachmentPath for the client.
* @param ctx * @param ctx
* @param trxName * @param trxName
*/ */
private void initAttachmentStoreDetails(Properties ctx, String trxName){ private void initAttachmentStoreDetails(Properties ctx, String trxName)
final MClient client = new MClient(ctx, this.getAD_Client_ID(), trxName); {
MClientInfo clientInfo = MClientInfo.get(ctx);
provider=new MStorageProvider(ctx, clientInfo.getAD_StorageProvider_ID(), trxName);
m_attachmentPathRoot=provider.getFolder();
if(m_attachmentPathRoot == null){
log.severe("no attachmentPath defined");
}
/* final MClient client = new MClient(ctx, this.getAD_Client_ID(), trxName);
isStoreAttachmentsOnFileSystem = client.isStoreAttachmentsOnFileSystem(); isStoreAttachmentsOnFileSystem = client.isStoreAttachmentsOnFileSystem();
if(isStoreAttachmentsOnFileSystem){ if(isStoreAttachmentsOnFileSystem){
if(File.separatorChar == '\\'){ if(File.separatorChar == '\\'){
@ -178,7 +195,7 @@ public class MAttachment extends X_AD_Attachment
m_attachmentPathRoot = m_attachmentPathRoot + File.separator; m_attachmentPathRoot = m_attachmentPathRoot + File.separator;
log.fine(m_attachmentPathRoot); log.fine(m_attachmentPathRoot);
} }
} }*/
} }
/** /**
@ -244,6 +261,7 @@ public class MAttachment extends X_AD_Attachment
*/ */
public boolean addEntry (File file) public boolean addEntry (File file)
{ {
if (file == null) if (file == null)
{ {
log.warning("No File"); log.warning("No File");
@ -411,11 +429,14 @@ public class MAttachment extends X_AD_Attachment
* @return name or null * @return name or null
*/ */
public String getEntryName(int index) { public String getEntryName(int index) {
String method=provider.getMethod();
if(method == null)
method="DB";
MAttachmentEntry item = getEntry(index); MAttachmentEntry item = getEntry(index);
if (item != null){ if (item != null){
//strip path //strip path
String name = item.getName(); String name = item.getName();
if(name!=null && isStoreAttachmentsOnFileSystem){ if(name!=null && "FileSystem".equals(method)){
name = name.substring(name.lastIndexOf(File.separator)+1); name = name.substring(name.lastIndexOf(File.separator)+1);
} }
return name; return name;
@ -491,10 +512,24 @@ public class MAttachment extends X_AD_Attachment
*/ */
private boolean saveLOBData() private boolean saveLOBData()
{ {
if(isStoreAttachmentsOnFileSystem){ ServiceQuery query=new ServiceQuery();
String method=provider.getMethod();
if(method == null)
method="DB";
query.put("method", method);
List<IAttachmentStore> storelist = Service.locator().list(IAttachmentStore.class, query).getServices();
if(storelist != null){
for(IAttachmentStore prov:storelist){
return prov.save(this,provider);
}
}
return false;
/*if(isStoreAttachmentsOnFileSystem){
return saveLOBDataToFileSystem(); return saveLOBDataToFileSystem();
} }
return saveLOBDataToDB(); return saveLOBDataToDB();*/
} }
/** /**
@ -648,10 +683,25 @@ public class MAttachment extends X_AD_Attachment
*/ */
private boolean loadLOBData () private boolean loadLOBData ()
{ {
if(isStoreAttachmentsOnFileSystem){
ServiceQuery query=new ServiceQuery();
String method=provider.getMethod();
if(method == null)
method="DB";
query.put("method", method);
List<IAttachmentStore> storelist = Service.locator().list(IAttachmentStore.class, query).getServices();
if(storelist != null){
for(IAttachmentStore prov:storelist){
return prov.loadLOBData(this,provider);
}
}
return false;
/*if(isStoreAttachmentsOnFileSystem){
return loadLOBDataFromFileSystem(); return loadLOBDataFromFileSystem();
} }
return loadLOBDataFromDB(); return loadLOBDataFromDB();*/
} }
/** /**
@ -717,7 +767,7 @@ public class MAttachment extends X_AD_Attachment
* Load Data from file system * Load Data from file system
* @return true if success * @return true if success
*/ */
private boolean loadLOBDataFromFileSystem(){ public boolean loadLOBDataFromFileSystem(){
if("".equals(m_attachmentPathRoot)){ if("".equals(m_attachmentPathRoot)){
log.severe("no attachmentPath defined"); log.severe("no attachmentPath defined");
return false; return false;
@ -812,7 +862,7 @@ public class MAttachment extends X_AD_Attachment
* Returns a path snippet, containing client, org, table and record id. * Returns a path snippet, containing client, org, table and record id.
* @return String * @return String
*/ */
private String getAttachmentPathSnippet(){ public String getAttachmentPathSnippet(){
StringBuilder msgreturn = new StringBuilder().append(this.getAD_Client_ID()).append(File.separator) StringBuilder msgreturn = new StringBuilder().append(this.getAD_Client_ID()).append(File.separator)
.append(this.getAD_Org_ID()).append(File.separator) .append(this.getAD_Org_ID()).append(File.separator)

View File

@ -1356,7 +1356,7 @@ public class MInOut extends X_M_InOut implements DocAction
if (!MStorageOnHand.add(getCtx(), getM_Warehouse_ID(), if (!MStorageOnHand.add(getCtx(), getM_Warehouse_ID(),
sLine.getM_Locator_ID(), sLine.getM_Locator_ID(),
sLine.getM_Product_ID(), sLine.getM_Product_ID(),
ma.getM_AttributeSetInstance_ID(), reservationAttributeSetInstance_ID, ma.getM_AttributeSetInstance_ID(),
QtyMA, QtyMA,
get_TrxName())) get_TrxName()))
{ {
@ -1438,7 +1438,7 @@ public class MInOut extends X_M_InOut implements DocAction
if (!MStorageOnHand.add(getCtx(), getM_Warehouse_ID(), if (!MStorageOnHand.add(getCtx(), getM_Warehouse_ID(),
sLine.getM_Locator_ID(), sLine.getM_Locator_ID(),
sLine.getM_Product_ID(), sLine.getM_Product_ID(),
sLine.getM_AttributeSetInstance_ID(), reservationAttributeSetInstance_ID, sLine.getM_AttributeSetInstance_ID(),
Qty, get_TrxName())) Qty, get_TrxName()))
{ {
String lastError = CLogger.retrieveErrorString(""); String lastError = CLogger.retrieveErrorString("");

View File

@ -440,7 +440,7 @@ public class MInventory extends X_M_Inventory implements DocAction
if (!MStorageOnHand.add(getCtx(), getM_Warehouse_ID(), if (!MStorageOnHand.add(getCtx(), getM_Warehouse_ID(),
line.getM_Locator_ID(), line.getM_Locator_ID(),
line.getM_Product_ID(), line.getM_Product_ID(),
ma.getM_AttributeSetInstance_ID(), 0, ma.getM_AttributeSetInstance_ID(),
QtyMA.negate(), get_TrxName())) QtyMA.negate(), get_TrxName()))
{ {
String lastError = CLogger.retrieveErrorString(""); String lastError = CLogger.retrieveErrorString("");
@ -491,7 +491,7 @@ public class MInventory extends X_M_Inventory implements DocAction
if (!MStorageOnHand.add(getCtx(), getM_Warehouse_ID(), if (!MStorageOnHand.add(getCtx(), getM_Warehouse_ID(),
line.getM_Locator_ID(), line.getM_Locator_ID(),
line.getM_Product_ID(), line.getM_Product_ID(),
line.getM_AttributeSetInstance_ID(), 0, line.getM_AttributeSetInstance_ID(),
qtyDiff,get_TrxName())) qtyDiff,get_TrxName()))
{ {
String lastError = CLogger.retrieveErrorString(""); String lastError = CLogger.retrieveErrorString("");

View File

@ -403,7 +403,7 @@ public class MMovement extends X_M_Movement implements DocAction
if (!MStorageOnHand.add(getCtx(),locator.getM_Warehouse_ID(), if (!MStorageOnHand.add(getCtx(),locator.getM_Warehouse_ID(),
line.getM_Locator_ID(), line.getM_Locator_ID(),
line.getM_Product_ID(), line.getM_Product_ID(),
ma.getM_AttributeSetInstance_ID(), 0, ma.getM_AttributeSetInstance_ID(),
ma.getMovementQty().negate(), get_TrxName())) ma.getMovementQty().negate(), get_TrxName()))
{ {
String lastError = CLogger.retrieveErrorString(""); String lastError = CLogger.retrieveErrorString("");
@ -421,7 +421,7 @@ public class MMovement extends X_M_Movement implements DocAction
if (!MStorageOnHand.add(getCtx(),locator.getM_Warehouse_ID(), if (!MStorageOnHand.add(getCtx(),locator.getM_Warehouse_ID(),
line.getM_LocatorTo_ID(), line.getM_LocatorTo_ID(),
line.getM_Product_ID(), line.getM_Product_ID(),
M_AttributeSetInstanceTo_ID, 0, M_AttributeSetInstanceTo_ID,
ma.getMovementQty(), get_TrxName())) ma.getMovementQty(), get_TrxName()))
{ {
String lastError = CLogger.retrieveErrorString(""); String lastError = CLogger.retrieveErrorString("");
@ -461,7 +461,7 @@ public class MMovement extends X_M_Movement implements DocAction
if (!MStorageOnHand.add(getCtx(),locator.getM_Warehouse_ID(), if (!MStorageOnHand.add(getCtx(),locator.getM_Warehouse_ID(),
line.getM_Locator_ID(), line.getM_Locator_ID(),
line.getM_Product_ID(), line.getM_Product_ID(),
line.getM_AttributeSetInstance_ID(), 0, line.getM_AttributeSetInstance_ID(),
line.getMovementQty().negate(), get_TrxName())) line.getMovementQty().negate(), get_TrxName()))
{ {
String lastError = CLogger.retrieveErrorString(""); String lastError = CLogger.retrieveErrorString("");
@ -473,7 +473,7 @@ public class MMovement extends X_M_Movement implements DocAction
if (!MStorageOnHand.add(getCtx(),locator.getM_Warehouse_ID(), if (!MStorageOnHand.add(getCtx(),locator.getM_Warehouse_ID(),
line.getM_LocatorTo_ID(), line.getM_LocatorTo_ID(),
line.getM_Product_ID(), line.getM_Product_ID(),
line.getM_AttributeSetInstanceTo_ID(), 0, line.getM_AttributeSetInstanceTo_ID(),
line.getMovementQty(), get_TrxName())) line.getMovementQty(), get_TrxName()))
{ {
String lastError = CLogger.retrieveErrorString(""); String lastError = CLogger.retrieveErrorString("");

View File

@ -164,7 +164,7 @@ public class MProjectIssue extends X_C_ProjectIssue
// //
MLocator loc = MLocator.get(getCtx(), getM_Locator_ID()); MLocator loc = MLocator.get(getCtx(), getM_Locator_ID());
if (MStorageOnHand.add(getCtx(), loc.getM_Warehouse_ID(), getM_Locator_ID(), if (MStorageOnHand.add(getCtx(), loc.getM_Warehouse_ID(), getM_Locator_ID(),
getM_Product_ID(), getM_AttributeSetInstance_ID(), getM_AttributeSetInstance_ID(), getM_Product_ID(), getM_AttributeSetInstance_ID(),
getMovementQty().negate(), get_TrxName())) getMovementQty().negate(), get_TrxName()))
{ {
if (mTrx.save(get_TrxName())) if (mTrx.save(get_TrxName()))

View File

@ -358,16 +358,15 @@ public class MStorageOnHand extends X_M_StorageOnHand
* @return true if updated * @return true if updated
*/ */
public static boolean add (Properties ctx, int M_Warehouse_ID, int M_Locator_ID, public static boolean add (Properties ctx, int M_Warehouse_ID, int M_Locator_ID,
int M_Product_ID, int M_AttributeSetInstance_ID, int reservationAttributeSetInstance_ID, int M_Product_ID, int M_AttributeSetInstance_ID,
BigDecimal diffQtyOnHand, String trxName) BigDecimal diffQtyOnHand, String trxName)
{ {
MStorageOnHand storage = null; if (diffQtyOnHand == null || diffQtyOnHand.signum() == 0)
StringBuffer diffText = new StringBuffer("("); return true;
// Get Storage // Get Storage
if (storage == null) MStorageOnHand storage = getCreate (ctx, M_Locator_ID, M_Product_ID, M_AttributeSetInstance_ID, trxName);
storage = getCreate (ctx, M_Locator_ID, DB.getDatabase().forUpdate(storage, 120);
M_Product_ID, M_AttributeSetInstance_ID, trxName);
// Verify // Verify
if (storage.getM_Locator_ID() != M_Locator_ID if (storage.getM_Locator_ID() != M_Locator_ID
&& storage.getM_Product_ID() != M_Product_ID && storage.getM_Product_ID() != M_Product_ID
@ -378,64 +377,12 @@ public class MStorageOnHand extends X_M_StorageOnHand
return false; return false;
} }
// CarlosRuiz - globalqss - Fix [ 1725383 ] QtyOrdered wrongly updated storage.setQtyOnHand (storage.getQtyOnHand().add (diffQtyOnHand));
MProduct prd = new MProduct(ctx, M_Product_ID, trxName); if (s_log.isLoggable(Level.FINE)) {
if (prd.getM_AttributeSet_ID() == 0) { StringBuilder diffText = new StringBuilder("(OnHand=").append(diffQtyOnHand).append(") -> ").append(storage.toString());
// Product doesn't manage attribute set, always reserved with 0
reservationAttributeSetInstance_ID = 0;
}
//
MStorageOnHand storage0 = null;
if (M_AttributeSetInstance_ID != reservationAttributeSetInstance_ID)
{
storage0 = get(ctx, M_Locator_ID,
M_Product_ID, reservationAttributeSetInstance_ID, trxName);
if (storage0 == null) // create if not existing - should not happen
{
MWarehouse wh = MWarehouse.get(ctx, M_Warehouse_ID);
int xM_Locator_ID = wh.getDefaultLocator().getM_Locator_ID();
storage0 = getCreate (ctx, xM_Locator_ID,
M_Product_ID, reservationAttributeSetInstance_ID, trxName);
}
}
boolean changed = false;
if (diffQtyOnHand != null && diffQtyOnHand.signum() != 0)
{
storage.setQtyOnHand (storage.getQtyOnHand().add (diffQtyOnHand));
diffText.append("OnHand=").append(diffQtyOnHand);
changed = true;
}
/*//@win commented out
if (diffQtyReserved != null && diffQtyReserved.signum() != 0)
{
if (storage0 == null)
storage.setQtyReserved (storage.getQtyReserved().add (diffQtyReserved));
else
storage0.setQtyReserved (storage0.getQtyReserved().add (diffQtyReserved));
diffText.append(" Reserved=").append(diffQtyReserved);
changed = true;
}
if (diffQtyOrdered != null && diffQtyOrdered.signum() != 0)
{
if (storage0 == null)
storage.setQtyOrdered (storage.getQtyOrdered().add (diffQtyOrdered));
else
storage0.setQtyOrdered (storage0.getQtyOrdered().add (diffQtyOrdered));
diffText.append(" Ordered=").append(diffQtyOrdered);
changed = true;
}
*/
if (changed)
{
diffText.append(") -> ").append(storage.toString());
s_log.fine(diffText.toString()); s_log.fine(diffText.toString());
if (storage0 != null)
storage0.saveEx(trxName); // No AttributeSetInstance (reserved/ordered)
return storage.save (trxName);
} }
return storage.save (trxName);
return true;
} // add } // add

View File

@ -0,0 +1,42 @@
/******************************************************************************
* 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.sql.ResultSet;
import java.util.Properties;
public class MStorageProvider extends X_AD_StorageProvider {
/**
*
*/
private static final long serialVersionUID = -4048103579840786187L;
public MStorageProvider(Properties ctx, int AD_StorageProvider_ID,
String trxName) {
super(ctx, AD_StorageProvider_ID, trxName);
}
public MStorageProvider(Properties ctx, ResultSet rs, String trxName) {
super(ctx, rs, trxName);
}
}

View File

@ -225,6 +225,9 @@ public class MStorageReservation extends X_M_StorageReservation {
int M_Product_ID, int M_AttributeSetInstance_ID, int reservationAttributeSetInstance_ID, int M_Product_ID, int M_AttributeSetInstance_ID, int reservationAttributeSetInstance_ID,
BigDecimal diffQty, boolean isSOTrx, String trxName) BigDecimal diffQty, boolean isSOTrx, String trxName)
{ {
if (diffQty == null || diffQty.signum() == 0)
return true;
/* Do NOT use FIFO ASI for reservation */ /* Do NOT use FIFO ASI for reservation */
MProduct prd = new MProduct(ctx, M_Product_ID, trxName); MProduct prd = new MProduct(ctx, M_Product_ID, trxName);
if (prd.getM_AttributeSet_ID() == 0 || ! prd.getM_AttributeSet().isInstanceAttribute()) { if (prd.getM_AttributeSet_ID() == 0 || ! prd.getM_AttributeSet().isInstanceAttribute()) {
@ -233,14 +236,14 @@ public class MStorageReservation extends X_M_StorageReservation {
M_AttributeSetInstance_ID = 0; M_AttributeSetInstance_ID = 0;
} }
// //
if (M_AttributeSetInstance_ID != reservationAttributeSetInstance_ID) {
MStorageReservation storage = null; M_AttributeSetInstance_ID = reservationAttributeSetInstance_ID;
StringBuffer diffText = new StringBuffer("("); }
// Get Storage // Get Storage
if (storage == null) MStorageReservation storage = getCreate (ctx, M_Warehouse_ID,
storage = getCreate (ctx, M_Warehouse_ID,
M_Product_ID, M_AttributeSetInstance_ID, isSOTrx, trxName); M_Product_ID, M_AttributeSetInstance_ID, isSOTrx, trxName);
DB.getDatabase().forUpdate(storage, 120);
// Verify // Verify
if (storage.getM_Warehouse_ID() != M_Warehouse_ID if (storage.getM_Warehouse_ID() != M_Warehouse_ID
&& storage.getM_Product_ID() != M_Product_ID && storage.getM_Product_ID() != M_Product_ID
@ -251,37 +254,12 @@ public class MStorageReservation extends X_M_StorageReservation {
return false; return false;
} }
MStorageReservation storage0 = null; storage.setQty (storage.getQty().add(diffQty));
if (M_AttributeSetInstance_ID != reservationAttributeSetInstance_ID) if (s_log.isLoggable(Level.FINE)) {
{ StringBuilder diffText = new StringBuilder("(Qty=").append(diffQty).append(") -> ").append(storage.toString());
storage0 = get(ctx, M_Warehouse_ID,
M_Product_ID, reservationAttributeSetInstance_ID, isSOTrx, trxName);
if (storage0 == null) // create if not existing - should not happen
{
storage0 = getCreate (ctx, M_Warehouse_ID,
M_Product_ID, reservationAttributeSetInstance_ID, isSOTrx, trxName);
}
}
boolean changed = false;
if (diffQty != null && diffQty.signum() != 0)
{
if (storage0 == null)
storage.setQty (storage.getQty().add(diffQty));
else
storage0.setQty (storage0.getQty().add (diffQty));
diffText.append(" Qty=").append(diffQty);
changed = true;
}
if (changed)
{
diffText.append(") -> ").append(storage.toString());
s_log.fine(diffText.toString()); s_log.fine(diffText.toString());
if (storage0 != null)
storage0.saveEx(trxName); // No AttributeSetInstance
return storage.save (trxName);
} }
return storage.save (trxName);
return true;
} // add } // add
/** /**

View File

@ -588,9 +588,15 @@ public abstract class PO
log.log(Level.WARNING, "Index invalid - " + index); log.log(Level.WARNING, "Index invalid - " + index);
return false; return false;
} }
if (m_newValues[index] == null) Object newval = m_newValues[index];
if (newval == null)
return false; return false;
return !m_newValues[index].equals(m_oldValues[index]); if (newval == Null.NULL)
newval = null;
Object oldval = m_oldValues[index];
if (newval == null && oldval == null)
return false;
return !newval.equals(oldval);
} // is_ValueChanged } // is_ValueChanged
/** /**

View File

@ -30,7 +30,7 @@ public class X_AD_Client extends PO implements I_AD_Client, I_Persistent
/** /**
* *
*/ */
private static final long serialVersionUID = 20121031L; private static final long serialVersionUID = 20121127L;
/** Standard Constructor */ /** Standard Constructor */
public X_AD_Client (Properties ctx, int AD_Client_ID, String trxName) public X_AD_Client (Properties ctx, int AD_Client_ID, String trxName)
@ -56,7 +56,6 @@ public class X_AD_Client extends PO implements I_AD_Client, I_Persistent
// F // F
setName (null); setName (null);
setStoreArchiveOnFileSystem (false); setStoreArchiveOnFileSystem (false);
setStoreAttachmentsOnFileSystem (false);
setValue (null); setValue (null);
} */ } */
} }
@ -612,27 +611,6 @@ public class X_AD_Client extends PO implements I_AD_Client, I_Persistent
return false; return false;
} }
/** Set Store Attachments On File System.
@param StoreAttachmentsOnFileSystem Store Attachments On File System */
public void setStoreAttachmentsOnFileSystem (boolean StoreAttachmentsOnFileSystem)
{
set_Value (COLUMNNAME_StoreAttachmentsOnFileSystem, Boolean.valueOf(StoreAttachmentsOnFileSystem));
}
/** Get Store Attachments On File System.
@return Store Attachments On File System */
public boolean isStoreAttachmentsOnFileSystem ()
{
Object oo = get_Value(COLUMNNAME_StoreAttachmentsOnFileSystem);
if (oo != null)
{
if (oo instanceof Boolean)
return ((Boolean)oo).booleanValue();
return "Y".equals(oo);
}
return false;
}
/** Set Unix Archive Path. /** Set Unix Archive Path.
@param UnixArchivePath Unix Archive Path */ @param UnixArchivePath Unix Archive Path */
public void setUnixArchivePath (String UnixArchivePath) public void setUnixArchivePath (String UnixArchivePath)
@ -647,20 +625,6 @@ public class X_AD_Client extends PO implements I_AD_Client, I_Persistent
return (String)get_Value(COLUMNNAME_UnixArchivePath); return (String)get_Value(COLUMNNAME_UnixArchivePath);
} }
/** Set Unix Attachment Path.
@param UnixAttachmentPath Unix Attachment Path */
public void setUnixAttachmentPath (String UnixAttachmentPath)
{
set_Value (COLUMNNAME_UnixAttachmentPath, UnixAttachmentPath);
}
/** Get Unix Attachment Path.
@return Unix Attachment Path */
public String getUnixAttachmentPath ()
{
return (String)get_Value(COLUMNNAME_UnixAttachmentPath);
}
/** Set Search Key. /** Set Search Key.
@param Value @param Value
Search key for the record in the format required - must be unique Search key for the record in the format required - must be unique
@ -691,18 +655,4 @@ public class X_AD_Client extends PO implements I_AD_Client, I_Persistent
{ {
return (String)get_Value(COLUMNNAME_WindowsArchivePath); return (String)get_Value(COLUMNNAME_WindowsArchivePath);
} }
/** Set Windows Attachment Path.
@param WindowsAttachmentPath Windows Attachment Path */
public void setWindowsAttachmentPath (String WindowsAttachmentPath)
{
set_Value (COLUMNNAME_WindowsAttachmentPath, WindowsAttachmentPath);
}
/** Get Windows Attachment Path.
@return Windows Attachment Path */
public String getWindowsAttachmentPath ()
{
return (String)get_Value(COLUMNNAME_WindowsAttachmentPath);
}
} }

View File

@ -29,7 +29,7 @@ public class X_AD_ClientInfo extends PO implements I_AD_ClientInfo, I_Persistent
/** /**
* *
*/ */
private static final long serialVersionUID = 20121031L; private static final long serialVersionUID = 20121127L;
/** Standard Constructor */ /** Standard Constructor */
public X_AD_ClientInfo (Properties ctx, int AD_ClientInfo_ID, String trxName) public X_AD_ClientInfo (Properties ctx, int AD_ClientInfo_ID, String trxName)
@ -83,6 +83,31 @@ public class X_AD_ClientInfo extends PO implements I_AD_ClientInfo, I_Persistent
return (String)get_Value(COLUMNNAME_AD_ClientInfo_UU); return (String)get_Value(COLUMNNAME_AD_ClientInfo_UU);
} }
public org.compiere.model.I_AD_StorageProvider getAD_StorageProvider() throws RuntimeException
{
return (org.compiere.model.I_AD_StorageProvider)MTable.get(getCtx(), org.compiere.model.I_AD_StorageProvider.Table_Name)
.getPO(getAD_StorageProvider_ID(), get_TrxName()); }
/** Set AD_StorageProvider_ID.
@param AD_StorageProvider_ID AD_StorageProvider_ID */
public void setAD_StorageProvider_ID (int AD_StorageProvider_ID)
{
if (AD_StorageProvider_ID < 1)
set_Value (COLUMNNAME_AD_StorageProvider_ID, null);
else
set_Value (COLUMNNAME_AD_StorageProvider_ID, Integer.valueOf(AD_StorageProvider_ID));
}
/** Get AD_StorageProvider_ID.
@return AD_StorageProvider_ID */
public int getAD_StorageProvider_ID ()
{
Integer ii = (Integer)get_Value(COLUMNNAME_AD_StorageProvider_ID);
if (ii == null)
return 0;
return ii.intValue();
}
public org.compiere.model.I_AD_Tree getAD_Tree_Activity() throws RuntimeException public org.compiere.model.I_AD_Tree getAD_Tree_Activity() throws RuntimeException
{ {
return (org.compiere.model.I_AD_Tree)MTable.get(getCtx(), org.compiere.model.I_AD_Tree.Table_Name) return (org.compiere.model.I_AD_Tree)MTable.get(getCtx(), org.compiere.model.I_AD_Tree.Table_Name)

View File

@ -0,0 +1,210 @@
/******************************************************************************
* 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.sql.ResultSet;
import java.util.Properties;
/** Generated Model for AD_StorageProvider
* @author iDempiere (generated)
* @version Release 1.0a - $Id$ */
public class X_AD_StorageProvider extends PO implements I_AD_StorageProvider, I_Persistent
{
/**
*
*/
private static final long serialVersionUID = 20121123L;
/** Standard Constructor */
public X_AD_StorageProvider (Properties ctx, int AD_StorageProvider_ID, String trxName)
{
super (ctx, AD_StorageProvider_ID, trxName);
/** if (AD_StorageProvider_ID == 0)
{
} */
}
/** Load Constructor */
public X_AD_StorageProvider (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_AD_StorageProvider[")
.append(get_ID()).append("]");
return sb.toString();
}
/** Set AD_StorageProvider_ID.
@param AD_StorageProvider_ID AD_StorageProvider_ID */
public void setAD_StorageProvider_ID (int AD_StorageProvider_ID)
{
if (AD_StorageProvider_ID < 1)
set_Value (COLUMNNAME_AD_StorageProvider_ID, null);
else
set_Value (COLUMNNAME_AD_StorageProvider_ID, Integer.valueOf(AD_StorageProvider_ID));
}
/** Get AD_StorageProvider_ID.
@return AD_StorageProvider_ID */
public int getAD_StorageProvider_ID ()
{
Integer ii = (Integer)get_Value(COLUMNNAME_AD_StorageProvider_ID);
if (ii == null)
return 0;
return ii.intValue();
}
/** Set AD_StorageProvider_UU.
@param AD_StorageProvider_UU AD_StorageProvider_UU */
public void setAD_StorageProvider_UU (String AD_StorageProvider_UU)
{
set_Value (COLUMNNAME_AD_StorageProvider_UU, AD_StorageProvider_UU);
}
/** Get AD_StorageProvider_UU.
@return AD_StorageProvider_UU */
public String getAD_StorageProvider_UU ()
{
return (String)get_Value(COLUMNNAME_AD_StorageProvider_UU);
}
/** Set Folder.
@param Folder
A folder on a local or remote system to store data into
*/
public void setFolder (String Folder)
{
set_Value (COLUMNNAME_Folder, Folder);
}
/** Get Folder.
@return A folder on a local or remote system to store data into
*/
public String getFolder ()
{
return (String)get_Value(COLUMNNAME_Folder);
}
/** Method AD_Reference_ID=200019 */
public static final int METHOD_AD_Reference_ID=200019;
/** File System = FileSystem */
public static final String METHOD_FileSystem = "FileSystem";
/** Database = DB */
public static final String METHOD_Database = "DB";
/** Set Method.
@param Method Method */
public void setMethod (String Method)
{
set_Value (COLUMNNAME_Method, Method);
}
/** Get Method.
@return Method */
public String getMethod ()
{
return (String)get_Value(COLUMNNAME_Method);
}
/** Set Name.
@param Name
Alphanumeric identifier of the entity
*/
public void setName (String Name)
{
set_Value (COLUMNNAME_Name, Name);
}
/** Get Name.
@return Alphanumeric identifier of the entity
*/
public String getName ()
{
return (String)get_Value(COLUMNNAME_Name);
}
/** Set Password.
@param Password
Password of any length (case sensitive)
*/
public void setPassword (String Password)
{
set_Value (COLUMNNAME_Password, Password);
}
/** Get Password.
@return Password of any length (case sensitive)
*/
public String getPassword ()
{
return (String)get_Value(COLUMNNAME_Password);
}
/** Set URL.
@param URL
Full URL address - e.g. http://www.idempiere.org
*/
public void setURL (String URL)
{
set_Value (COLUMNNAME_URL, URL);
}
/** Get URL.
@return Full URL address - e.g. http://www.idempiere.org
*/
public String getURL ()
{
return (String)get_Value(COLUMNNAME_URL);
}
/** Set Registered EMail.
@param UserName
Email of the responsible for the System
*/
public void setUserName (String UserName)
{
set_Value (COLUMNNAME_UserName, UserName);
}
/** Get Registered EMail.
@return Email of the responsible for the System
*/
public String getUserName ()
{
return (String)get_Value(COLUMNNAME_UserName);
}
}

View File

@ -29,7 +29,7 @@ public class X_AD_WizardProcess extends PO implements I_AD_WizardProcess, I_Pers
/** /**
* *
*/ */
private static final long serialVersionUID = 20121031L; private static final long serialVersionUID = 20121116L;
/** Standard Constructor */ /** Standard Constructor */
public X_AD_WizardProcess (Properties ctx, int AD_WizardProcess_ID, String trxName) public X_AD_WizardProcess (Properties ctx, int AD_WizardProcess_ID, String trxName)
@ -70,6 +70,34 @@ public class X_AD_WizardProcess extends PO implements I_AD_WizardProcess, I_Pers
return sb.toString(); return sb.toString();
} }
public org.compiere.model.I_AD_User getAD_User() throws RuntimeException
{
return (org.compiere.model.I_AD_User)MTable.get(getCtx(), org.compiere.model.I_AD_User.Table_Name)
.getPO(getAD_User_ID(), get_TrxName()); }
/** Set User/Contact.
@param AD_User_ID
User within the system - Internal or Business Partner Contact
*/
public void setAD_User_ID (int AD_User_ID)
{
if (AD_User_ID < 1)
set_Value (COLUMNNAME_AD_User_ID, null);
else
set_Value (COLUMNNAME_AD_User_ID, Integer.valueOf(AD_User_ID));
}
/** Get User/Contact.
@return User within the system - Internal or Business Partner Contact
*/
public int getAD_User_ID ()
{
Integer ii = (Integer)get_Value(COLUMNNAME_AD_User_ID);
if (ii == null)
return 0;
return ii.intValue();
}
public org.compiere.model.I_AD_WF_Node getAD_WF_Node() throws RuntimeException public org.compiere.model.I_AD_WF_Node getAD_WF_Node() throws RuntimeException
{ {
return (org.compiere.model.I_AD_WF_Node)MTable.get(getCtx(), org.compiere.model.I_AD_WF_Node.Table_Name) return (org.compiere.model.I_AD_WF_Node)MTable.get(getCtx(), org.compiere.model.I_AD_WF_Node.Table_Name)

View File

@ -885,7 +885,7 @@ public class MDDOrder extends X_DD_Order implements DocAction
// Update Storage // Update Storage
if (!MStorageOnHand.add(getCtx(), locator_to.getM_Warehouse_ID(), locator_to.getM_Locator_ID(), if (!MStorageOnHand.add(getCtx(), locator_to.getM_Warehouse_ID(), locator_to.getM_Locator_ID(),
line.getM_Product_ID(), line.getM_Product_ID(),
line.getM_AttributeSetInstance_ID(), line.getM_AttributeSetInstance_ID(), line.getM_AttributeSetInstance_ID(),
Env.ZERO, get_TrxName())) Env.ZERO, get_TrxName()))
{ {
throw new AdempiereException(); throw new AdempiereException();
@ -893,7 +893,7 @@ public class MDDOrder extends X_DD_Order implements DocAction
if (!MStorageOnHand.add(getCtx(), locator_from.getM_Warehouse_ID(), locator_from.getM_Locator_ID(), if (!MStorageOnHand.add(getCtx(), locator_from.getM_Warehouse_ID(), locator_from.getM_Locator_ID(),
line.getM_Product_ID(), line.getM_Product_ID(),
line.getM_AttributeSetInstanceTo_ID(), line.getM_AttributeSetInstance_ID(), line.getM_AttributeSetInstanceTo_ID(),
Env.ZERO, get_TrxName())) Env.ZERO, get_TrxName()))
{ {
throw new AdempiereException(); throw new AdempiereException();

View File

@ -93,8 +93,6 @@ public class WReportCustomization implements IFormController,EventListener<Even
private Label pipeSeparator; private Label pipeSeparator;
private ToolBarButton bExport = new ToolBarButton(); private ToolBarButton bExport = new ToolBarButton();
private Button bnext ; private Button bnext ;
private Button bcancel;
private Button bRun;
private ToolBarButton btnSave; private ToolBarButton btnSave;
private Tabbox tabbox = new Tabbox(); private Tabbox tabbox = new Tabbox();
private Tabs tabs = new Tabs(); private Tabs tabs = new Tabs();
@ -102,6 +100,7 @@ public class WReportCustomization implements IFormController,EventListener<Even
private Window winExportFile = null; private Window winExportFile = null;
private Listbox cboType = new Listbox(); private Listbox cboType = new Listbox();
private ConfirmPanel confirmPanel = new ConfirmPanel(true); private ConfirmPanel confirmPanel = new ConfirmPanel(true);
private ConfirmPanel confirmPanelMain = new ConfirmPanel(true);
public boolean isChange=false; public boolean isChange=false;
public ZkReportViewer viewer; public ZkReportViewer viewer;
MPrintFormat fm; MPrintFormat fm;
@ -179,7 +178,7 @@ public class WReportCustomization implements IFormController,EventListener<Even
headerPanel.appendChild(newPrintFormat); headerPanel.appendChild(newPrintFormat);
Separator tor =new Separator("vertical"); Separator tor =new Separator("vertical");
tor.setSpacing("500px"); tor.setSpacing("23%");
headerPanel.appendChild(tor); headerPanel.appendChild(tor);
selectAll = new Label(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "SelectAll"))); selectAll = new Label(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "SelectAll")));
@ -195,7 +194,6 @@ public class WReportCustomization implements IFormController,EventListener<Even
headerPanel.appendChild(pipeSeparator); headerPanel.appendChild(pipeSeparator);
headerPanel.appendChild(new Separator("vertical")); headerPanel.appendChild(new Separator("vertical"));
headerPanel.appendChild(deselectAll); headerPanel.appendChild(deselectAll);
headerPanel.appendChild(new Separator("vertical")); headerPanel.appendChild(new Separator("vertical"));
Auxhead head=new Auxhead(); Auxhead head=new Auxhead();
@ -205,7 +203,7 @@ public class WReportCustomization implements IFormController,EventListener<Even
headerPanel.appendChild(new Separator("horizontal")); headerPanel.appendChild(new Separator("horizontal"));
tabbox.setWidth("100%"); tabbox.setWidth("100%");
tabbox.setHeight("80%"); tabbox.setHeight("87%");
tabfo2.addEventListener(Events.ON_CLICK, this); tabfo2.addEventListener(Events.ON_CLICK, this);
tabsc3.addEventListener(Events.ON_CLICK, this); tabsc3.addEventListener(Events.ON_CLICK, this);
tabgc4.addEventListener(Events.ON_CLICK, this); tabgc4.addEventListener(Events.ON_CLICK, this);
@ -285,27 +283,17 @@ public class WReportCustomization implements IFormController,EventListener<Even
foot.appendChild(new Separator("vertical")); foot.appendChild(new Separator("vertical"));
} }
bRun=new Button();
bRun.setLabel(Msg.getMsg(Env.getCtx(), "Run"));
bRun.setName("bRun");
bRun.addEventListener(Events.ON_CLICK, this);
foot.appendChild(bRun);
Separator se =new Separator("vertical");
se.setSpacing("500px");
foot.appendChild(se);
bnext=new Button(); bnext=new Button();
bnext.setLabel(Msg.getMsg(Env.getCtx(), "NextPage")); bnext.setLabel(Msg.getMsg(Env.getCtx(), "NextPage"));
bnext.setName("Next"); bnext.setName("Next");
bnext.addEventListener(Events.ON_CLICK, this); bnext.addEventListener(Events.ON_CLICK, this);
foot.appendChild(bnext); foot.appendChild(bnext);
foot.appendChild(new Separator("vertical")); Vbox vb = new Vbox();
vb.setWidth("50%");
bcancel=new Button(); foot.appendChild(vb);
bcancel.setName("Cancel"); vb.appendChild(confirmPanelMain);
bcancel.addEventListener(Events.ON_CLICK, this); confirmPanelMain.addActionListener(this);
bcancel.setLabel("Cancel"); confirmPanelMain.setVflex("0");
foot.appendChild(bcancel);
f.appendChild(foot); f.appendChild(foot);
grid.appendChild(f); grid.appendChild(f);
@ -345,15 +333,9 @@ public class WReportCustomization implements IFormController,EventListener<Even
tabbox.setSelectedIndex(oldtabidx); tabbox.setSelectedIndex(oldtabidx);
} }
else{ else{
if("Cancel".equals(bt.getName())){
close();
}
if("NewPrintFormat".equals(bt.getName())){ if("NewPrintFormat".equals(bt.getName())){
copyFormat(); copyFormat();
} }
if("bRun".equals(bt.getName())){
runReport();
}
} }
} }
} else { } else {
@ -365,12 +347,13 @@ public class WReportCustomization implements IFormController,EventListener<Even
oldtabidx = tabidx; oldtabidx = tabidx;
} }
} }
if (event.getTarget().getId().equals(ConfirmPanel.A_CANCEL)){
if (event.getTarget().getId().equals(ConfirmPanel.A_CANCEL)) close();
winExportFile.onClose(); }else if (event.getTarget().getId().equals(ConfirmPanel.A_OK)){
else if (event.getTarget().getId().equals(ConfirmPanel.A_OK)) ((WRCTabPanel) tabbox.getSelectedTabpanel()).updatePFI();
exportFile(); onSave();
close();
}
selectAll.setVisible(oldtabidx == 0); selectAll.setVisible(oldtabidx == 0);
deselectAll.setVisible(oldtabidx == 0); deselectAll.setVisible(oldtabidx == 0);
pipeSeparator.setVisible(oldtabidx == 0); pipeSeparator.setVisible(oldtabidx == 0);
@ -439,10 +422,18 @@ public class WReportCustomization implements IFormController,EventListener<Even
winExportFile.appendChild(vb); winExportFile.appendChild(vb);
vb.appendChild(hb); vb.appendChild(hb);
vb.appendChild(confirmPanel); vb.appendChild(confirmPanel);
confirmPanel.addActionListener(this); EventListener exportListener= new EventListener()
{
public void onEvent(Event event) throws Exception {
if (event.getTarget().getId().equals(ConfirmPanel.A_CANCEL))
winExportFile.onClose();
else if (event.getTarget().getId().equals(ConfirmPanel.A_OK))
exportFile();
}
};
confirmPanel.addActionListener(exportListener);
confirmPanel.setVflex("0"); confirmPanel.setVflex("0");
} }
winExportFile.setAttribute(Window.MODE_KEY, Window.MODE_HIGHLIGHTED); winExportFile.setAttribute(Window.MODE_KEY, Window.MODE_HIGHLIGHTED);
AEnv.showWindow(winExportFile); AEnv.showWindow(winExportFile);
} // cmd_export } // cmd_export
@ -524,7 +515,7 @@ public class WReportCustomization implements IFormController,EventListener<Even
public void close() public void close()
{ {
SessionManager.getAppDesktop().closeActiveWindow(); form.detach();
} }
public void copyFormat(){ public void copyFormat(){
@ -550,7 +541,7 @@ public class WReportCustomization implements IFormController,EventListener<Even
tpsf5.setMPrintFormat(newpf); tpsf5.setMPrintFormat(newpf);
tpsf5.setPrintFormatItems(pfi); tpsf5.setPrintFormatItems(pfi);
tpsf5.refresh(); tpsf5.refresh();
setIsChanged(true); setIsChanged(false);
comboReport.removeAllItems(); comboReport.removeAllItems();
comboReport.appendItem(newpf.getName(), newpf.get_ID()); comboReport.appendItem(newpf.getName(), newpf.get_ID());
@ -562,12 +553,6 @@ public class WReportCustomization implements IFormController,EventListener<Even
btnSave.setDisabled(!isChange); btnSave.setDisabled(!isChange);
bExport.setDisabled(isChange); bExport.setDisabled(isChange);
bRun.setDisabled(isChange);
newPrintFormat.setDisabled(isChange); newPrintFormat.setDisabled(isChange);
} }
public void runReport(){
m_reportEngine.setPrintFormat(m_reportEngine.getPrintFormat()); // reload
new ZkReportViewerProvider().openViewer(m_reportEngine);
}
} }

View File

@ -24,20 +24,22 @@ import java.util.logging.Level;
import org.adempiere.model.MWizardProcess; import org.adempiere.model.MWizardProcess;
import org.adempiere.webui.LayoutUtils; import org.adempiere.webui.LayoutUtils;
import org.adempiere.webui.apps.AEnv;
import org.adempiere.webui.component.Button; import org.adempiere.webui.component.Button;
import org.adempiere.webui.component.Checkbox;
import org.adempiere.webui.component.Grid; import org.adempiere.webui.component.Grid;
import org.adempiere.webui.component.Label; import org.adempiere.webui.component.Label;
import org.adempiere.webui.component.Panel; import org.adempiere.webui.component.Panel;
import org.adempiere.webui.component.Row; import org.adempiere.webui.component.Row;
import org.adempiere.webui.component.Rows; import org.adempiere.webui.component.Rows;
import org.adempiere.webui.component.Textbox; import org.adempiere.webui.component.Textbox;
import org.adempiere.webui.editor.WSearchEditor;
import org.adempiere.webui.editor.WTableDirEditor; import org.adempiere.webui.editor.WTableDirEditor;
import org.adempiere.webui.event.ValueChangeEvent;
import org.adempiere.webui.event.ValueChangeListener;
import org.adempiere.webui.panel.ADForm; import org.adempiere.webui.panel.ADForm;
import org.adempiere.webui.panel.CustomForm; import org.adempiere.webui.panel.CustomForm;
import org.adempiere.webui.panel.IFormController; import org.adempiere.webui.panel.IFormController;
import org.adempiere.webui.session.SessionManager; import org.adempiere.webui.session.SessionManager;
import org.adempiere.webui.util.TreeUtils;
import org.compiere.apps.form.SetupWizard; import org.compiere.apps.form.SetupWizard;
import org.compiere.model.MLookup; import org.compiere.model.MLookup;
import org.compiere.model.MLookupFactory; import org.compiere.model.MLookupFactory;
@ -62,6 +64,7 @@ import org.zkoss.zul.Treecell;
import org.zkoss.zul.Treechildren; import org.zkoss.zul.Treechildren;
import org.zkoss.zul.Treeitem; import org.zkoss.zul.Treeitem;
import org.zkoss.zul.Treerow; import org.zkoss.zul.Treerow;
import org.zkoss.zul.Vbox;
import org.zkoss.zul.West; import org.zkoss.zul.West;
/** /**
@ -70,8 +73,7 @@ import org.zkoss.zul.West;
* @author Carlos Ruiz * @author Carlos Ruiz
* *
*/ */
@SuppressWarnings({"unchecked", "rawtypes"}) public class WSetupWizard extends SetupWizard implements IFormController, EventListener
public class WSetupWizard extends SetupWizard implements IFormController, EventListener, ValueChangeListener
{ {
private CustomForm form = new CustomForm(); private CustomForm form = new CustomForm();
@ -81,23 +83,37 @@ public class WSetupWizard extends SetupWizard implements IFormController, EventL
private Label progressLabel = new Label(); private Label progressLabel = new Label();
// //
private Tree wfnodeTree; private Tree wfnodeTree;
private Treeitem prevti = null;
private Label titleLabel = new Label(); private Label titleLabel = new Label();
private Iframe helpFrame = new Iframe(); private Iframe helpFrame = new Iframe();
private Label notesLabel = new Label(Msg.getElement(Env.getCtx(), MWizardProcess.COLUMNNAME_Note)); private Label notesLabel = new Label(Msg.getElement(Env.getCtx(), MWizardProcess.COLUMNNAME_Note));
private Textbox notesField = new Textbox(); private Textbox notesField = new Textbox();
private Label userLabel = new Label(Msg.getMsg(Env.getCtx(), "User"));
private WSearchEditor userField;
private Label statusLabel = new Label(); private Label statusLabel = new Label();
private WTableDirEditor statusField; private WTableDirEditor statusField;
private Button bRefresh = new Button(); private Button bRefresh = new Button();
private Button bOK = new Button(); private Button bOK = new Button();
private Button bNext = new Button(); private Button bNext = new Button();
private Button bZoom = new Button();
private Button bExpand = new Button();
private Checkbox justmine = new Checkbox();
private Checkbox showColors = new Checkbox();
private ArrayList<Treeitem> nextItems = new ArrayList<Treeitem>(); private ArrayList<Treeitem> nextItems = new ArrayList<Treeitem>();
private static final String WIZARD_LABEL_STYLE = "font-weight: bold"; private static final String WIZARD_LABEL_STYLE = "font-weight: bold";
private static final String NODE_LABEL_STYLE = "margin-left:20px";
private boolean expandTree = false;
private Vbox east = new Vbox();
private Vbox eastdown = new Vbox();
private Vbox westdown = new Vbox();
private ArrayList<Integer> openNodes = new ArrayList<Integer>();
public WSetupWizard() public WSetupWizard()
{ {
@ -120,6 +136,7 @@ public class WSetupWizard extends SetupWizard implements IFormController, EventL
{ {
wfnodeTree = new Tree(); wfnodeTree = new Tree();
wfnodeTree.addEventListener(Events.ON_SELECT, this); wfnodeTree.addEventListener(Events.ON_SELECT, this);
showColors.setChecked(true);
loadWizardNodes(); loadWizardNodes();
} // preInit } // preInit
@ -127,7 +144,9 @@ public class WSetupWizard extends SetupWizard implements IFormController, EventL
* Load Wizard Nodes * Load Wizard Nodes
*/ */
private void loadWizardNodes() { private void loadWizardNodes() {
nextItems.removeAll(nextItems);
Treechildren treeChildren = wfnodeTree.getTreechildren(); Treechildren treeChildren = wfnodeTree.getTreechildren();
List<MWorkflow> wfwizards = getWfWizards();
if (treeChildren == null) if (treeChildren == null)
{ {
treeChildren = new Treechildren(); treeChildren = new Treechildren();
@ -135,7 +154,6 @@ public class WSetupWizard extends SetupWizard implements IFormController, EventL
wfnodeTree.setMultiple(false); wfnodeTree.setMultiple(false);
} }
List<MWorkflow> wfwizards = getWfWizards();
for(MWorkflow wfwizard : wfwizards) for(MWorkflow wfwizard : wfwizards)
{ {
addWfEntry(wfwizard); addWfEntry(wfwizard);
@ -162,9 +180,16 @@ public class WSetupWizard extends SetupWizard implements IFormController, EventL
treerow.appendChild(treecell); treerow.appendChild(treecell);
treecell.appendChild(div); treecell.appendChild(div);
nextItems.add(treeitemwf); nextItems.add(treeitemwf);
if (openNodes.contains(wfwizard.getAD_Workflow_ID()))
treeitemwf.setOpen(true);
addNodes(wfwizard, treeitemwf); addNodes(wfwizard, treeitemwf);
treeitemwf.setAttribute("AD_Workflow_ID", wfwizard.getAD_Workflow_ID()); treeitemwf.setAttribute("AD_Workflow_ID", wfwizard.getAD_Workflow_ID());
if (prevti != null && prevti.getAttribute("AD_Workflow_ID") != null) {
if (prevti.getAttribute("AD_Workflow_ID").equals(treeitemwf.getAttribute("AD_Workflow_ID")))
wfnodeTree.setSelectedItem(treeitemwf);
}
} }
private void addNodes(MWorkflow wfwizard, Treeitem treeitemwf) { private void addNodes(MWorkflow wfwizard, Treeitem treeitemwf) {
@ -177,7 +202,17 @@ public class WSetupWizard extends SetupWizard implements IFormController, EventL
private void addWfNode(MWFNode node, Treeitem treeitemwf) { private void addWfNode(MWFNode node, Treeitem treeitemwf) {
/* TODO: Color of node according to wizard status */ /* TODO: Color of node according to wizard status */
Label nodeLabel = new Label(node.getName(true)); Label nodeLabel = new Label(node.getName(true));
nodeLabel.setStyle(NODE_LABEL_STYLE); if (node != null && showColors.isChecked()) {
MWizardProcess wp = MWizardProcess.get(Env.getCtx(), node.getAD_WF_Node_ID(), Env.getAD_Client_ID(Env.getCtx()));
String status = wp.getWizardStatus();
if ( MWizardProcess.WIZARDSTATUS_Finished.equals(status)
|| MWizardProcess.WIZARDSTATUS_Skipped.equals(status)) {
nodeLabel.setStyle("background-color: #90EE90;margin-left:20px;");
} else {
nodeLabel.setStyle("background-color: #FFFF00;margin-left:20px;");
}
}
Div div = new Div(); Div div = new Div();
div.setStyle("display:inline;"); div.setStyle("display:inline;");
div.appendChild(nodeLabel); div.appendChild(nodeLabel);
@ -198,6 +233,10 @@ public class WSetupWizard extends SetupWizard implements IFormController, EventL
treecell.appendChild(div); treecell.appendChild(div);
childItem.setAttribute("AD_WF_Node_ID", node.getAD_WF_Node_ID()); childItem.setAttribute("AD_WF_Node_ID", node.getAD_WF_Node_ID());
if (prevti != null && prevti.getAttribute("AD_WF_Node_ID") != null) {
if (prevti.getAttribute("AD_WF_Node_ID").equals(childItem.getAttribute("AD_WF_Node_ID")))
wfnodeTree.setSelectedItem(childItem);
}
nextItems.add(childItem); nextItems.add(childItem);
} }
@ -223,10 +262,28 @@ public class WSetupWizard extends SetupWizard implements IFormController, EventL
bOK.setTooltiptext(Msg.getMsg(Env.getCtx(), "Update")); bOK.setTooltiptext(Msg.getMsg(Env.getCtx(), "Update"));
bOK.addEventListener(Events.ON_CLICK, this); bOK.addEventListener(Events.ON_CLICK, this);
bNext.setImage("/images/Detail24.png"); bNext.setImage("/images/Next24.png");
bNext.setTooltiptext(Msg.getMsg(Env.getCtx(), "Next")); bNext.setTooltiptext(Msg.getMsg(Env.getCtx(), "Next"));
bNext.addEventListener(Events.ON_CLICK, this); bNext.addEventListener(Events.ON_CLICK, this);
bZoom.setImage("/images/Zoom16.png");
bZoom.setTooltiptext(Msg.getMsg(Env.getCtx(), "Zoom"));
bZoom.addEventListener(Events.ON_CLICK, this);
bExpand.setLabel("Expand Tree");
bExpand.setTooltiptext(Msg.getMsg(Env.getCtx(), "ExpandTree"));
bExpand.addEventListener(Events.ON_CLICK, this);
justmine.setLabel("Just Mine");
justmine.setTooltiptext(Msg.getMsg(Env.getCtx(), "JustMine"));
justmine.addEventListener(Events.ON_CHECK,this);
showColors.setLabel("Show Colors");
showColors.setTooltiptext(Msg.getMsg(Env.getCtx(), "ShowColors"));
showColors.addEventListener(Events.ON_CHECK,this);
North north = new North(); North north = new North();
mainLayout.appendChild(north); mainLayout.appendChild(north);
north.appendChild(northPanel); north.appendChild(northPanel);
@ -245,14 +302,20 @@ public class WSetupWizard extends SetupWizard implements IFormController, EventL
false, "AD_Ref_List.Value IN ('D','S','I','F','P')"); false, "AD_Ref_List.Value IN ('D','S','I','F','P')");
statusField = new WTableDirEditor("WizardStatus", true, false, true,wizardL); statusField = new WTableDirEditor("WizardStatus", true, false, true,wizardL);
statusField.setValue(MWizardProcess.WIZARDSTATUS_Pending); statusField.setValue(MWizardProcess.WIZARDSTATUS_Pending);
statusField.addValueChangeListener(this);
// east.setVflex("1");
east.setHflex("1");
West west = new West(); West west = new West();
mainLayout.appendChild(west); mainLayout.appendChild(west);
west.appendChild(wfnodeTree); west.appendChild(east);
east.appendChild(wfnodeTree);
wfnodeTree.setVflex("1"); wfnodeTree.setVflex("1");
wfnodeTree.setHflex("1"); wfnodeTree.setHflex("1");
east.appendChild(eastdown);
eastdown.setOrient("horizontal");
eastdown.appendChild(bExpand);
eastdown.appendChild(justmine);
eastdown.appendChild(showColors);
west.setAutoscroll(true); west.setAutoscroll(true);
west.setWidth("30%"); west.setWidth("30%");
@ -288,17 +351,26 @@ public class WSetupWizard extends SetupWizard implements IFormController, EventL
notesField.setRows(4); notesField.setRows(4);
notesField.setWidth("100%"); notesField.setWidth("100%");
MLookup lookup = MLookupFactory.get(Env.getCtx(), form.getWindowNo(),
0, 200913, DisplayType.Search);
userField = new WSearchEditor(lookup, Msg.translate(
Env.getCtx(), "AD_User_ID"), "", false, false, true);
row = new Row(); row = new Row();
rows.appendChild(row); rows.appendChild(row);
Div div = new Div(); westdown.setOrient("horizontal");
div.appendChild(statusLabel); westdown.appendChild(bZoom);
div.appendChild(statusField.getComponent()); westdown.appendChild(userLabel);
div.appendChild(new Space()); westdown.appendChild(userField.getComponent());
div.setAlign("right"); westdown.appendChild(new Space());
div.appendChild(bRefresh); westdown.appendChild(statusLabel);
div.appendChild(bOK); westdown.appendChild(statusField.getComponent());
div.appendChild(bNext); westdown.appendChild(new Space());
row.appendChild(div); westdown.appendChild(bRefresh);
westdown.appendChild(bOK);
westdown.appendChild(bNext);
row.appendChild(westdown);
row.setAlign("right");
East east = new East(); East east = new East();
mainLayout.appendChild(east); mainLayout.appendChild(east);
@ -323,6 +395,7 @@ public class WSetupWizard extends SetupWizard implements IFormController, EventL
progressLabel.setText(msg); progressLabel.setText(msg);
progressbar.setValue(percent); progressbar.setValue(percent);
progressbar.setTooltiptext(msg); progressbar.setTooltiptext(msg);
progressbar.setStyle("background: #BBC2DB;");
} }
/** /**
@ -342,29 +415,104 @@ public class WSetupWizard extends SetupWizard implements IFormController, EventL
if (e.getTarget() == wfnodeTree) { if (e.getTarget() == wfnodeTree) {
onTreeSelection(e); onTreeSelection(e);
} else if (e.getTarget() == bRefresh) { } else if (e.getTarget() == bRefresh) {
refresh();
showInRightPanel(0, m_node.getAD_WF_Node_ID()); showInRightPanel(0, m_node.getAD_WF_Node_ID());
} else if (e.getTarget() == bOK) { } else if (e.getTarget() == bOK) {
save(notesField.getText(), (String) statusField.getValue()); int userid = 0;
showInRightPanel(0, m_node.getAD_WF_Node_ID()); if (!userField.isNullOrEmpty())
refreshProgress(); userid = (Integer)userField.getValue();
if (save(notesField.getText(), (String) statusField.getValue(), userid))
repaintTree();
} else if (e.getTarget() == bNext) { } else if (e.getTarget() == bNext) {
navigateToNext(); navigateToNext();
} else if (e.getTarget() == bZoom) {
zoom();
} else if (e.getTarget() == bExpand) {
expandTree();
} else if (e.getTarget() == justmine) {
justMine();
} else if (e.getTarget() == showColors) {
showColors();
} }
} // actionPerformed } // actionPerformed
private void refresh() { private void showColors() {
if (m_node != null) { if (!showColors.isChecked()) {
MWizardProcess wp = MWizardProcess.get(Env.getCtx(), m_node.getAD_WF_Node_ID(), Env.getAD_Client_ID(Env.getCtx())); for (Treeitem nextItem : nextItems){
notesField.setText(wp.getNote()); Treeitem ti= nextItem;
statusField.setValue(wp.getWizardStatus()); if (ti.getLevel() != 0) {
ti.setStyle("background-color: #FFFFFF;");
}
}
}
repaintTree();
}
private void justMine() {
if (justmine.isChecked()) {
showChildren(false);
} else {
showChildren(true);
} }
} }
private void showChildren(boolean showmine) {
int user = Env.getAD_User_ID(Env.getCtx());
for (Treeitem nextItem : nextItems){
Treeitem ti= nextItem;
if (ti.getLevel()!= 0){
MWizardProcess wp = MWizardProcess.get(Env.getCtx(), (Integer) ti.getAttribute("AD_WF_Node_ID"), Env.getAD_Client_ID(Env.getCtx()));
if (wp.getAD_User_ID() != user){
ti.setVisible(showmine);
}
}
}
}
private void expandTree() {
if(!expandTree){
TreeUtils.expandAll(wfnodeTree);
expandTree = true;
}else{
TreeUtils.collapseAll(wfnodeTree);
expandTree = false;
}
}
private void zoom() {
if(m_node != null)
AEnv.zoom(m_node.getAD_Window_ID(), null);
}
private void repaintTree() {
east.removeChild(wfnodeTree);
east.removeChild(eastdown);
east.setVflex("1");
east.setHflex("1");
openNodes.removeAll(openNodes);
for (Treeitem nextItem : nextItems) {
if (nextItem.isOpen() && nextItem.getAttribute("AD_Workflow_ID") != null) {
openNodes.add((Integer) nextItem.getAttribute("AD_Workflow_ID"));
}
}
prevti = wfnodeTree.getSelectedItem();
wfnodeTree.clear();
loadWizardNodes();
east.appendChild(wfnodeTree);
east.appendChild(eastdown);
refreshProgress();
}
private void navigateToNext() { private void navigateToNext() {
boolean repaint = false;
if (m_node != null) { if (m_node != null) {
save(notesField.getText(), (String) statusField.getValue()); int userid = 0;
refreshProgress(); if (!userField.isNullOrEmpty())
userid = (Integer)userField.getValue();
repaint = save(notesField.getText(), (String) statusField.getValue(), userid);
} }
Treeitem ti = wfnodeTree.getSelectedItem(); Treeitem ti = wfnodeTree.getSelectedItem();
if (ti == null || nextItems.indexOf(ti)+1 == nextItems.size()) { if (ti == null || nextItems.indexOf(ti)+1 == nextItems.size()) {
@ -377,6 +525,8 @@ public class WSetupWizard extends SetupWizard implements IFormController, EventL
wfnodeTree.setSelectedItem(nextti); wfnodeTree.setSelectedItem(nextti);
showItem(nextti); showItem(nextti);
} }
if (repaint)
repaintTree();
} }
/** /**
@ -413,6 +563,7 @@ public class WSetupWizard extends SetupWizard implements IFormController, EventL
MWizardProcess wp = MWizardProcess.get(Env.getCtx(), ad_wf_node_id, Env.getAD_Client_ID(Env.getCtx())); MWizardProcess wp = MWizardProcess.get(Env.getCtx(), ad_wf_node_id, Env.getAD_Client_ID(Env.getCtx()));
notesField.setText(wp.getNote()); notesField.setText(wp.getNote());
statusField.setValue(wp.getWizardStatus()); statusField.setValue(wp.getWizardStatus());
userField.setValue(wp.getAD_User_ID() > 0 ? wp.getAD_User_ID() : null);
setNotesPanelVisible(true); setNotesPanelVisible(true);
} else { } else {
MWorkflow wf = MWorkflow.get(Env.getCtx(), ad_workflow_id); MWorkflow wf = MWorkflow.get(Env.getCtx(), ad_workflow_id);
@ -439,6 +590,9 @@ public class WSetupWizard extends SetupWizard implements IFormController, EventL
bOK.setVisible(visible); bOK.setVisible(visible);
statusLabel.setVisible(visible); statusLabel.setVisible(visible);
statusField.setVisible(visible); statusField.setVisible(visible);
userLabel.setVisible(visible);
userField.setVisible(visible);
bZoom.setVisible(visible);
} }
public ADForm getForm() public ADForm getForm()
@ -446,10 +600,4 @@ public class WSetupWizard extends SetupWizard implements IFormController, EventL
return form; return form;
} }
@Override
public void valueChange(ValueChangeEvent e) {
log.info(e.getPropertyName() + "=" + e.getNewValue());
/* if (e.getPropertyName().equals("WizardStatus")) */
}
} // WSetupWizard } // WSetupWizard

View File

@ -42,8 +42,8 @@ import org.compiere.util.Env;
import org.compiere.util.Msg; import org.compiere.util.Msg;
import org.zkoss.util.media.AMedia; import org.zkoss.util.media.AMedia;
import org.zkoss.util.media.Media; import org.zkoss.util.media.Media;
import org.zkoss.zk.au.out.AuScript;
import org.zkoss.zk.au.out.AuEcho; import org.zkoss.zk.au.out.AuEcho;
import org.zkoss.zk.au.out.AuScript;
import org.zkoss.zk.ui.event.Event; import org.zkoss.zk.ui.event.Event;
import org.zkoss.zk.ui.event.EventListener; import org.zkoss.zk.ui.event.EventListener;
import org.zkoss.zk.ui.event.Events; import org.zkoss.zk.ui.event.Events;
@ -51,12 +51,12 @@ import org.zkoss.zk.ui.event.UploadEvent;
import org.zkoss.zk.ui.util.Clients; import org.zkoss.zk.ui.util.Clients;
import org.zkoss.zul.Borderlayout; import org.zkoss.zul.Borderlayout;
import org.zkoss.zul.Center; import org.zkoss.zul.Center;
import org.zkoss.zul.North;
import org.zkoss.zul.South;
import org.zkoss.zul.Div; import org.zkoss.zul.Div;
import org.zkoss.zul.Filedownload; import org.zkoss.zul.Filedownload;
import org.zkoss.zul.Hbox; import org.zkoss.zul.Hbox;
import org.zkoss.zul.Iframe; import org.zkoss.zul.Iframe;
import org.zkoss.zul.North;
import org.zkoss.zul.South;
/** /**
* *
@ -66,9 +66,9 @@ import org.zkoss.zul.Iframe;
public class WAttachment extends Window implements EventListener<Event> public class WAttachment extends Window implements EventListener<Event>
{ {
/** /**
* generated serial version Id *
*/ */
private static final long serialVersionUID = 2923895336573554570L; private static final long serialVersionUID = 4311076973993361653L;
private static CLogger log = CLogger.getCLogger(WAttachment.class); private static CLogger log = CLogger.getCLogger(WAttachment.class);
@ -574,24 +574,27 @@ public class WAttachment extends Window implements EventListener<Event>
} }
} }
private byte[] getMediaData(Media media) { private byte[] getMediaData(Media media) {
byte[] bytes = null; byte[] bytes = null;
if (media.inMemory()) try{
bytes = media.getByteData();
else { if (media.inMemory())
InputStream is = media.getStreamData(); bytes = media.isBinary() ? media.getByteData() : media.getStringData().getBytes(getCharset(media.getContentType()));
ByteArrayOutputStream baos = new ByteArrayOutputStream(); else {
byte[] buf = new byte[ 1000 ]; InputStream is = media.getStreamData();
int byteread = 0; ByteArrayOutputStream baos = new ByteArrayOutputStream();
try { byte[] buf = new byte[ 1000 ];
while (( byteread=is.read(buf) )!=-1) int byteread = 0;
while (( byteread=is.read(buf) )!=-1)
baos.write(buf,0,byteread); baos.write(buf,0,byteread);
} catch (IOException e) {
log.log(Level.SEVERE, e.getLocalizedMessage(), e);
throw new IllegalStateException(e.getLocalizedMessage());
}
bytes = baos.toByteArray(); bytes = baos.toByteArray();
}
} catch (IOException e) {
log.log(Level.SEVERE, e.getLocalizedMessage(), e);
throw new IllegalStateException(e.getLocalizedMessage());
} }
return bytes; return bytes;
@ -673,4 +676,16 @@ public class WAttachment extends Window implements EventListener<Event>
} }
} }
} // saveAttachmentToFile } // saveAttachmentToFile
static private String getCharset(String contentType) {
if (contentType != null) {
int j = contentType.indexOf("charset=");
if (j >= 0) {
String cs = contentType.substring(j + 8).trim();
if (cs.length() > 0) return cs;
}
}
return "UTF-8";
}
} }

View File

@ -1106,12 +1106,24 @@ public class ZkReportViewer extends Window implements EventListener<Event>, ITab
int AD_PrintFormat_ID = m_reportEngine.getPrintFormat().get_ID(); int AD_PrintFormat_ID = m_reportEngine.getPrintFormat().get_ID();
Env.setContext(m_ctx, "AD_PrintFormat_ID", AD_PrintFormat_ID); Env.setContext(m_ctx, "AD_PrintFormat_ID", AD_PrintFormat_ID);
ADForm form = ADForm.openForm(SystemIDs.FORM_REPORT_WIZARD);
ADForm form = ADForm.openForm(SystemIDs.FORM_REPORT_WIZARD);
WReportCustomization av = (WReportCustomization) form.getICustomForm(); WReportCustomization av = (WReportCustomization) form.getICustomForm();
av.setReportEngine(m_reportEngine); av.setReportEngine(m_reportEngine);
form.setClosable(true);
form.setAttribute(Window.MODE_KEY, Window.MODE_EMBEDDED); form.setWidth("70%");
form.setHeight("85%");
form.addEventListener(DialogEvents.ON_WINDOW_CLOSE, new EventListener<Event>() {
@Override
public void onEvent(Event event) throws Exception {
if (DialogEvents.ON_WINDOW_CLOSE.equals(event.getName())) {
if(m_reportEngine.getPrintFormat().get_ID()!=Env.getContextAsInt(m_ctx, "AD_PrintFormat_ID")){
fillComboReport (m_reportEngine.getPrintFormat().get_ID());
}
cmd_report();
}
}
});
form.setAttribute(Window.MODE_KEY, Window.MODE_HIGHLIGHTED);
SessionManager.getAppDesktop().showWindow(form); SessionManager.getAppDesktop().showWindow(form);
} // cmd_Wizard } // cmd_Wizard

View File

@ -80,18 +80,21 @@ public class SetupWizard
.list(); .list();
} }
public void save(String note, String wizardStatus) { public boolean save(String note, String wizardStatus, int userid) {
MWizardProcess wp = MWizardProcess.get(Env.getCtx(), m_node.getAD_WF_Node_ID(), Env.getAD_Client_ID(Env.getCtx())); MWizardProcess wp = MWizardProcess.get(Env.getCtx(), m_node.getAD_WF_Node_ID(), Env.getAD_Client_ID(Env.getCtx()));
if (note != null && note.length() == 0) if (note != null && note.length() == 0)
note = null; note = null;
if (wizardStatus != null && wizardStatus.length() == 0) if (wizardStatus != null && wizardStatus.length() == 0)
wizardStatus = null; wizardStatus = null;
if ((wp.getNote() == null && note != null) || (note != null && !note.equals(wp.getNote()))) wp.setAD_User_ID(userid);
wp.setNote(note); wp.setNote(note);
if ((wp.getWizardStatus() == null && wizardStatus != null) || (wizardStatus != null && !wizardStatus.equals(wp.getWizardStatus()))) wp.setWizardStatus(wizardStatus);
wp.setWizardStatus(wizardStatus); boolean statusChanged = wp.is_ValueChanged("WizardStatus");
if (wp.is_Changed()) if (statusChanged
|| wp.is_ValueChanged("Note")
|| wp.is_ValueChanged("AD_User_ID"))
wp.saveEx(); wp.saveEx();
return statusChanged;
} }
} // SetupWizard } // SetupWizard

View File

@ -1255,10 +1255,21 @@ public class DB_Oracle implements AdempiereDatabase
for(int i = 0; i < keyColumns.length; i++) { for(int i = 0; i < keyColumns.length; i++) {
if (i > 0) if (i > 0)
sqlBuffer.append(" AND "); sqlBuffer.append(" AND ");
sqlBuffer.append(keyColumns[i]).append(" = ? "); sqlBuffer.append(keyColumns[i]).append("=?");
}
sqlBuffer.append(" FOR UPDATE WAIT ").append((timeout > 0 ? timeout : LOCK_TIME_OUT));
Object[] parameters = new Object[keyColumns.length];
for(int i = 0; i < keyColumns.length; i++) {
Object parameter = po.get_Value(keyColumns[i]);
if (parameter != null && parameter instanceof Boolean) {
if ((Boolean) parameter)
parameter = "Y";
else
parameter = "N";
}
parameters[i] = parameter;
} }
sqlBuffer.append(" FOR UPDATE ");
sqlBuffer.append(" WAIT ").append((timeout > 0 ? timeout : LOCK_TIME_OUT));
PreparedStatement stmt = null; PreparedStatement stmt = null;
ResultSet rs = null; ResultSet rs = null;
@ -1266,7 +1277,7 @@ public class DB_Oracle implements AdempiereDatabase
stmt = DB.prepareStatement(sqlBuffer.toString(), stmt = DB.prepareStatement(sqlBuffer.toString(),
ResultSet.TYPE_FORWARD_ONLY, ResultSet.CONCUR_UPDATABLE, po.get_TrxName()); ResultSet.TYPE_FORWARD_ONLY, ResultSet.CONCUR_UPDATABLE, po.get_TrxName());
for(int i = 0; i < keyColumns.length; i++) { for(int i = 0; i < keyColumns.length; i++) {
stmt.setObject(i+1, po.get_Value(keyColumns[i])); stmt.setObject(i+1, parameters[i]);
} }
rs = stmt.executeQuery(); rs = stmt.executeQuery();
if (rs.next()) { if (rs.next()) {
@ -1276,6 +1287,7 @@ public class DB_Oracle implements AdempiereDatabase
} }
} catch (Exception e) { } catch (Exception e) {
log.log(Level.INFO, e.getLocalizedMessage(), e); log.log(Level.INFO, e.getLocalizedMessage(), e);
throw new DBException("Could not lock record for " + po.toString() + " caused by " + e.getLocalizedMessage());
} finally { } finally {
DB.close(rs, stmt); DB.close(rs, stmt);
} }

View File

@ -994,9 +994,22 @@ public class DB_PostgreSQL implements AdempiereDatabase
for(int i = 0; i < keyColumns.length; i++) { for(int i = 0; i < keyColumns.length; i++) {
if (i > 0) if (i > 0)
sqlBuffer.append(" AND "); sqlBuffer.append(" AND ");
sqlBuffer.append(keyColumns[i]).append(" = ? "); sqlBuffer.append(keyColumns[i]).append("=?");
} }
sqlBuffer.append(" FOR UPDATE "); sqlBuffer.append(" FOR UPDATE ");
Object[] parameters = new Object[keyColumns.length];
for(int i = 0; i < keyColumns.length; i++) {
Object parameter = po.get_Value(keyColumns[i]);
if (parameter != null && parameter instanceof Boolean) {
if ((Boolean) parameter)
parameter = "Y";
else
parameter = "N";
}
parameters[i] = parameter;
}
PreparedStatement stmt = null; PreparedStatement stmt = null;
ResultSet rs = null; ResultSet rs = null;
int currentTimeout = -1; int currentTimeout = -1;
@ -1004,7 +1017,7 @@ public class DB_PostgreSQL implements AdempiereDatabase
stmt = DB.prepareStatement(sqlBuffer.toString(), stmt = DB.prepareStatement(sqlBuffer.toString(),
ResultSet.TYPE_FORWARD_ONLY, ResultSet.CONCUR_UPDATABLE, po.get_TrxName()); ResultSet.TYPE_FORWARD_ONLY, ResultSet.CONCUR_UPDATABLE, po.get_TrxName());
for(int i = 0; i < keyColumns.length; i++) { for(int i = 0; i < keyColumns.length; i++) {
stmt.setObject(i+1, po.get_Value(keyColumns[i])); stmt.setObject(i+1, parameters[i]);
} }
currentTimeout = setStatementTimeout(stmt.getConnection(), (timeout > 0 ? timeout : LOCK_TIME_OUT)); currentTimeout = setStatementTimeout(stmt.getConnection(), (timeout > 0 ? timeout : LOCK_TIME_OUT));
@ -1016,6 +1029,7 @@ public class DB_PostgreSQL implements AdempiereDatabase
} }
} catch (Exception e) { } catch (Exception e) {
log.log(Level.INFO, e.getLocalizedMessage(), e); log.log(Level.INFO, e.getLocalizedMessage(), e);
throw new DBException("Could not lock record for " + po.toString() + " caused by " + e.getLocalizedMessage());
} finally { } finally {
try { try {
setStatementTimeout(stmt.getConnection(), currentTimeout); setStatementTimeout(stmt.getConnection(), currentTimeout);