[ 2056097 ] Fix Multiple Change Components

http://sourceforge.net/tracker/index.php?func=detail&aid=2056097&group_id=176962&atid=879332
This commit is contained in:
vpj-cd 2008-08-17 17:39:12 +00:00
parent 274d3df9f7
commit fc486133a5
3 changed files with 345 additions and 150 deletions

View File

@ -20,20 +20,17 @@ import java.math.*;
import java.sql.*;
import java.util.*;
import java.util.logging.*;
import org.compiere.model.*;
import org.compiere.util.*;
import org.compiere.model.Query;
import org.compiere.process.*;
//import compiere.model.*;
import org.eevolution.model.QueryDB;
import org.eevolution.model.*;
/**
* Component Change into BOM
*
* @author Victor Perez
* @version $Id: ComponentChange.java,v 1.1 2004/01/17 05:24:03 jjanke Exp $
* @author victor.perez@e-evolution.com
* @version $Id: ComponentChange.java
*/
public class ComponentChange extends SvrProcess
{
@ -44,6 +41,7 @@ public class ComponentChange extends SvrProcess
private String p_Action;
private int p_New_M_Product_ID =0;
private BigDecimal p_Qty = null;
private int p_M_ChangeNotice_ID=0;
private int morepara = 0;
/**
* Prepare - e.g., get Parameters.
@ -60,7 +58,7 @@ public class ComponentChange extends SvrProcess
;
else if (name.equals("M_Product_ID") && morepara == 0)
{
p_M_Product_ID = ((BigDecimal)para[i].getParameter()).intValue();
p_M_Product_ID = para[i].getParameterAsInt();
morepara = 1;
}
else if (name.equals("ValidTo"))
@ -70,52 +68,44 @@ public class ComponentChange extends SvrProcess
else if (name.equals("Action"))
p_Action = ((String)para[i].getParameter());
else if (name.equals("M_Product_ID"))
p_New_M_Product_ID = ((BigDecimal)para[i].getParameter()).intValue();
p_New_M_Product_ID = para[i].getParameterAsInt();
else if (name.equals("Qty"))
p_Qty = ((BigDecimal)para[i].getParameter());
else if (name.equals("M_ChangeNotice_ID"))
p_M_ChangeNotice_ID = para[i].getParameterAsInt();
else
log.log(Level.SEVERE,"prepare - Unknown Parameter: " + name);
}
} // prepare
/**
* Perrform process.
* Perform process.
* @return Message
* @throws Exception if not successful
*/
protected String doIt() throws Exception
{
StringBuffer result = new StringBuffer("");
/*System.out.println("Existing Product" + p_M_Product_ID );
System.out.println("ValidTo" + p_ValidTo );
System.out.println("ValidFrom" + p_ValidFrom );
System.out.println("Action" + p_Action );
System.out.println("New Product" + p_New_M_Product_ID);
System.out.println("Qty" + p_Qty );*/
log.info("Existing Product" + p_M_Product_ID );
log.info("ValidTo" + p_ValidTo);
log.info("ValidFrom" + p_ValidFrom);
log.info("Action" + p_Action);
log.info("New Product" + p_New_M_Product_ID);
log.info("Qty" + p_Qty );
QueryDB query = new QueryDB("org.eevolution.model.X_PP_Product_BOMLine");
StringBuffer filter = new StringBuffer("M_Product_ID = " + p_M_Product_ID);
if (p_ValidFrom != null)
{
filter.append(" AND TRUNC(ValidFrom) >= ").append(DB.TO_DATE(p_ValidTo, true));
}
String whereClause = "M_Product_ID = ?";
if (p_ValidTo !=null)
whereClause +=" AND TRUNC(ValidTo) <= "+ DB.TO_DATE(p_ValidTo);
if (p_ValidFrom != null)
whereClause +=" AND TRUNC(ValidFrom) >= "+DB.TO_DATE(p_ValidFrom);
List<MPPProductBOMLine> components = new Query(getCtx(), MPPProductBOMLine.Table_Name,
whereClause,get_TrxName()).setParameters(new Object[]{p_M_Product_ID}).list();
for(MPPProductBOMLine bomline : components)
{
filter.append(" AND TRUNC(ValidTo) <= ").append(DB.TO_DATE(p_ValidTo, true));
}
java.util.List results = query.execute(filter.toString());
Iterator select = results.iterator();
while (select.hasNext())
{
X_PP_Product_BOMLine bomline = (X_PP_Product_BOMLine) select.next();
if (p_Action.equals("A"))
{
X_PP_Product_BOMLine newbomline = new X_PP_Product_BOMLine(Env.getCtx(), 0,null);
MPPProductBOMLine newbomline = new MPPProductBOMLine(Env.getCtx(), 0 ,get_TrxName());
newbomline.setAssay(bomline.getAssay());
newbomline.setBackflushGroup(bomline.getBackflushGroup());
newbomline.setQtyBatch(bomline.getQtyBatch());
@ -136,24 +126,27 @@ public class ComponentChange extends SvrProcess
newbomline.setPP_Product_BOM_ID(bomline.getPP_Product_BOM_ID());
newbomline.setScrap(bomline.getScrap());
newbomline.setValidFrom(newbomline.getUpdated());
newbomline.save(get_TrxName());
result.append("Component add");
newbomline.setM_ChangeNotice_ID(p_M_ChangeNotice_ID);
newbomline.saveEx();
addLog("Component add");
}
else if (p_Action.equals("D"))
{
bomline.setM_ChangeNotice_ID(p_M_ChangeNotice_ID);
bomline.setIsActive(false);
bomline.save(get_TrxName());
result.append("Deactivate ");
bomline.saveEx();
addLog("Deactivate ");
}
else if (p_Action.equals("E"))
{
bomline.setM_ChangeNotice_ID(p_M_ChangeNotice_ID);
bomline.setValidTo(bomline.getUpdated());
bomline.save(get_TrxName());
result.append("Expire ");
bomline.saveEx();
addLog("Expire");
}
else if (p_Action.equals("R"))
{
X_PP_Product_BOMLine newbomline = new X_PP_Product_BOMLine(Env.getCtx(), 0,null);
MPPProductBOMLine newbomline = new MPPProductBOMLine(getCtx(), 0 , get_TrxName());
newbomline.setAssay(bomline.getAssay());
newbomline.setBackflushGroup(bomline.getBackflushGroup());
newbomline.setQtyBatch(bomline.getQtyBatch());
@ -174,14 +167,16 @@ public class ComponentChange extends SvrProcess
newbomline.setPP_Product_BOM_ID(bomline.getPP_Product_BOM_ID());
newbomline.setScrap(bomline.getScrap());
newbomline.setValidFrom(newbomline.getUpdated());
newbomline.save(get_TrxName());
newbomline.setM_ChangeNotice_ID(p_M_ChangeNotice_ID);
newbomline.save();
bomline.setIsActive(false);
bomline.save(get_TrxName());
result.append("Replace");
bomline.setM_ChangeNotice_ID(p_M_ChangeNotice_ID);
bomline.saveEx();
addLog("Replace");
}
else if (p_Action.equals("RE"))
{
X_PP_Product_BOMLine newbomline = new X_PP_Product_BOMLine(Env.getCtx(), 0,null);
MPPProductBOMLine newbomline = new MPPProductBOMLine(getCtx(), 0 , get_TrxName());
newbomline.setAssay(bomline.getAssay());
newbomline.setBackflushGroup(bomline.getBackflushGroup());
newbomline.setQtyBatch(bomline.getQtyBatch());
@ -203,13 +198,13 @@ public class ComponentChange extends SvrProcess
newbomline.setPP_Product_BOM_ID(bomline.getPP_Product_BOM_ID());
newbomline.setScrap(bomline.getScrap());
newbomline.setValidFrom(newbomline.getUpdated());
newbomline.save(get_TrxName());
newbomline.saveEx();
bomline.setValidTo(bomline.getUpdated());
bomline.save(get_TrxName());
result.append("Replace & Expire");
bomline.setM_ChangeNotice_ID(p_M_ChangeNotice_ID);
bomline.saveEx();
addLog("Replace & Expire");
}
}
return result.toString();
return "@OK@";
} // doIt
} // Componet Change
} // Component Change

