|
@@ -11,7 +11,6 @@ import com.zanxiang.common.constant.Constants;
|
|
|
import com.zanxiang.common.domain.ResultMap;
|
|
|
import com.zanxiang.common.enums.HttpStatusEnum;
|
|
|
import com.zanxiang.common.enums.OsEnum;
|
|
|
-import com.zanxiang.common.enums.ResEnum;
|
|
|
import com.zanxiang.module.util.JsonUtil;
|
|
|
import com.zanxiang.sdk.domain.bo.ProductPayParamBO;
|
|
|
import com.zanxiang.sdk.util.HttpUtil;
|
|
@@ -121,14 +120,14 @@ public class AliPayService extends PayBaseService {
|
|
|
if (flag) {
|
|
|
if (paySuccess(orderNo, params.get("total_amount"), params.get("trade_no"), gamePayWayId)) {
|
|
|
log.info("支付宝异步回调成功 request:{},orderNo:{},商户订单号为:{}", request, orderNo, params.get("trade_no"));
|
|
|
- return ResEnum.SUCCESS.getMsg();
|
|
|
+ return HttpStatusEnum.SUCCESS.getMsg();
|
|
|
}
|
|
|
}
|
|
|
log.error("支付宝异步回调-验证签名失败 request:{}", request);
|
|
|
} catch (Exception e) {
|
|
|
e.printStackTrace();
|
|
|
}
|
|
|
- return ResEnum.FAIL.getMsg();
|
|
|
+ return HttpStatusEnum.FAIL.getMsg();
|
|
|
}
|
|
|
|
|
|
/**
|
|
@@ -193,7 +192,7 @@ public class AliPayService extends PayBaseService {
|
|
|
//请求失败
|
|
|
if (!ResponseChecker.success(response)) {
|
|
|
log.error("支付宝h5支付失败,product : {}, response : {}", JsonUtil.toString(product), JsonUtil.toString(response));
|
|
|
- return ResultMap.error(ResEnum.FAIL.getMsg());
|
|
|
+ return ResultMap.error(HttpStatusEnum.FAIL.getMsg());
|
|
|
}
|
|
|
HashMap<String, String> result = new HashMap<>();
|
|
|
String body = response.getBody();
|
|
@@ -235,7 +234,7 @@ public class AliPayService extends PayBaseService {
|
|
|
return ResultMap.ok(product.getPayDevice(), result.get("appLink"), product.getOutTradeNo());
|
|
|
} catch (Exception e) {
|
|
|
log.error("支付宝h5支付失败,meg : {}", e.getMessage());
|
|
|
- return ResultMap.error(ResEnum.FAIL.getMsg());
|
|
|
+ return ResultMap.error(HttpStatusEnum.FAIL.getMsg());
|
|
|
}
|
|
|
}
|
|
|
|
|
@@ -255,11 +254,11 @@ public class AliPayService extends PayBaseService {
|
|
|
if (ResponseChecker.success(response)) {
|
|
|
return ResultMap.ok(product.getPayDevice(), response.getBody(), product.getOutTradeNo());
|
|
|
} else {
|
|
|
- return ResultMap.error(ResEnum.FAIL.getMsg());
|
|
|
+ return ResultMap.error(HttpStatusEnum.FAIL.getMsg());
|
|
|
}
|
|
|
} catch (Exception e) {
|
|
|
log.error("pc端支付生成异常 e:{}", e.getMessage());
|
|
|
- return ResultMap.error(ResEnum.FAIL.getMsg());
|
|
|
+ return ResultMap.error(HttpStatusEnum.FAIL.getMsg());
|
|
|
}
|
|
|
}
|
|
|
|
|
@@ -277,12 +276,12 @@ public class AliPayService extends PayBaseService {
|
|
|
if (ResponseChecker.success(response)) {
|
|
|
return ResultMap.ok(product.getPayDevice(), response.getBody(), product.getOutTradeNo());
|
|
|
} else {
|
|
|
- return ResultMap.error(ResEnum.FAIL.getMsg());
|
|
|
+ return ResultMap.error(HttpStatusEnum.FAIL.getMsg());
|
|
|
}
|
|
|
} catch (Exception e) {
|
|
|
e.printStackTrace();
|
|
|
log.error("app端支付生成异常 e:{}", e.getMessage());
|
|
|
- return ResultMap.error(ResEnum.FAIL.getMsg());
|
|
|
+ return ResultMap.error(HttpStatusEnum.FAIL.getMsg());
|
|
|
}
|
|
|
}
|
|
|
|