Author: hansbak
Date: Wed Jul 5 16:13:07 2006
New Revision: 419381
URL:
http://svn.apache.org/viewvc?rev=419381&view=revLog:
add a clearCommerce service to check for creditcard validity only
Modified:
incubator/ofbiz/trunk/applications/accounting/servicedef/services_clearcommerce.xml
incubator/ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/thirdparty/clearcommerce/CCPaymentServices.java
Modified: incubator/ofbiz/trunk/applications/accounting/servicedef/services_clearcommerce.xml
URL:
http://svn.apache.org/viewvc/incubator/ofbiz/trunk/applications/accounting/servicedef/services_clearcommerce.xml?rev=419381&r1=419380&r2=419381&view=diff==============================================================================
--- incubator/ofbiz/trunk/applications/accounting/servicedef/services_clearcommerce.xml (original)
+++ incubator/ofbiz/trunk/applications/accounting/servicedef/services_clearcommerce.xml Wed Jul 5 16:13:07 2006
@@ -28,6 +28,7 @@
location="org.ofbiz.accounting.thirdparty.clearcommerce.CCPaymentServices" invoke="ccAuth">
<description>ClearCommerce Credit Card Authorization</description>
<implements service="ccAuthInterface"/>
+ <attribute name="ccAction" type="String" mode="IN" optional="true"/>
</service>
<service name="clearCommerceCCCapture" engine="java"
location="org.ofbiz.accounting.thirdparty.clearcommerce.CCPaymentServices" invoke="ccCapture">
Modified: incubator/ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/thirdparty/clearcommerce/CCPaymentServices.java
URL:
http://svn.apache.org/viewvc/incubator/ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/thirdparty/clearcommerce/CCPaymentServices.java?rev=419381&r1=419380&r2=419381&view=diff==============================================================================
--- incubator/ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/thirdparty/clearcommerce/CCPaymentServices.java (original)
+++ incubator/ofbiz/trunk/applications/accounting/src/org/ofbiz/accounting/thirdparty/clearcommerce/CCPaymentServices.java Wed Jul 5 16:13:07 2006
@@ -58,9 +58,10 @@
public final static String module = CCPaymentServices.class.getName();
-
public static Map ccAuth(DispatchContext dctx, Map context) {
- Document authRequestDoc = buildPrimaryTxRequest(context, "PreAuth", (Double) context.get("processAmount"),
+ String ccAction = (String) context.get("ccAction");
+ if (ccAction == null) ccAction = new String("PreAuth");
+ Document authRequestDoc = buildPrimaryTxRequest(context, ccAction, (Double) context.get("processAmount"),
(String) context.get("orderId"));
Document authResponseDoc = null;