IDEMPIERE-905 Post-it functionality / integrate from Nicolas Micoud (nmicoud)
This commit is contained in:
parent
6e4dc8a5f5
commit
a1cbcf500b
|
@ -0,0 +1,225 @@
|
||||||
|
SET SQLBLANKLINES ON
|
||||||
|
SET DEFINE OFF
|
||||||
|
|
||||||
|
-- IDEMPIERE-905 Post-it functionality
|
||||||
|
-- Nov 24, 2016 5:45:40 PM CET
|
||||||
|
INSERT INTO AD_Window (AD_Window_ID,Name,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,WindowType,Processing,EntityType,IsSOTrx,IsDefault,WinHeight,WinWidth,IsBetaFunctionality,AD_Window_UU) VALUES (200089,'Post-it',0,0,'Y',TO_DATE('2016-11-24 17:45:40','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:40','YYYY-MM-DD HH24:MI:SS'),100,'M','N','D','Y','N',0,0,'N','f892195b-f1fe-46e9-9b4e-bc76c10c6e31')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:41 PM CET
|
||||||
|
INSERT INTO AD_Table (AD_Table_ID,Name,AD_Window_ID,TableName,LoadSeq,AccessLevel,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,IsSecurityEnabled,IsDeleteable,IsHighVolume,IsView,EntityType,ImportTable,IsChangeLog,ReplicationType,CopyColumnsFromTable,IsCentrallyMaintained,AD_Table_UU,Processing) VALUES (200215,'Post-it',200089,'AD_PostIt',0,'7',0,0,'Y',TO_DATE('2016-11-24 17:45:40','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:40','YYYY-MM-DD HH24:MI:SS'),100,'N','N','N','N','D','N','N','L','N','Y','817f3e09-c45c-426c-82ae-36be50eeffa4','N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:41 PM CET
|
||||||
|
INSERT INTO AD_Sequence (Name,CurrentNext,IsAudited,StartNewYear,Description,IsActive,IsTableID,AD_Client_ID,AD_Org_ID,Created,CreatedBy,Updated,UpdatedBy,AD_Sequence_ID,IsAutoSequence,StartNo,IncrementNo,CurrentNextSys,AD_Sequence_UU) VALUES ('AD_PostIt',1000000,'N','N','Table AD_PostIt','Y','Y',0,0,TO_DATE('2016-11-24 17:45:41','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:41','YYYY-MM-DD HH24:MI:SS'),100,200279,'Y',1000000,1,200000,'15a7484a-97cf-4372-95bf-71e1b0e54b63')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:42 PM CET
|
||||||
|
INSERT INTO AD_Element (AD_Element_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,ColumnName,Name,PrintName,EntityType,AD_Element_UU) VALUES (203056,0,0,'Y',TO_DATE('2016-11-24 17:45:41','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:41','YYYY-MM-DD HH24:MI:SS'),100,'AD_Postit_ID','Post-it','Post-it','D','469aef37-8458-47d8-8c67-d437f2f008d7')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:42 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,AD_Table_ID,ColumnName,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsEncrypted,AD_Reference_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,SeqNoSelection,IsToolbarButton) VALUES (212922,0,'Post-it',200215,'AD_Postit_ID',10,'Y','N','Y','N','N',0,'N',13,0,0,'Y',TO_DATE('2016-11-24 17:45:42','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:42','YYYY-MM-DD HH24:MI:SS'),100,203056,'N','N','D','Y','N','N','Y','5cafeed3-f69a-49a7-9e55-3367f3cfa4c6','N',0,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:42 PM CET
|
||||||
|
CREATE TABLE AD_PostIt (AD_Postit_ID NUMBER(10) NOT NULL, CONSTRAINT AD_PostIt_Key PRIMARY KEY (AD_Postit_ID))
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:42 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,Description,Help,AD_Table_ID,ColumnName,DefaultValue,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsEncrypted,AD_Reference_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,SeqNoSelection,IsToolbarButton) VALUES (212923,0,'Client','Client/Tenant for this installation.','A Client is a company or a legal entity. You cannot share data between Clients. Tenant is a synonym for Client.',200215,'AD_Client_ID','@#AD_Client_ID@',10,'N','N','Y','N','N',0,'N',19,0,0,'Y',TO_DATE('2016-11-24 17:45:42','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:42','YYYY-MM-DD HH24:MI:SS'),100,102,'N','N','D','Y','N','N','Y','a3ba33e5-12cc-49b3-937d-e1556017fdfd','N',0,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:42 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD AD_Client_ID NUMBER(10) NOT NULL
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:43 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,Description,Help,AD_Table_ID,ColumnName,DefaultValue,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsEncrypted,AD_Reference_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,SeqNoSelection,IsToolbarButton) VALUES (212924,0,'Organization','Organizational entity within client','An organization is a unit of your client or legal entity - examples are store, department. You can share data between organizations.',200215,'AD_Org_ID','@AD_Org_ID@',10,'N','N','Y','N','N',0,'N',19,0,0,'Y',TO_DATE('2016-11-24 17:45:42','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:42','YYYY-MM-DD HH24:MI:SS'),100,113,'N','N','D','Y','N','N','Y','268c3174-3926-4dbd-afad-3ecdef03d19e','N',0,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:43 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD AD_Org_ID NUMBER(10) NOT NULL
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:43 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,Description,Help,AD_Table_ID,ColumnName,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsEncrypted,AD_Reference_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,SeqNoSelection,IsToolbarButton) VALUES (212925,0,'Table','Database Table information','The Database Table provides the information of the table definition',200215,'AD_Table_ID',10,'N','N','N','N','N',0,'N',30,0,0,'Y',TO_DATE('2016-11-24 17:45:43','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:43','YYYY-MM-DD HH24:MI:SS'),100,126,'Y','N','D','Y','N','N','Y','d5628cb4-04fd-4365-a0f9-f7b555ae31aa','Y',0,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:43 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD AD_Table_ID NUMBER(10) DEFAULT NULL
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:43 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,Description,Help,AD_Table_ID,ColumnName,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsEncrypted,AD_Reference_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,SeqNoSelection,IsToolbarButton) VALUES (212926,0,'Created','Date this record was created','The Created field indicates the date that this record was created.',200215,'Created',7,'N','N','Y','N','N',0,'N',16,0,0,'Y',TO_DATE('2016-11-24 17:45:43','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:43','YYYY-MM-DD HH24:MI:SS'),100,245,'N','N','D','Y','N','N','Y','aafb5372-b3c7-4360-a157-98d663fcea8c','N',0,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:43 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD Created DATE NOT NULL
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:44 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,Description,Help,AD_Table_ID,ColumnName,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsEncrypted,AD_Reference_ID,AD_Reference_Value_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,SeqNoSelection,IsToolbarButton) VALUES (212927,0,'Created By','User who created this records','The Created By field indicates the user who created this record.',200215,'CreatedBy',10,'N','N','Y','N','N',0,'N',30,110,0,0,'Y',TO_DATE('2016-11-24 17:45:44','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:44','YYYY-MM-DD HH24:MI:SS'),100,246,'N','N','D','Y','N','N','Y','c6910bd9-1cfb-46ea-ba6e-2ce622f27efc','N',0,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:44 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD CreatedBy NUMBER(10) NOT NULL
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:44 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,Description,Help,AD_Table_ID,ColumnName,DefaultValue,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsEncrypted,AD_Reference_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,SeqNoSelection,IsToolbarButton) VALUES (212928,0,'Active','The record is active in the system','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.',200215,'IsActive','Y',1,'N','N','Y','N','N',0,'N',20,0,0,'Y',TO_DATE('2016-11-24 17:45:44','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:44','YYYY-MM-DD HH24:MI:SS'),100,348,'N','N','D','Y','N','N','Y','8f113935-c0ad-4f46-ac28-27092953d5db','N',0,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:44 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD IsActive CHAR(1) DEFAULT 'Y' CHECK (IsActive IN ('Y','N')) NOT NULL
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:45 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,AD_Table_ID,ColumnName,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsEncrypted,AD_Reference_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,SeqNoSelection,IsToolbarButton) VALUES (212929,0,'Description',200215,'Text',2000,'N','N','N','N','N',0,'N',10,0,0,'Y',TO_DATE('2016-11-24 17:45:44','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:44','YYYY-MM-DD HH24:MI:SS'),100,53475,'Y','N','D','Y','N','N','Y','afcb6eb7-4141-421f-8386-ae0cd00bd832','Y',0,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:45 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD Text VARCHAR2(2000) DEFAULT NULL
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:45 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,Description,Help,AD_Table_ID,ColumnName,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsEncrypted,AD_Reference_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,SeqNoSelection,IsToolbarButton) VALUES (212930,0,'Record ID','Direct internal record ID','The Record ID is the internal unique identifier of a record. Please note that zooming to the record may not be successful for Orders, Invoices and Shipment/Receipts as sometimes the Sales Order type is not known.',200215,'Record_ID',10,'N','N','N','N','N',0,'N',28,0,0,'Y',TO_DATE('2016-11-24 17:45:45','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:45','YYYY-MM-DD HH24:MI:SS'),100,538,'Y','N','D','Y','N','N','Y','3846e3ae-5ae7-43ef-9f64-1426371d1732','Y',0,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:45 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD Record_ID NUMBER(10) DEFAULT NULL
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:46 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,Description,Help,AD_Table_ID,ColumnName,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsEncrypted,AD_Reference_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,SeqNoSelection,IsToolbarButton) VALUES (212931,0,'Updated','Date this record was updated','The Updated field indicates the date that this record was updated.',200215,'Updated',7,'N','N','Y','N','N',0,'N',16,0,0,'Y',TO_DATE('2016-11-24 17:45:45','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:45','YYYY-MM-DD HH24:MI:SS'),100,607,'Y','N','D','Y','N','N','Y','a38f1c45-13f4-491e-b897-286cc3f99131','N',0,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:46 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD Updated DATE NOT NULL
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:46 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,Description,Help,AD_Table_ID,ColumnName,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsEncrypted,AD_Reference_ID,AD_Reference_Value_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,SeqNoSelection,IsToolbarButton) VALUES (212932,0,'Updated By','User who updated this records','The Updated By field indicates the user who updated this record.',200215,'UpdatedBy',10,'N','N','Y','N','N',0,'N',30,110,0,0,'Y',TO_DATE('2016-11-24 17:45:46','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:46','YYYY-MM-DD HH24:MI:SS'),100,608,'Y','N','D','Y','N','N','Y','601e1653-02d2-40cd-8572-b87b65c7b2cd','N',0,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:46 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD UpdatedBy NUMBER(10) NOT NULL
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:47 PM CET
|
||||||
|
INSERT INTO AD_Element (AD_Element_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,ColumnName,Name,PrintName,EntityType,AD_Element_UU) VALUES (203057,0,0,'Y',TO_DATE('2016-11-24 17:45:46','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:46','YYYY-MM-DD HH24:MI:SS'),100,'AD_PostIt_UU','AD_PostIt_UU','AD_PostIt_UU','D','7a8d19a8-3e03-4c27-9c4b-2ffe32199d81')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:47 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,AD_Table_ID,ColumnName,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,IsEncrypted,AD_Reference_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,IsToolbarButton) VALUES (212933,1,'AD_PostIt_UU',200215,'AD_PostIt_UU',36,'N','N','N','N','N','N',10,0,0,'Y',TO_DATE('2016-11-24 17:45:47','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:47','YYYY-MM-DD HH24:MI:SS'),100,203057,'Y','N','D','Y','N','N','Y','ad482a89-b32e-4cba-9d95-6b79ad401fa0','N','N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:47 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD AD_PostIt_UU VARCHAR2(36) DEFAULT NULL
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:47 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD CONSTRAINT AD_PostIt_UU_idx UNIQUE (AD_PostIt_UU)
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:47 PM CET
|
||||||
|
INSERT INTO AD_Tab (AD_Tab_ID,Name,AD_Window_ID,SeqNo,IsSingleRow,AD_Table_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,HasTree,IsInfoTab,IsTranslationTab,IsReadOnly,Processing,ImportFields,TabLevel,IsSortTab,EntityType,IsInsertRecord,IsAdvancedTab,AD_Tab_UU) VALUES (200220,'Post-it',200089,10,'N',200215,0,0,'Y',TO_DATE('2016-11-24 17:45:47','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:47','YYYY-MM-DD HH24:MI:SS'),100,'N','N','N','N','N','N',0,'N','D','Y','N','715973a5-5d22-4d36-8241-6ff369cac595')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:48 PM CET
|
||||||
|
INSERT INTO AD_Field (AD_Field_ID,Name,Description,Help,AD_Tab_ID,AD_Column_ID,IsDisplayed,DisplayLength,SeqNo,IsSameLine,IsHeading,IsFieldOnly,IsEncrypted,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,IsReadOnly,IsCentrallyMaintained,EntityType,AD_Field_UU,IsDisplayedGrid,SeqNoGrid,XPosition,ColumnSpan,NumLines,IsQuickEntry) VALUES (204344,'Active','The record is active in the system','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.',200220,212928,'N',1,0,'N','N','N','N',0,0,'Y',TO_DATE('2016-11-24 17:45:47','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:47','YYYY-MM-DD HH24:MI:SS'),100,'N','Y','D','a697ef4c-a87e-42b4-8d93-338ec0e65df8','N',0,1,1,1,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:48 PM CET
|
||||||
|
INSERT INTO AD_Field (AD_Field_ID,Name,Description,Help,AD_Tab_ID,AD_Column_ID,IsDisplayed,DisplayLength,SeqNo,IsSameLine,IsHeading,IsFieldOnly,IsEncrypted,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,IsReadOnly,IsCentrallyMaintained,EntityType,AD_Field_UU,IsDisplayedGrid,SeqNoGrid,XPosition,ColumnSpan,NumLines,IsQuickEntry) VALUES (204345,'Client','Client/Tenant for this installation.','A Client is a company or a legal entity. You cannot share data between Clients. Tenant is a synonym for Client.',200220,212923,'Y',10,10,'N','N','N','N',0,0,'Y',TO_DATE('2016-11-24 17:45:48','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:48','YYYY-MM-DD HH24:MI:SS'),100,'N','Y','D','f63b0185-31a4-42a8-8102-e6a26efc4673','Y',10,1,1,1,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:48 PM CET
|
||||||
|
INSERT INTO AD_Field (AD_Field_ID,Name,Description,Help,AD_Tab_ID,AD_Column_ID,IsDisplayed,DisplayLength,SeqNo,IsSameLine,IsHeading,IsFieldOnly,IsEncrypted,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,IsReadOnly,IsCentrallyMaintained,EntityType,AD_Field_UU,IsAllowCopy,IsDisplayedGrid,SeqNoGrid,XPosition,ColumnSpan,NumLines,IsQuickEntry) VALUES (204346,'Organization','Organizational entity within client','An organization is a unit of your client or legal entity - examples are store, department. You can share data between organizations.',200220,212924,'Y',10,20,'Y','N','N','N',0,0,'Y',TO_DATE('2016-11-24 17:45:48','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:48','YYYY-MM-DD HH24:MI:SS'),100,'N','Y','D','6953b9b3-d4ed-44a0-af7b-f6ffbb136d31','Y','Y',20,1,1,1,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:49 PM CET
|
||||||
|
INSERT INTO AD_Field (AD_Field_ID,Name,Description,Help,AD_Tab_ID,AD_Column_ID,IsDisplayed,DisplayLength,SeqNo,IsSameLine,IsHeading,IsFieldOnly,IsEncrypted,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,IsReadOnly,IsCentrallyMaintained,EntityType,AD_Field_UU,IsDisplayedGrid,SeqNoGrid,XPosition,ColumnSpan,NumLines,IsQuickEntry) VALUES (204347,'Table','Database Table information','The Database Table provides the information of the table definition',200220,212925,'Y',10,30,'N','N','N','N',0,0,'Y',TO_DATE('2016-11-24 17:45:48','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:48','YYYY-MM-DD HH24:MI:SS'),100,'N','Y','D','23249d8e-93d2-403e-9425-5a48198bada3','Y',30,1,1,1,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:49 PM CET
|
||||||
|
INSERT INTO AD_Field (AD_Field_ID,Name,Description,Help,AD_Tab_ID,AD_Column_ID,IsDisplayed,DisplayLength,SeqNo,IsSameLine,IsHeading,IsFieldOnly,IsEncrypted,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,IsReadOnly,IsCentrallyMaintained,EntityType,AD_Field_UU,IsDisplayedGrid,SeqNoGrid,XPosition,ColumnSpan,NumLines,IsQuickEntry) VALUES (204348,'Record ID','Direct internal record ID','The Record ID is the internal unique identifier of a record. Please note that zooming to the record may not be successful for Orders, Invoices and Shipment/Receipts as sometimes the Sales Order type is not known.',200220,212930,'Y',10,40,'N','N','N','N',0,0,'Y',TO_DATE('2016-11-24 17:45:49','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:49','YYYY-MM-DD HH24:MI:SS'),100,'N','Y','D','aa0d4cc6-00b3-4df7-bf98-cd5cc4b288fe','Y',40,1,1,1,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:50 PM CET
|
||||||
|
INSERT INTO AD_Field (AD_Field_ID,Name,AD_Tab_ID,AD_Column_ID,IsDisplayed,DisplayLength,SeqNo,IsSameLine,IsHeading,IsFieldOnly,IsEncrypted,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,IsReadOnly,IsCentrallyMaintained,EntityType,AD_Field_UU,IsDisplayedGrid,SeqNoGrid,XPosition,ColumnSpan,NumLines,IsQuickEntry) VALUES (204349,'Description',200220,212929,'Y',2000,50,'N','N','N','N',0,0,'Y',TO_DATE('2016-11-24 17:45:49','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:49','YYYY-MM-DD HH24:MI:SS'),100,'N','Y','D','a72006bb-ed45-4988-9b92-1203f1e7950a','Y',50,1,1,1,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:50 PM CET
|
||||||
|
INSERT INTO AD_Field (AD_Field_ID,Name,AD_Tab_ID,AD_Column_ID,IsDisplayed,DisplayLength,IsSameLine,IsHeading,IsFieldOnly,IsEncrypted,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,IsReadOnly,IsCentrallyMaintained,EntityType,AD_Field_UU,IsDisplayedGrid,XPosition,ColumnSpan,NumLines,IsQuickEntry) VALUES (204350,'Post-it',200220,212922,'N',10,'N','N','N','N',0,0,'Y',TO_DATE('2016-11-24 17:45:50','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:50','YYYY-MM-DD HH24:MI:SS'),100,'N','Y','D','458b8179-2e74-4b75-ba2e-ae19587ba6b3','N',1,1,1,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:50 PM CET
|
||||||
|
INSERT INTO AD_Message (MsgType,MsgText,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Message_ID,Value,EntityType,AD_Message_UU) VALUES ('I','Post-it',0,0,'Y',TO_DATE('2016-11-24 17:45:50','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:50','YYYY-MM-DD HH24:MI:SS'),100,200411,'PostIt','D','1b48e86b-6fb8-4e45-961b-0c8a9611339f')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:51 PM CET
|
||||||
|
INSERT INTO AD_Message (MsgType,MsgText,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Message_ID,Value,EntityType,AD_Message_UU) VALUES ('I','Created by {0} / {1}',0,0,'Y',TO_DATE('2016-11-24 17:45:50','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:50','YYYY-MM-DD HH24:MI:SS'),100,200412,'PostItCreated','D','1f0e605a-c851-4786-a5b4-de63ad980ee5')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:51 PM CET
|
||||||
|
INSERT INTO AD_Message (MsgType,MsgText,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Message_ID,Value,EntityType,AD_Message_UU) VALUES ('I','Updated by {0} / {1}',0,0,'Y',TO_DATE('2016-11-24 17:45:51','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:51','YYYY-MM-DD HH24:MI:SS'),100,200413,'PostItUpdated','D','575b0ae3-81b3-4d36-97ab-8c636957f74c')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:51 PM CET
|
||||||
|
INSERT INTO AD_Menu (AD_Menu_ID,Name,Action,AD_Window_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,IsSummary,IsSOTrx,IsReadOnly,EntityType,IsCentrallyMaintained,AD_Menu_UU) VALUES (200144,'Post-it','W',200089,0,0,'Y',TO_DATE('2016-11-24 17:45:51','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2016-11-24 17:45:51','YYYY-MM-DD HH24:MI:SS'),100,'N','N','N','D','Y','1262283c-4b52-4a6f-976c-09213d27b0e5')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:51 PM CET
|
||||||
|
INSERT INTO AD_TREENODEMM(AD_Client_ID, AD_Org_ID, CreatedBy, UpdatedBy, Parent_ID, SeqNo, AD_Tree_ID, Node_ID)VALUES(0, 0, 0, 0, 566,0, 10, 200144)
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:52 PM CET
|
||||||
|
UPDATE AD_Column SET FKConstraintName='ADClient_ADPostIt', FKConstraintType='N',Updated=TO_DATE('2016-11-24 17:45:52','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=212923
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:52 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD CONSTRAINT ADClient_ADPostIt FOREIGN KEY (AD_Client_ID) REFERENCES ad_client(ad_client_id) DEFERRABLE INITIALLY DEFERRED
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:52 PM CET
|
||||||
|
UPDATE AD_Column SET FKConstraintName='ADOrg_ADPostIt', FKConstraintType='N',Updated=TO_DATE('2016-11-24 17:45:52','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=212924
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:52 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD CONSTRAINT ADOrg_ADPostIt FOREIGN KEY (AD_Org_ID) REFERENCES ad_org(ad_org_id) DEFERRABLE INITIALLY DEFERRED
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:52 PM CET
|
||||||
|
UPDATE AD_Column SET FKConstraintName='ADTable_ADPostIt', FKConstraintType='N',Updated=TO_DATE('2016-11-24 17:45:52','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=212925
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:52 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD CONSTRAINT ADTable_ADPostIt FOREIGN KEY (AD_Table_ID) REFERENCES ad_table(ad_table_id) DEFERRABLE INITIALLY DEFERRED
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:52 PM CET
|
||||||
|
UPDATE AD_Column SET FKConstraintName='CreatedBy_ADPostIt', FKConstraintType='N',Updated=TO_DATE('2016-11-24 17:45:52','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=212927
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:52 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD CONSTRAINT CreatedBy_ADPostIt FOREIGN KEY (CreatedBy) REFERENCES ad_user(ad_user_id) DEFERRABLE INITIALLY DEFERRED
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:52 PM CET
|
||||||
|
UPDATE AD_Column SET FKConstraintName='UpdatedBy_ADPostIt', FKConstraintType='N',Updated=TO_DATE('2016-11-24 17:45:52','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=212932
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:52 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD CONSTRAINT UpdatedBy_ADPostIt FOREIGN KEY (UpdatedBy) REFERENCES ad_user(ad_user_id) DEFERRABLE INITIALLY DEFERRED
|
||||||
|
;
|
||||||
|
|
||||||
|
SELECT register_migration_script('201611241746_IDEMPIERE-905.sql') FROM dual
|
||||||
|
;
|
||||||
|
|
|
@ -0,0 +1,119 @@
|
||||||
|
SET SQLBLANKLINES ON
|
||||||
|
SET DEFINE OFF
|
||||||
|
|
||||||
|
-- IDEMPIERE-905 Post-it functionality
|
||||||
|
-- Nov 24, 2016 8:20:47 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=280,Updated=TO_DATE('2016-11-24 20:20:47','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200081
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:20:55 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=270,Updated=TO_DATE('2016-11-24 20:20:55','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200067
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:02 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=260,Updated=TO_DATE('2016-11-24 20:21:02','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200057
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:07 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=250,Updated=TO_DATE('2016-11-24 20:21:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200078
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:10 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=240,Updated=TO_DATE('2016-11-24 20:21:10','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200056
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:14 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=230,Updated=TO_DATE('2016-11-24 20:21:14','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200055
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:17 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=220,Updated=TO_DATE('2016-11-24 20:21:17','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200054
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:21 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=210,Updated=TO_DATE('2016-11-24 20:21:21','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200053
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:24 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=200,Updated=TO_DATE('2016-11-24 20:21:24','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200052
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:28 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=190,Updated=TO_DATE('2016-11-24 20:21:28','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200051
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:34 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=180,Updated=TO_DATE('2016-11-24 20:21:34','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200050
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:38 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=170,Updated=TO_DATE('2016-11-24 20:21:38','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200049
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:41 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=160,Updated=TO_DATE('2016-11-24 20:21:41','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200044
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:46 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=150,Updated=TO_DATE('2016-11-24 20:21:46','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200043
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:49 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=140,Updated=TO_DATE('2016-11-24 20:21:49','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200058
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:54 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=130,Updated=TO_DATE('2016-11-24 20:21:54','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200041
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:22:18 PM CET
|
||||||
|
INSERT INTO AD_ToolBarButton (AD_Client_ID,AD_Org_ID,Created,CreatedBy,ComponentName,IsActive,AD_ToolBarButton_ID,Name,Updated,UpdatedBy,IsCustomization,KeyStroke_KeyCode,KeyStroke_Modifiers,AD_ToolBarButton_UU,Action,SeqNo,IsAdvancedButton,IsAddSeparator) VALUES (0,0,TO_DATE('2016-11-24 20:22:17','YYYY-MM-DD HH24:MI:SS'),100,'PostIt','Y',200088,'Window - PostIt',TO_DATE('2016-11-24 20:22:17','YYYY-MM-DD HH24:MI:SS'),100,'N',0,0,'50125137-56a4-4254-a92c-59cd0867c8aa','W',120,'N','N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:23:26 PM CET
|
||||||
|
UPDATE AD_Field SET SeqNo=10, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, ColumnSpan=2, IsToolbarButton=NULL,Updated=TO_DATE('2016-11-24 20:23:26','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=204345
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:23:26 PM CET
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=20, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=4, ColumnSpan=2, IsToolbarButton=NULL,Updated=TO_DATE('2016-11-24 20:23:26','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=204346
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:23:26 PM CET
|
||||||
|
UPDATE AD_Field SET SeqNo=30, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, ColumnSpan=2, IsToolbarButton=NULL,Updated=TO_DATE('2016-11-24 20:23:26','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=204347
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:23:26 PM CET
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=40, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=5, IsToolbarButton=NULL,Updated=TO_DATE('2016-11-24 20:23:26','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=204348
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:23:26 PM CET
|
||||||
|
UPDATE AD_Field SET SeqNo=50, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, ColumnSpan=5, NumLines=10, IsToolbarButton=NULL,Updated=TO_DATE('2016-11-24 20:23:26','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=204349
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:23:26 PM CET
|
||||||
|
UPDATE AD_Field SET SeqNo=0, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_DATE('2016-11-24 20:23:26','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=204350
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:24:06 PM CET
|
||||||
|
UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=204345
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:24:06 PM CET
|
||||||
|
UPDATE AD_Field SET SeqNoGrid=10,IsDisplayedGrid='Y' WHERE AD_Field_ID=204346
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:24:06 PM CET
|
||||||
|
UPDATE AD_Field SET SeqNoGrid=20,IsDisplayedGrid='Y' WHERE AD_Field_ID=204347
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:24:06 PM CET
|
||||||
|
UPDATE AD_Field SET SeqNoGrid=30,IsDisplayedGrid='Y' WHERE AD_Field_ID=204348
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:24:06 PM CET
|
||||||
|
UPDATE AD_Field SET SeqNoGrid=40,IsDisplayedGrid='Y' WHERE AD_Field_ID=204349
|
||||||
|
;
|
||||||
|
|
||||||
|
SELECT register_migration_script('201611242027_IDEMPIERE-905.sql') FROM dual
|
||||||
|
;
|
||||||
|
|
|
@ -0,0 +1,222 @@
|
||||||
|
-- IDEMPIERE-905 Post-it functionality
|
||||||
|
-- Nov 24, 2016 5:45:40 PM CET
|
||||||
|
INSERT INTO AD_Window (AD_Window_ID,Name,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,WindowType,Processing,EntityType,IsSOTrx,IsDefault,WinHeight,WinWidth,IsBetaFunctionality,AD_Window_UU) VALUES (200089,'Post-it',0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:40','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:40','YYYY-MM-DD HH24:MI:SS'),100,'M','N','D','Y','N',0,0,'N','f892195b-f1fe-46e9-9b4e-bc76c10c6e31')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:41 PM CET
|
||||||
|
INSERT INTO AD_Table (AD_Table_ID,Name,AD_Window_ID,TableName,LoadSeq,AccessLevel,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,IsSecurityEnabled,IsDeleteable,IsHighVolume,IsView,EntityType,ImportTable,IsChangeLog,ReplicationType,CopyColumnsFromTable,IsCentrallyMaintained,AD_Table_UU,Processing) VALUES (200215,'Post-it',200089,'AD_PostIt',0,'7',0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:40','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:40','YYYY-MM-DD HH24:MI:SS'),100,'N','N','N','N','D','N','N','L','N','Y','817f3e09-c45c-426c-82ae-36be50eeffa4','N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:41 PM CET
|
||||||
|
INSERT INTO AD_Sequence (Name,CurrentNext,IsAudited,StartNewYear,Description,IsActive,IsTableID,AD_Client_ID,AD_Org_ID,Created,CreatedBy,Updated,UpdatedBy,AD_Sequence_ID,IsAutoSequence,StartNo,IncrementNo,CurrentNextSys,AD_Sequence_UU) VALUES ('AD_PostIt',1000000,'N','N','Table AD_PostIt','Y','Y',0,0,TO_TIMESTAMP('2016-11-24 17:45:41','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:41','YYYY-MM-DD HH24:MI:SS'),100,200279,'Y',1000000,1,200000,'15a7484a-97cf-4372-95bf-71e1b0e54b63')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:42 PM CET
|
||||||
|
INSERT INTO AD_Element (AD_Element_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,ColumnName,Name,PrintName,EntityType,AD_Element_UU) VALUES (203056,0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:41','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:41','YYYY-MM-DD HH24:MI:SS'),100,'AD_Postit_ID','Post-it','Post-it','D','469aef37-8458-47d8-8c67-d437f2f008d7')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:42 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,AD_Table_ID,ColumnName,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsEncrypted,AD_Reference_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,SeqNoSelection,IsToolbarButton) VALUES (212922,0,'Post-it',200215,'AD_Postit_ID',10,'Y','N','Y','N','N',0,'N',13,0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:42','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:42','YYYY-MM-DD HH24:MI:SS'),100,203056,'N','N','D','Y','N','N','Y','5cafeed3-f69a-49a7-9e55-3367f3cfa4c6','N',0,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:42 PM CET
|
||||||
|
CREATE TABLE AD_PostIt (AD_Postit_ID NUMERIC(10) NOT NULL, CONSTRAINT AD_PostIt_Key PRIMARY KEY (AD_Postit_ID))
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:42 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,Description,Help,AD_Table_ID,ColumnName,DefaultValue,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsEncrypted,AD_Reference_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,SeqNoSelection,IsToolbarButton) VALUES (212923,0,'Client','Client/Tenant for this installation.','A Client is a company or a legal entity. You cannot share data between Clients. Tenant is a synonym for Client.',200215,'AD_Client_ID','@#AD_Client_ID@',10,'N','N','Y','N','N',0,'N',19,0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:42','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:42','YYYY-MM-DD HH24:MI:SS'),100,102,'N','N','D','Y','N','N','Y','a3ba33e5-12cc-49b3-937d-e1556017fdfd','N',0,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:42 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD COLUMN AD_Client_ID NUMERIC(10) NOT NULL
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:43 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,Description,Help,AD_Table_ID,ColumnName,DefaultValue,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsEncrypted,AD_Reference_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,SeqNoSelection,IsToolbarButton) VALUES (212924,0,'Organization','Organizational entity within client','An organization is a unit of your client or legal entity - examples are store, department. You can share data between organizations.',200215,'AD_Org_ID','@AD_Org_ID@',10,'N','N','Y','N','N',0,'N',19,0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:42','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:42','YYYY-MM-DD HH24:MI:SS'),100,113,'N','N','D','Y','N','N','Y','268c3174-3926-4dbd-afad-3ecdef03d19e','N',0,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:43 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD COLUMN AD_Org_ID NUMERIC(10) NOT NULL
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:43 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,Description,Help,AD_Table_ID,ColumnName,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsEncrypted,AD_Reference_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,SeqNoSelection,IsToolbarButton) VALUES (212925,0,'Table','Database Table information','The Database Table provides the information of the table definition',200215,'AD_Table_ID',10,'N','N','N','N','N',0,'N',30,0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:43','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:43','YYYY-MM-DD HH24:MI:SS'),100,126,'Y','N','D','Y','N','N','Y','d5628cb4-04fd-4365-a0f9-f7b555ae31aa','Y',0,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:43 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD COLUMN AD_Table_ID NUMERIC(10) DEFAULT NULL
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:43 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,Description,Help,AD_Table_ID,ColumnName,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsEncrypted,AD_Reference_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,SeqNoSelection,IsToolbarButton) VALUES (212926,0,'Created','Date this record was created','The Created field indicates the date that this record was created.',200215,'Created',7,'N','N','Y','N','N',0,'N',16,0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:43','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:43','YYYY-MM-DD HH24:MI:SS'),100,245,'N','N','D','Y','N','N','Y','aafb5372-b3c7-4360-a157-98d663fcea8c','N',0,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:43 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD COLUMN Created TIMESTAMP NOT NULL
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:44 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,Description,Help,AD_Table_ID,ColumnName,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsEncrypted,AD_Reference_ID,AD_Reference_Value_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,SeqNoSelection,IsToolbarButton) VALUES (212927,0,'Created By','User who created this records','The Created By field indicates the user who created this record.',200215,'CreatedBy',10,'N','N','Y','N','N',0,'N',30,110,0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:44','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:44','YYYY-MM-DD HH24:MI:SS'),100,246,'N','N','D','Y','N','N','Y','c6910bd9-1cfb-46ea-ba6e-2ce622f27efc','N',0,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:44 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD COLUMN CreatedBy NUMERIC(10) NOT NULL
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:44 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,Description,Help,AD_Table_ID,ColumnName,DefaultValue,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsEncrypted,AD_Reference_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,SeqNoSelection,IsToolbarButton) VALUES (212928,0,'Active','The record is active in the system','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.',200215,'IsActive','Y',1,'N','N','Y','N','N',0,'N',20,0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:44','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:44','YYYY-MM-DD HH24:MI:SS'),100,348,'N','N','D','Y','N','N','Y','8f113935-c0ad-4f46-ac28-27092953d5db','N',0,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:44 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD COLUMN IsActive CHAR(1) DEFAULT 'Y' CHECK (IsActive IN ('Y','N')) NOT NULL
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:45 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,AD_Table_ID,ColumnName,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsEncrypted,AD_Reference_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,SeqNoSelection,IsToolbarButton) VALUES (212929,0,'Description',200215,'Text',2000,'N','N','N','N','N',0,'N',10,0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:44','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:44','YYYY-MM-DD HH24:MI:SS'),100,53475,'Y','N','D','Y','N','N','Y','afcb6eb7-4141-421f-8386-ae0cd00bd832','Y',0,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:45 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD COLUMN Text VARCHAR(2000) DEFAULT NULL
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:45 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,Description,Help,AD_Table_ID,ColumnName,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsEncrypted,AD_Reference_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,SeqNoSelection,IsToolbarButton) VALUES (212930,0,'Record ID','Direct internal record ID','The Record ID is the internal unique identifier of a record. Please note that zooming to the record may not be successful for Orders, Invoices and Shipment/Receipts as sometimes the Sales Order type is not known.',200215,'Record_ID',10,'N','N','N','N','N',0,'N',28,0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:45','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:45','YYYY-MM-DD HH24:MI:SS'),100,538,'Y','N','D','Y','N','N','Y','3846e3ae-5ae7-43ef-9f64-1426371d1732','Y',0,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:45 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD COLUMN Record_ID NUMERIC(10) DEFAULT NULL
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:46 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,Description,Help,AD_Table_ID,ColumnName,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsEncrypted,AD_Reference_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,SeqNoSelection,IsToolbarButton) VALUES (212931,0,'Updated','Date this record was updated','The Updated field indicates the date that this record was updated.',200215,'Updated',7,'N','N','Y','N','N',0,'N',16,0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:45','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:45','YYYY-MM-DD HH24:MI:SS'),100,607,'Y','N','D','Y','N','N','Y','a38f1c45-13f4-491e-b897-286cc3f99131','N',0,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:46 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD COLUMN Updated TIMESTAMP NOT NULL
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:46 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,Description,Help,AD_Table_ID,ColumnName,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,SeqNo,IsEncrypted,AD_Reference_ID,AD_Reference_Value_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,SeqNoSelection,IsToolbarButton) VALUES (212932,0,'Updated By','User who updated this records','The Updated By field indicates the user who updated this record.',200215,'UpdatedBy',10,'N','N','Y','N','N',0,'N',30,110,0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:46','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:46','YYYY-MM-DD HH24:MI:SS'),100,608,'Y','N','D','Y','N','N','Y','601e1653-02d2-40cd-8572-b87b65c7b2cd','N',0,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:46 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD COLUMN UpdatedBy NUMERIC(10) NOT NULL
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:47 PM CET
|
||||||
|
INSERT INTO AD_Element (AD_Element_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,ColumnName,Name,PrintName,EntityType,AD_Element_UU) VALUES (203057,0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:46','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:46','YYYY-MM-DD HH24:MI:SS'),100,'AD_PostIt_UU','AD_PostIt_UU','AD_PostIt_UU','D','7a8d19a8-3e03-4c27-9c4b-2ffe32199d81')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:47 PM CET
|
||||||
|
INSERT INTO AD_Column (AD_Column_ID,Version,Name,AD_Table_ID,ColumnName,FieldLength,IsKey,IsParent,IsMandatory,IsTranslated,IsIdentifier,IsEncrypted,AD_Reference_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Element_ID,IsUpdateable,IsSelectionColumn,EntityType,IsSyncDatabase,IsAlwaysUpdateable,IsAutocomplete,IsAllowLogging,AD_Column_UU,IsAllowCopy,IsToolbarButton) VALUES (212933,1,'AD_PostIt_UU',200215,'AD_PostIt_UU',36,'N','N','N','N','N','N',10,0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:47','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:47','YYYY-MM-DD HH24:MI:SS'),100,203057,'Y','N','D','Y','N','N','Y','ad482a89-b32e-4cba-9d95-6b79ad401fa0','N','N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:47 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD COLUMN AD_PostIt_UU VARCHAR(36) DEFAULT NULL
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:47 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD CONSTRAINT AD_PostIt_UU_idx UNIQUE (AD_PostIt_UU)
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:47 PM CET
|
||||||
|
INSERT INTO AD_Tab (AD_Tab_ID,Name,AD_Window_ID,SeqNo,IsSingleRow,AD_Table_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,HasTree,IsInfoTab,IsTranslationTab,IsReadOnly,Processing,ImportFields,TabLevel,IsSortTab,EntityType,IsInsertRecord,IsAdvancedTab,AD_Tab_UU) VALUES (200220,'Post-it',200089,10,'N',200215,0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:47','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:47','YYYY-MM-DD HH24:MI:SS'),100,'N','N','N','N','N','N',0,'N','D','Y','N','715973a5-5d22-4d36-8241-6ff369cac595')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:48 PM CET
|
||||||
|
INSERT INTO AD_Field (AD_Field_ID,Name,Description,Help,AD_Tab_ID,AD_Column_ID,IsDisplayed,DisplayLength,SeqNo,IsSameLine,IsHeading,IsFieldOnly,IsEncrypted,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,IsReadOnly,IsCentrallyMaintained,EntityType,AD_Field_UU,IsDisplayedGrid,SeqNoGrid,XPosition,ColumnSpan,NumLines,IsQuickEntry) VALUES (204344,'Active','The record is active in the system','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.',200220,212928,'N',1,0,'N','N','N','N',0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:47','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:47','YYYY-MM-DD HH24:MI:SS'),100,'N','Y','D','a697ef4c-a87e-42b4-8d93-338ec0e65df8','N',0,1,1,1,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:48 PM CET
|
||||||
|
INSERT INTO AD_Field (AD_Field_ID,Name,Description,Help,AD_Tab_ID,AD_Column_ID,IsDisplayed,DisplayLength,SeqNo,IsSameLine,IsHeading,IsFieldOnly,IsEncrypted,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,IsReadOnly,IsCentrallyMaintained,EntityType,AD_Field_UU,IsDisplayedGrid,SeqNoGrid,XPosition,ColumnSpan,NumLines,IsQuickEntry) VALUES (204345,'Client','Client/Tenant for this installation.','A Client is a company or a legal entity. You cannot share data between Clients. Tenant is a synonym for Client.',200220,212923,'Y',10,10,'N','N','N','N',0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:48','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:48','YYYY-MM-DD HH24:MI:SS'),100,'N','Y','D','f63b0185-31a4-42a8-8102-e6a26efc4673','Y',10,1,1,1,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:48 PM CET
|
||||||
|
INSERT INTO AD_Field (AD_Field_ID,Name,Description,Help,AD_Tab_ID,AD_Column_ID,IsDisplayed,DisplayLength,SeqNo,IsSameLine,IsHeading,IsFieldOnly,IsEncrypted,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,IsReadOnly,IsCentrallyMaintained,EntityType,AD_Field_UU,IsAllowCopy,IsDisplayedGrid,SeqNoGrid,XPosition,ColumnSpan,NumLines,IsQuickEntry) VALUES (204346,'Organization','Organizational entity within client','An organization is a unit of your client or legal entity - examples are store, department. You can share data between organizations.',200220,212924,'Y',10,20,'Y','N','N','N',0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:48','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:48','YYYY-MM-DD HH24:MI:SS'),100,'N','Y','D','6953b9b3-d4ed-44a0-af7b-f6ffbb136d31','Y','Y',20,1,1,1,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:49 PM CET
|
||||||
|
INSERT INTO AD_Field (AD_Field_ID,Name,Description,Help,AD_Tab_ID,AD_Column_ID,IsDisplayed,DisplayLength,SeqNo,IsSameLine,IsHeading,IsFieldOnly,IsEncrypted,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,IsReadOnly,IsCentrallyMaintained,EntityType,AD_Field_UU,IsDisplayedGrid,SeqNoGrid,XPosition,ColumnSpan,NumLines,IsQuickEntry) VALUES (204347,'Table','Database Table information','The Database Table provides the information of the table definition',200220,212925,'Y',10,30,'N','N','N','N',0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:48','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:48','YYYY-MM-DD HH24:MI:SS'),100,'N','Y','D','23249d8e-93d2-403e-9425-5a48198bada3','Y',30,1,1,1,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:49 PM CET
|
||||||
|
INSERT INTO AD_Field (AD_Field_ID,Name,Description,Help,AD_Tab_ID,AD_Column_ID,IsDisplayed,DisplayLength,SeqNo,IsSameLine,IsHeading,IsFieldOnly,IsEncrypted,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,IsReadOnly,IsCentrallyMaintained,EntityType,AD_Field_UU,IsDisplayedGrid,SeqNoGrid,XPosition,ColumnSpan,NumLines,IsQuickEntry) VALUES (204348,'Record ID','Direct internal record ID','The Record ID is the internal unique identifier of a record. Please note that zooming to the record may not be successful for Orders, Invoices and Shipment/Receipts as sometimes the Sales Order type is not known.',200220,212930,'Y',10,40,'N','N','N','N',0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:49','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:49','YYYY-MM-DD HH24:MI:SS'),100,'N','Y','D','aa0d4cc6-00b3-4df7-bf98-cd5cc4b288fe','Y',40,1,1,1,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:50 PM CET
|
||||||
|
INSERT INTO AD_Field (AD_Field_ID,Name,AD_Tab_ID,AD_Column_ID,IsDisplayed,DisplayLength,SeqNo,IsSameLine,IsHeading,IsFieldOnly,IsEncrypted,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,IsReadOnly,IsCentrallyMaintained,EntityType,AD_Field_UU,IsDisplayedGrid,SeqNoGrid,XPosition,ColumnSpan,NumLines,IsQuickEntry) VALUES (204349,'Description',200220,212929,'Y',2000,50,'N','N','N','N',0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:49','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:49','YYYY-MM-DD HH24:MI:SS'),100,'N','Y','D','a72006bb-ed45-4988-9b92-1203f1e7950a','Y',50,1,1,1,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:50 PM CET
|
||||||
|
INSERT INTO AD_Field (AD_Field_ID,Name,AD_Tab_ID,AD_Column_ID,IsDisplayed,DisplayLength,IsSameLine,IsHeading,IsFieldOnly,IsEncrypted,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,IsReadOnly,IsCentrallyMaintained,EntityType,AD_Field_UU,IsDisplayedGrid,XPosition,ColumnSpan,NumLines,IsQuickEntry) VALUES (204350,'Post-it',200220,212922,'N',10,'N','N','N','N',0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:50','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:50','YYYY-MM-DD HH24:MI:SS'),100,'N','Y','D','458b8179-2e74-4b75-ba2e-ae19587ba6b3','N',1,1,1,'N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:50 PM CET
|
||||||
|
INSERT INTO AD_Message (MsgType,MsgText,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Message_ID,Value,EntityType,AD_Message_UU) VALUES ('I','Post-it',0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:50','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:50','YYYY-MM-DD HH24:MI:SS'),100,200411,'PostIt','D','1b48e86b-6fb8-4e45-961b-0c8a9611339f')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:51 PM CET
|
||||||
|
INSERT INTO AD_Message (MsgType,MsgText,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Message_ID,Value,EntityType,AD_Message_UU) VALUES ('I','Created by {0} / {1}',0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:50','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:50','YYYY-MM-DD HH24:MI:SS'),100,200412,'PostItCreated','D','1f0e605a-c851-4786-a5b4-de63ad980ee5')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:51 PM CET
|
||||||
|
INSERT INTO AD_Message (MsgType,MsgText,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,AD_Message_ID,Value,EntityType,AD_Message_UU) VALUES ('I','Updated by {0} / {1}',0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:51','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:51','YYYY-MM-DD HH24:MI:SS'),100,200413,'PostItUpdated','D','575b0ae3-81b3-4d36-97ab-8c636957f74c')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:51 PM CET
|
||||||
|
INSERT INTO AD_Menu (AD_Menu_ID,Name,"action",AD_Window_ID,AD_Client_ID,AD_Org_ID,IsActive,Created,CreatedBy,Updated,UpdatedBy,IsSummary,IsSOTrx,IsReadOnly,EntityType,IsCentrallyMaintained,AD_Menu_UU) VALUES (200144,'Post-it','W',200089,0,0,'Y',TO_TIMESTAMP('2016-11-24 17:45:51','YYYY-MM-DD HH24:MI:SS'),100,TO_TIMESTAMP('2016-11-24 17:45:51','YYYY-MM-DD HH24:MI:SS'),100,'N','N','N','D','Y','1262283c-4b52-4a6f-976c-09213d27b0e5')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:51 PM CET
|
||||||
|
INSERT INTO AD_TREENODEMM(AD_Client_ID, AD_Org_ID, CreatedBy, UpdatedBy, Parent_ID, SeqNo, AD_Tree_ID, Node_ID)VALUES(0, 0, 0, 0, 566,0, 10, 200144)
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:52 PM CET
|
||||||
|
UPDATE AD_Column SET FKConstraintName='ADClient_ADPostIt', FKConstraintType='N',Updated=TO_TIMESTAMP('2016-11-24 17:45:52','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=212923
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:52 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD CONSTRAINT ADClient_ADPostIt FOREIGN KEY (AD_Client_ID) REFERENCES ad_client(ad_client_id) DEFERRABLE INITIALLY DEFERRED
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:52 PM CET
|
||||||
|
UPDATE AD_Column SET FKConstraintName='ADOrg_ADPostIt', FKConstraintType='N',Updated=TO_TIMESTAMP('2016-11-24 17:45:52','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=212924
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:52 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD CONSTRAINT ADOrg_ADPostIt FOREIGN KEY (AD_Org_ID) REFERENCES ad_org(ad_org_id) DEFERRABLE INITIALLY DEFERRED
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:52 PM CET
|
||||||
|
UPDATE AD_Column SET FKConstraintName='ADTable_ADPostIt', FKConstraintType='N',Updated=TO_TIMESTAMP('2016-11-24 17:45:52','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=212925
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:52 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD CONSTRAINT ADTable_ADPostIt FOREIGN KEY (AD_Table_ID) REFERENCES ad_table(ad_table_id) DEFERRABLE INITIALLY DEFERRED
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:52 PM CET
|
||||||
|
UPDATE AD_Column SET FKConstraintName='CreatedBy_ADPostIt', FKConstraintType='N',Updated=TO_TIMESTAMP('2016-11-24 17:45:52','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=212927
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:52 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD CONSTRAINT CreatedBy_ADPostIt FOREIGN KEY (CreatedBy) REFERENCES ad_user(ad_user_id) DEFERRABLE INITIALLY DEFERRED
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:52 PM CET
|
||||||
|
UPDATE AD_Column SET FKConstraintName='UpdatedBy_ADPostIt', FKConstraintType='N',Updated=TO_TIMESTAMP('2016-11-24 17:45:52','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=212932
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 5:45:52 PM CET
|
||||||
|
ALTER TABLE AD_PostIt ADD CONSTRAINT UpdatedBy_ADPostIt FOREIGN KEY (UpdatedBy) REFERENCES ad_user(ad_user_id) DEFERRABLE INITIALLY DEFERRED
|
||||||
|
;
|
||||||
|
|
||||||
|
SELECT register_migration_script('201611241746_IDEMPIERE-905.sql') FROM dual
|
||||||
|
;
|
||||||
|
|
|
@ -0,0 +1,116 @@
|
||||||
|
-- IDEMPIERE-905 Post-it functionality
|
||||||
|
-- Nov 24, 2016 8:20:47 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=280,Updated=TO_TIMESTAMP('2016-11-24 20:20:47','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200081
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:20:55 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=270,Updated=TO_TIMESTAMP('2016-11-24 20:20:55','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200067
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:02 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=260,Updated=TO_TIMESTAMP('2016-11-24 20:21:02','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200057
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:07 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=250,Updated=TO_TIMESTAMP('2016-11-24 20:21:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200078
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:10 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=240,Updated=TO_TIMESTAMP('2016-11-24 20:21:10','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200056
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:14 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=230,Updated=TO_TIMESTAMP('2016-11-24 20:21:14','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200055
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:17 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=220,Updated=TO_TIMESTAMP('2016-11-24 20:21:17','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200054
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:21 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=210,Updated=TO_TIMESTAMP('2016-11-24 20:21:21','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200053
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:24 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=200,Updated=TO_TIMESTAMP('2016-11-24 20:21:24','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200052
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:28 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=190,Updated=TO_TIMESTAMP('2016-11-24 20:21:28','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200051
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:34 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=180,Updated=TO_TIMESTAMP('2016-11-24 20:21:34','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200050
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:38 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=170,Updated=TO_TIMESTAMP('2016-11-24 20:21:38','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200049
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:41 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=160,Updated=TO_TIMESTAMP('2016-11-24 20:21:41','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200044
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:46 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=150,Updated=TO_TIMESTAMP('2016-11-24 20:21:46','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200043
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:49 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=140,Updated=TO_TIMESTAMP('2016-11-24 20:21:49','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200058
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:21:54 PM CET
|
||||||
|
UPDATE AD_ToolBarButton SET SeqNo=130,Updated=TO_TIMESTAMP('2016-11-24 20:21:54','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_ToolBarButton_ID=200041
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:22:18 PM CET
|
||||||
|
INSERT INTO AD_ToolBarButton (AD_Client_ID,AD_Org_ID,Created,CreatedBy,ComponentName,IsActive,AD_ToolBarButton_ID,Name,Updated,UpdatedBy,IsCustomization,KeyStroke_KeyCode,KeyStroke_Modifiers,AD_ToolBarButton_UU,"action",SeqNo,IsAdvancedButton,IsAddSeparator) VALUES (0,0,TO_TIMESTAMP('2016-11-24 20:22:17','YYYY-MM-DD HH24:MI:SS'),100,'PostIt','Y',200088,'Window - PostIt',TO_TIMESTAMP('2016-11-24 20:22:17','YYYY-MM-DD HH24:MI:SS'),100,'N',0,0,'50125137-56a4-4254-a92c-59cd0867c8aa','W',120,'N','N')
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:23:26 PM CET
|
||||||
|
UPDATE AD_Field SET SeqNo=10, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, ColumnSpan=2, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2016-11-24 20:23:26','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=204345
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:23:26 PM CET
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=20, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=4, ColumnSpan=2, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2016-11-24 20:23:26','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=204346
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:23:26 PM CET
|
||||||
|
UPDATE AD_Field SET SeqNo=30, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, ColumnSpan=2, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2016-11-24 20:23:26','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=204347
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:23:26 PM CET
|
||||||
|
UPDATE AD_Field SET IsDisplayed='Y', SeqNo=40, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, XPosition=5, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2016-11-24 20:23:26','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=204348
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:23:26 PM CET
|
||||||
|
UPDATE AD_Field SET SeqNo=50, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, ColumnSpan=5, NumLines=10, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2016-11-24 20:23:26','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=204349
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:23:26 PM CET
|
||||||
|
UPDATE AD_Field SET SeqNo=0, AD_Reference_Value_ID=NULL, AD_Val_Rule_ID=NULL, IsToolbarButton=NULL,Updated=TO_TIMESTAMP('2016-11-24 20:23:26','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=204350
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:24:06 PM CET
|
||||||
|
UPDATE AD_Field SET SeqNoGrid=0,IsDisplayedGrid='N' WHERE AD_Field_ID=204345
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:24:06 PM CET
|
||||||
|
UPDATE AD_Field SET SeqNoGrid=10,IsDisplayedGrid='Y' WHERE AD_Field_ID=204346
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:24:06 PM CET
|
||||||
|
UPDATE AD_Field SET SeqNoGrid=20,IsDisplayedGrid='Y' WHERE AD_Field_ID=204347
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:24:06 PM CET
|
||||||
|
UPDATE AD_Field SET SeqNoGrid=30,IsDisplayedGrid='Y' WHERE AD_Field_ID=204348
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 24, 2016 8:24:06 PM CET
|
||||||
|
UPDATE AD_Field SET SeqNoGrid=40,IsDisplayedGrid='Y' WHERE AD_Field_ID=204349
|
||||||
|
;
|
||||||
|
|
||||||
|
SELECT register_migration_script('201611242027_IDEMPIERE-905.sql') FROM dual
|
||||||
|
;
|
||||||
|
|
|
@ -229,6 +229,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
|
||||||
public static final String CTX_SQL = "_TabInfo_SQL";
|
public static final String CTX_SQL = "_TabInfo_SQL";
|
||||||
public static final String CTX_IsSortTab = "_TabInfo_IsSortTab";
|
public static final String CTX_IsSortTab = "_TabInfo_IsSortTab";
|
||||||
|
|
||||||
|
//private HashMap<Integer,Integer> m_PostIts = null;
|
||||||
|
|
||||||
/**************************************************************************
|
/**************************************************************************
|
||||||
* Tab loader for Tabs > 0
|
* Tab loader for Tabs > 0
|
||||||
|
@ -2186,6 +2187,23 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
|
||||||
int recordID = m_mTable.getKeyID(m_currentRow);
|
int recordID = m_mTable.getKeyID(m_currentRow);
|
||||||
return MChat.getID(m_vo.AD_Table_ID, recordID);
|
return MChat.getID(m_vo.AD_Table_ID, recordID);
|
||||||
} // getCM_ChatID
|
} // getCM_ChatID
|
||||||
|
|
||||||
|
public boolean hasPostIt()
|
||||||
|
{
|
||||||
|
return getAD_PostIt_ID() > 0;
|
||||||
|
} // hasChat
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get PostItID for this record.
|
||||||
|
* @return ID or 0, if not found
|
||||||
|
*/
|
||||||
|
public int getAD_PostIt_ID()
|
||||||
|
{
|
||||||
|
if (!canHaveAttachment())
|
||||||
|
return 0;
|
||||||
|
int recordID = m_mTable.getKeyID(m_currentRow);
|
||||||
|
return MPostIt.getID(m_vo.AD_Table_ID, recordID);
|
||||||
|
} // getAD_PostIt_ID
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -0,0 +1,164 @@
|
||||||
|
/******************************************************************************
|
||||||
|
* 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_PostIt
|
||||||
|
* @author iDempiere (generated)
|
||||||
|
* @version Release 4.1
|
||||||
|
*/
|
||||||
|
public interface I_AD_PostIt
|
||||||
|
{
|
||||||
|
|
||||||
|
/** TableName=AD_PostIt */
|
||||||
|
public static final String Table_Name = "AD_PostIt";
|
||||||
|
|
||||||
|
/** AD_Table_ID=200215 */
|
||||||
|
public static final int Table_ID = 200215;
|
||||||
|
|
||||||
|
KeyNamePair Model = new KeyNamePair(Table_ID, Table_Name);
|
||||||
|
|
||||||
|
/** AccessLevel = 7 - System - Client - Org
|
||||||
|
*/
|
||||||
|
BigDecimal accessLevel = BigDecimal.valueOf(7);
|
||||||
|
|
||||||
|
/** 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_Postit_ID */
|
||||||
|
public static final String COLUMNNAME_AD_Postit_ID = "AD_Postit_ID";
|
||||||
|
|
||||||
|
/** Set Post-it */
|
||||||
|
public void setAD_Postit_ID (int AD_Postit_ID);
|
||||||
|
|
||||||
|
/** Get Post-it */
|
||||||
|
public int getAD_Postit_ID();
|
||||||
|
|
||||||
|
/** Column name AD_PostIt_UU */
|
||||||
|
public static final String COLUMNNAME_AD_PostIt_UU = "AD_PostIt_UU";
|
||||||
|
|
||||||
|
/** Set AD_PostIt_UU */
|
||||||
|
public void setAD_PostIt_UU (String AD_PostIt_UU);
|
||||||
|
|
||||||
|
/** Get AD_PostIt_UU */
|
||||||
|
public String getAD_PostIt_UU();
|
||||||
|
|
||||||
|
/** Column name AD_Table_ID */
|
||||||
|
public static final String COLUMNNAME_AD_Table_ID = "AD_Table_ID";
|
||||||
|
|
||||||
|
/** Set Table.
|
||||||
|
* Database Table information
|
||||||
|
*/
|
||||||
|
public void setAD_Table_ID (int AD_Table_ID);
|
||||||
|
|
||||||
|
/** Get Table.
|
||||||
|
* Database Table information
|
||||||
|
*/
|
||||||
|
public int getAD_Table_ID();
|
||||||
|
|
||||||
|
public org.compiere.model.I_AD_Table getAD_Table() throws RuntimeException;
|
||||||
|
|
||||||
|
/** Column name Created */
|
||||||
|
public static final String COLUMNNAME_Created = "Created";
|
||||||
|
|
||||||
|
/** Get Created.
|
||||||
|
* Date this record was created
|
||||||
|
*/
|
||||||
|
public Timestamp getCreated();
|
||||||
|
|
||||||
|
/** Column name CreatedBy */
|
||||||
|
public static final String COLUMNNAME_CreatedBy = "CreatedBy";
|
||||||
|
|
||||||
|
/** Get Created By.
|
||||||
|
* User who created this records
|
||||||
|
*/
|
||||||
|
public int getCreatedBy();
|
||||||
|
|
||||||
|
/** Column name IsActive */
|
||||||
|
public static final String COLUMNNAME_IsActive = "IsActive";
|
||||||
|
|
||||||
|
/** Set Active.
|
||||||
|
* The record is active in the system
|
||||||
|
*/
|
||||||
|
public void setIsActive (boolean IsActive);
|
||||||
|
|
||||||
|
/** Get Active.
|
||||||
|
* The record is active in the system
|
||||||
|
*/
|
||||||
|
public boolean isActive();
|
||||||
|
|
||||||
|
/** Column name Record_ID */
|
||||||
|
public static final String COLUMNNAME_Record_ID = "Record_ID";
|
||||||
|
|
||||||
|
/** Set Record ID.
|
||||||
|
* Direct internal record ID
|
||||||
|
*/
|
||||||
|
public void setRecord_ID (int Record_ID);
|
||||||
|
|
||||||
|
/** Get Record ID.
|
||||||
|
* Direct internal record ID
|
||||||
|
*/
|
||||||
|
public int getRecord_ID();
|
||||||
|
|
||||||
|
/** Column name Text */
|
||||||
|
public static final String COLUMNNAME_Text = "Text";
|
||||||
|
|
||||||
|
/** Set Description */
|
||||||
|
public void setText (String Text);
|
||||||
|
|
||||||
|
/** Get Description */
|
||||||
|
public String getText();
|
||||||
|
|
||||||
|
/** 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();
|
||||||
|
}
|
|
@ -0,0 +1,102 @@
|
||||||
|
/******************************************************************************
|
||||||
|
* Product: Adempiere ERP & CRM Smart Business Solution *
|
||||||
|
* Copyright (C) 1999-2006 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.text.SimpleDateFormat;
|
||||||
|
import java.util.Properties;
|
||||||
|
|
||||||
|
import org.compiere.util.DB;
|
||||||
|
import org.compiere.util.Msg;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* PostIt Model
|
||||||
|
*
|
||||||
|
* @author Nicolas Micoud
|
||||||
|
* @version $Id: MPostIt.java
|
||||||
|
*/
|
||||||
|
public class MPostIt extends X_AD_PostIt
|
||||||
|
{
|
||||||
|
private static final long serialVersionUID = -5053130533036069784L;
|
||||||
|
|
||||||
|
/**************************************************************************
|
||||||
|
* Standard Constructor
|
||||||
|
* @param ctx context
|
||||||
|
* @param XXA_PostIt_ID id
|
||||||
|
* @param trxName transcation
|
||||||
|
*/
|
||||||
|
public MPostIt (Properties ctx, int XXA_PostIt_ID, String trxName)
|
||||||
|
{
|
||||||
|
super (ctx, XXA_PostIt_ID, trxName);
|
||||||
|
} // MPostIt
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Full Constructor
|
||||||
|
* @param ctx context
|
||||||
|
* @param AD_Table_ID table
|
||||||
|
* @param Record_ID record
|
||||||
|
* @param Description description
|
||||||
|
* @param trxName transaction
|
||||||
|
*/
|
||||||
|
public MPostIt (Properties ctx, int AD_Table_ID, int Record_ID, String trxName)
|
||||||
|
{
|
||||||
|
this (ctx, 0, trxName);
|
||||||
|
setAD_Table_ID (AD_Table_ID);
|
||||||
|
setRecord_ID (Record_ID);
|
||||||
|
} // MPostIt
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Load Constructor
|
||||||
|
* @param ctx context
|
||||||
|
* @param rs result set
|
||||||
|
* @param trxName transaction
|
||||||
|
*/
|
||||||
|
public MPostIt (Properties ctx, ResultSet rs, String trxName)
|
||||||
|
{
|
||||||
|
super (ctx, rs, trxName);
|
||||||
|
} // MPostIt
|
||||||
|
|
||||||
|
|
||||||
|
public String getCreatedString()
|
||||||
|
{
|
||||||
|
MUser user = MUser.get(getCtx(), getCreatedBy());
|
||||||
|
String date = new SimpleDateFormat("d MMM yyyy (HH:mm)").format(getCreated());
|
||||||
|
Object[] args = new Object[] {user.getName(), date};
|
||||||
|
return Msg.getMsg(getCtx(), "PostItCreated", args);
|
||||||
|
} // getCreated
|
||||||
|
|
||||||
|
|
||||||
|
public String getUpdatedString()
|
||||||
|
{
|
||||||
|
String retValue = "";
|
||||||
|
if (getUpdated().getTime() != getCreated().getTime())
|
||||||
|
{
|
||||||
|
MUser user = MUser.get(getCtx(), getUpdatedBy());
|
||||||
|
String date = new SimpleDateFormat("d MMM yyyy (HH:mm)").format(getUpdated());
|
||||||
|
Object[] args = new Object[] {user.getName(), date};
|
||||||
|
retValue = Msg.getMsg(getCtx(), "PostItUpdated", args);
|
||||||
|
}
|
||||||
|
|
||||||
|
return retValue;
|
||||||
|
} // getUpdatedString
|
||||||
|
|
||||||
|
public static int getID(int Table_ID, int Record_ID) {
|
||||||
|
String sql="SELECT AD_PostIt_ID FROM AD_PostIt WHERE AD_Table_ID=? AND Record_ID=?";
|
||||||
|
int postItID = DB.getSQLValueEx(null, sql, Table_ID, Record_ID);
|
||||||
|
return postItID;
|
||||||
|
}
|
||||||
|
} // MPostIt
|
|
@ -62,7 +62,8 @@ public class PO_Record
|
||||||
// X_CM_CStageTTable.Table_ID,
|
// X_CM_CStageTTable.Table_ID,
|
||||||
X_K_Index.Table_ID,
|
X_K_Index.Table_ID,
|
||||||
X_AD_Note.Table_ID,
|
X_AD_Note.Table_ID,
|
||||||
X_AD_RecentItem.Table_ID
|
X_AD_RecentItem.Table_ID,
|
||||||
|
X_AD_PostIt.Table_ID
|
||||||
};
|
};
|
||||||
/** Cascade Table Names */
|
/** Cascade Table Names */
|
||||||
private static String[] s_cascadeNames = new String[]{
|
private static String[] s_cascadeNames = new String[]{
|
||||||
|
@ -72,7 +73,8 @@ public class PO_Record
|
||||||
// X_CM_CStageTTable.Table_Name,
|
// X_CM_CStageTTable.Table_Name,
|
||||||
X_K_Index.Table_Name,
|
X_K_Index.Table_Name,
|
||||||
X_AD_Note.Table_Name,
|
X_AD_Note.Table_Name,
|
||||||
X_AD_RecentItem.Table_Name
|
X_AD_RecentItem.Table_Name,
|
||||||
|
X_AD_PostIt.Table_Name
|
||||||
};
|
};
|
||||||
|
|
||||||
/** Restrict Table ID */
|
/** Restrict Table ID */
|
||||||
|
|
|
@ -0,0 +1,170 @@
|
||||||
|
/******************************************************************************
|
||||||
|
* 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_PostIt
|
||||||
|
* @author iDempiere (generated)
|
||||||
|
* @version Release 4.1 - $Id$ */
|
||||||
|
public class X_AD_PostIt extends PO implements I_AD_PostIt, I_Persistent
|
||||||
|
{
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
private static final long serialVersionUID = 20161124L;
|
||||||
|
|
||||||
|
/** Standard Constructor */
|
||||||
|
public X_AD_PostIt (Properties ctx, int AD_PostIt_ID, String trxName)
|
||||||
|
{
|
||||||
|
super (ctx, AD_PostIt_ID, trxName);
|
||||||
|
/** if (AD_PostIt_ID == 0)
|
||||||
|
{
|
||||||
|
setAD_Postit_ID (0);
|
||||||
|
} */
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Load Constructor */
|
||||||
|
public X_AD_PostIt (Properties ctx, ResultSet rs, String trxName)
|
||||||
|
{
|
||||||
|
super (ctx, rs, trxName);
|
||||||
|
}
|
||||||
|
|
||||||
|
/** AccessLevel
|
||||||
|
* @return 7 - System - 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_PostIt[")
|
||||||
|
.append(get_ID()).append("]");
|
||||||
|
return sb.toString();
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Set Post-it.
|
||||||
|
@param AD_Postit_ID Post-it */
|
||||||
|
public void setAD_Postit_ID (int AD_Postit_ID)
|
||||||
|
{
|
||||||
|
if (AD_Postit_ID < 1)
|
||||||
|
set_ValueNoCheck (COLUMNNAME_AD_Postit_ID, null);
|
||||||
|
else
|
||||||
|
set_ValueNoCheck (COLUMNNAME_AD_Postit_ID, Integer.valueOf(AD_Postit_ID));
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Get Post-it.
|
||||||
|
@return Post-it */
|
||||||
|
public int getAD_Postit_ID ()
|
||||||
|
{
|
||||||
|
Integer ii = (Integer)get_Value(COLUMNNAME_AD_Postit_ID);
|
||||||
|
if (ii == null)
|
||||||
|
return 0;
|
||||||
|
return ii.intValue();
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Set AD_PostIt_UU.
|
||||||
|
@param AD_PostIt_UU AD_PostIt_UU */
|
||||||
|
public void setAD_PostIt_UU (String AD_PostIt_UU)
|
||||||
|
{
|
||||||
|
set_Value (COLUMNNAME_AD_PostIt_UU, AD_PostIt_UU);
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Get AD_PostIt_UU.
|
||||||
|
@return AD_PostIt_UU */
|
||||||
|
public String getAD_PostIt_UU ()
|
||||||
|
{
|
||||||
|
return (String)get_Value(COLUMNNAME_AD_PostIt_UU);
|
||||||
|
}
|
||||||
|
|
||||||
|
public org.compiere.model.I_AD_Table getAD_Table() throws RuntimeException
|
||||||
|
{
|
||||||
|
return (org.compiere.model.I_AD_Table)MTable.get(getCtx(), org.compiere.model.I_AD_Table.Table_Name)
|
||||||
|
.getPO(getAD_Table_ID(), get_TrxName()); }
|
||||||
|
|
||||||
|
/** Set Table.
|
||||||
|
@param AD_Table_ID
|
||||||
|
Database Table information
|
||||||
|
*/
|
||||||
|
public void setAD_Table_ID (int AD_Table_ID)
|
||||||
|
{
|
||||||
|
if (AD_Table_ID < 1)
|
||||||
|
set_Value (COLUMNNAME_AD_Table_ID, null);
|
||||||
|
else
|
||||||
|
set_Value (COLUMNNAME_AD_Table_ID, Integer.valueOf(AD_Table_ID));
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Get Table.
|
||||||
|
@return Database Table information
|
||||||
|
*/
|
||||||
|
public int getAD_Table_ID ()
|
||||||
|
{
|
||||||
|
Integer ii = (Integer)get_Value(COLUMNNAME_AD_Table_ID);
|
||||||
|
if (ii == null)
|
||||||
|
return 0;
|
||||||
|
return ii.intValue();
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Set Record ID.
|
||||||
|
@param Record_ID
|
||||||
|
Direct internal record ID
|
||||||
|
*/
|
||||||
|
public void setRecord_ID (int Record_ID)
|
||||||
|
{
|
||||||
|
if (Record_ID < 0)
|
||||||
|
set_Value (COLUMNNAME_Record_ID, null);
|
||||||
|
else
|
||||||
|
set_Value (COLUMNNAME_Record_ID, Integer.valueOf(Record_ID));
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Get Record ID.
|
||||||
|
@return Direct internal record ID
|
||||||
|
*/
|
||||||
|
public int getRecord_ID ()
|
||||||
|
{
|
||||||
|
Integer ii = (Integer)get_Value(COLUMNNAME_Record_ID);
|
||||||
|
if (ii == null)
|
||||||
|
return 0;
|
||||||
|
return ii.intValue();
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Set Description.
|
||||||
|
@param Text Description */
|
||||||
|
public void setText (String Text)
|
||||||
|
{
|
||||||
|
set_Value (COLUMNNAME_Text, Text);
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Get Description.
|
||||||
|
@return Description */
|
||||||
|
public String getText ()
|
||||||
|
{
|
||||||
|
return (String)get_Value(COLUMNNAME_Text);
|
||||||
|
}
|
||||||
|
}
|
|
@ -90,6 +90,7 @@ import org.compiere.grid.VSortTab;
|
||||||
import org.compiere.grid.VTabbedPane;
|
import org.compiere.grid.VTabbedPane;
|
||||||
import org.compiere.grid.ed.VButton;
|
import org.compiere.grid.ed.VButton;
|
||||||
import org.compiere.grid.ed.VDocAction;
|
import org.compiere.grid.ed.VDocAction;
|
||||||
|
import org.compiere.grid.ed.VPostIt;
|
||||||
import org.compiere.model.DataStatusEvent;
|
import org.compiere.model.DataStatusEvent;
|
||||||
import org.compiere.model.DataStatusListener;
|
import org.compiere.model.DataStatusListener;
|
||||||
import org.compiere.model.GridField;
|
import org.compiere.model.GridField;
|
||||||
|
@ -337,8 +338,8 @@ public final class APanel extends CPanel
|
||||||
private AppsAction aReport, aEnd, aHome, aHelp, aProduct, aLogout,
|
private AppsAction aReport, aEnd, aHome, aHelp, aProduct, aLogout,
|
||||||
aAccount, aCalculator, aCalendar, aEditor, aPreference, aScript,
|
aAccount, aCalculator, aCalendar, aEditor, aPreference, aScript,
|
||||||
aOnline, aMailSupport, aAbout, aPrintScr, aScrShot, aExit, aBPartner,
|
aOnline, aMailSupport, aAbout, aPrintScr, aScrShot, aExit, aBPartner,
|
||||||
aDeleteSelection, aShowAllWindow;
|
aDeleteSelection, aShowAllWindow, aPostIt;
|
||||||
|
|
||||||
private SwitchAction aSwitchLinesDownAction, aSwitchLinesUpAction;
|
private SwitchAction aSwitchLinesDownAction, aSwitchLinesUpAction;
|
||||||
|
|
||||||
private WindowMenu m_WindowMenu;
|
private WindowMenu m_WindowMenu;
|
||||||
|
@ -446,6 +447,7 @@ public final class APanel extends CPanel
|
||||||
|
|
||||||
mView.addSeparator();
|
mView.addSeparator();
|
||||||
aAttachment = addAction("Attachment", mView, KeyStroke.getKeyStroke(KeyEvent.VK_F7, 0), true); // toggle
|
aAttachment = addAction("Attachment", mView, KeyStroke.getKeyStroke(KeyEvent.VK_F7, 0), true); // toggle
|
||||||
|
aPostIt = addAction("PostIt", mView, null, true);
|
||||||
aChat = addAction("Chat", mView, null, true); // toggle
|
aChat = addAction("Chat", mView, null, true); // toggle
|
||||||
aHistory = addAction("History", mView, KeyStroke.getKeyStroke(KeyEvent.VK_F9, 0), true); // toggle
|
aHistory = addAction("History", mView, KeyStroke.getKeyStroke(KeyEvent.VK_F9, 0), true); // toggle
|
||||||
mView.addSeparator();
|
mView.addSeparator();
|
||||||
|
@ -518,6 +520,7 @@ public final class APanel extends CPanel
|
||||||
toolBar.add(aRefresh.getButton()); // F5
|
toolBar.add(aRefresh.getButton()); // F5
|
||||||
toolBar.add(aFind.getButton());
|
toolBar.add(aFind.getButton());
|
||||||
toolBar.add(aAttachment.getButton());
|
toolBar.add(aAttachment.getButton());
|
||||||
|
toolBar.add(aPostIt.getButton());
|
||||||
toolBar.add(aChat.getButton());
|
toolBar.add(aChat.getButton());
|
||||||
toolBar.add(aMulti.getButton());
|
toolBar.add(aMulti.getButton());
|
||||||
toolBar.addSeparator();
|
toolBar.addSeparator();
|
||||||
|
@ -1275,12 +1278,15 @@ public final class APanel extends CPanel
|
||||||
{
|
{
|
||||||
aAttachment.setEnabled(true);
|
aAttachment.setEnabled(true);
|
||||||
aAttachment.setPressed(m_curTab.hasAttachment());
|
aAttachment.setPressed(m_curTab.hasAttachment());
|
||||||
|
aPostIt.setEnabled(true);
|
||||||
|
aPostIt.setPressed(m_curTab.hasPostIt());
|
||||||
aChat.setEnabled(true);
|
aChat.setEnabled(true);
|
||||||
aChat.setPressed(m_curTab.hasChat());
|
aChat.setPressed(m_curTab.hasChat());
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
aAttachment.setEnabled(false);
|
aAttachment.setEnabled(false);
|
||||||
|
aPostIt.setEnabled(false);
|
||||||
aChat.setEnabled(false);
|
aChat.setEnabled(false);
|
||||||
}
|
}
|
||||||
// Lock Indicator
|
// Lock Indicator
|
||||||
|
@ -1582,6 +1588,7 @@ public final class APanel extends CPanel
|
||||||
aFind.setEnabled(false);
|
aFind.setEnabled(false);
|
||||||
aRefresh.setEnabled(false);
|
aRefresh.setEnabled(false);
|
||||||
aAttachment.setEnabled(false);
|
aAttachment.setEnabled(false);
|
||||||
|
aPostIt.setEnabled(false);
|
||||||
aChat.setEnabled(false);
|
aChat.setEnabled(false);
|
||||||
}
|
}
|
||||||
else // Grid Tab
|
else // Grid Tab
|
||||||
|
@ -1591,6 +1598,7 @@ public final class APanel extends CPanel
|
||||||
aFind.setEnabled(true);
|
aFind.setEnabled(true);
|
||||||
aRefresh.setEnabled(true);
|
aRefresh.setEnabled(true);
|
||||||
aAttachment.setEnabled(true);
|
aAttachment.setEnabled(true);
|
||||||
|
aPostIt.setEnabled(true);
|
||||||
aChat.setEnabled(true);
|
aChat.setEnabled(true);
|
||||||
|
|
||||||
// IDEMPIERE-587 - Swing: Toolbar Button to start Process from button fields
|
// IDEMPIERE-587 - Swing: Toolbar Button to start Process from button fields
|
||||||
|
@ -1762,6 +1770,8 @@ public final class APanel extends CPanel
|
||||||
// View
|
// View
|
||||||
else if (cmd.equals(aAttachment.getName()))
|
else if (cmd.equals(aAttachment.getName()))
|
||||||
cmd_attachment();
|
cmd_attachment();
|
||||||
|
else if (cmd.equals(aPostIt.getName()))
|
||||||
|
cmd_postIt();
|
||||||
else if (cmd.equals(aChat.getName()))
|
else if (cmd.equals(aChat.getName()))
|
||||||
cmd_chat();
|
cmd_chat();
|
||||||
else if (cmd.equals(aHistory.getName()))
|
else if (cmd.equals(aHistory.getName()))
|
||||||
|
@ -2630,6 +2640,35 @@ public final class APanel extends CPanel
|
||||||
new AExport(this);
|
new AExport(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private void cmd_postIt()
|
||||||
|
{
|
||||||
|
int record_ID = m_curTab.getRecord_ID();
|
||||||
|
if (log.isLoggable(Level.INFO)) log.info("Record_ID=" + record_ID);
|
||||||
|
if (record_ID == -1) // No Key
|
||||||
|
{
|
||||||
|
aChat.setEnabled(false);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
// Find display
|
||||||
|
String infoName = null;
|
||||||
|
String infoDisplay = null;
|
||||||
|
for (int i = 0; i < m_curTab.getFieldCount(); i++)
|
||||||
|
{
|
||||||
|
GridField field = m_curTab.getField(i);
|
||||||
|
if (field.isKey())
|
||||||
|
infoName = field.getHeader();
|
||||||
|
if ((field.getColumnName().equals("Name") || field.getColumnName().equals("DocumentNo") )
|
||||||
|
&& field.getValue() != null)
|
||||||
|
infoDisplay = field.getValue().toString();
|
||||||
|
if (infoName != null && infoDisplay != null)
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
String header = infoName + ": " + infoDisplay;
|
||||||
|
//
|
||||||
|
|
||||||
|
new VPostIt (AEnv.getFrame(this), header, m_curTab.getAD_PostIt_ID(), m_curTab.getAD_Table_ID(), record_ID, null);
|
||||||
|
aPostIt.setPressed(m_curTab.hasPostIt());
|
||||||
|
} // cmd_postIt
|
||||||
|
|
||||||
/**************************************************************************
|
/**************************************************************************
|
||||||
* Start Button Process
|
* Start Button Process
|
||||||
|
|
|
@ -0,0 +1,325 @@
|
||||||
|
/******************************************************************************
|
||||||
|
* Product: Adempiere ERP & CRM Smart Business Solution *
|
||||||
|
* Copyright (C) 1999-2006 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.grid.ed;
|
||||||
|
|
||||||
|
import java.awt.BorderLayout;
|
||||||
|
import java.awt.Dimension;
|
||||||
|
import java.awt.Frame;
|
||||||
|
import java.awt.Toolkit;
|
||||||
|
import java.awt.event.ActionEvent;
|
||||||
|
import java.awt.event.ActionListener;
|
||||||
|
import java.awt.event.KeyEvent;
|
||||||
|
import java.awt.event.KeyListener;
|
||||||
|
import java.io.BufferedWriter;
|
||||||
|
import java.io.FileInputStream;
|
||||||
|
import java.io.FileOutputStream;
|
||||||
|
import java.io.InputStreamReader;
|
||||||
|
import java.io.OutputStreamWriter;
|
||||||
|
import java.io.UnsupportedEncodingException;
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
|
import javax.swing.JDialog;
|
||||||
|
import javax.swing.JFileChooser;
|
||||||
|
import javax.swing.JMenu;
|
||||||
|
import javax.swing.JMenuBar;
|
||||||
|
import javax.swing.JSplitPane;
|
||||||
|
import javax.swing.JTabbedPane;
|
||||||
|
import javax.swing.event.ChangeEvent;
|
||||||
|
import javax.swing.event.ChangeListener;
|
||||||
|
|
||||||
|
import org.adempiere.plaf.AdempierePLAF;
|
||||||
|
import org.compiere.apps.AEnv;
|
||||||
|
import org.compiere.apps.ConfirmPanel;
|
||||||
|
import org.compiere.apps.StatusBar;
|
||||||
|
import org.compiere.model.MPostIt;
|
||||||
|
import org.compiere.swing.CDialog;
|
||||||
|
import org.compiere.swing.CMenuItem;
|
||||||
|
import org.compiere.swing.CPanel;
|
||||||
|
import org.compiere.swing.CTextArea;
|
||||||
|
import org.compiere.swing.CTextPane;
|
||||||
|
import org.compiere.util.CLogger;
|
||||||
|
import org.compiere.util.Env;
|
||||||
|
import org.compiere.util.Msg;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Post-it, bas<EFBFBD> sur Editor
|
||||||
|
*
|
||||||
|
* @author Nico
|
||||||
|
*/
|
||||||
|
public class VPostIt extends CDialog implements ChangeListener, ActionListener, KeyListener
|
||||||
|
{
|
||||||
|
private static final long serialVersionUID = -8314686583942866712L;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Standard constructor
|
||||||
|
* @param frame parent
|
||||||
|
* @param header heading
|
||||||
|
* @param postItID
|
||||||
|
* @param tableID
|
||||||
|
* @param recordID
|
||||||
|
* @param trxName
|
||||||
|
*/
|
||||||
|
public VPostIt(Frame frame, String header, int postItID, int tableID, int recordID, String trxName)
|
||||||
|
{
|
||||||
|
super (frame, header, frame != null);
|
||||||
|
try
|
||||||
|
{
|
||||||
|
jbInit();
|
||||||
|
setDefaultCloseOperation(JDialog.DISPOSE_ON_CLOSE);
|
||||||
|
}
|
||||||
|
catch(Exception ex)
|
||||||
|
{
|
||||||
|
log.log(Level.SEVERE, "", ex);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (postItID > 0)
|
||||||
|
m_postIt = new MPostIt (Env.getCtx(), postItID, trxName);
|
||||||
|
else
|
||||||
|
m_postIt = new MPostIt (Env.getCtx(), tableID, recordID, trxName);
|
||||||
|
|
||||||
|
// Set Text
|
||||||
|
textArea.setText(m_postIt.getText());
|
||||||
|
textArea.setEditable(true);
|
||||||
|
textArea.setBackground(AdempierePLAF.getFieldBackground_Normal());
|
||||||
|
textPane.setBackground(AdempierePLAF.getFieldBackground_Inactive());
|
||||||
|
|
||||||
|
String createdupdated = null;
|
||||||
|
if (m_postIt.getAD_Postit_ID() > 0)
|
||||||
|
createdupdated = m_postIt.getCreatedString();
|
||||||
|
String updated = m_postIt.getUpdatedString();
|
||||||
|
|
||||||
|
if (!updated.equals(""))
|
||||||
|
createdupdated += "\n" + updated;
|
||||||
|
|
||||||
|
modifText.setText(createdupdated);
|
||||||
|
modifText.setReadWrite(false);
|
||||||
|
|
||||||
|
updateStatusBar();
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
AEnv.showCenterWindow(frame, this);
|
||||||
|
}
|
||||||
|
catch (Exception e)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
modifText.requestFocus();
|
||||||
|
} // Editor
|
||||||
|
|
||||||
|
/** Maximum Size */
|
||||||
|
private int m_maxSize = 2000;
|
||||||
|
/** Logger */
|
||||||
|
private static CLogger log = CLogger.getCLogger(VPostIt.class);
|
||||||
|
|
||||||
|
private CPanel panel = new CPanel();
|
||||||
|
private BorderLayout panelLayout = new BorderLayout();
|
||||||
|
private JTabbedPane tabbedPane = new JTabbedPane();
|
||||||
|
private CTextArea textArea = new CTextArea();
|
||||||
|
private CTextPane textPane = new CTextPane();
|
||||||
|
private JMenuBar menuBar = new JMenuBar();
|
||||||
|
private JMenu mFile = new JMenu();
|
||||||
|
private CMenuItem mImport = new CMenuItem();
|
||||||
|
private CMenuItem mExport = new CMenuItem();
|
||||||
|
private ConfirmPanel confirmPanel = new ConfirmPanel();
|
||||||
|
private StatusBar statusBar = new StatusBar(false);
|
||||||
|
private CTextArea modifText = new CTextArea();
|
||||||
|
private MPostIt m_postIt = null;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Static Init
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
|
private void jbInit() throws Exception
|
||||||
|
{
|
||||||
|
panel.setLayout(panelLayout);
|
||||||
|
this.setJMenuBar(menuBar);
|
||||||
|
// Text Tab
|
||||||
|
textArea.setPreferredSize(new Dimension(500, 300));
|
||||||
|
textArea.setWrapStyleWord(true);
|
||||||
|
textArea.setLineWrap(true);
|
||||||
|
tabbedPane.add(textArea, "Text");
|
||||||
|
textArea.addKeyListener(this);
|
||||||
|
// HTML Tab
|
||||||
|
textPane.setContentType("text/html");
|
||||||
|
textPane.setEditable(false);
|
||||||
|
tabbedPane.add(textPane, "HTML");
|
||||||
|
//
|
||||||
|
// Traduction de File <EFBFBD> partir du message File ; cf org.compiere.apps.AEnv.getMenu(String)
|
||||||
|
String textFile = Msg.getMsg(Env.getCtx(), "File");
|
||||||
|
int pos = textFile.indexOf('&');
|
||||||
|
if (pos != -1 && textFile.length() > pos) // We have a nemonic
|
||||||
|
{
|
||||||
|
char ch = textFile.toUpperCase().charAt(pos+1);
|
||||||
|
if (ch != ' ')
|
||||||
|
textFile = textFile.substring(0, pos) + textFile.substring(pos+1);
|
||||||
|
}
|
||||||
|
mFile.setText(textFile);
|
||||||
|
mImport.setText(Msg.getMsg(Env.getCtx(), "Import"));
|
||||||
|
mImport.addActionListener(this);
|
||||||
|
mExport.setText(Msg.getMsg(Env.getCtx(), "Export"));
|
||||||
|
mExport.addActionListener(this);
|
||||||
|
tabbedPane.addChangeListener(this);
|
||||||
|
|
||||||
|
modifText.setPreferredSize(new Dimension(500,50));
|
||||||
|
JSplitPane textPane = new JSplitPane(JSplitPane.VERTICAL_SPLIT, true, tabbedPane, modifText);
|
||||||
|
panel.add(textPane, BorderLayout.CENTER);
|
||||||
|
|
||||||
|
confirmPanel.addActionListener(this);
|
||||||
|
panel.add(confirmPanel, BorderLayout.SOUTH);
|
||||||
|
this.getContentPane().add(panel, BorderLayout.CENTER);
|
||||||
|
this.getContentPane().add(statusBar, BorderLayout.SOUTH);
|
||||||
|
//
|
||||||
|
menuBar.add(mFile);
|
||||||
|
mFile.add(mImport);
|
||||||
|
mFile.add(mExport);
|
||||||
|
updateStatusBar();
|
||||||
|
} // jbInit
|
||||||
|
|
||||||
|
/**
|
||||||
|
* ActionListener
|
||||||
|
* @param e event
|
||||||
|
*/
|
||||||
|
public void actionPerformed(ActionEvent e)
|
||||||
|
{
|
||||||
|
if (e.getActionCommand().equals(ConfirmPanel.A_OK))
|
||||||
|
{
|
||||||
|
m_postIt.setText(textArea.getText());
|
||||||
|
m_postIt.saveEx();
|
||||||
|
log.fine("OK - length=" + textArea.getText().length());
|
||||||
|
dispose();
|
||||||
|
}
|
||||||
|
else if (e.getActionCommand().equals(ConfirmPanel.A_CANCEL))
|
||||||
|
dispose();
|
||||||
|
else if (e.getSource() == mImport)
|
||||||
|
importText();
|
||||||
|
else if (e.getSource() == mExport)
|
||||||
|
exportText();
|
||||||
|
} // actionPerformed
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Update Status Bar
|
||||||
|
*/
|
||||||
|
private void updateStatusBar()
|
||||||
|
{
|
||||||
|
String str = textArea.getText();
|
||||||
|
int length = str.length();
|
||||||
|
statusBar.setStatusDB(length);
|
||||||
|
int size = length;
|
||||||
|
try
|
||||||
|
{
|
||||||
|
size = str.getBytes("UTF-8").length;
|
||||||
|
}
|
||||||
|
catch (UnsupportedEncodingException e)
|
||||||
|
{
|
||||||
|
log.log(Level.SEVERE, str, e);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (m_maxSize == 0)
|
||||||
|
statusBar.setStatusLine(String.valueOf(size));
|
||||||
|
else if (size < m_maxSize)
|
||||||
|
statusBar.setStatusLine(size + " < " + m_maxSize, false);
|
||||||
|
else if (size == m_maxSize)
|
||||||
|
statusBar.setStatusLine(size + " = " + m_maxSize, false);
|
||||||
|
else
|
||||||
|
{
|
||||||
|
statusBar.setStatusLine(size + " > " + m_maxSize, true);
|
||||||
|
Toolkit.getDefaultToolkit().beep();
|
||||||
|
}
|
||||||
|
} // updateStatusBar
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Import Text from File
|
||||||
|
*/
|
||||||
|
private void importText()
|
||||||
|
{
|
||||||
|
JFileChooser jc = new JFileChooser();
|
||||||
|
jc.setDialogTitle(Msg.getMsg(Env.getCtx(), "ImportText"));
|
||||||
|
jc.setDialogType(JFileChooser.OPEN_DIALOG);
|
||||||
|
jc.setFileSelectionMode(JFileChooser.FILES_ONLY);
|
||||||
|
//
|
||||||
|
if (jc.showOpenDialog(this) != JFileChooser.APPROVE_OPTION)
|
||||||
|
return;
|
||||||
|
|
||||||
|
StringBuffer sb = new StringBuffer();
|
||||||
|
try
|
||||||
|
{
|
||||||
|
InputStreamReader in = new InputStreamReader (new FileInputStream (jc.getSelectedFile()));
|
||||||
|
char[] cbuf = new char[1024];
|
||||||
|
int count;
|
||||||
|
while ((count = in.read(cbuf)) > 0)
|
||||||
|
sb.append(cbuf, 0, count);
|
||||||
|
in.close();
|
||||||
|
}
|
||||||
|
catch (Exception e)
|
||||||
|
{
|
||||||
|
log.log(Level.WARNING, e.getMessage());
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
textArea.setText(sb.toString());
|
||||||
|
updateStatusBar();
|
||||||
|
} // importText
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Export Text to File
|
||||||
|
*/
|
||||||
|
private void exportText()
|
||||||
|
{
|
||||||
|
JFileChooser jc = new JFileChooser();
|
||||||
|
jc.setDialogTitle(Msg.getMsg(Env.getCtx(), "ExportText"));
|
||||||
|
jc.setDialogType(JFileChooser.SAVE_DIALOG);
|
||||||
|
jc.setFileSelectionMode(JFileChooser.FILES_ONLY);
|
||||||
|
//
|
||||||
|
if (jc.showSaveDialog(this) != JFileChooser.APPROVE_OPTION)
|
||||||
|
return;
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
BufferedWriter bout = new BufferedWriter (new OutputStreamWriter (new FileOutputStream (jc.getSelectedFile())));
|
||||||
|
bout.write(textArea.getText());
|
||||||
|
bout.flush();
|
||||||
|
bout.close();
|
||||||
|
}
|
||||||
|
catch (Exception e)
|
||||||
|
{
|
||||||
|
log.log(Level.WARNING, e.getMessage());
|
||||||
|
}
|
||||||
|
} // exportText
|
||||||
|
|
||||||
|
/**
|
||||||
|
* ChangeListener for TabbedPane
|
||||||
|
* @param e event
|
||||||
|
*/
|
||||||
|
public void stateChanged(ChangeEvent e)
|
||||||
|
{
|
||||||
|
if (tabbedPane.getSelectedIndex() == 1) // switch to HTML
|
||||||
|
textPane.setText(textArea.getText());
|
||||||
|
} // stateChanged
|
||||||
|
|
||||||
|
public void keyTyped (KeyEvent e)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
public void keyPressed (KeyEvent e)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
public void keyReleased (KeyEvent e)
|
||||||
|
{
|
||||||
|
updateStatusBar();
|
||||||
|
}
|
||||||
|
|
||||||
|
} // VPostIt
|
Binary file not shown.
After Width: | Height: | Size: 613 B |
Binary file not shown.
After Width: | Height: | Size: 1.4 KiB |
Binary file not shown.
After Width: | Height: | Size: 853 B |
Binary file not shown.
After Width: | Height: | Size: 2.5 KiB |
|
@ -96,6 +96,8 @@ public class ADWindowToolbar extends FToolbar implements EventListener<Event>
|
||||||
private ToolBarButton btnZoomAcross, btnActiveWorkflows, btnRequests, btnProductInfo;
|
private ToolBarButton btnZoomAcross, btnActiveWorkflows, btnRequests, btnProductInfo;
|
||||||
|
|
||||||
private ToolBarButton btnChat;
|
private ToolBarButton btnChat;
|
||||||
|
|
||||||
|
private ToolBarButton btnPostIt;
|
||||||
|
|
||||||
private ToolBarButton btnCustomize;
|
private ToolBarButton btnCustomize;
|
||||||
|
|
||||||
|
@ -167,6 +169,7 @@ public class ADWindowToolbar extends FToolbar implements EventListener<Event>
|
||||||
btnFind = createButton("Find", "Find", "Find");
|
btnFind = createButton("Find", "Find", "Find");
|
||||||
btnFind.setTooltiptext(btnFind.getTooltiptext()+ " Alt+F");
|
btnFind.setTooltiptext(btnFind.getTooltiptext()+ " Alt+F");
|
||||||
btnAttachment = createButton("Attachment", "Attachment", "Attachment");
|
btnAttachment = createButton("Attachment", "Attachment", "Attachment");
|
||||||
|
btnPostIt = createButton("PostIt", "PostIt", "PostIt");
|
||||||
btnChat = createButton("Chat", "Chat", "Chat");
|
btnChat = createButton("Chat", "Chat", "Chat");
|
||||||
btnGridToggle = createButton("Toggle", "Multi", "Multi");
|
btnGridToggle = createButton("Toggle", "Multi", "Multi");
|
||||||
btnGridToggle.setTooltiptext(btnGridToggle.getTooltiptext()+ " Alt+T");
|
btnGridToggle.setTooltiptext(btnGridToggle.getTooltiptext()+ " Alt+T");
|
||||||
|
@ -560,6 +563,11 @@ public class ADWindowToolbar extends FToolbar implements EventListener<Event>
|
||||||
this.btnLock.setImage(imgURL);
|
this.btnLock.setImage(imgURL);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void enablePostIt(boolean enabled)
|
||||||
|
{
|
||||||
|
this.btnPostIt.setDisabled(!enabled);
|
||||||
|
}
|
||||||
|
|
||||||
public Event getEvent()
|
public Event getEvent()
|
||||||
{
|
{
|
||||||
return event;
|
return event;
|
||||||
|
|
|
@ -75,6 +75,7 @@ import org.adempiere.webui.window.CustomizeGridViewDialog;
|
||||||
import org.adempiere.webui.window.FDialog;
|
import org.adempiere.webui.window.FDialog;
|
||||||
import org.adempiere.webui.window.FindWindow;
|
import org.adempiere.webui.window.FindWindow;
|
||||||
import org.adempiere.webui.window.WChat;
|
import org.adempiere.webui.window.WChat;
|
||||||
|
import org.adempiere.webui.window.WPostIt;
|
||||||
import org.adempiere.webui.window.WRecordAccessDialog;
|
import org.adempiere.webui.window.WRecordAccessDialog;
|
||||||
import org.compiere.grid.ICreateFrom;
|
import org.compiere.grid.ICreateFrom;
|
||||||
import org.compiere.model.DataStatusEvent;
|
import org.compiere.model.DataStatusEvent;
|
||||||
|
@ -1022,6 +1023,47 @@ public abstract class AbstractADWindowContent extends AbstractUIPart implements
|
||||||
chat.showWindow();
|
chat.showWindow();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void onPostIt()
|
||||||
|
{
|
||||||
|
int recordId = adTabbox.getSelectedGridTab().getRecord_ID();
|
||||||
|
logger.info("Record_ID=" + recordId);
|
||||||
|
|
||||||
|
if (recordId== -1) // No Key
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Find display
|
||||||
|
String infoName = null;
|
||||||
|
String infoDisplay = null;
|
||||||
|
for (int i = 0; i < adTabbox.getSelectedGridTab().getFieldCount(); i++)
|
||||||
|
{
|
||||||
|
GridField field = adTabbox.getSelectedGridTab().getField(i);
|
||||||
|
if (field.isKey())
|
||||||
|
infoName = field.getHeader();
|
||||||
|
if ((field.getColumnName().equals("Name") || field.getColumnName().equals("DocumentNo") )
|
||||||
|
&& field.getValue() != null)
|
||||||
|
infoDisplay = field.getValue().toString();
|
||||||
|
if (infoName != null && infoDisplay != null)
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
String header = infoName + ": " + infoDisplay;
|
||||||
|
|
||||||
|
WPostIt postit = new WPostIt(header, adTabbox.getSelectedGridTab().getAD_PostIt_ID(), adTabbox.getSelectedGridTab().getAD_Table_ID(), recordId, null);
|
||||||
|
postit.addEventListener(DialogEvents.ON_WINDOW_CLOSE, new EventListener<Event>() {
|
||||||
|
@Override
|
||||||
|
public void onEvent(Event event) throws Exception {
|
||||||
|
hideBusyMask();
|
||||||
|
toolbar.getButton("PostIt").setPressed(adTabbox.getSelectedGridTab().hasPostIt());
|
||||||
|
focusToActivePanel();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
getComponent().getParent().appendChild(postit);
|
||||||
|
showBusyMask(postit);
|
||||||
|
LayoutUtils.openOverlappedWindow(getComponent(), postit, "middle_center");
|
||||||
|
postit.showWindow();
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see ToolbarListener#onToggle()
|
* @see ToolbarListener#onToggle()
|
||||||
*/
|
*/
|
||||||
|
@ -1291,6 +1333,7 @@ public abstract class AbstractADWindowContent extends AbstractUIPart implements
|
||||||
toolbar.enableTabNavigation(breadCrumb.hasParentLink(), adTabbox.getSelectedDetailADTabpanel() != null);
|
toolbar.enableTabNavigation(breadCrumb.hasParentLink(), adTabbox.getSelectedDetailADTabpanel() != null);
|
||||||
|
|
||||||
toolbar.getButton("Attachment").setPressed(adTabbox.getSelectedGridTab().hasAttachment());
|
toolbar.getButton("Attachment").setPressed(adTabbox.getSelectedGridTab().hasAttachment());
|
||||||
|
toolbar.getButton("PostIt").setPressed(adTabbox.getSelectedGridTab().hasPostIt());
|
||||||
toolbar.getButton("Chat").setPressed(adTabbox.getSelectedGridTab().hasChat());
|
toolbar.getButton("Chat").setPressed(adTabbox.getSelectedGridTab().hasChat());
|
||||||
toolbar.getButton("Find").setPressed(adTabbox.getSelectedGridTab().isQueryActive());
|
toolbar.getButton("Find").setPressed(adTabbox.getSelectedGridTab().isQueryActive());
|
||||||
|
|
||||||
|
@ -1627,7 +1670,7 @@ public abstract class AbstractADWindowContent extends AbstractUIPart implements
|
||||||
toolbar.enableAttachment(false);
|
toolbar.enableAttachment(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check Chat
|
// Check Chat and PostIt
|
||||||
boolean canHaveChat = true;
|
boolean canHaveChat = true;
|
||||||
if (e.isLoading() &&
|
if (e.isLoading() &&
|
||||||
adTabbox.getSelectedGridTab().getCurrentRow() > e.getLoadedRows())
|
adTabbox.getSelectedGridTab().getCurrentRow() > e.getLoadedRows())
|
||||||
|
@ -1642,10 +1685,13 @@ public abstract class AbstractADWindowContent extends AbstractUIPart implements
|
||||||
{
|
{
|
||||||
toolbar.enableChat(true);
|
toolbar.enableChat(true);
|
||||||
toolbar.getButton("Chat").setPressed(adTabbox.getSelectedGridTab().hasChat());
|
toolbar.getButton("Chat").setPressed(adTabbox.getSelectedGridTab().hasChat());
|
||||||
|
toolbar.enablePostIt(true);
|
||||||
|
toolbar.getButton("PostIt").setPressed(adTabbox.getSelectedGridTab().hasPostIt());
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
toolbar.enableChat(false);
|
toolbar.enableChat(false);
|
||||||
|
toolbar.enablePostIt(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
toolbar.getButton("Find").setPressed(adTabbox.getSelectedGridTab().isQueryActive());
|
toolbar.getButton("Find").setPressed(adTabbox.getSelectedGridTab().isQueryActive());
|
||||||
|
|
|
@ -0,0 +1,200 @@
|
||||||
|
/******************************************************************************
|
||||||
|
* Copyright (C) 2008 Low Heng Sin *
|
||||||
|
* This program is free software; you can redistribute it and/or modify it *
|
||||||
|
* under the terms version 2 of the GNU General Public License as published *
|
||||||
|
* by the Free Software Foundation. This program is distributed in the hope *
|
||||||
|
* that it will be useful, but WITHOUT ANY WARRANTY; without even the implied *
|
||||||
|
* warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. *
|
||||||
|
* See the GNU General Public License for more details. *
|
||||||
|
* You should have received a copy of the GNU General Public License along *
|
||||||
|
* with this program; if not, write to the Free Software Foundation, Inc., *
|
||||||
|
* 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. *
|
||||||
|
*****************************************************************************/
|
||||||
|
package org.adempiere.webui.window;
|
||||||
|
|
||||||
|
import org.adempiere.webui.component.ConfirmPanel;
|
||||||
|
import org.adempiere.webui.component.Label;
|
||||||
|
import org.adempiere.webui.component.Tab;
|
||||||
|
import org.adempiere.webui.component.Tabbox;
|
||||||
|
import org.adempiere.webui.component.Tabpanel;
|
||||||
|
import org.adempiere.webui.component.Tabpanels;
|
||||||
|
import org.adempiere.webui.component.Tabs;
|
||||||
|
import org.adempiere.webui.component.Textbox;
|
||||||
|
import org.adempiere.webui.component.VerticalBox;
|
||||||
|
import org.adempiere.webui.component.Window;
|
||||||
|
import org.compiere.model.MPostIt;
|
||||||
|
import org.compiere.util.Env;
|
||||||
|
import org.zkforge.ckez.CKeditor;
|
||||||
|
import org.zkoss.zk.ui.event.Event;
|
||||||
|
import org.zkoss.zk.ui.event.EventListener;
|
||||||
|
import org.zkoss.zk.ui.event.Events;
|
||||||
|
import org.zkoss.zul.Separator;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* bas<EFBFBD> sur WTextEditorDialog
|
||||||
|
* @author Nico
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
public class WPostIt extends Window implements EventListener<Event>{
|
||||||
|
|
||||||
|
private static final long serialVersionUID = -3852236029054284848L;
|
||||||
|
private boolean editable;
|
||||||
|
private int maxSize;
|
||||||
|
private String note;
|
||||||
|
private Tabbox tabbox;
|
||||||
|
private Textbox textBox;
|
||||||
|
private CKeditor editor;
|
||||||
|
private Label status;
|
||||||
|
private Label createdBox;
|
||||||
|
private Label updatedBox;
|
||||||
|
private String created;
|
||||||
|
private String updated;
|
||||||
|
private MPostIt m_postIt;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param title
|
||||||
|
* @param text
|
||||||
|
* @param editable
|
||||||
|
* @param maxSize
|
||||||
|
*/
|
||||||
|
public WPostIt(String title, int postItID, int tableID, int recordID, /*String created, String updated,*/ String trxName) {
|
||||||
|
super();
|
||||||
|
setTitle(title);
|
||||||
|
this.editable = true;
|
||||||
|
this.maxSize = 2000;
|
||||||
|
|
||||||
|
if (postItID > 0)
|
||||||
|
m_postIt = new MPostIt (Env.getCtx(), postItID, trxName);
|
||||||
|
else
|
||||||
|
m_postIt = new MPostIt (Env.getCtx(), tableID, recordID, trxName);
|
||||||
|
|
||||||
|
String created = null;
|
||||||
|
if (m_postIt.getAD_Postit_ID() > 0)
|
||||||
|
created = m_postIt.getCreatedString();
|
||||||
|
String updated = m_postIt.getUpdatedString();
|
||||||
|
|
||||||
|
this.created = created;
|
||||||
|
this.updated = updated;
|
||||||
|
this.note = m_postIt.getText();
|
||||||
|
|
||||||
|
init();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void init() {
|
||||||
|
setBorder("normal");
|
||||||
|
|
||||||
|
VerticalBox vbox = new VerticalBox();
|
||||||
|
appendChild(vbox);
|
||||||
|
|
||||||
|
tabbox = new Tabbox();
|
||||||
|
vbox.appendChild(tabbox);
|
||||||
|
Tabs tabs = new Tabs();
|
||||||
|
tabbox.appendChild(tabs);
|
||||||
|
Tabpanels tabPanels = new Tabpanels();
|
||||||
|
tabbox.appendChild(tabPanels);
|
||||||
|
|
||||||
|
Tab tab = new Tab("Text");
|
||||||
|
tabs.appendChild(tab);
|
||||||
|
|
||||||
|
Tabpanel tabPanel = new Tabpanel();
|
||||||
|
tabPanels.appendChild(tabPanel);
|
||||||
|
textBox = new Textbox(note);
|
||||||
|
textBox.setCols(80);
|
||||||
|
textBox.setRows(30);
|
||||||
|
textBox.setEnabled(editable);
|
||||||
|
textBox.setWidth("700px");
|
||||||
|
textBox.setHeight("500px");
|
||||||
|
tabPanel.appendChild(textBox);
|
||||||
|
|
||||||
|
tab = new Tab("HTML");
|
||||||
|
tabs.appendChild(tab);
|
||||||
|
|
||||||
|
tabPanel = new Tabpanel();
|
||||||
|
tabPanels.appendChild(tabPanel);
|
||||||
|
|
||||||
|
editor = new CKeditor();
|
||||||
|
tabPanel.appendChild(editor);
|
||||||
|
editor.setWidth("700px");
|
||||||
|
editor.setHeight("500px");
|
||||||
|
editor.setValue(note);
|
||||||
|
|
||||||
|
vbox.appendChild(new Separator());
|
||||||
|
createdBox = new Label();
|
||||||
|
createdBox.setText(created);
|
||||||
|
vbox.appendChild(createdBox);
|
||||||
|
updatedBox = new Label();
|
||||||
|
updatedBox.setText(updated);
|
||||||
|
vbox.appendChild(updatedBox);
|
||||||
|
|
||||||
|
vbox.appendChild(new Separator());
|
||||||
|
|
||||||
|
ConfirmPanel confirmPanel = new ConfirmPanel(true);
|
||||||
|
vbox.appendChild(confirmPanel);
|
||||||
|
confirmPanel.addActionListener(this);
|
||||||
|
|
||||||
|
if (maxSize > 0) {
|
||||||
|
status = new Label();
|
||||||
|
appendChild(status);
|
||||||
|
updateStatus(note==null ? 0 : note.length());
|
||||||
|
|
||||||
|
status.setStyle("margin-top:10px;");
|
||||||
|
textBox.addEventListener(Events.ON_CHANGE, this);
|
||||||
|
editor.addEventListener(Events.ON_CHANGE, this);
|
||||||
|
}
|
||||||
|
|
||||||
|
tabbox.addEventListener(Events.ON_SELECT, this);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param event
|
||||||
|
*/
|
||||||
|
public void onEvent(Event event) throws Exception {
|
||||||
|
if (event.getTarget().getId().equals(ConfirmPanel.A_CANCEL)) {
|
||||||
|
detach();
|
||||||
|
} else if (event.getTarget().getId().equals(ConfirmPanel.A_OK)) {
|
||||||
|
if (editable) {
|
||||||
|
m_postIt.setText(textBox.getText());
|
||||||
|
m_postIt.saveEx();
|
||||||
|
}
|
||||||
|
detach();
|
||||||
|
} else if (event.getName().equals(Events.ON_SELECT)) {
|
||||||
|
if (editable) {
|
||||||
|
if (tabbox.getSelectedIndex() == 0) {
|
||||||
|
textBox.setText(editor.getValue());
|
||||||
|
updateStatus(textBox.getText().length());
|
||||||
|
} else {
|
||||||
|
editor.setValue(textBox.getText());
|
||||||
|
updateStatus(editor.getValue().length());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else if (event.getName().equals(Events.ON_CHANGE)) {
|
||||||
|
if (event.getTarget() == textBox) {
|
||||||
|
updateStatus(textBox.getText().length());
|
||||||
|
} else if (event.getTarget() == editor) {
|
||||||
|
updateStatus(editor.getValue().length());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void updateStatus(int newLength) {
|
||||||
|
if (status != null && maxSize > 0) {
|
||||||
|
StringBuffer msg = new StringBuffer();
|
||||||
|
msg.append(newLength);
|
||||||
|
if (newLength == maxSize)
|
||||||
|
msg.append(" = ");
|
||||||
|
else if (newLength < maxSize)
|
||||||
|
msg.append(" < ");
|
||||||
|
else
|
||||||
|
msg.append(" > ");
|
||||||
|
msg.append(maxSize);
|
||||||
|
|
||||||
|
status.setValue(msg.toString());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public void showWindow()
|
||||||
|
{
|
||||||
|
textBox.focus();
|
||||||
|
}
|
||||||
|
}
|
Binary file not shown.
After Width: | Height: | Size: 2.0 KiB |
Loading…
Reference in New Issue