Commit 1e83c14c authored by 张永's avatar 张永

111

parent 4ed735e3
......@@ -7,7 +7,7 @@ import com.alibaba.fastjson.JSONObject;
public interface CrmService {
public void vUpdateAcceptCoupon(String StoreNO, String CouponNO, BigDecimal PayAmount, BigDecimal TotalRealSaleAmount, String OutTradeNO, String cashier, String hostname, String ipaddress);
public void couponVerification(String StoreNO, String CouponNO, String SalesOrderID, BigDecimal AcceptAmount, BigDecimal TotalRealSaleAmount, String OutTradeNO, String GoodsList, String cashier,String isOnline,String payTypeID);
public void couponVerification(String StoreNO, String CouponNO, String SalesOrderID, BigDecimal AcceptAmount, BigDecimal TotalRealSaleAmount, String OutTradeNO, String GoodsList, String cashier,String isOnline,String payTypeID,String agentID);
public void vUpdateMemPoint(int TradeType, String StoreNO, String CardNO, BigDecimal PayPoint, String OutTradeNO, String cashier, String hostname, String ipaddress);
......
......@@ -78,7 +78,7 @@ public class CrmServiceImpl implements CrmService{
* @param hostname
* @param ipaddress
*/
public void couponVerification(String StoreNO, String CouponNO, String SalesOrderID, BigDecimal AcceptAmount, BigDecimal TotalRealSaleAmount, String OutTradeNO, String GoodsList, String cashier,String isOnline,String payTypeID) {
public void couponVerification(String StoreNO, String CouponNO, String SalesOrderID, BigDecimal AcceptAmount, BigDecimal TotalRealSaleAmount, String OutTradeNO, String GoodsList, String cashier,String isOnline,String payTypeID,String agentID) {
Map<String, Object> parameters = new HashMap<String, Object>();
parameters.put("storeNO", StoreNO);
parameters.put("couponNO", CouponNO);
......@@ -90,7 +90,8 @@ public class CrmServiceImpl implements CrmService{
parameters.put("goodsList", GoodsList);
parameters.put("isOnline", isOnline);
parameters.put("payTypeID", payTypeID);
String json = crmClient.post("/api/member/couponVerification", parameters);
parameters.put("agentID", agentID);
String json = crmClient.post("/api/member/b2b/couponVerification", parameters);
JSONObject jsonObject = JSON.parseObject(json);
......@@ -261,7 +262,7 @@ public class CrmServiceImpl implements CrmService{
parameters.put("cashier", cashier);
parameters.put("hostname", hostname);
parameters.put("ipaddress", ipaddress);
String json = crmClient.post("/api/member/vCancelAcceptCoupon", parameters);
String json = crmClient.post("/api/member/b2b/vCancelAcceptCoupon", parameters);
JSONObject jsonObject = JSON.parseObject(json);
int code = jsonObject.getIntValue("code");
if(code != 200) {
......
......@@ -1766,8 +1766,10 @@ public class OrderServiceImpl implements OrderService {
OutParameter pStatus = new OutParameter(Types.INTEGER);
OutParameter pErrorMsg = new OutParameter(Types.VARCHAR);
String agentId = payObj.get("AgentID")+"";
if(PayTypeID != null && Tag != null && ( PayTypeID.equals("81") || PayTypeID.equals("882") ) && Tag.intValue() == 0) { //优会券和提货券
crmService.couponVerification(shopNO, PayCardNO, salesOrderID, PayAmount, TotalRealSaleAmount, OutTradeNO, goodsList, cashier,"1",PayTypeID);
crmService.couponVerification(shopNO, PayCardNO, salesOrderID, PayAmount, TotalRealSaleAmount, OutTradeNO, goodsList, cashier,"1",PayTypeID,agentId);
jdbcTemplate.exec("exec up_B2BSalesOrderPayConfirm ?, ?, ?, ?, ?, ?, ?, ?, ?, ?", new Object[] {salesOrderID, PayTypeID, PayAmount, PayCardNO, PayDateTime, OutTradeNO, pOrderStatus, pOrderStatusName, pStatus, pErrorMsg});
Integer rStatus = (Integer)pStatus.getValue();
String rErrorMsg = (String)pErrorMsg.getValue();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment