diff --git a/migration/i1.0b-release/oracle/20130613110000_IDEMPIERE-978.sql b/migration/i1.0b-release/oracle/20130613110000_IDEMPIERE-978.sql new file mode 100644 index 0000000000..3a2ed63de5 --- /dev/null +++ b/migration/i1.0b-release/oracle/20130613110000_IDEMPIERE-978.sql @@ -0,0 +1,157 @@ +-- Jun 12, 2013 6:37:56 PM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +UPDATE AD_Tab SET DisplayLogic='@HasRegion@=''Y''',Updated=TO_DATE('2013-06-12 18:37:56','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=136 +; + +-- Jun 12, 2013 6:38:30 PM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +UPDATE AD_Tab SET AD_Column_ID=7053, DisplayLogic='@HasRegion@=''Y''',Updated=TO_DATE('2013-06-12 18:38:30','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=215 +; + +-- Jun 13, 2013 10:00:26 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Tab (ImportFields,Processing,IsSingleRow,AD_Window_ID,SeqNo,IsTranslationTab,IsSortTab,AD_Table_ID,HasTree,IsInfoTab,WhereClause,IsReadOnly,IsInsertRecord,IsAdvancedTab,TabLevel,AD_Tab_UU,EntityType,Name,Description,AD_Tab_ID,AD_Org_ID,Created,CreatedBy,Updated,UpdatedBy,IsActive,AD_Client_ID) VALUES ('N','N','N',122,35,'N','N',186,'N','N','C_Region_ID IS NULL','N','Y','N',0,'27c212e2-6808-408a-91b8-7284e2b26c75','D','City (Without Regions)','Cities without Region',200095,0,TO_DATE('2013-06-13 10:00:25','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2013-06-13 10:00:25','YYYY-MM-DD HH24:MI:SS'),100,'Y',0) +; + +-- Jun 13, 2013 10:00:26 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Tab_Trl (AD_Language,AD_Tab_ID, Help,CommitWarning,Name,Description, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Tab_Trl_UU ) SELECT l.AD_Language,t.AD_Tab_ID, t.Help,t.CommitWarning,t.Name,t.Description, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Tab t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Tab_ID=200095 AND NOT EXISTS (SELECT * FROM AD_Tab_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Tab_ID=t.AD_Tab_ID) +; + +-- Jun 13, 2013 10:00:58 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,SeqNo,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,AD_Field_UU,IsDisplayed,IsFieldOnly,UpdatedBy,AD_Org_ID,Created,CreatedBy,Updated,IsActive,IsDisplayedGrid,SeqNoGrid,XPosition,IsQuickEntry,AD_Client_ID,ColumnSpan,NumLines) VALUES ('N',200095,14,'N','N',7052,10,'Y',202185,'N','City in a country','D','City','City','aa6f52b3-f6a0-4160-ae1a-da47af9d82f4','N','N',100,0,TO_DATE('2013-06-13 10:00:57','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2013-06-13 10:00:57','YYYY-MM-DD HH24:MI:SS'),'Y','N',10,1,'N',0,2,1) +; + +-- Jun 13, 2013 10:00:58 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=202185 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jun 13, 2013 10:00:58 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,SeqNo,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,AD_Field_UU,IsDisplayed,IsFieldOnly,UpdatedBy,AD_Org_ID,Created,CreatedBy,Updated,IsActive,IsDisplayedGrid,SeqNoGrid,XPosition,IsQuickEntry,AD_Client_ID,ColumnSpan,NumLines) VALUES ('N',200095,14,'N','N',1107,20,'Y',202186,'Y','A Client is a company or a legal entity. You cannot share data between Clients. Tenant is a synonym for Client.','D','Client/Tenant for this installation.','Client','fe8af11f-7c8e-48d4-9eb8-b54f2f21d2b0','Y','N',100,0,TO_DATE('2013-06-13 10:00:58','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2013-06-13 10:00:58','YYYY-MM-DD HH24:MI:SS'),'Y','Y',20,1,'N',0,2,1) +; + +-- Jun 13, 2013 10:00:58 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=202186 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jun 13, 2013 10:00:59 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,SeqNo,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,AD_Field_UU,IsDisplayed,IsFieldOnly,UpdatedBy,AD_Org_ID,Created,CreatedBy,Updated,IsActive,IsDisplayedGrid,SeqNoGrid,XPosition,IsQuickEntry,AD_Client_ID,ColumnSpan,NumLines) VALUES ('N',200095,14,'Y','N',1108,30,'Y',202187,'N','An organization is a unit of your client or legal entity - examples are store, department. You can share data between organizations.','D','Organizational entity within client','Organization','36b92d99-2c21-4a03-b9fa-9e704593ef6e','Y','N',100,0,TO_DATE('2013-06-13 10:00:58','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2013-06-13 10:00:58','YYYY-MM-DD HH24:MI:SS'),'Y','Y',30,4,'N',0,2,1) +; + +-- Jun 13, 2013 10:00:59 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=202187 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jun 13, 2013 10:00:59 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,SeqNo,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,AD_Field_UU,IsDisplayed,IsFieldOnly,UpdatedBy,AD_Org_ID,Created,CreatedBy,Updated,IsActive,IsDisplayedGrid,SeqNoGrid,XPosition,IsQuickEntry,AD_Client_ID,ColumnSpan,NumLines) VALUES ('N',200095,14,'N','N',7057,40,'Y',202188,'Y','The Country defines a Country. Each Country must be defined before it can be used in any document.','D','Country ','Country','f9bd6fb5-c072-4344-9dd8-03f8329fe789','Y','N',100,0,TO_DATE('2013-06-13 10:00:59','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2013-06-13 10:00:59','YYYY-MM-DD HH24:MI:SS'),'Y','Y',40,1,'N',0,2,1) +; + +-- Jun 13, 2013 10:00:59 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=202188 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jun 13, 2013 10:01:00 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,SeqNo,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,AD_Field_UU,IsDisplayed,IsFieldOnly,UpdatedBy,AD_Org_ID,Created,CreatedBy,Updated,IsActive,IsDisplayedGrid,SeqNoGrid,XPosition,IsQuickEntry,AD_Client_ID,ColumnSpan,NumLines) VALUES ('N',200095,14,'Y','N',7053,50,'Y',202189,'N','The Region identifies a unique Region for this Country.','D','Identifies a geographical Region','Region','86b81f79-8fc7-4ee1-8d14-c1b5b5ec72f0','Y','N',100,0,TO_DATE('2013-06-13 10:00:59','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2013-06-13 10:00:59','YYYY-MM-DD HH24:MI:SS'),'Y','Y',50,4,'N',0,2,1) +; + +-- Jun 13, 2013 10:01:00 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=202189 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jun 13, 2013 10:01:00 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field (SortNo,IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,SeqNo,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,AD_Field_UU,IsDisplayed,IsFieldOnly,UpdatedBy,AD_Org_ID,Created,CreatedBy,Updated,IsActive,IsDisplayedGrid,SeqNoGrid,XPosition,IsQuickEntry,AD_Client_ID,ColumnSpan,NumLines) VALUES (1,'N',200095,60,'N','N',1233,60,'Y',202190,'N','The name of an entity (record) is used as an default search option in addition to the search key. The name is up to 60 characters in length.','D','Alphanumeric identifier of the entity','Name','4941981e-61fb-489a-89bc-79760dc2362d','Y','N',100,0,TO_DATE('2013-06-13 10:01:00','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2013-06-13 10:01:00','YYYY-MM-DD HH24:MI:SS'),'Y','Y',60,1,'N',0,5,1) +; + +-- Jun 13, 2013 10:01:00 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=202190 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jun 13, 2013 10:01:01 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,SeqNo,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,AD_Field_UU,IsDisplayed,IsFieldOnly,UpdatedBy,AD_Org_ID,Created,CreatedBy,Updated,IsActive,IsDisplayedGrid,SeqNoGrid,XPosition,IsQuickEntry,AD_Client_ID,ColumnSpan,NumLines) VALUES ('N',200095,1,'N','N',1109,70,'Y',202191,'N','There are two methods of making records unavailable in the system: One is to delete the record, the other is to de-activate the record. A de-activated record is not available for selection, but available for reports. +There are two reasons for de-activating and not deleting records: +(1) The system requires the record for audit purposes. +(2) The record is referenced by other records. E.g., you cannot delete a Business Partner, if there are invoices for this partner record existing. You de-activate the Business Partner and prevent that this record is used for future entries.','D','The record is active in the system','Active','2b497371-c40f-4236-8afa-f2431b121ca2','Y','N',100,0,TO_DATE('2013-06-13 10:01:00','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2013-06-13 10:01:00','YYYY-MM-DD HH24:MI:SS'),'Y','Y',70,2,'N',0,2,1) +; + +-- Jun 13, 2013 10:01:01 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=202191 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jun 13, 2013 10:01:02 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,SeqNo,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,AD_Field_UU,IsDisplayed,IsFieldOnly,UpdatedBy,AD_Org_ID,Created,CreatedBy,Updated,IsActive,IsDisplayedGrid,SeqNoGrid,XPosition,IsQuickEntry,AD_Client_ID,ColumnSpan,NumLines) VALUES ('N',200095,11,'N','N',7051,80,'Y',202192,'N','The Postal Code or ZIP identifies the postal code for this entity''s address.','D','Postal code','ZIP','c6408f16-0fa3-4b77-94f1-6a1d162a0f3f','Y','N',100,0,TO_DATE('2013-06-13 10:01:01','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2013-06-13 10:01:01','YYYY-MM-DD HH24:MI:SS'),'Y','Y',80,1,'N',0,2,1) +; + +-- Jun 13, 2013 10:01:02 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=202192 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jun 13, 2013 10:01:02 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,SeqNo,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,AD_Field_UU,IsDisplayed,IsFieldOnly,UpdatedBy,AD_Org_ID,Created,CreatedBy,Updated,IsActive,IsDisplayedGrid,SeqNoGrid,XPosition,IsQuickEntry,AD_Client_ID,ColumnSpan,NumLines) VALUES ('N',200095,11,'Y','N',7055,90,'Y',202193,'N','Phone Area Code','D','Phone Area Code','Area Code','3aaaa4ed-885b-4670-9f71-87e14cc278c4','Y','N',100,0,TO_DATE('2013-06-13 10:01:02','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2013-06-13 10:01:02','YYYY-MM-DD HH24:MI:SS'),'Y','Y',90,4,'N',0,2,1) +; + +-- Jun 13, 2013 10:01:02 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=202193 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jun 13, 2013 10:01:03 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,SeqNo,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,AD_Field_UU,IsDisplayed,IsFieldOnly,UpdatedBy,AD_Org_ID,Created,CreatedBy,Updated,IsActive,IsDisplayedGrid,SeqNoGrid,XPosition,IsQuickEntry,AD_Client_ID,ColumnSpan,NumLines) VALUES ('N',200095,11,'N','N',7054,100,'Y',202194,'N','UN/Locode is a combination of a 2-character country code and a 3-character location code, e.g. BEANR is known as the city of Antwerp (ANR) which is located in Belgium (BE). +

See: http://www.unece.org/cefact/locode/service/main.htm','D','Location code - UN/LOCODE ','Locode','76ff8f96-236f-4977-bd43-7f9c3a613be5','Y','N',100,0,TO_DATE('2013-06-13 10:01:02','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2013-06-13 10:01:02','YYYY-MM-DD HH24:MI:SS'),'Y','Y',100,1,'N',0,2,1) +; + +-- Jun 13, 2013 10:01:03 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=202194 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jun 13, 2013 10:01:03 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,SeqNo,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,AD_Field_UU,IsDisplayed,IsFieldOnly,UpdatedBy,AD_Org_ID,Created,CreatedBy,Updated,IsActive,IsDisplayedGrid,SeqNoGrid,XPosition,IsQuickEntry,AD_Client_ID,ColumnSpan,NumLines) VALUES ('N',200095,15,'Y','N',7056,110,'Y',202195,'N','This column contains the geographical coordinates (latitude/longitude) of the location.

+In order to avoid unnecessary use of non-standard characters and space, the following standard presentation is used:
+0000N 00000W 0000S 00000E
+where the two last digits refer to minutes and the two or three first digits indicate the degrees','D','Location coordinate','Coordinates','cd58632f-e015-4439-9807-feed94a0be2e','Y','N',100,0,TO_DATE('2013-06-13 10:01:03','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2013-06-13 10:01:03','YYYY-MM-DD HH24:MI:SS'),'Y','Y',110,4,'N',0,2,1) +; + +-- Jun 13, 2013 10:01:03 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=202195 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jun 13, 2013 10:01:43 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +UPDATE AD_Field SET IsReadOnly='Y', DefaultValue='-1',Updated=TO_DATE('2013-06-13 10:01:43','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=202189 +; + +-- Jun 13, 2013 10:07:08 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +UPDATE AD_Tab SET WhereClause='C_Region_ID IS NULL AND C_Country_ID = @C_Country_ID@',Updated=TO_DATE('2013-06-13 10:07:08','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=200095 +; + + +-- Jun 13, 2013 10:40:56 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +UPDATE AD_Tab SET AD_Column_ID=7057, TabLevel=1,Updated=TO_DATE('2013-06-13 10:40:56','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=200095 +; + + +SELECT register_migration_script('20130613110000_IDEMPIERE-978.sql') FROM dual +; + diff --git a/migration/i1.0b-release/oracle/201306131356_IDEMPIERE-974.sql b/migration/i1.0b-release/oracle/201306131356_IDEMPIERE-974.sql new file mode 100644 index 0000000000..d907089a2e --- /dev/null +++ b/migration/i1.0b-release/oracle/201306131356_IDEMPIERE-974.sql @@ -0,0 +1,8 @@ +-- Jun 13, 2013 1:55:56 PM COT +-- IDEMPIERE-975 Issue in populating BP location for new sales order +UPDATE AD_Message SET MsgText='Please fill in required data for:', Value='FillMinimumInfo',Updated=TO_DATE('2013-06-13 13:55:56','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Message_ID=200180 +; + +SELECT register_migration_script('201306131356_IDEMPIERE-974.sql') FROM dual +; + diff --git a/migration/i1.0b-release/postgresql/20130613110000_IDEMPIERE-978.sql b/migration/i1.0b-release/postgresql/20130613110000_IDEMPIERE-978.sql new file mode 100644 index 0000000000..f40f312da1 --- /dev/null +++ b/migration/i1.0b-release/postgresql/20130613110000_IDEMPIERE-978.sql @@ -0,0 +1,157 @@ +-- Jun 12, 2013 6:37:56 PM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +UPDATE AD_Tab SET DisplayLogic='@HasRegion@=''Y''',Updated=TO_TIMESTAMP('2013-06-12 18:37:56','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=136 +; + +-- Jun 12, 2013 6:38:30 PM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +UPDATE AD_Tab SET AD_Column_ID=7053, DisplayLogic='@HasRegion@=''Y''',Updated=TO_TIMESTAMP('2013-06-12 18:38:30','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=215 +; + +-- Jun 13, 2013 10:00:26 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Tab (ImportFields,Processing,IsSingleRow,AD_Window_ID,SeqNo,IsTranslationTab,IsSortTab,AD_Table_ID,HasTree,IsInfoTab,WhereClause,IsReadOnly,IsInsertRecord,IsAdvancedTab,TabLevel,AD_Tab_UU,EntityType,Name,Description,AD_Tab_ID,AD_Org_ID,Created,CreatedBy,Updated,UpdatedBy,IsActive,AD_Client_ID) VALUES ('N','N','N',122,35,'N','N',186,'N','N','C_Region_ID IS NULL','N','Y','N',0,'27c212e2-6808-408a-91b8-7284e2b26c75','D','City (Without Regions)','Cities without Region',200095,0,TO_TIMESTAMP('2013-06-13 10:00:25','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2013-06-13 10:00:25','YYYY-MM-DD HH24:MI:SS'),100,'Y',0) +; + +-- Jun 13, 2013 10:00:26 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Tab_Trl (AD_Language,AD_Tab_ID, Help,CommitWarning,Name,Description, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Tab_Trl_UU ) SELECT l.AD_Language,t.AD_Tab_ID, t.Help,t.CommitWarning,t.Name,t.Description, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Tab t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Tab_ID=200095 AND NOT EXISTS (SELECT * FROM AD_Tab_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Tab_ID=t.AD_Tab_ID) +; + +-- Jun 13, 2013 10:00:58 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,SeqNo,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,AD_Field_UU,IsDisplayed,IsFieldOnly,UpdatedBy,AD_Org_ID,Created,CreatedBy,Updated,IsActive,IsDisplayedGrid,SeqNoGrid,XPosition,IsQuickEntry,AD_Client_ID,ColumnSpan,NumLines) VALUES ('N',200095,14,'N','N',7052,10,'Y',202185,'N','City in a country','D','City','City','aa6f52b3-f6a0-4160-ae1a-da47af9d82f4','N','N',100,0,TO_TIMESTAMP('2013-06-13 10:00:57','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2013-06-13 10:00:57','YYYY-MM-DD HH24:MI:SS'),'Y','N',10,1,'N',0,2,1) +; + +-- Jun 13, 2013 10:00:58 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=202185 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jun 13, 2013 10:00:58 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,SeqNo,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,AD_Field_UU,IsDisplayed,IsFieldOnly,UpdatedBy,AD_Org_ID,Created,CreatedBy,Updated,IsActive,IsDisplayedGrid,SeqNoGrid,XPosition,IsQuickEntry,AD_Client_ID,ColumnSpan,NumLines) VALUES ('N',200095,14,'N','N',1107,20,'Y',202186,'Y','A Client is a company or a legal entity. You cannot share data between Clients. Tenant is a synonym for Client.','D','Client/Tenant for this installation.','Client','fe8af11f-7c8e-48d4-9eb8-b54f2f21d2b0','Y','N',100,0,TO_TIMESTAMP('2013-06-13 10:00:58','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2013-06-13 10:00:58','YYYY-MM-DD HH24:MI:SS'),'Y','Y',20,1,'N',0,2,1) +; + +-- Jun 13, 2013 10:00:58 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=202186 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jun 13, 2013 10:00:59 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,SeqNo,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,AD_Field_UU,IsDisplayed,IsFieldOnly,UpdatedBy,AD_Org_ID,Created,CreatedBy,Updated,IsActive,IsDisplayedGrid,SeqNoGrid,XPosition,IsQuickEntry,AD_Client_ID,ColumnSpan,NumLines) VALUES ('N',200095,14,'Y','N',1108,30,'Y',202187,'N','An organization is a unit of your client or legal entity - examples are store, department. You can share data between organizations.','D','Organizational entity within client','Organization','36b92d99-2c21-4a03-b9fa-9e704593ef6e','Y','N',100,0,TO_TIMESTAMP('2013-06-13 10:00:58','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2013-06-13 10:00:58','YYYY-MM-DD HH24:MI:SS'),'Y','Y',30,4,'N',0,2,1) +; + +-- Jun 13, 2013 10:00:59 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=202187 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jun 13, 2013 10:00:59 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,SeqNo,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,AD_Field_UU,IsDisplayed,IsFieldOnly,UpdatedBy,AD_Org_ID,Created,CreatedBy,Updated,IsActive,IsDisplayedGrid,SeqNoGrid,XPosition,IsQuickEntry,AD_Client_ID,ColumnSpan,NumLines) VALUES ('N',200095,14,'N','N',7057,40,'Y',202188,'Y','The Country defines a Country. Each Country must be defined before it can be used in any document.','D','Country ','Country','f9bd6fb5-c072-4344-9dd8-03f8329fe789','Y','N',100,0,TO_TIMESTAMP('2013-06-13 10:00:59','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2013-06-13 10:00:59','YYYY-MM-DD HH24:MI:SS'),'Y','Y',40,1,'N',0,2,1) +; + +-- Jun 13, 2013 10:00:59 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=202188 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jun 13, 2013 10:01:00 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,SeqNo,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,AD_Field_UU,IsDisplayed,IsFieldOnly,UpdatedBy,AD_Org_ID,Created,CreatedBy,Updated,IsActive,IsDisplayedGrid,SeqNoGrid,XPosition,IsQuickEntry,AD_Client_ID,ColumnSpan,NumLines) VALUES ('N',200095,14,'Y','N',7053,50,'Y',202189,'N','The Region identifies a unique Region for this Country.','D','Identifies a geographical Region','Region','86b81f79-8fc7-4ee1-8d14-c1b5b5ec72f0','Y','N',100,0,TO_TIMESTAMP('2013-06-13 10:00:59','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2013-06-13 10:00:59','YYYY-MM-DD HH24:MI:SS'),'Y','Y',50,4,'N',0,2,1) +; + +-- Jun 13, 2013 10:01:00 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=202189 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jun 13, 2013 10:01:00 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field (SortNo,IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,SeqNo,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,AD_Field_UU,IsDisplayed,IsFieldOnly,UpdatedBy,AD_Org_ID,Created,CreatedBy,Updated,IsActive,IsDisplayedGrid,SeqNoGrid,XPosition,IsQuickEntry,AD_Client_ID,ColumnSpan,NumLines) VALUES (1,'N',200095,60,'N','N',1233,60,'Y',202190,'N','The name of an entity (record) is used as an default search option in addition to the search key. The name is up to 60 characters in length.','D','Alphanumeric identifier of the entity','Name','4941981e-61fb-489a-89bc-79760dc2362d','Y','N',100,0,TO_TIMESTAMP('2013-06-13 10:01:00','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2013-06-13 10:01:00','YYYY-MM-DD HH24:MI:SS'),'Y','Y',60,1,'N',0,5,1) +; + +-- Jun 13, 2013 10:01:00 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=202190 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jun 13, 2013 10:01:01 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,SeqNo,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,AD_Field_UU,IsDisplayed,IsFieldOnly,UpdatedBy,AD_Org_ID,Created,CreatedBy,Updated,IsActive,IsDisplayedGrid,SeqNoGrid,XPosition,IsQuickEntry,AD_Client_ID,ColumnSpan,NumLines) VALUES ('N',200095,1,'N','N',1109,70,'Y',202191,'N','There are two methods of making records unavailable in the system: One is to delete the record, the other is to de-activate the record. A de-activated record is not available for selection, but available for reports. +There are two reasons for de-activating and not deleting records: +(1) The system requires the record for audit purposes. +(2) The record is referenced by other records. E.g., you cannot delete a Business Partner, if there are invoices for this partner record existing. You de-activate the Business Partner and prevent that this record is used for future entries.','D','The record is active in the system','Active','2b497371-c40f-4236-8afa-f2431b121ca2','Y','N',100,0,TO_TIMESTAMP('2013-06-13 10:01:00','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2013-06-13 10:01:00','YYYY-MM-DD HH24:MI:SS'),'Y','Y',70,2,'N',0,2,1) +; + +-- Jun 13, 2013 10:01:01 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=202191 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jun 13, 2013 10:01:02 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,SeqNo,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,AD_Field_UU,IsDisplayed,IsFieldOnly,UpdatedBy,AD_Org_ID,Created,CreatedBy,Updated,IsActive,IsDisplayedGrid,SeqNoGrid,XPosition,IsQuickEntry,AD_Client_ID,ColumnSpan,NumLines) VALUES ('N',200095,11,'N','N',7051,80,'Y',202192,'N','The Postal Code or ZIP identifies the postal code for this entity''s address.','D','Postal code','ZIP','c6408f16-0fa3-4b77-94f1-6a1d162a0f3f','Y','N',100,0,TO_TIMESTAMP('2013-06-13 10:01:01','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2013-06-13 10:01:01','YYYY-MM-DD HH24:MI:SS'),'Y','Y',80,1,'N',0,2,1) +; + +-- Jun 13, 2013 10:01:02 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=202192 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jun 13, 2013 10:01:02 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,SeqNo,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,AD_Field_UU,IsDisplayed,IsFieldOnly,UpdatedBy,AD_Org_ID,Created,CreatedBy,Updated,IsActive,IsDisplayedGrid,SeqNoGrid,XPosition,IsQuickEntry,AD_Client_ID,ColumnSpan,NumLines) VALUES ('N',200095,11,'Y','N',7055,90,'Y',202193,'N','Phone Area Code','D','Phone Area Code','Area Code','3aaaa4ed-885b-4670-9f71-87e14cc278c4','Y','N',100,0,TO_TIMESTAMP('2013-06-13 10:01:02','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2013-06-13 10:01:02','YYYY-MM-DD HH24:MI:SS'),'Y','Y',90,4,'N',0,2,1) +; + +-- Jun 13, 2013 10:01:02 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=202193 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jun 13, 2013 10:01:03 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,SeqNo,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,AD_Field_UU,IsDisplayed,IsFieldOnly,UpdatedBy,AD_Org_ID,Created,CreatedBy,Updated,IsActive,IsDisplayedGrid,SeqNoGrid,XPosition,IsQuickEntry,AD_Client_ID,ColumnSpan,NumLines) VALUES ('N',200095,11,'N','N',7054,100,'Y',202194,'N','UN/Locode is a combination of a 2-character country code and a 3-character location code, e.g. BEANR is known as the city of Antwerp (ANR) which is located in Belgium (BE). +

See: http://www.unece.org/cefact/locode/service/main.htm','D','Location code - UN/LOCODE ','Locode','76ff8f96-236f-4977-bd43-7f9c3a613be5','Y','N',100,0,TO_TIMESTAMP('2013-06-13 10:01:02','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2013-06-13 10:01:02','YYYY-MM-DD HH24:MI:SS'),'Y','Y',100,1,'N',0,2,1) +; + +-- Jun 13, 2013 10:01:03 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=202194 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jun 13, 2013 10:01:03 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field (IsEncrypted,AD_Tab_ID,DisplayLength,IsSameLine,IsHeading,AD_Column_ID,SeqNo,IsCentrallyMaintained,AD_Field_ID,IsReadOnly,Help,EntityType,Description,Name,AD_Field_UU,IsDisplayed,IsFieldOnly,UpdatedBy,AD_Org_ID,Created,CreatedBy,Updated,IsActive,IsDisplayedGrid,SeqNoGrid,XPosition,IsQuickEntry,AD_Client_ID,ColumnSpan,NumLines) VALUES ('N',200095,15,'Y','N',7056,110,'Y',202195,'N','This column contains the geographical coordinates (latitude/longitude) of the location.

+In order to avoid unnecessary use of non-standard characters and space, the following standard presentation is used:
+0000N 00000W 0000S 00000E
+where the two last digits refer to minutes and the two or three first digits indicate the degrees','D','Location coordinate','Coordinates','cd58632f-e015-4439-9807-feed94a0be2e','Y','N',100,0,TO_TIMESTAMP('2013-06-13 10:01:03','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2013-06-13 10:01:03','YYYY-MM-DD HH24:MI:SS'),'Y','Y',110,4,'N',0,2,1) +; + +-- Jun 13, 2013 10:01:03 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Help,Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy,AD_Field_Trl_UU ) SELECT l.AD_Language,t.AD_Field_ID, t.Help,t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy,Generate_UUID() FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=202195 AND NOT EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language=l.AD_Language AND tt.AD_Field_ID=t.AD_Field_ID) +; + +-- Jun 13, 2013 10:01:43 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +UPDATE AD_Field SET IsReadOnly='Y', DefaultValue='-1',Updated=TO_TIMESTAMP('2013-06-13 10:01:43','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=202189 +; + +-- Jun 13, 2013 10:07:08 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +UPDATE AD_Tab SET WhereClause='C_Region_ID IS NULL AND C_Country_ID = @C_Country_ID@',Updated=TO_TIMESTAMP('2013-06-13 10:07:08','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=200095 +; + + +-- Jun 13, 2013 10:40:56 AM COT +-- IDEMPIERE-978 Creating cities is assigning wrong region +UPDATE AD_Tab SET AD_Column_ID=7057, TabLevel=1,Updated=TO_TIMESTAMP('2013-06-13 10:40:56','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=200095 +; + + +SELECT register_migration_script('20130613110000_IDEMPIERE-978.sql') FROM dual +; + diff --git a/migration/i1.0b-release/postgresql/201306131356_IDEMPIERE-974.sql b/migration/i1.0b-release/postgresql/201306131356_IDEMPIERE-974.sql new file mode 100644 index 0000000000..8479cc6b60 --- /dev/null +++ b/migration/i1.0b-release/postgresql/201306131356_IDEMPIERE-974.sql @@ -0,0 +1,8 @@ +-- Jun 13, 2013 1:55:56 PM COT +-- IDEMPIERE-975 Issue in populating BP location for new sales order +UPDATE AD_Message SET MsgText='Please fill in required data for:', Value='FillMinimumInfo',Updated=TO_TIMESTAMP('2013-06-13 13:55:56','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Message_ID=200180 +; + +SELECT register_migration_script('201306131356_IDEMPIERE-974.sql') FROM dual +; + diff --git a/org.adempiere.base/src/org/compiere/model/GridTable.java b/org.adempiere.base/src/org/compiere/model/GridTable.java index ab1c166058..39f557504f 100644 --- a/org.adempiere.base/src/org/compiere/model/GridTable.java +++ b/org.adempiere.base/src/org/compiere/model/GridTable.java @@ -2844,7 +2844,8 @@ public class GridTable extends AbstractTableModel } // update buffer - setDataAtRow(row, rowDataDB); + if (rowDataDB!=null) + setDataAtRow(row, rowDataDB); // info m_rowData = null; m_changed = false; diff --git a/org.adempiere.base/src/org/compiere/model/MAttributeSet.java b/org.adempiere.base/src/org/compiere/model/MAttributeSet.java index be02f0ae70..234badba8a 100644 --- a/org.adempiere.base/src/org/compiere/model/MAttributeSet.java +++ b/org.adempiere.base/src/org/compiere/model/MAttributeSet.java @@ -41,8 +41,7 @@ public class MAttributeSet extends X_M_AttributeSet /** * */ - private static final long serialVersionUID = -2703536167929259405L; - + private static final long serialVersionUID = -187568054160926817L; /** * Get MAttributeSet from Cache @@ -210,13 +209,40 @@ public class MAttributeSet extends X_M_AttributeSet } // isMandatoryShipping /** - * Exclude entry + * Exclude column entry * @param AD_Column_ID column * @param isSOTrx sales order * @return true if excluded */ public boolean excludeEntry (int AD_Column_ID, boolean isSOTrx) { + MColumn column = MColumn.get(getCtx(), AD_Column_ID); + return excludeTableEntry(column.getAD_Table_ID(), isSOTrx); + } // excludeEntry + + /** + * Exclude table entry + * @param AD_Table_ID column + * @param isSOTrx sales order + * @return true if excluded + */ + public boolean excludeTableEntry (int AD_Table_ID, boolean isSOTrx) + { + loadExcludes(); + // Find it + if (m_excludes != null && m_excludes.length > 0) + { + for (int i = 0; i < m_excludes.length; i++) + { + if (m_excludes[i].getAD_Table_ID() == AD_Table_ID + && m_excludes[i].isSOTrx() == isSOTrx) + return true; + } + } + return false; + } // excludeTableEntry + + private void loadExcludes() { if (m_excludes == null) { final String whereClause = X_M_AttributeSetExclude.COLUMNNAME_M_AttributeSet_ID+"=?"; @@ -227,19 +253,7 @@ public class MAttributeSet extends X_M_AttributeSet m_excludes = new X_M_AttributeSetExclude[list.size ()]; list.toArray (m_excludes); } - // Find it - if (m_excludes != null && m_excludes.length > 0) - { - MColumn column = MColumn.get(getCtx(), AD_Column_ID); - for (int i = 0; i < m_excludes.length; i++) - { - if (m_excludes[i].getAD_Table_ID() == column.getAD_Table_ID() - && m_excludes[i].isSOTrx() == isSOTrx) - return true; - } - } - return false; - } // excludeEntry + } /** * Exclude Lot creation diff --git a/org.adempiere.base/src/org/compiere/model/MInOut.java b/org.adempiere.base/src/org/compiere/model/MInOut.java index 3439a78d8e..2180842ddb 100644 --- a/org.adempiere.base/src/org/compiere/model/MInOut.java +++ b/org.adempiere.base/src/org/compiere/model/MInOut.java @@ -1186,9 +1186,11 @@ public class MInOut extends X_M_InOut implements DocAction continue; if (product != null && product.isASIMandatory(isSOTrx())) { - m_processMsg = "@M_AttributeSet_ID@ @IsMandatory@ (@Line@ #" + lines[i].getLine() + - ", @M_Product_ID@=" + product.getValue() + ")"; - return DocAction.STATUS_Invalid; + if (! product.getAttributeSet().excludeTableEntry(MInOutLine.Table_ID, isSOTrx())) { + m_processMsg = "@M_AttributeSet_ID@ @IsMandatory@ (@Line@ #" + lines[i].getLine() + + ", @M_Product_ID@=" + product.getValue() + ")"; + return DocAction.STATUS_Invalid; + } } } setVolume(Volume); diff --git a/org.adempiere.base/src/org/compiere/model/MInventoryLine.java b/org.adempiere.base/src/org/compiere/model/MInventoryLine.java index 34270120eb..5badb4c46a 100644 --- a/org.adempiere.base/src/org/compiere/model/MInventoryLine.java +++ b/org.adempiere.base/src/org/compiere/model/MInventoryLine.java @@ -260,7 +260,7 @@ public class MInventoryLine extends X_M_InventoryLine log.saveError("ParentComplete", Msg.translate(getCtx(), "M_InventoryLine")); return false; } - if (newRecord && m_isManualEntry) + if (m_isManualEntry) { // Product requires ASI if (getM_AttributeSetInstance_ID() == 0) @@ -268,11 +268,13 @@ public class MInventoryLine extends X_M_InventoryLine MProduct product = MProduct.get(getCtx(), getM_Product_ID()); if (product != null && product.isASIMandatory(isSOTrx())) { - log.saveError("FillMandatory", Msg.getElement(getCtx(), COLUMNNAME_M_AttributeSetInstance_ID)); - return false; + if (! product.getAttributeSet().excludeTableEntry(MInventoryLine.Table_ID, isSOTrx())) { + log.saveError("FillMandatory", Msg.getElement(getCtx(), COLUMNNAME_M_AttributeSetInstance_ID)); + return false; + } } } // No ASI - } // new or manual + } // manual // Set Line No if (getLine() == 0) @@ -423,12 +425,10 @@ public class MInventoryLine extends X_M_InventoryLine * @return true if is internal use inventory */ public boolean isInternalUseInventory() { - /* TODO: need to add M_Inventory.IsInternalUseInventory flag - see FR [ 1879029 ] Added IsInternalUseInventory flag to M_Inventory table - MInventory parent = getParent(); - return parent != null && parent.isInternalUseInventory(); - */ - return getQtyInternalUse().signum() != 0; + // IDEMPIERE-675 + MDocType dt = MDocType.get(getCtx(), getParent().getC_DocType_ID()); + String docSubTypeInv = dt.getDocSubTypeInv(); + return (MDocType.DOCSUBTYPEINV_InternalUseInventory.equals(docSubTypeInv)); } /** diff --git a/org.adempiere.base/src/org/compiere/model/MMovementLine.java b/org.adempiere.base/src/org/compiere/model/MMovementLine.java index b47398df55..05c063fc08 100644 --- a/org.adempiere.base/src/org/compiere/model/MMovementLine.java +++ b/org.adempiere.base/src/org/compiere/model/MMovementLine.java @@ -211,9 +211,11 @@ public class MMovementLine extends X_M_MovementLine // Mandatory Instance MProduct product = getProduct(); if (getM_AttributeSetInstance_ID() == 0) { - if (product != null && product.isASIMandatory(false)) { - log.saveError("FillMandatory", Msg.getElement(getCtx(), COLUMNNAME_M_AttributeSetInstance_ID)); - return false; + if (product != null && product.isASIMandatory(true)) { + if (! product.getAttributeSet().excludeTableEntry(MMovementLine.Table_ID, true /*outgoing*/)) { + log.saveError("FillMandatory", Msg.getElement(getCtx(), COLUMNNAME_M_AttributeSetInstance_ID)); + return false; + } } } if (getM_AttributeSetInstanceTo_ID() == 0) @@ -225,10 +227,12 @@ public class MMovementLine extends X_M_MovementLine setM_AttributeSetInstanceTo_ID(getM_AttributeSetInstance_ID()); } - if (product != null && product.isASIMandatory(true) && getM_AttributeSetInstanceTo_ID() == 0) + if (product != null && product.isASIMandatory(false) && getM_AttributeSetInstanceTo_ID() == 0) { - log.saveError("FillMandatory", Msg.getElement(getCtx(), COLUMNNAME_M_AttributeSetInstanceTo_ID)); - return false; + if (! product.getAttributeSet().excludeTableEntry(MMovementLine.Table_ID, false /*incoming*/)) { + log.saveError("FillMandatory", Msg.getElement(getCtx(), COLUMNNAME_M_AttributeSetInstanceTo_ID)); + return false; + } } } // ASI diff --git a/org.adempiere.base/src/org/compiere/model/MOrder.java b/org.adempiere.base/src/org/compiere/model/MOrder.java index e71c3fcf75..aa6eee8924 100644 --- a/org.adempiere.base/src/org/compiere/model/MOrder.java +++ b/org.adempiere.base/src/org/compiere/model/MOrder.java @@ -1310,19 +1310,21 @@ public class MOrder extends X_C_Order implements DocAction } // convert DocType // Mandatory Product Attribute Set Instance - String mandatoryType = "='Y'"; // IN ('Y','S') - String sql = "SELECT COUNT(*) " - + "FROM C_OrderLine ol" - + " INNER JOIN M_Product p ON (ol.M_Product_ID=p.M_Product_ID)" - + " INNER JOIN M_AttributeSet pas ON (p.M_AttributeSet_ID=pas.M_AttributeSet_ID) " - + "WHERE pas.MandatoryType" + mandatoryType - + " AND (ol.M_AttributeSetInstance_ID is NULL OR ol.M_AttributeSetInstance_ID = 0)" - + " AND ol.C_Order_ID=?"; - int no = DB.getSQLValue(get_TrxName(), sql, getC_Order_ID()); - if (no != 0) - { - m_processMsg = "@LinesWithoutProductAttribute@ (" + no + ")"; - return DocAction.STATUS_Invalid; + for (MOrderLine line : getLines()) { + if (line.getM_Product_ID() > 0 && line.getM_AttributeSetInstance_ID() == 0) { + MProduct product = line.getProduct(); + if (product.isASIMandatory(isSOTrx())) { + if (! product.getAttributeSet().excludeTableEntry(MOrderLine.Table_ID, isSOTrx())) { + StringBuilder msg = new StringBuilder("@M_AttributeSet_ID@ @IsMandatory@ (@Line@ #") + .append(line.getLine()) + .append(", @M_Product_ID@=") + .append(product.getValue()) + .append(")"); + m_processMsg = msg.toString(); + return DocAction.STATUS_Invalid; + } + } + } } // Lines diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/ADSortTab.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/ADSortTab.java index d0b64c9f93..83e348ad01 100644 --- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/ADSortTab.java +++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/ADSortTab.java @@ -1000,7 +1000,7 @@ public class ADSortTab extends Panel implements IADTabpanel yesModel.removeAllElements(); noModel.removeAllElements(); - setIsChanged(false); + //setIsChanged(false); bAdd.setEnabled(false); bRemove.setEnabled(false); bUp.setEnabled(false); diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/AbstractADWindowContent.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/AbstractADWindowContent.java index 84c0305be4..1602482b63 100644 --- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/AbstractADWindowContent.java +++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/AbstractADWindowContent.java @@ -1441,7 +1441,7 @@ public abstract class AbstractADWindowContent extends AbstractUIPart implements // // No Rows - if (e.getTotalRows() == 0 && insertRecord && !detailTab) + if (e.getTotalRows() == 0 && insertRecord && !detailTab && !tabPanel.getGridTab().isSortTab()) { toolbar.enableNew(true); toolbar.enableDelete(false); diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/CompositeADTabbox.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/CompositeADTabbox.java index e8a283b252..05c260819c 100644 --- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/CompositeADTabbox.java +++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/CompositeADTabbox.java @@ -687,6 +687,8 @@ public class CompositeADTabbox extends AbstractADTabbox IADTabpanel detailPanel = getSelectedDetailADTabpanel(); if (detailPanel != null) { detailPanel.getGridTab().dataIgnore(); + if (detailPanel.getGridTab().isSortTab()) + detailPanel.activate(true); } headerTab.getGridTab().dataIgnore(); } diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/DetailPane.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/DetailPane.java index a09a61d695..18354c05ab 100644 --- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/DetailPane.java +++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/adwindow/DetailPane.java @@ -532,7 +532,7 @@ public class DetailPane extends Panel implements EventListener, IdSpace { Toolbar toolbar = (Toolbar) tabpanel.getFirstChild(); IADTabpanel adtab = getADTabpanel(index); - if (adtab.getGridTab().isSortTab()) + if (adtab!=null && adtab.getGridTab().isSortTab()) readOnly = true; boolean insertRecord = !readOnly; diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/HelpController.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/HelpController.java index f0bb4c7c5e..1de491c144 100644 --- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/HelpController.java +++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/panel/HelpController.java @@ -171,6 +171,8 @@ public class HelpController sb.append("\n\n

\n"); String ctxHelpMsg = getCtxHelpMsgList(ctxType, recordId); + String helpMsg, nameMsg, descMsg; + if (ctxHelpMsg.length() > 0) sb.append(stripHtml(ctxHelpMsg, false) + "
\n"); else @@ -180,58 +182,145 @@ public class HelpController if (ctxType.equals(X_AD_CtxHelp.CTXTYPE_Tab)) { MTab tab = new MTab(Env.getCtx(), recordId, null); - if (tab != null && tab.getName() != null && tab.getName().length() != 0) - { - sb.append("

\n" + tab.getName() + ""); - - if (tab.getDescription() != null && tab.getDescription().length() != 0) - sb.append("

\n" + tab.getDescription() + ""); - - if (tab.getHelp() != null && tab.getHelp().length() != 0) - sb.append("

\n" + tab.getHelp()); - } + if (!Env.isBaseLanguage(Env.getCtx(), "AD_Tab")) { + + nameMsg = tab.get_Translation("Name"); + if (tab != null && nameMsg != null && nameMsg.length() != 0) + sb.append("

\n" + nameMsg + ""); + + descMsg = tab.get_Translation("Description"); + if (descMsg != null && descMsg.length() != 0) + sb.append("

\n" + descMsg + ""); + + helpMsg = tab.get_Translation("Help"); + if (helpMsg != null && helpMsg.length() != 0) + sb.append("

\n" + helpMsg); + + } + + else { + if (tab != null && tab.getName() != null + && tab.getName().length() != 0) { + sb.append("

\n" + tab.getName() + ""); + + if (tab.getDescription() != null + && tab.getDescription().length() != 0) + sb.append("

\n" + tab.getDescription() + + ""); + + if (tab.getHelp() != null + && tab.getHelp().length() != 0) + sb.append("

\n" + tab.getHelp()); + } + } } else if (ctxType.equals(X_AD_CtxHelp.CTXTYPE_Process)) { MProcess process = new MProcess(Env.getCtx(), recordId, null); - if (process != null && process.getName() != null && process.getName().length() != 0) - { - sb.append("

\n" + process.getName() + ""); - - if (process.getDescription() != null && process.getDescription().length() != 0) - sb.append("

\n" + process.getDescription() + ""); - - if (process.getHelp() != null && process.getHelp().length() != 0) - sb.append("

\n" + process.getHelp()); - } + if (!Env.isBaseLanguage(Env.getCtx(), "AD_Process")) { + + nameMsg = process.get_Translation("Name"); + if (process != null && nameMsg != null + && nameMsg.length() != 0) + sb.append("

\n" + nameMsg + ""); + + descMsg = process.get_Translation("Description"); + if (descMsg != null && descMsg.length() != 0) + sb.append("

\n" + descMsg + ""); + + helpMsg = process.get_Translation("Help"); + if (helpMsg != null && helpMsg.length() != 0) + sb.append("

\n" + helpMsg); + + } else { + + if (process != null && process.getName() != null + && process.getName().length() != 0) + sb.append("

\n" + process.getName() + ""); + + if (process.getDescription() != null + && process.getDescription().length() != 0) + sb.append("

\n" + process.getDescription() + + ""); + + if (process.getHelp() != null + && process.getHelp().length() != 0) + sb.append("

\n" + process.getHelp()); + + } + } else if (ctxType.equals(X_AD_CtxHelp.CTXTYPE_Form)) { MForm form = new MForm(Env.getCtx(), recordId, null); - if (form != null && form.getName() != null && form.getName().length() != 0) - { - sb.append("

\n" + form.getName() + ""); - - if (form.getDescription() != null && form.getDescription().length() != 0) - sb.append("

\n" + form.getDescription() + ""); - - if (form.getHelp() != null && form.getHelp().length() != 0) - sb.append("

\n" + form.getHelp()); - } + if (!Env.isBaseLanguage(Env.getCtx(), "AD_Form")) { + + nameMsg = form.get_Translation("Name"); + + if (form != null && nameMsg != null + && nameMsg.length() != 0) + sb.append("

\n" + nameMsg + ""); + + descMsg = form.get_Translation("Description"); + if (descMsg != null && descMsg.length() != 0) + sb.append("

\n" + descMsg + ""); + + helpMsg = form.get_Translation("Help"); + if (helpMsg != null && helpMsg.length() != 0) + sb.append("

\n" + helpMsg); + + } else { + + if (form != null && form.getName() != null + && form.getName().length() != 0) { + sb.append("

\n" + form.getName() + ""); + + if (form.getDescription() != null + && form.getDescription().length() != 0) + sb.append("

\n" + form.getDescription() + + ""); + + if (form.getHelp() != null + && form.getHelp().length() != 0) + sb.append("

\n" + form.getHelp()); + } + + } } else if (ctxType.equals(X_AD_CtxHelp.CTXTYPE_Info)) { MInfoWindow info = new MInfoWindow(Env.getCtx(), recordId, null); - if (info != null && info.getName() != null && info.getName().length() != 0) - { - sb.append("

\n" + info.getName() + ""); - - if (info.getDescription() != null && info.getDescription().length() != 0) - sb.append("

\n" + info.getDescription() + ""); - - if (info.getHelp() != null && info.getHelp().length() != 0) - sb.append("

\n" + info.getHelp()); - } + if (!Env.getLoginLanguage(Env.getCtx()).isBaseLanguage()) { + + nameMsg = info.get_Translation("Name"); + if (info != null && nameMsg != null + && nameMsg.length() != 0) { + sb.append("

\n" + nameMsg + ""); + + descMsg = info.get_Translation("Description"); + if (descMsg != null && descMsg.length() != 0) + sb.append("

\n" + descMsg + ""); + + helpMsg = info.get_Translation("Help"); + if (helpMsg != null && helpMsg.length() != 0) + sb.append("

\n" + helpMsg); + + } else { + if (info != null && info.getName() != null + && info.getName().length() != 0) + sb.append("

\n" + info.getName() + ""); + + if (info.getDescription() != null + && info.getDescription().length() != 0) + sb.append("

\n" + info.getDescription() + + ""); + + if (info.getHelp() != null + && info.getHelp().length() != 0) + sb.append("

\n" + info.getHelp()); + + } + } } else if (ctxType.equals(X_AD_CtxHelp.CTXTYPE_Workflow)) {