details: https://code.openbravo.com/erp/devel/pi/rev/6dc56949e444 changeset: 15761:6dc56949e444 user: Sandra Huguet <sandra.huguet <at> openbravo.com> date: Mon Mar 05 16:26:51 2012 +0100 summary: Fixed bug 9655 It Shows the correct error message in Multiphase Project It Shows the correct error message in Copy Button in Multiphase Project and it shows the combo field as required
details: https://code.openbravo.com/erp/devel/pi/rev/a75ed57d60b6 changeset: 15762:a75ed57d60b6 user: Víctor Martínez Romanos <victor.martinez <at> openbravo.com> date: Mon Mar 12 15:35:18 2012 +0100 summary: Issue 9655: updated copyright year diffstat: src/org/openbravo/erpCommon/ad_actionButton/ProjectCopyFrom.html | 4 +- src/org/openbravo/erpCommon/ad_actionButton/ProjectCopyFrom.java | 21 ++++++--- 2 files changed, 16 insertions(+), 9 deletions(-) diffs (68 lines): diff -r cfc846dc3703 -r a75ed57d60b6 src/org/openbravo/erpCommon/ad_actionButton/ProjectCopyFrom.html --- a/src/org/openbravo/erpCommon/ad_actionButton/ProjectCopyFrom.html Mon Mar 12 15:31:42 2012 +0100 +++ b/src/org/openbravo/erpCommon/ad_actionButton/ProjectCopyFrom.html Mon Mar 12 15:35:18 2012 +0100 @@ -11,7 +11,7 @@ * under the License. * The Original Code is Openbravo ERP. * The Initial Developer of the Original Code is Openbravo SLU - * All portions are Copyright (C) 2001-2011 Openbravo SLU + * All portions are Copyright (C) 2001-2012 Openbravo SLU * All Rights Reserved. * Contributor(s): ______________________________________. ************************************************************************ @@ -120,7 +120,7 @@ <tr> <td class="TitleCell"><span class="LabelText">Project</span></td> <td class="Combo_ContentCell" colspan="2"> - <select name="inpProject" id="inpProject" class="Combo Combo_TwoCells_width"> + <select name="inpProject" id="inpProject" class="Combo Combo_TwoCells_width required" required="true"> <option value=""><div id="reportcProjectId"></div></option> </select> </td> diff -r cfc846dc3703 -r a75ed57d60b6 src/org/openbravo/erpCommon/ad_actionButton/ProjectCopyFrom.java --- a/src/org/openbravo/erpCommon/ad_actionButton/ProjectCopyFrom.java Mon Mar 12 15:31:42 2012 +0100 +++ b/src/org/openbravo/erpCommon/ad_actionButton/ProjectCopyFrom.java Mon Mar 12 15:35:18 2012 +0100 @@ -11,7 +11,7 @@ * under the License. * The Original Code is Openbravo ERP. * The Initial Developer of the Original Code is Openbravo SLU - * All portions are Copyright (C) 2001-2010 Openbravo SLU + * All portions are Copyright (C) 2001-2012 Openbravo SLU * All Rights Reserved. * Contributor(s): ______________________________________. ************************************************************************ @@ -73,14 +73,20 @@ private OBError processButton(VariablesSecureApp vars, String strKey, String strProject, String windowId) { Connection conn = null; - OBError myMessage = null; + + OBError myMessage = new OBError(); if (strProject == null || strProject.equals("")) { - extracted(myMessage).setType("Error"); - extracted(myMessage).setTitle(Utility.messageBD(this, "Error", vars.getLanguage())); - extracted(myMessage).setMessage( - Utility.messageBD(this, "NoProjectSelected", vars.getLanguage())); - return extracted(myMessage); + try { + releaseRollbackConnection(conn); + } catch (Exception ignored) { + } + log4j.warn("Rollback in transaction"); + myMessage.setType("Error"); + myMessage.setTitle(Utility.messageBD(this, "Error", vars.getLanguage())); + myMessage.setMessage(Utility.messageBD(this, "NoProjectSelected", vars.getLanguage())); } + else{ + try { conn = this.getTransactionConnection(); String projectCategory = ProjectCopyFromData.selectProjectCategory(this, strKey); @@ -162,6 +168,7 @@ log4j.warn("Rollback in transaction"); myMessage = Utility.translateError(this, vars, vars.getLanguage(), "ProcessRunError"); } + } return extracted(myMessage); } ------------------------------------------------------------------------------ Try before you buy = See our experts in action! The most comprehensive online learning library for Microsoft developers is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, Metro Style Apps, more. Free future releases when you subscribe now! http://p.sf.net/sfu/learndevnow-dev2 _______________________________________________ Openbravo-commits mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/openbravo-commits
