details:   https://code.openbravo.com/erp/devel/pi/rev/717cfc93ba9b
changeset: 17987:717cfc93ba9b
user:      Ioritz Cia <ioritz.cia <at> openbravo.com>
date:      Tue Sep 18 13:02:56 2012 +0200
summary:   Fixes issue 21671: User can change the organization when the invoice 
has lines.

details:   https://code.openbravo.com/erp/devel/pi/rev/86e3a64ee722
changeset: 17988:86e3a64ee722
user:      Ioritz Cia <ioritz.cia <at> openbravo.com>
date:      Tue Sep 18 18:38:18 2012 +0200
summary:   Fixes issue 21670: Some M_transaction 'movement types' are not used.

details:   https://code.openbravo.com/erp/devel/pi/rev/9681ae1efd04
changeset: 17989:9681ae1efd04
user:      Ioritz Cia <ioritz.cia <at> openbravo.com>
date:      Tue Sep 18 18:39:03 2012 +0200
summary:   Fixes issue 21678: Match Statement process button shows an error
if the user does not have access to Matching algorithm window or table.

details:   https://code.openbravo.com/erp/devel/pi/rev/a11f82799fbf
changeset: 17990:a11f82799fbf
user:      Ioritz Cia <ioritz.cia <at> openbravo.com>
date:      Wed Sep 19 12:48:16 2012 +0200
summary:   Fixes issue 21686: Wrong 'Paid Out' amount after reactivate a 
Payment In.

diffstat:

 
modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/ad_actionbutton/AddOrderOrInvoice.java
 |   6 ++--
 
modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/ad_actionbutton/MatchTransaction.java
  |  15 ++++++++-
 src-db/database/sourcedata/AD_COLUMN.xml                                       
                              |   4 +-
 src-db/database/sourcedata/AD_REF_LIST.xml                                     
                              |   4 +-
 4 files changed, 20 insertions(+), 9 deletions(-)

diffs (100 lines):

diff -r ce64e9cc6a7d -r a11f82799fbf 
modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/ad_actionbutton/AddOrderOrInvoice.java
--- 
a/modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/ad_actionbutton/AddOrderOrInvoice.java
      Tue Sep 18 12:38:05 2012 +0200
+++ 
b/modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/ad_actionbutton/AddOrderOrInvoice.java
      Wed Sep 19 12:48:16 2012 +0200
@@ -468,12 +468,12 @@
         // Amounts
         if (payment.isReceipt()) {
           glItem.put("glitemPaidOutAmt", psdGLItem.getAmount().signum() < 0 ? 
psdGLItem.getAmount()
-              : BigDecimal.ZERO);
+              .abs() : BigDecimal.ZERO);
           glItem.put("glitemReceivedInAmt",
               psdGLItem.getAmount().signum() > 0 ? psdGLItem.getAmount() : 
BigDecimal.ZERO);
         } else {
-          glItem.put("glitemReceivedInAmt",
-              psdGLItem.getAmount().signum() < 0 ? psdGLItem.getAmount() : 
BigDecimal.ZERO);
+          glItem.put("glitemReceivedInAmt", psdGLItem.getAmount().signum() < 0 
? psdGLItem
+              .getAmount().abs() : BigDecimal.ZERO);
           glItem.put("glitemPaidOutAmt", psdGLItem.getAmount().signum() > 0 ? 
psdGLItem.getAmount()
               : BigDecimal.ZERO);
         }
diff -r ce64e9cc6a7d -r a11f82799fbf 
modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/ad_actionbutton/MatchTransaction.java
--- 
a/modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/ad_actionbutton/MatchTransaction.java
       Tue Sep 18 12:38:05 2012 +0200
+++ 
b/modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/ad_actionbutton/MatchTransaction.java
       Wed Sep 19 12:48:16 2012 +0200
@@ -372,6 +372,7 @@
     FIN_FinancialAccount financial = 