View File

@ -0,0 +1,100 @@
-- Aug 17, 2008 10:49:37 AM CDT
-- Water Mark for Document Printed
INSERT INTO AD_Process_Para (AD_Client_ID,AD_Element_ID,AD_Org_ID,AD_Process_ID,AD_Process_Para_ID,AD_Reference_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsCentrallyMaintained,IsMandatory,IsRange,Name,SeqNo,Updated,UpdatedBy) VALUES (0,454,0,53008,53242,19,'M_Product_ID',TO_DATE('2008-08-17 10:49:34','YYYY-MM-DD HH24:MI:SS'),0,'Product, Service, Item','EE01',10,'Identifies an item which is either purchased or sold in this organization.','Y','Y','Y','N','Product',50,TO_DATE('2008-08-17 10:49:34','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Aug 17, 2008 10:49:38 AM CDT
-- Water Mark for Document Printed
INSERT INTO AD_Process_Para_Trl (AD_Language,AD_Process_Para_ID, Description,Help,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Process_Para_ID, t.Description,t.Help,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Process_Para t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Process_Para_ID=53242 AND EXISTS (SELECT * FROM AD_Process_Para_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Process_Para_ID!=t.AD_Process_Para_ID)
;
-- Aug 17, 2008 10:52:26 AM CDT
-- Water Mark for Document Printed
INSERT INTO AD_Process_Para (AD_Client_ID,AD_Element_ID,AD_Org_ID,AD_Process_ID,AD_Process_Para_ID,AD_Reference_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsCentrallyMaintained,IsMandatory,IsRange,Name,SeqNo,Updated,UpdatedBy) VALUES (0,617,0,53008,53243,15,'ValidFrom',TO_DATE('2008-08-17 10:52:25','YYYY-MM-DD HH24:MI:SS'),0,'Valid from including this date (first day)','EE01',10,'The Valid From date indicates the first day of a date range','Y','Y','N','N','Valid from',10,TO_DATE('2008-08-17 10:52:25','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Aug 17, 2008 10:52:26 AM CDT
-- Water Mark for Document Printed
INSERT INTO AD_Process_Para_Trl (AD_Language,AD_Process_Para_ID, Description,Help,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Process_Para_ID, t.Description,t.Help,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Process_Para t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Process_Para_ID=53243 AND EXISTS (SELECT * FROM AD_Process_Para_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Process_Para_ID!=t.AD_Process_Para_ID)
;
-- Aug 17, 2008 10:52:43 AM CDT
-- Water Mark for Document Printed
UPDATE AD_Process_Para SET AD_Element_ID=618,Updated=TO_DATE('2008-08-17 10:52:43','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53031
;
-- Aug 17, 2008 10:54:17 AM CDT
-- Water Mark for Document Printed
INSERT INTO AD_Process_Para (AD_Client_ID,AD_Element_ID,AD_Org_ID,AD_Process_ID,AD_Process_Para_ID,AD_Reference_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsCentrallyMaintained,IsMandatory,IsRange,Name,SeqNo,Updated,UpdatedBy) VALUES (0,526,0,53008,53244,29,'Qty',TO_DATE('2008-08-17 10:54:16','YYYY-MM-DD HH24:MI:SS'),0,'Quantity','EE01',10,'The Quantity indicates the number of a specific product or item for this document.','Y','Y','N','N','Quantity',60,TO_DATE('2008-08-17 10:54:16','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Aug 17, 2008 10:54:17 AM CDT
-- Water Mark for Document Printed
INSERT INTO AD_Process_Para_Trl (AD_Language,AD_Process_Para_ID, Description,Help,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Process_Para_ID, t.Description,t.Help,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Process_Para t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Process_Para_ID=53244 AND EXISTS (SELECT * FROM AD_Process_Para_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Process_Para_ID!=t.AD_Process_Para_ID)
;
-- Aug 17, 2008 10:54:41 AM CDT
-- Water Mark for Document Printed
UPDATE AD_Process_Para SET IsCentrallyMaintained='N',Updated=TO_DATE('2008-08-17 10:54:41','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53243
;
-- Aug 17, 2008 10:55:07 AM CDT
-- Water Mark for Document Printed
UPDATE AD_Process_Para SET SeqNo=10,Updated=TO_DATE('2008-08-17 10:55:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53242
;
-- Aug 17, 2008 10:55:14 AM CDT
-- Water Mark for Document Printed
UPDATE AD_Process_Para SET SeqNo=30,Updated=TO_DATE('2008-08-17 10:55:14','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53031
;
-- Aug 17, 2008 10:55:18 AM CDT
-- Water Mark for Document Printed
UPDATE AD_Process_Para SET SeqNo=20,Updated=TO_DATE('2008-08-17 10:55:18','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53243
;
-- Aug 17, 2008 10:55:34 AM CDT
-- Water Mark for Document Printed
UPDATE AD_Process_Para SET FieldLength=10,Updated=TO_DATE('2008-08-17 10:55:34','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53030
;
-- Aug 17, 2008 10:55:41 AM CDT
-- Water Mark for Document Printed
UPDATE AD_Process_Para SET FieldLength=10,Updated=TO_DATE('2008-08-17 10:55:41','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53032
;
-- Aug 17, 2008 10:55:56 AM CDT
-- Water Mark for Document Printed
UPDATE AD_Process_Para SET SeqNo=40,Updated=TO_DATE('2008-08-17 10:55:56','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53032
;
-- Aug 17, 2008 10:56:02 AM CDT
-- Water Mark for Document Printed
UPDATE AD_Process_Para SET SeqNo=50,Updated=TO_DATE('2008-08-17 10:56:02','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53030
;
-- Aug 17, 2008 10:57:03 AM CDT
-- Multi Change Component
UPDATE AD_Process_Para SET AD_Element_ID=454,Updated=TO_DATE('2008-08-17 10:57:03','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53030
;
-- Aug 17, 2008 11:00:31 AM CDT
-- Multi Change Component
UPDATE AD_Process_Para SET DisplayLogic=NULL,Updated=TO_DATE('2008-08-17 11:00:31','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53030
;
-- Aug 17, 2008 11:03:26 AM CDT
-- Multi Change Component
UPDATE AD_Process_Para SET DisplayLogic='@Action@=''A'' | @Action@=''R'' | @Action@=''RE'' ',Updated=TO_DATE('2008-08-17 11:03:26','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53030
;
-- Aug 17, 2008 12:04:00 PM CDT
-- Multi Change Component
INSERT INTO AD_Process_Para (AD_Client_ID,AD_Element_ID,AD_Org_ID,AD_Process_ID,AD_Process_Para_ID,AD_Reference_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsCentrallyMaintained,IsMandatory,IsRange,Name,SeqNo,Updated,UpdatedBy) VALUES (0,2783,0,53008,53245,19,'M_ChangeNotice_ID',TO_DATE('2008-08-17 12:03:59','YYYY-MM-DD HH24:MI:SS'),0,'Change Notice','EE01',10,'Bill of Materials (Engineering) Change Notice (Version)','Y','Y','N','N','Change Notice',70,TO_DATE('2008-08-17 12:03:59','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Aug 17, 2008 12:04:00 PM CDT
-- Multi Change Component
INSERT INTO AD_Process_Para_Trl (AD_Language,AD_Process_Para_ID, Description,Help,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Process_Para_ID, t.Description,t.Help,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Process_Para t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Process_Para_ID=53245 AND EXISTS (SELECT * FROM AD_Process_Para_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Process_Para_ID!=t.AD_Process_Para_ID)
;

View File

@ -0,0 +1,100 @@
-- Aug 17, 2008 10:49:37 AM CDT
-- Multi Change Component
INSERT INTO AD_Process_Para (AD_Client_ID,AD_Element_ID,AD_Org_ID,AD_Process_ID,AD_Process_Para_ID,AD_Reference_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsCentrallyMaintained,IsMandatory,IsRange,Name,SeqNo,Updated,UpdatedBy) VALUES (0,454,0,53008,53242,19,'M_Product_ID',TO_TIMESTAMP('2008-08-17 10:49:34','YYYY-MM-DD HH24:MI:SS'),0,'Product, Service, Item','EE01',10,'Identifies an item which is either purchased or sold in this organization.','Y','Y','Y','N','Product',50,TO_TIMESTAMP('2008-08-17 10:49:34','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Aug 17, 2008 10:49:38 AM CDT
-- Multi Change Component
INSERT INTO AD_Process_Para_Trl (AD_Language,AD_Process_Para_ID, Description,Help,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Process_Para_ID, t.Description,t.Help,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Process_Para t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Process_Para_ID=53242 AND EXISTS (SELECT * FROM AD_Process_Para_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Process_Para_ID!=t.AD_Process_Para_ID)
;
-- Aug 17, 2008 10:52:26 AM CDT
-- Multi Change Component
INSERT INTO AD_Process_Para (AD_Client_ID,AD_Element_ID,AD_Org_ID,AD_Process_ID,AD_Process_Para_ID,AD_Reference_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsCentrallyMaintained,IsMandatory,IsRange,Name,SeqNo,Updated,UpdatedBy) VALUES (0,617,0,53008,53243,15,'ValidFrom',TO_TIMESTAMP('2008-08-17 10:52:25','YYYY-MM-DD HH24:MI:SS'),0,'Valid from including this date (first day)','EE01',10,'The Valid From date indicates the first day of a date range','Y','Y','N','N','Valid from',10,TO_TIMESTAMP('2008-08-17 10:52:25','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Aug 17, 2008 10:52:26 AM CDT
-- Multi Change Component
INSERT INTO AD_Process_Para_Trl (AD_Language,AD_Process_Para_ID, Description,Help,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Process_Para_ID, t.Description,t.Help,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Process_Para t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Process_Para_ID=53243 AND EXISTS (SELECT * FROM AD_Process_Para_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Process_Para_ID!=t.AD_Process_Para_ID)
;
-- Aug 17, 2008 10:52:43 AM CDT
-- Multi Change Component
UPDATE AD_Process_Para SET AD_Element_ID=618,Updated=TO_TIMESTAMP('2008-08-17 10:52:43','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53031
;
-- Aug 17, 2008 10:54:17 AM CDT
-- Multi Change Component
INSERT INTO AD_Process_Para (AD_Client_ID,AD_Element_ID,AD_Org_ID,AD_Process_ID,AD_Process_Para_ID,AD_Reference_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsCentrallyMaintained,IsMandatory,IsRange,Name,SeqNo,Updated,UpdatedBy) VALUES (0,526,0,53008,53244,29,'Qty',TO_TIMESTAMP('2008-08-17 10:54:16','YYYY-MM-DD HH24:MI:SS'),0,'Quantity','EE01',10,'The Quantity indicates the number of a specific product or item for this document.','Y','Y','N','N','Quantity',60,TO_TIMESTAMP('2008-08-17 10:54:16','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Aug 17, 2008 10:54:17 AM CDT
-- Multi Change Component
INSERT INTO AD_Process_Para_Trl (AD_Language,AD_Process_Para_ID, Description,Help,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Process_Para_ID, t.Description,t.Help,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Process_Para t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Process_Para_ID=53244 AND EXISTS (SELECT * FROM AD_Process_Para_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Process_Para_ID!=t.AD_Process_Para_ID)
;
-- Aug 17, 2008 10:54:41 AM CDT
-- Multi Change Component
UPDATE AD_Process_Para SET IsCentrallyMaintained='N',Updated=TO_TIMESTAMP('2008-08-17 10:54:41','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53243
;
-- Aug 17, 2008 10:55:07 AM CDT
-- Multi Change Component
UPDATE AD_Process_Para SET SeqNo=10,Updated=TO_TIMESTAMP('2008-08-17 10:55:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53242
;
-- Aug 17, 2008 10:55:14 AM CDT
-- Multi Change Component
UPDATE AD_Process_Para SET SeqNo=30,Updated=TO_TIMESTAMP('2008-08-17 10:55:14','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53031
;
-- Aug 17, 2008 10:55:18 AM CDT
-- Multi Change Component
UPDATE AD_Process_Para SET SeqNo=20,Updated=TO_TIMESTAMP('2008-08-17 10:55:18','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53243
;
-- Aug 17, 2008 10:55:34 AM CDT
-- Multi Change Component
UPDATE AD_Process_Para SET FieldLength=10,Updated=TO_TIMESTAMP('2008-08-17 10:55:34','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53030
;
-- Aug 17, 2008 10:55:41 AM CDT
-- Multi Change Component
UPDATE AD_Process_Para SET FieldLength=10,Updated=TO_TIMESTAMP('2008-08-17 10:55:41','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53032
;
-- Aug 17, 2008 10:55:56 AM CDT
-- Multi Change Component
UPDATE AD_Process_Para SET SeqNo=40,Updated=TO_TIMESTAMP('2008-08-17 10:55:56','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53032
;
-- Aug 17, 2008 10:56:02 AM CDT
-- Multi Change Component
UPDATE AD_Process_Para SET SeqNo=50,Updated=TO_TIMESTAMP('2008-08-17 10:56:02','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53030
;
-- Aug 17, 2008 10:57:03 AM CDT
-- Multi Change Component
UPDATE AD_Process_Para SET AD_Element_ID=454,Updated=TO_TIMESTAMP('2008-08-17 10:57:03','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53030
;
-- Aug 17, 2008 11:00:31 AM CDT
-- Multi Change Component
UPDATE AD_Process_Para SET DisplayLogic=NULL,Updated=TO_TIMESTAMP('2008-08-17 11:00:31','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53030
;
-- Aug 17, 2008 11:03:26 AM CDT
-- Multi Change Component
UPDATE AD_Process_Para SET DisplayLogic='@Action@=''A'' | @Action@=''R'' | @Action@=''RE'' ',Updated=TO_TIMESTAMP('2008-08-17 11:03:26','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_Process_Para_ID=53030
;
-- Aug 17, 2008 12:04:00 PM CDT
-- Multi Change Component
INSERT INTO AD_Process_Para (AD_Client_ID,AD_Element_ID,AD_Org_ID,AD_Process_ID,AD_Process_Para_ID,AD_Reference_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsCentrallyMaintained,IsMandatory,IsRange,Name,SeqNo,Updated,UpdatedBy) VALUES (0,2783,0,53008,53245,19,'M_ChangeNotice_ID',TO_TIMESTAMP('2008-08-17 12:03:59','YYYY-MM-DD HH24:MI:SS'),0,'Change Notice','EE01',10,'Bill of Materials (Engineering) Change Notice (Version)','Y','Y','N','N','Change Notice',70,TO_TIMESTAMP('2008-08-17 12:03:59','YYYY-MM-DD HH24:MI:SS'),0)
;
-- Aug 17, 2008 12:04:00 PM CDT
-- Multi Change Component
INSERT INTO AD_Process_Para_Trl (AD_Language,AD_Process_Para_ID, Description,Help,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Process_Para_ID, t.Description,t.Help,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Process_Para t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Process_Para_ID=53245 AND EXISTS (SELECT * FROM AD_Process_Para_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Process_Para_ID!=t.AD_Process_Para_ID)
;