Project:
View Issue Details[ Jump to Notes ] | [ Issue History ] [ Print ] | |||||||
ID | ||||||||
0015054 | ||||||||
Type | Category | Severity | Reproducibility | Date Submitted | Last Update | |||
backport | [Openbravo ERP] 01. General setup | trivial | always | 2010-10-27 18:10 | 2015-02-12 14:41 | |||
Reporter | egoitz | View Status | public | |||||
Assigned To | mirurita | |||||||
Priority | normal | Resolution | out of date | Fixed in Version | ||||
Status | closed | Fix in branch | Fixed in SCM revision | |||||
Projection | none | ETA | none | Target Version | ||||
OS | Any | Database | Any | Java version | ||||
OS Version | Database version | Ant version | ||||||
Product Version | 2.50MP22 | SCM revision | ||||||
Review Assigned To | ||||||||
Web browser | ||||||||
Modules | Core | |||||||
Regression level | ||||||||
Regression date | ||||||||
Regression introduced in release | ||||||||
Regression introduced by commit | ||||||||
Triggers an Emergency Pack | No | |||||||
Summary | 0015054: The dataset from core used in initial client setup is available when your client was created before add this dataset | |||||||
Description | The dataset from core used in initial client setup is available when your client was created before add this dataset. This dataset shouldn't appear because all the data included on the dataset is already on the client, because it was created before adding this new feature. | |||||||
Steps To Reproduce | -Starting in a release earlier that 2.50mp19 execute the initial client setup -Update to the last release -Go to enterprise managamente window and see that the core dataset is available to be applied. *This is not correct because the data was created before. | |||||||
Tags | No tags attached. | |||||||
Attached Files | issue15054.diff [^] (44,715 bytes) 2011-09-08 17:27 [Show Content] [Hide Content]diff --git a/src-util/modulescript/build/classes/org/openbravo/modulescript/ApplyInitialSetupDataset.class b/src-util/modulescript/build/classes/org/openbravo/modulescript/ApplyInitialSetupDataset.class new file mode 100644 index 0000000000000000000000000000000000000000..a6c286740d892c16c2ae163df34ece1c7f85b179 GIT binary patch literal 11683 zc$~$W2Y4LC*~jNqyOAt}IolXh1vtS4@a*nvGX&U~-E~AHTi6E2ki<DlXZt|biPOo! z>4o&(LwbeugoKtxI_bSP(tCq6NJ2>dbF0$`N1!hx&-3v-KHdFpc6R2i|GDMUcfR*V z#+cjD+sD37r4n&Yy`1_uE#cJ9>99W5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m4;cLm=m%su diff --git a/src-util/modulescript/build/classes/org/openbravo/modulescript/ApplyInitialSetupDatasetData.class b/src-util/modulescript/build/classes/org/openbravo/modulescript/ApplyInitialSetupDatasetData.class new file mode 100644 index 0000000000000000000000000000000000000000..b0696219b48afd5e916ed9b0b533f16b9edf6bd5 GIT binary patch literal 9169 zc$~#p4SZD9mH*$&$9wbg5+IV`AmTt3CLs{82<z}=NJ5PbM3R6a+Blhc34@b)VP+D+ z?sj)8l<fy@TeT}_yIs32ZdWOy1`q|ewcV}Tk8NwU^`q=sb=%$Uwzk`~tzFaqz3<Ir zW->u6yT8pZx%b?A&pqedbI<wT^YYZ2kDdf@shDY?1E1FMR{_k!y*j!Kd<K6l2cOmP zIUU_{d{B<>)6paQztOQt_Mg|WS@wS`oBK69V4y}yIwboq$mXzt2XVyU@<Tcv*71mr zQ5{Eh9Mf@J$D=w<Xn4%P96Vl$lQ>n0C-8Tb_#(cf;Yqpe(+0kbuNe4y{Db8Bs$6?Y zvi_rnuNhc~uWR^*j&JJtC#mmSQs1{Vd`HLA2Ac3)9nZ-ASp!S)JsscI@toZCtQ7XV zY+lguqK+TvIIZKKb^MEtm!!%c>UdelE7G1<b^NQ2A4$nS*6?o{{$0SAv<H@M7YKIP z>4B!`P&Bs9YEpAe9rnP0m0lq*wLO){c3Cky9p5lK*k`2$YC5(@N1{#1XlkITJDX0V z2FT}4MF%YbBN}f>CahGpJuXl^Vx=<)I~5%o;v6R`<B9(MSlWta<)|XT#=kN_1*-)- z;rh)K(_+UdW=cmQWjXqKqJ2qADz#(L<mPBPA;<2dH@hv75x890Zx30izI1fNZW^@X z!$~U>ODBf1P0dukOCBN-O?F$^;i1-OHkz@rvZLMS4OrQUN1Pt6FLy|t%<B?Xl6KDv zPh=>&C(ti9Y*5~*>dr=EH?5Bjx%T@rR?>=P1qQ+;M~Kt9KAPFoVy9AMp%<@C+arlM zFQtC#Ih?m9HbJ1kg14cacigr!W(~<n`abb?EN^c=C)?-RecLJVOk9kym_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z#YFvKmG!5;7yLVka{g2#oPJD0Z(%DWz51?`9=8@za+oLUEd(@H~B63E$)AgvR|b1 z=NT0*u%i9}rF@%__#H;X)70`^#`!axd6tsDPx;SL*NfElJVWgT;lqoJ>eDK6`&pH4 zbYs)c8K(~RbH7su`vu%pUEXj$at$|fJ&cW=DspGzCn`2QwD-p<Hodg^RTY~~g?p8Z z&CY^1qBJCnD^<OOZ<0vVSvlwa6ERnP`U1vzn0E~CehAYZRR1R!|3se3_EYM!`7eJ5 DmFx$C diff --git a/src-util/modulescript/build/javasqlc/src/org/openbravo/modulescript/ApplyInitialSetupDatasetData.java b/src-util/modulescript/build/javasqlc/src/org/openbravo/modulescript/ApplyInitialSetupDatasetData.java new file mode 100644 --- /dev/null +++ b/src-util/modulescript/build/javasqlc/src/org/openbravo/modulescript/ApplyInitialSetupDatasetData.java @@ -0,0 +1,225 @@ +//Sqlc generated V1.O00-1 +package org.openbravo.modulescript; + +import java.sql.*; + +import org.apache.log4j.Logger; + +import javax.servlet.ServletException; + +import org.openbravo.data.FieldProvider; +import org.openbravo.database.ConnectionProvider; +import org.openbravo.data.UtilSql; +import java.util.*; + +class ApplyInitialSetupDatasetData implements FieldProvider { +static Logger log4j = Logger.getLogger(ApplyInitialSetupDatasetData.class); + private String InitRecordNumber="0"; + public String name; + public String adClientId; + public String versionapplied; + public String diffcreated; + public String id; + + public String getInitRecordNumber() { + return InitRecordNumber; + } + + public String getField(String fieldName) { + if (fieldName.equalsIgnoreCase("name")) + return name; + else if (fieldName.equalsIgnoreCase("ad_client_id") || fieldName.equals("adClientId")) + return adClientId; + else if (fieldName.equalsIgnoreCase("versionapplied")) + return versionapplied; + else if (fieldName.equalsIgnoreCase("diffcreated")) + return diffcreated; + else if (fieldName.equalsIgnoreCase("id")) + return id; + else { + log4j.debug("Field does not exist: " + fieldName); + return null; + } + } + + public static ApplyInitialSetupDatasetData[] select(ConnectionProvider connectionProvider) throws ServletException { + return select(connectionProvider, 0, 0); + } + + public static ApplyInitialSetupDatasetData[] select(ConnectionProvider connectionProvider, int firstRegister, int numberRegisters) throws ServletException { + String strSql = ""; + strSql = strSql + + " select c.name, c.ad_client_id, coalesce(cm.version,om.version) as versionApplied," + + " to_number((select coalesce(min(dt.created),now()) from c_doctype dt where dt.ad_client_id=c.ad_client_id) - c.created) as diffCreated," + + " '' as id" + + " from ad_client c" + + " left join ad_clientmodule cm on c.ad_client_id=cm.ad_client_id and cm.ad_module_id='0'" + + " left join ad_orgmodule om on c.ad_client_id=om.ad_client_id and om.ad_module_id='0'" + + " order by c.name"; + + ResultSet result; + Vector<java.lang.Object> vector = new Vector<java.lang.Object>(0); + PreparedStatement st = null; + + try { + st = connectionProvider.getPreparedStatement(strSql); + + result = st.executeQuery(); + long countRecord = 0; + long countRecordSkip = 1; + boolean continueResult = true; + while(countRecordSkip < firstRegister && continueResult) { + continueResult = result.next(); + countRecordSkip++; + } + while(continueResult && result.next()) { + countRecord++; + ApplyInitialSetupDatasetData objectApplyInitialSetupDatasetData = new ApplyInitialSetupDatasetData(); + objectApplyInitialSetupDatasetData.name = UtilSql.getValue(result, "name"); + objectApplyInitialSetupDatasetData.adClientId = UtilSql.getValue(result, "ad_client_id"); + objectApplyInitialSetupDatasetData.versionapplied = UtilSql.getValue(result, "versionapplied"); + objectApplyInitialSetupDatasetData.diffcreated = UtilSql.getValue(result, "diffcreated"); + objectApplyInitialSetupDatasetData.id = UtilSql.getValue(result, "id"); + objectApplyInitialSetupDatasetData.InitRecordNumber = Integer.toString(firstRegister); + vector.addElement(objectApplyInitialSetupDatasetData); + if (countRecord >= numberRegisters && numberRegisters != 0) { + continueResult = false; + } + } + result.close(); + } catch(SQLException e){ + log4j.error("SQL error in query: " + strSql + "Exception:"+ e); + throw new ServletException("@CODE=" + Integer.toString(e.getErrorCode()) + "@" + e.getMessage()); + } catch(Exception ex){ + log4j.error("Exception in query: " + strSql + "Exception:"+ ex); + throw new ServletException("@CODE=@" + ex.getMessage()); + } finally { + try { + connectionProvider.releasePreparedStatement(st); + } catch(Exception ignore){ + ignore.printStackTrace(); + } + } + ApplyInitialSetupDatasetData objectApplyInitialSetupDatasetData[] = new ApplyInitialSetupDatasetData[vector.size()]; + vector.copyInto(objectApplyInitialSetupDatasetData); + return(objectApplyInitialSetupDatasetData); + } + + public static String existingId(ConnectionProvider connectionProvider, String tablename, String columnname, String value, String client) throws ServletException { + String strSql = ""; + strSql = strSql + + " SELECT "; + strSql = strSql + ((tablename==null || tablename.equals(""))?"":tablename); + strSql = strSql + + "_ID as id" + + " FROM "; + strSql = strSql + ((tablename==null || tablename.equals(""))?"":tablename); + strSql = strSql + + " WHERE "; + strSql = strSql + ((columnname==null || columnname.equals(""))?"":columnname); + strSql = strSql + + " = ?" + + " AND AD_CLIENT_ID = ?"; + + ResultSet result; + String strReturn = ""; + PreparedStatement st = null; + + int iParameter = 0; + try { + st = connectionProvider.getPreparedStatement(strSql); + if (tablename != null && !(tablename.equals(""))) { + } + if (tablename != null && !(tablename.equals(""))) { + } + if (columnname != null && !(columnname.equals(""))) { + } + iParameter++; UtilSql.setValue(st, iParameter, 12, null, value); + iParameter++; UtilSql.setValue(st, iParameter, 12, null, client); + + result = st.executeQuery(); + if(result.next()) { + strReturn = UtilSql.getValue(result, "id"); + } + result.close(); + } catch(SQLException e){ + log4j.error("SQL error in query: " + strSql + "Exception:"+ e); + throw new ServletException("@CODE=" + Integer.toString(e.getErrorCode()) + "@" + e.getMessage()); + } catch(Exception ex){ + log4j.error("Exception in query: " + strSql + "Exception:"+ ex); + throw new ServletException("@CODE=@" + ex.getMessage()); + } finally { + try { + connectionProvider.releasePreparedStatement(st); + } catch(Exception ignore){ + ignore.printStackTrace(); + } + } + return(strReturn); + } + + public static int insertRefDataLoaded(ConnectionProvider connectionProvider, String clientId, String genericId, String specificId, String tableId) throws ServletException { + String strSql = ""; + strSql = strSql + + " INSERT INTO AD_REF_DATA_LOADED (ad_ref_data_loaded_id, ad_client_id, ad_org_id, isactive, created, createdby, updated, updatedby, ad_module_id, generic_id, specific_id, ad_table_id)" + + " VALUES(get_uuid(), ?, '0', 'Y', now(), '100', now(), '100', '0', ?, ?, ?)"; + + int updateCount = 0; + PreparedStatement st = null; + + int iParameter = 0; + try { + st = connectionProvider.getPreparedStatement(strSql); + iParameter++; UtilSql.setValue(st, iParameter, 12, null, clientId); + iParameter++; UtilSql.setValue(st, iParameter, 12, null, genericId); + iParameter++; UtilSql.setValue(st, iParameter, 12, null, specificId); + iParameter++; UtilSql.setValue(st, iParameter, 12, null, tableId); + + updateCount = st.executeUpdate(); + } catch(SQLException e){ + log4j.error("SQL error in query: " + strSql + "Exception:"+ e); + throw new ServletException("@CODE=" + Integer.toString(e.getErrorCode()) + "@" + e.getMessage()); + } catch(Exception ex){ + log4j.error("Exception in query: " + strSql + "Exception:"+ ex); + throw new ServletException("@CODE=@" + ex.getMessage()); + } finally { + try { + connectionProvider.releasePreparedStatement(st); + } catch(Exception ignore){ + ignore.printStackTrace(); + } + } + return(updateCount); + } + + public static int insertClientModule(ConnectionProvider connectionProvider, String clientId) throws ServletException { + String strSql = ""; + strSql = strSql + + " INSERT INTO AD_CLIENTMODULE (ad_clientmodule_id, ad_client_id, ad_org_id, isactive, created, createdby, updated, updatedby, ad_module_id, version)" + + " VALUES(get_uuid(), ?, '0', 'Y', now(), '100', now(), '100', '0', (select version from ad_module where ad_module_id='0'))"; + + int updateCount = 0; + PreparedStatement st = null; + + int iParameter = 0; + try { + st = connectionProvider.getPreparedStatement(strSql); + iParameter++; UtilSql.setValue(st, iParameter, 12, null, clientId); + + updateCount = st.executeUpdate(); + } catch(SQLException e){ + log4j.error("SQL error in query: " + strSql + "Exception:"+ e); + throw new ServletException("@CODE=" + Integer.toString(e.getErrorCode()) + "@" + e.getMessage()); + } catch(Exception ex){ + log4j.error("Exception in query: " + strSql + "Exception:"+ ex); + throw new ServletException("@CODE=@" + ex.getMessage()); + } finally { + try { + connectionProvider.releasePreparedStatement(st); + } catch(Exception ignore){ + ignore.printStackTrace(); + } + } + return(updateCount); + } +} diff --git a/src-util/modulescript/src/org/openbravo/modulescript/ApplyInitialSetupDataset.java b/src-util/modulescript/src/org/openbravo/modulescript/ApplyInitialSetupDataset.java new file mode 100644 --- /dev/null +++ b/src-util/modulescript/src/org/openbravo/modulescript/ApplyInitialSetupDataset.java @@ -0,0 +1,260 @@ +/* + ************************************************************************* + * The contents of this file are subject to the Openbravo Public License + * Version 1.0 (the "License"), being the Mozilla Public License + * Version 1.1 with a permitted attribution clause; you may not use this + * file except in compliance with the License. You may obtain a copy of + * the License at http://www.openbravo.com/legal/license.html + * Software distributed under the License is distributed on an "AS IS" + * basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the + * License for the specific language governing rights and limitations + * under the License. + * The Original Code is Openbravo ERP. + * The Initial Developer of the Original Code is Openbravo SLU + * All portions are Copyright (C) 2011 Openbravo SLU + * All Rights Reserved. + * Contributor(s): ______________________________________. + ************************************************************************ + */ +package org.openbravo.modulescript; + +import java.math.BigDecimal; +import org.apache.log4j.Logger; +import org.openbravo.database.ConnectionProvider; +import org.openbravo.modulescript.ModuleScript; + +public class ApplyInitialSetupDataset extends ModuleScript { + + private static final Logger log4j = Logger.getLogger(UpdateClientGLCategory.class); + + public void execute() { + try { + ConnectionProvider cp = getConnectionProvider(); + + ApplyInitialSetupDatasetData data[] = ApplyInitialSetupDatasetData.select(cp); + for (int indClients = 0; indClients < data.length; indClients++) { + BigDecimal bdDiffCreated = BigDecimal.TEN; + if (data[indClients].diffcreated != null) + bdDiffCreated = new BigDecimal(data[indClients].diffcreated); + boolean boDocTypesCreatedWithClient = bdDiffCreated.compareTo(new BigDecimal("0.01")) <= 0; + boolean boModuleNotApplied = data[indClients].versionapplied == null + || "".equals(data[indClients].versionapplied); + if (boModuleNotApplied && boDocTypesCreatedWithClient) { + for (int indDBElements = 0; indDBElements < directElements.length; indDBElements++) { + String existingId = ApplyInitialSetupDatasetData.existingId(cp, + directElements[indDBElements].table, directElements[indDBElements].column, + directElements[indDBElements].value, data[indClients].adClientId); + if (existingId != null && !"".equals(existingId)) + ApplyInitialSetupDatasetData.insertRefDataLoaded(cp, data[indClients].adClientId, + directElements[indDBElements].id, existingId, + directElements[indDBElements].tableId); + } + ApplyInitialSetupDatasetData.insertClientModule(cp, data[indClients].adClientId); + } + } + } catch (Exception e) { + handleError(e); + } + } + + public class DBInsert { + public DBInsert(String table, String tableId, String id, String column, String value) { + this.table = table; + this.tableId = tableId; + this.id = id; + this.column = column; + this.value = value; + } + + String table; + String tableId; + String id; + String column; + String value; + } + + DBInsert[] directElements = { + new DBInsert("GL_Category", "218", "102C08DF5D4341D5B7FDF758632503D2", "Name", "AR Invoice"), + new DBInsert("GL_Category", "218", "160C37CC0D36480E8B91B015FAC747DC", "Name", + "Material Management"), + new DBInsert("GL_Category", "218", "3005499D637B41AF86222E4BDA29D415", "Name", "Movement"), + new DBInsert("GL_Category", "218", "37501231BC434F2DB0BF5F706CEBCC1F", "Name", "Production"), + new DBInsert("GL_Category", "218", "47D760C2B9C942EA86D47E6422C3BF9C", "Name", "Manual"), + new DBInsert("GL_Category", "218", "5106A21601924DA9996DC40C34954F8A", "Name", "Inventory"), + new DBInsert("GL_Category", "218", "745A2B441A2644DF934D1B1E462292E9", "Name", "None"), + new DBInsert("GL_Category", "218", "82B88F71CF71401584FC1DFEFD9EB33D", "Name", "MatchInv"), + new DBInsert("GL_Category", "218", "844F34E0FA4045C6A3D00B6D4D53107B", "Name", "Settlement"), + new DBInsert("GL_Category", "218", "A431AFE1356141728139523053B672C4", "Name", "AP Invoice"), + new DBInsert("GL_Category", "218", "AAB8DB8C913E4AA0A651A5C0DC061C1A", "Name", + "Bank Statement"), + new DBInsert("GL_Category", "218", "C79381E3F81140DBAAD73E6B0CD74901", "Name", "AP Payment"), + new DBInsert("GL_Category", "218", "D6A6F219061F4C34B87E1CC4DD6797F3", "Name", "Cash"), + new DBInsert("GL_Category", "218", "E8752D97421B434F8355331B680DC652", "Name", "AR Receipt"), + new DBInsert("GL_Category", "218", "FA9102F37B904275A3CCD9935D69ED51", "Name", "MatchPO"), + new DBInsert("GL_Category", "218", "FC670B83E59C4E7CBD6B999D3F28B251", "Name", "Standard"), + new DBInsert("AD_Sequence", "115", "01A4350CC9044517BA7B1B05EEF065FF", "Name", + "MM Shipment Indirect"), + new DBInsert("AD_Sequence", "115", "0FBF9530BC584A6E9415F7AD01A23201", "Name", + "Standard Order"), + new DBInsert("AD_Sequence", "115", "267B166C6F4B49E893CF6276EE396E7D", "Name", "Production"), + new DBInsert("AD_Sequence", "115", "2D47C580583242259DF1FFEA4D914A94", "Name", "MM Shipment"), + new DBInsert("AD_Sequence", "115", "31A0AE4B070A49EAA5D755D33D7B9C8C", "Name", + "Reversed Sales Invoice"), + new DBInsert("AD_Sequence", "115", "4D72691638A24A0194882A302FCF9494", "Name", "AP Payment"), + new DBInsert("AD_Sequence", "115", "6D3C7477332F47CD8A0F6A5C4805EBD4", "Name", "Prepay Order"), + new DBInsert("AD_Sequence", "115", "74C3CC2BCDDA45F5BBFE8DF603728749", "Name", + "Purchase Requisition"), + new DBInsert("AD_Sequence", "115", "7C2F74C43970423E890C8892C43673E9", "Name", "Settlement"), + new DBInsert("AD_Sequence", "115", "81EEB6FAFE5D4E6B9389CAAC6297495B", "Name", + "Physical Inventory"), + new DBInsert("AD_Sequence", "115", "81F0991C4D884F82AF34E6CD72C0BFEC", "Name", "Quotation"), + new DBInsert("AD_Sequence", "115", "8547DE01C56D4C67A28F37AA5E72046D", "Name", "Proposal"), + new DBInsert("AD_Sequence", "115", "8CA21B8285CC4C4E8DCAD896DB03213E", "Name", "Cash Journal"), + new DBInsert("AD_Sequence", "115", "949C664EE54A4AA5B23CE288E1677916", "Name", + "Bank Statement"), + new DBInsert("AD_Sequence", "115", "A55E308B07EF453B87ED12516E3C9F7D", "Name", + "Matched Invoices"), + new DBInsert("AD_Sequence", "115", "A6A631F13B004AB8AD39573E95EE992E", "Name", + "Return Material"), + new DBInsert("AD_Sequence", "115", "A7C5B67A2BB244A19F475160A5AFCE5E", "Name", + "Inventory Move"), + new DBInsert("AD_Sequence", "115", "AE79ADF07A5E4E6E9C5367505C1C3463", "Name", + "Purchase Order"), + new DBInsert("AD_Sequence", "115", "B277787F93854F888B32177DCF14C43D", "Name", + "Reversed Purchase Invoice"), + new DBInsert("AD_Sequence", "115", "B380E35582BD4D1A930146F1BA72C03F", "Name", "GL Journal"), + new DBInsert("AD_Sequence", "115", "B74E4F916A4B4A67BA572CAE835B4049", "Name", + "AR Credit Memo"), + new DBInsert("AD_Sequence", "115", "BCF68C60AFAE45358B7D78FCAB3EB783", "Name", + "Matched Purchase Orders"), + new DBInsert("AD_Sequence", "115", "C114BA11CB23468B86887B3619AA52CC", "Name", "Depreciation"), + new DBInsert("AD_Sequence", "115", "CF53CE0FBB6B4FBB89C4939E191AFFD4", "Name", + "Manual Settlement"), + new DBInsert("AD_Sequence", "115", "EC5B218F09F44618B98FA0D233E3DC70", "Name", "AR Invoice"), + new DBInsert("AD_Sequence", "115", "F3659AAEFC2741F788BB474159616023", "Name", "AR Receipt"), + new DBInsert("AD_Sequence", "115", "F4F629F131124F198601A47F5FEDF53A", "Name", "Credit Order"), + new DBInsert("AD_Sequence", "115", "F6907986413D46C4BE3E27174895CC48", "Name", + "Warehouse Order"), + new DBInsert("AD_Sequence", "115", "FE1DFB9999224BE7B1B84B9E5D4CDA0B", "Name", + "Debt Payment Management"), + new DBInsert("AD_Sequence", "115", "FFB42B38D6A34634B534AB499B13644C", "Name", "POS Order"), + new DBInsert("C_DocType", "217", "0A1D4A2DB7144D81A821E31A9B332ACB", "Name", "Quotation"), + new DBInsert("C_DocType", "217", "0CD50184705A42CCBECA4EC967646440", "Name", "MM Shipment"), + new DBInsert("C_DocType", "217", "15C8DCE82DA841968ABCD614FED68576", "Name", "Proposal"), + new DBInsert("C_DocType", "217", "15F495A6290040F194A9AA4622FE0C01", "Name", "Prepay Order"), + new DBInsert("C_DocType", "217", "2030AD7DD4284E2B936E261662EF735A", "Name", "MM Receipt"), + new DBInsert("C_DocType", "217", "2D7C15F0F44E4F289A729415EFD700C1", "Name", + "Return Material"), + new DBInsert("C_DocType", "217", "3DDDC41E36534A79B7CC1B725472882D", "Name", "Inventory Move"), + new DBInsert("C_DocType", "217", "40EE9B1CD3B345FABEFDA62B407B407F", "Name", "AR Invoice"), + new DBInsert("C_DocType", "217", "42B7DE94BC324C3F9CC0934375E90FFF", "Name", "AP CreditMemo"), + new DBInsert("C_DocType", "217", "51005B2C07EB41C5A2E7C25A4640ACD7", "Name", "GL Journal"), + new DBInsert("C_DocType", "217", "511A9371A0F74195AA3F6D66C722729D", "Name", "POS Order"), + new DBInsert("C_DocType", "217", "5C6E02993E9B4FCA81C07955EF676C62", "Name", "AP Invoice"), + new DBInsert("C_DocType", "217", "5EA6556D24034412B5F26F6BA7245318", "Name", + "Matched Invoices"), + new DBInsert("C_DocType", "217", "6543EB94DC664371BAF61B8E8AC121F3", "Name", "Bank Statement"), + new DBInsert("C_DocType", "217", "67C3266D11A04078B7A14AC21E91C711", "Name", + "Reversed Sales Invoice"), + new DBInsert("C_DocType", "217", "6B13D02AD3C44C4CB0CFBD1288E0CB10", "Name", + "Physical Inventory"), + new DBInsert("C_DocType", "217", "6F3BBCA488F6474A806C59FD1137CBF5", "Name", + "Purchase Requisition"), + new DBInsert("C_DocType", "217", "76E7C671FCE34556908E563F825C2937", "Name", + "Warehouse Order"), + new DBInsert("C_DocType", "217", "808F8818F724497D94282AC83493F394", "Name", "Purchase Order"), + new DBInsert("C_DocType", "217", "857F464FDEE34F6DB5AEC50981419FBF", "Name", "Settlement"), + new DBInsert("C_DocType", "217", "8F343D831EA6434D9720FECAF5FB957E", "Name", + "Debt Payment Management"), + new DBInsert("C_DocType", "217", "9883CB89E41E496D987D8838C3CE0DC7", "Name", + "Matched Purchase Orders"), + new DBInsert("C_DocType", "217", "A0C72093D5614867906A6E878F96FBBD", "Name", "Depreciation"), + new DBInsert("C_DocType", "217", "A58B8296E0ED42E386468D4527DE8F30", "Name", "Cash Journal"), + new DBInsert("C_DocType", "217", "AFFD4594FB734E9682D5769669A9D471", "Name", + "Reversed Purchase Invoice"), + new DBInsert("C_DocType", "217", "B476CFAE109047DEB5BC9AC80A03297A", "Name", "AR Credit Memo"), + new DBInsert("C_DocType", "217", "B968C737ED3E4C808E425A72CC445DFE", "Name", + "Manual Settlement"), + new DBInsert("C_DocType", "217", "CB6EEA256BBC41109911215C5A14D39B", "Name", "Standard Order"), + new DBInsert("C_DocType", "217", "D132517AE775435B8EB2832CC61FCAB1", "Name", "AR Receipt"), + new DBInsert("C_DocType", "217", "E7F4802D902A42A59143DCCBEDE4DE85", "Name", "Credit Order"), + new DBInsert("C_DocType", "217", "EC0B46C525A0417DA286823864620991", "Name", "Production"), + new DBInsert("C_DocType", "217", "ED1E059C9CF54062BA43B79F3EB89C77", "Name", "AP Payment"), + new DBInsert("C_DocType", "217", "F8CC92C7234644DEAD9F63174F45B2BF", "Name", + "MM Shipment Indirect"), + new DBInsert("AD_Preference", "195", "AAEF5567618F49FE8BA729E550614AA0", "Attribute", + "C_DocTypeTarget_ID"), + new DBInsert("C_POC_DOCTYPE_TEMPLATE", "1000500001", "02376C41DA824413A9BE649443924C03", + "Name", "Purchase Order Report template"), + new DBInsert("C_POC_DOCTYPE_TEMPLATE", "1000500001", "11DD7B13EAC94215B6F8F735BBED4D55", + "Name", "Quotation Report template"), + new DBInsert("C_POC_DOCTYPE_TEMPLATE", "1000500001", "4F23CD7CD64D468EA4753C0C7B09FD53", + "Name", "Return Material Report template"), + new DBInsert("C_POC_DOCTYPE_TEMPLATE", "1000500001", "70AEA0C77DB743A4A89058BFE091FEEA", + "Name", "Standard order report template"), + new DBInsert("C_POC_DOCTYPE_TEMPLATE", "1000500001", "8E2539C66CFB43F79613217E35CC5D14", + "Name", "AR Receipt Report template"), + new DBInsert("C_POC_DOCTYPE_TEMPLATE", "1000500001", "9FB97CCA66EA49F29A0EF5080E2AFF29", + "Name", "AR Credit Memo Report template"), + new DBInsert("C_POC_DOCTYPE_TEMPLATE", "1000500001", "A16BD46A069F4502BDDFD9A555AEAA48", + "Name", "AR Invoice Report template"), + new DBInsert("C_POC_DOCTYPE_TEMPLATE", "1000500001", "A76CE6794C2E467394C21675524DBA9C", + "Name", "Proposal Report template"), + new DBInsert("C_POC_DOCTYPE_TEMPLATE", "1000500001", "AF10A903167240F883C7EE7A3325981D", + "Name", "POS Order Report template"), + new DBInsert("C_POC_DOCTYPE_TEMPLATE", "1000500001", "B1DF02E45C4946C7BB1D45C065C49577", + "Name", "AP Credit Report template"), + new DBInsert("C_POC_DOCTYPE_TEMPLATE", "1000500001", "B94A012B25FB4C319804BED013BD584B", + "Name", "Prepay Order Report template"), + new DBInsert("C_POC_DOCTYPE_TEMPLATE", "1000500001", "BC7220FEA2F44F9C9FB6619FC58B6944", + "Name", "MM Receipt Report template"), + new DBInsert("C_POC_DOCTYPE_TEMPLATE", "1000500001", "C6A6AF1CA3C94B3899CAEC27EE427402", + "Name", "MM Shipment Report template"), + new DBInsert("C_POC_DOCTYPE_TEMPLATE", "1000500001", "C76E1DE89DA04BF6B6FAEDDA0216EE7A", + "Name", "Warehouse Order Memo Report template"), + new DBInsert("C_POC_DOCTYPE_TEMPLATE", "1000500001", "D9BB431F120746C8A84266CA42D02029", + "Name", "On Credit Order Report template"), + new DBInsert("C_POC_DOCTYPE_TEMPLATE", "1000500001", "E5901A1122F641089417A08A7317764C", + "Name", "AP Invoice Report template"), + new DBInsert("C_POC_DOCTYPE_TEMPLATE", "1000500001", "E87E9B580A024383B2E79BD768288899", + "Name", "MM Shipment Indirect Report template"), + new DBInsert("C_POC_DOCTYPE_TEMPLATE", "1000500001", "FA45DFAC61A542658CC02B64E476F4C0", + "Name", "AP Payment Report template") }; + DBInsert[] indirectElements = { + new DBInsert("C_POC_EMAILDEFINITION", "1000500004", "0680791915544EDAA32727AD21542EE3", null, + "AR Receipt Report template"), + new DBInsert("C_POC_EMAILDEFINITION", "1000500004", "878ECF0D5A238C7BE040007F010129BA", null, + "AR Invoice Report template"), + new DBInsert("C_POC_EMAILDEFINITION", "1000500004", "878ECF0D5A298C7BE040007F010129BA", null, + "AR Credit Memo Report template"), + new DBInsert("C_POC_EMAILDEFINITION", "1000500004", "878ECF0D5A2E8C7BE040007F010129BA", null, + "MM Shipment Report template"), + new DBInsert("C_POC_EMAILDEFINITION", "1000500004", "878ECF0D5A318C7BE040007F010129BA", null, + "MM Shipment Indirect Report template"), + new DBInsert("C_POC_EMAILDEFINITION", "1000500004", "878ECF0D5A348C7BE040007F010129BA", null, + "MM Receipt Report template"), + new DBInsert("C_POC_EMAILDEFINITION", "1000500004", "878ECF0D5A378C7BE040007F010129BA", null, + "AP Invoice Report template"), + new DBInsert("C_POC_EMAILDEFINITION", "1000500004", "878ECF0D5A3A8C7BE040007F010129BA", null, + "AP Credit Report template"), + new DBInsert("C_POC_EMAILDEFINITION", "1000500004", "878ECF0D5A3F8C7BE040007F010129BA", null, + "Purchase Order Report template"), + new DBInsert("C_POC_EMAILDEFINITION", "1000500004", "878ECF0D5A5A8C7BE040007F010129BA", null, + "Quotation Report template"), + new DBInsert("C_POC_EMAILDEFINITION", "1000500004", "878ECF0D5A5D8C7BE040007F010129BA", null, + "Proposal Report template"), + new DBInsert("C_POC_EMAILDEFINITION", "1000500004", "878ECF0D5A608C7BE040007F010129BA", null, + "Prepay Order Report template"), + new DBInsert("C_POC_EMAILDEFINITION", "1000500004", "878ECF0D5A638C7BE040007F010129BA", null, + "Return Material Report template"), + new DBInsert("C_POC_EMAILDEFINITION", "1000500004", "878ECF0D5A668C7BE040007F010129BA", null, + "Standard order report template"), + new DBInsert("C_POC_EMAILDEFINITION", "1000500004", "878ECF0D5A698C7BE040007F010129BA", null, + "On Credit Order Report template"), + new DBInsert("C_POC_EMAILDEFINITION", "1000500004", "878ECF0D5A6C8C7BE040007F010129BA", null, + "Warehouse Order Memo Report template"), + new DBInsert("C_POC_EMAILDEFINITION", "1000500004", "878ECF0D5A6F8C7BE040007F010129BA", null, + "POS Order Report template"), + new DBInsert("C_POC_EMAILDEFINITION", "1000500004", "E8CBFC5AD3784396BC2D14CD1A104316", null, + "AP Payment Report template") }; +} \ No newline at end of file diff --git a/src-util/modulescript/src/org/openbravo/modulescript/ApplyInitialSetupDataset_data.xsql b/src-util/modulescript/src/org/openbravo/modulescript/ApplyInitialSetupDataset_data.xsql new file mode 100644 --- /dev/null +++ b/src-util/modulescript/src/org/openbravo/modulescript/ApplyInitialSetupDataset_data.xsql @@ -0,0 +1,66 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<!-- + ************************************************************************* + * The contents of this file are subject to the Openbravo Public License + * Version 1.0 (the "License"), being the Mozilla Public License + * Version 1.1 with a permitted attribution clause; you may not use this + * file except in compliance with the License. You may obtain a copy of + * the License at http://www.openbravo.com/legal/license.html + * Software distributed under the License is distributed on an "AS IS" + * basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the + * License for the specific language governing rights and limitations + * under the License. + * The Original Code is Openbravo ERP. + * The Initial Developer of the Original Code is Openbravo SLU + * All portions are Copyright (C) 2011 Openbravo SLU + * All Rights Reserved. + * Contributor(s): ______________________________________. + ************************************************************************ +--> +<SqlClass name="ApplyInitialSetupDatasetData" package="org.openbravo.modulescript"> + <SqlMethod name="select" type="preparedStatement" return="multiple"> + <Sql><![CDATA[ + select c.name, c.ad_client_id, coalesce(cm.version,om.version) as versionApplied, + to_number((select coalesce(min(dt.created),now()) from c_doctype dt where dt.ad_client_id=c.ad_client_id) - c.created) as diffCreated, + '' as id + from ad_client c + left join ad_clientmodule cm on c.ad_client_id=cm.ad_client_id and cm.ad_module_id='0' + left join ad_orgmodule om on c.ad_client_id=om.ad_client_id and om.ad_module_id='0' + order by c.name + ]]> + </Sql> + </SqlMethod> + <SqlMethod name="existingId" type="preparedStatement" return="String" default=""> + <Sql><![CDATA[ + SELECT C_DOCTYPE_ID as id + FROM C_DOCTYPE + WHERE NAME = ? + AND AD_CLIENT_ID = ? + ]]> + </Sql> + <Parameter name="tablename" optional="true" type="replace" after="SELECT " text="C_DOCTYPE"/> + <Parameter name="tablename" optional="true" type="replace" after="FROM " text="C_DOCTYPE "/> + <Parameter name="columnname" optional="true" type="replace" after="WHERE " text="NAME"/> + <Parameter name="value"/> + <Parameter name="client"/> + </SqlMethod> + <SqlMethod name="insertRefDataLoaded" type="preparedStatement" return="rowCount"> + <SqlMethodComment></SqlMethodComment> + <Sql> + INSERT INTO AD_REF_DATA_LOADED (ad_ref_data_loaded_id, ad_client_id, ad_org_id, isactive, created, createdby, updated, updatedby, ad_module_id, generic_id, specific_id, ad_table_id) + VALUES(get_uuid(), ?, '0', 'Y', now(), '100', now(), '100', '0', ?, ?, ?) + </Sql> + <Parameter name="clientId"/> + <Parameter name="genericId"/> + <Parameter name="specificId"/> + <Parameter name="tableId"/> + </SqlMethod> + <SqlMethod name="insertClientModule" type="preparedStatement" return="rowCount"> + <SqlMethodComment></SqlMethodComment> + <Sql> + INSERT INTO AD_CLIENTMODULE (ad_clientmodule_id, ad_client_id, ad_org_id, isactive, created, createdby, updated, updatedby, ad_module_id, version) + VALUES(get_uuid(), ?, '0', 'Y', now(), '100', now(), '100', '0', (select version from ad_module where ad_module_id='0')) + </Sql> + <Parameter name="clientId"/> + </SqlMethod> +</SqlClass> \ No newline at end of file | |||||||
Relationships [ Relation Graph ] [ Dependency Graph ] | ||||||||||||||||||||||
|
Notes | |
(0032924) egoitz (developer) 2010-11-30 17:43 |
Good solution |
(0040375) dalsasua (reporter) 2011-08-22 10:06 |
Attached a diff with proposed solution. Compilation fails due to a check in the import.sample.data, due to the sub-classes in the module scripts and/or build validations. |
(0074423) plujan (manager) 2015-02-12 14:41 |
Backports to 2.50 branch are no longer supported |
Issue History | |||
Date Modified | Username | Field | Change |
2010-10-27 18:10 | egoitz | New Issue | |
2010-10-27 18:10 | egoitz | Assigned To | => dalsasua |
2010-10-27 18:10 | egoitz | Issue Monitored: networkb | |
2010-10-28 12:53 | dalsasua | Relationship added | related to 0015000 |
2010-10-28 16:48 | bursie | Issue Monitored: bursie | |
2010-11-02 16:08 | dalsasua | Relationship added | related to 0015100 |
2010-11-25 18:06 | adrianromero | Status | new => feedback |
2010-11-30 17:43 | egoitz | Note Added: 0032924 | |
2010-11-30 17:52 | egoitz | Modules | => Core |
2010-11-30 17:52 | egoitz | Status | feedback => new |
2010-12-02 18:06 | adrianromero | Severity | major => minor |
2010-12-16 16:22 | eduardo_Argal | Target Version | 2.50MP25 => |
2011-01-11 12:37 | adrianromero | Type | defect => backport |
2011-01-11 12:38 | adrianromero | Issue cloned | 0015603 |
2011-01-11 12:38 | adrianromero | Relationship added | depends on 0015603 |
2011-01-11 12:40 | adrianromero | Status | new => scheduled |
2011-01-11 12:40 | adrianromero | fix_in_branch | => pi |
2011-01-26 10:38 | egoitz | Priority | urgent => normal |
2011-01-26 10:38 | egoitz | fix_in_branch | pi => |
2011-01-27 15:40 | adrianromero | Severity | minor => trivial |
2011-07-20 18:17 | dalsasua | Assigned To | dalsasua => jonalegriaesarte |
2011-08-22 10:06 | dalsasua | File Added: diff | |
2011-08-22 10:06 | dalsasua | Note Added: 0040375 | |
2011-09-08 17:09 | dalsasua | File Deleted: diff | |
2011-09-08 17:27 | dalsasua | File Added: issue15054.diff | |
2012-04-03 12:20 | jonalegriaesarte | Assigned To | jonalegriaesarte => vmromanos |
2012-05-10 12:12 | gorka_gil | Assigned To | vmromanos => mirurita |
2015-02-12 14:41 | plujan | Note Added: 0074423 | |
2015-02-12 14:41 | plujan | Status | scheduled => closed |
2015-02-12 14:41 | plujan | Resolution | open => out of date |
Copyright © 2000 - 2009 MantisBT Group |