OBDal.getInstance().get(FIN_FinancialAccount.class,
         strFinancialAccountId);
     try {
+      OBContext.setAdminMode(true);
       new 
FIN_MatchingTransaction(financial.getMatchingAlgorithm().getJavaClassName());
     } catch (Exception ex) {
       OBDal.getInstance().rollbackAndClose();
@@ -380,6 +381,8 @@
       vars.setMessage(strTabId, message);
       printPageClosePopUp(response, vars, Utility.getTabURL(strTabId, "R", 
true));
       return;
+    } finally {
+      OBContext.restorePreviousMode();
     }
     try {
       ComboTableData comboTableData = new ComboTableData(vars, this, "LIST", 
"",
@@ -408,8 +411,16 @@
     XmlDocument xmlDocument = xmlEngine.readXmlTemplate(
         
"org/openbravo/advpaymentmngt/ad_actionbutton/MatchTransactionGrid").createXmlDocument();
 
-    FieldProvider[] data = getMatchedBankStatementLinesData(vars, 
strFinancialAccountId,
-        strReconciliationId, strPaymentTypeFilter, strShowCleared, 
strHideDate);
+    FieldProvider[] data = null;
+    try {
+      OBContext.setAdminMode(true);
+      data = getMatchedBankStatementLinesData(vars, strFinancialAccountId, 
strReconciliationId,
+          strPaymentTypeFilter, strShowCleared, strHideDate);
+    } catch (Exception e) {
+      log4j.debug("Output: Exception ocurred while retrieving Bank Statement 
Lines.");
+    } finally {
+      OBContext.restorePreviousMode();
+    }
 
     xmlDocument.setData("structure", data);
 
diff -r ce64e9cc6a7d -r a11f82799fbf src-db/database/sourcedata/AD_COLUMN.xml
--- a/src-db/database/sourcedata/AD_COLUMN.xml  Tue Sep 18 12:38:05 2012 +0200
+++ b/src-db/database/sourcedata/AD_COLUMN.xml  Wed Sep 19 12:48:16 2012 +0200
@@ -29412,7 +29412,7 @@
 <!--2163-->  <ISKEY><![CDATA[N]]></ISKEY>
 <!--2163-->  <ISPARENT><![CDATA[N]]></ISPARENT>
 <!--2163-->  <ISMANDATORY><![CDATA[Y]]></ISMANDATORY>
-<!--2163-->  <ISUPDATEABLE><![CDATA[Y]]></ISUPDATEABLE>
+<!--2163-->  <ISUPDATEABLE><![CDATA[N]]></ISUPDATEABLE>
 <!--2163-->  <READONLYLOGIC><![CDATA[@Processed@='Y']]></READONLYLOGIC>
 <!--2163-->  <ISIDENTIFIER><![CDATA[N]]></ISIDENTIFIER>
 <!--2163-->  <SEQNO><![CDATA[100]]></SEQNO>
@@ -54829,7 +54829,7 @@
 <!--3486-->  <ISKEY><![CDATA[N]]></ISKEY>
 <!--3486-->  <ISPARENT><![CDATA[N]]></ISPARENT>
 <!--3486-->  <ISMANDATORY><![CDATA[Y]]></ISMANDATORY>
-<!--3486-->  <ISUPDATEABLE><![CDATA[Y]]></ISUPDATEABLE>
+<!--3486-->  <ISUPDATEABLE><![CDATA[N]]></ISUPDATEABLE>
 <!--3486-->  <READONLYLOGIC><![CDATA[@Processed@='Y']]></READONLYLOGIC>
 <!--3486-->  <ISIDENTIFIER><![CDATA[N]]></ISIDENTIFIER>
 <!--3486-->  <SEQNO><![CDATA[100]]></SEQNO>
diff -r ce64e9cc6a7d -r a11f82799fbf src-db/database/sourcedata/AD_REF_LIST.xml
--- a/src-db/database/sourcedata/AD_REF_LIST.xml        Tue Sep 18 12:38:05 
2012 +0200
+++ b/src-db/database/sourcedata/AD_REF_LIST.xml        Wed Sep 19 12:48:16 
2012 +0200
@@ -2141,7 +2141,7 @@
 <!--313-->  <AD_REF_LIST_ID><![CDATA[313]]></AD_REF_LIST_ID>
 <!--313-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
 <!--313-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
-<!--313-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--313-->  <ISACTIVE><![CDATA[N]]></ISACTIVE>
 <!--313-->  <VALUE><![CDATA[C+]]></VALUE>
 <!--313-->  <NAME><![CDATA[Customer Returns]]></NAME>
 <!--313-->  <AD_REFERENCE_ID><![CDATA[189]]></AD_REFERENCE_ID>
@@ -2163,7 +2163,7 @@
 <!--315-->  <AD_REF_LIST_ID><![CDATA[315]]></AD_REF_LIST_ID>
 <!--315-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
 <!--315-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
-<!--315-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--315-->  <ISACTIVE><![CDATA[N]]></ISACTIVE>
 <!--315-->  <VALUE><![CDATA[V-]]></VALUE>
 <!--315-->  <NAME><![CDATA[Vendor Returns]]></NAME>
 <!--315-->  <AD_REFERENCE_ID><![CDATA[189]]></AD_REFERENCE_ID>

------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://ad.doubleclick.net/clk;258768047;13503038;j?
http://info.appdynamics.com/FreeJavaPerformanceDownload.html
_______________________________________________
Openbravo-commits mailing list
Openbravo-commits@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openbravo-commits

Reply via email to