修改判断

master
lvxinran 2021-06-30 16:36:16 +08:00
parent 5e7c817921
commit 109b866547
2 changed files with 4 additions and 7 deletions

View File

@ -90,10 +90,6 @@ public class PayLogic {
LOGGER.info("serviceKey : " + serviceKey);
try {
rPCClient = ClientAdapterPo.getClientAdapterPo(serviceKey);
if(sdk==PaySdkEnum.QUICK){
//quick的是元
amount = String.valueOf(Double.parseDouble(amount )*100);
}
result = rPCClient.getClient().deliveryRecharge(cUserInfo.getId(), goodsId, openId, orderId, 0, (int)Double.parseDouble(amount));
} catch (Exception e) {
LOGGER.info("callback=>", e);

View File

@ -93,14 +93,15 @@ public class QuickRechargeController {
String[] callback = callbackInfo.split("_");
String orderNo = map.get("order_no");
String amount = map.get("amount");
return payLogic.initOrder(callbackInfo,orderNo,amount,new Date(System.currentTimeMillis()),callback[0],PaySdkEnum.QUICK);
//quick的是元 要处理一下
String amountForward = String.valueOf(Double.parseDouble(amount) * 100);
return payLogic.initOrder(callbackInfo,orderNo,amountForward,new Date(System.currentTimeMillis()),callback[0],PaySdkEnum.QUICK);
}
public boolean sign(String ntdata0,String sign0,String md5Sign){
String paramStr = ntdata0+sign0+md5key;
String sign = MD5Util.encrypByMd5(paramStr);
LOGGER.info("加密前字符串:{}",paramStr);
// LOGGER.info("加密前字符串:{}",paramStr);
LOGGER.info("加密后得:{}",sign);
if(sign.equals(md5Sign)){
return true;