Fixes bug 7621: Currency selector on Price list window should show full currencies name, not only ISO code
authorEduardo Argal Guibert <eduardo.argal@openbravo.com>
Thu, 17 Nov 2011 17:19:35 +0100
changeset 14284 21e554d27846
parent 14283 cf9c0c12d20a
child 14285 e66447e44d48
Fixes bug 7621: Currency selector on Price list window should show full currencies name, not only ISO code
src/org/openbravo/erpCommon/ad_forms/InitialClientSetup.java
src/org/openbravo/erpCommon/ad_forms/InitialOrgSetup.java
src/org/openbravo/erpCommon/ad_forms/MonedaCombo_data.xsql
--- a/src/org/openbravo/erpCommon/ad_forms/InitialClientSetup.java	Thu Nov 17 17:17:42 2011 +0100
+++ b/src/org/openbravo/erpCommon/ad_forms/InitialClientSetup.java	Thu Nov 17 17:19:35 2011 +0100
@@ -103,7 +103,7 @@
     xmlDocument.setParameter("moduleTree", tree.toHtml());
     xmlDocument.setParameter("moduleTreeDescription", tree.descriptionToHtml());
 
-    xmlDocument.setData("reportCurrency", "liststructure", MonedaComboData.select(this));
+    xmlDocument.setData("reportCurrency", "liststructure", MonedaComboData.selectISO(this));
     response.setContentType("text/html; charset=UTF-8");
     PrintWriter out = response.getWriter();
     out.println(xmlDocument.print());
--- a/src/org/openbravo/erpCommon/ad_forms/InitialOrgSetup.java	Thu Nov 17 17:17:42 2011 +0100
+++ b/src/org/openbravo/erpCommon/ad_forms/InitialOrgSetup.java	Thu Nov 17 17:19:35 2011 +0100
@@ -134,7 +134,7 @@
 
       xmlDocument.setParameter("paramLocationId", "");
       xmlDocument.setParameter("paramLocationDescription", "");
-      xmlDocument.setData("reportCurrency", "liststructure", MonedaComboData.select(this));
+      xmlDocument.setData("reportCurrency", "liststructure", MonedaComboData.selectISO(this));
       xmlDocument.setData("reportOrgType", "liststructure",
           InitialOrgSetupData.selectOrgType(this, vars.getLanguage(), vars.getClient()));
       xmlDocument.setData("reportParentOrg", "liststructure",
--- a/src/org/openbravo/erpCommon/ad_forms/MonedaCombo_data.xsql	Thu Nov 17 17:17:42 2011 +0100
+++ b/src/org/openbravo/erpCommon/ad_forms/MonedaCombo_data.xsql	Thu Nov 17 17:19:35 2011 +0100
@@ -31,4 +31,11 @@
       FROM C_Currency ORDER BY 2
       </Sql>
    </SqlMethod>
+   <SqlMethod name="selectISO" type="preparedStatement" return="multiple">
+      <SqlMethodComment></SqlMethodComment>
+      <Sql>
+      SELECT C_Currency_ID as id, iso_code as name
+      FROM C_Currency ORDER BY 2
+      </Sql>
+   </SqlMethod>
 </SqlClass>