Author: jleroux
Date: Tue Dec 23 09:51:56 2014
New Revision: 1647522
URL:
http://svn.apache.org/r1647522Log:
A patch from Prateek Ashtikar for "Issue reported while performing Refund & Void (java.lang.ClassCastException: java.lang.String cannot be cast to java.math.BigDecimal)"
https://issues.apache.org/jira/browse/OFBIZ-5927Change committed in AIMPaymentServices.java.
Modified:
ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/thirdparty/authorizedotnet/AIMPaymentServices.java
Modified: ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/thirdparty/authorizedotnet/AIMPaymentServices.java
URL:
http://svn.apache.org/viewvc/ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/thirdparty/authorizedotnet/AIMPaymentServices.java?rev=1647522&r1=1647521&r2=1647522&view=diff==============================================================================
--- ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/thirdparty/authorizedotnet/AIMPaymentServices.java (original)
+++ ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/thirdparty/authorizedotnet/AIMPaymentServices.java Tue Dec 23 09:51:56 2014
@@ -824,7 +824,8 @@ public class AIMPaymentServices {
private static BigDecimal getXAmount(Map<String, Object> request) {
BigDecimal amt = BigDecimal.ZERO;
if (request.get("x_Amount") != null) {
- BigDecimal amount = (BigDecimal) request.get("x_Amount");
+ String newAmt = request.get("x_Amount").toString();
+ BigDecimal amount = new BigDecimal(newAmt);
try {
amt = amount;
} catch (NumberFormatException e) {