gpt4 book ai didi

com.github.binarywang.wxpay.bean.notify.WxPayOrderNotifyResult.getReturnCode()方法的使用及代码示例

转载 作者:知者 更新时间:2024-03-22 02:37:05 24 4
gpt4 key购买 nike

本文整理了Java中com.github.binarywang.wxpay.bean.notify.WxPayOrderNotifyResult.getReturnCode()方法的一些代码示例,展示了WxPayOrderNotifyResult.getReturnCode()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。WxPayOrderNotifyResult.getReturnCode()方法的具体详情如下:
包路径:com.github.binarywang.wxpay.bean.notify.WxPayOrderNotifyResult
类名称:WxPayOrderNotifyResult
方法名:getReturnCode

WxPayOrderNotifyResult.getReturnCode介绍

暂无

代码示例

代码示例来源:origin: jmdhappy/xxpay-master

&& !PayConstant.RETURN_VALUE_SUCCESS.equalsIgnoreCase(params.getReturnCode())) {
_log.error("returnCode={},resultCode={},errCode={},errCodeDes={}", params.getReturnCode(), params.getResultCode(), params.getErrCode(), params.getErrCodeDes());
payContext.put("retMsg", "notify data failed");
return false;

代码示例来源:origin: jmdhappy/xxpay-master

&& !PayConstant.RETURN_VALUE_SUCCESS.equalsIgnoreCase(params.getReturnCode())) {
_log.error("returnCode={},resultCode={},errCode={},errCodeDes={}", params.getReturnCode(), params.getResultCode(), params.getErrCode(), params.getErrCodeDes());
payContext.put("retMsg", "notify data failed");
return false;

代码示例来源:origin: jmdhappy/xxpay-master

&& !PayConstant.RETURN_VALUE_SUCCESS.equalsIgnoreCase(params.getReturnCode())) {
_log.error("returnCode={},resultCode={},errCode={},errCodeDes={}", params.getReturnCode(), params.getResultCode(), params.getErrCode(), params.getErrCodeDes());
payContext.put("retMsg", "notify data failed");
return false;

代码示例来源:origin: com.github.binarywang/weixin-java-pay

@Override
public void checkResult(WxPayService wxPayService, String signType, boolean checkSuccess) throws WxPayException {
 //防止伪造成功通知
 if (WxPayConstants.ResultCode.SUCCESS.equals(getReturnCode()) && getSign() == null) {
  throw new WxPayException("伪造的通知!");
 }
 
 super.checkResult(wxPayService, signType, checkSuccess);
}

代码示例来源:origin: binarywang/WxJava

@Override
public void checkResult(WxPayService wxPayService, String signType, boolean checkSuccess) throws WxPayException {
 //防止伪造成功通知
 if (WxPayConstants.ResultCode.SUCCESS.equals(getReturnCode()) && getSign() == null) {
  throw new WxPayException("伪造的通知!");
 }
 
 super.checkResult(wxPayService, signType, checkSuccess);
}

代码示例来源:origin: ustcwudi/springboot-seed

@PostMapping("/pay_callback/{type}/{id}/{rid}/{uid}")
public ResponseEntity<?> parseOrderNotifyResult(@ApiParam("支付类型") @PathVariable("type") Integer type,
                        @ApiParam("主键") @PathVariable("id") long id,
                        @ApiParam("外键") @PathVariable("rid") long rid,
                        @ApiParam("用户id") @PathVariable("uid") long uid,
                        @RequestBody String xmlData) throws WxPayException {
  WxPayOrderNotifyResult result = wxPayAPI.parseOrderNotifyResult(xmlData);
  if (result.getReturnCode().equals("SUCCESS")) {
    if (type == 1) {
      Payment payment = paymentService.selectByID(id).get();
      payment.setBankType(result.getBankType());
      payment.setOutTradeNo(result.getOutTradeNo());
      payment.setTransactionNo(result.getTransactionId());
      payment.setComment(result.getReturnCode());
      paymentService.modifyById(payment);
      CarFee carFee = carFeeService.selectByID(rid).get();
      carFee.setPaymentAmount(new BigDecimal(payment.getTotalFee()).divide(new BigDecimal(100)));
      carFee.setPaymentTime(new Date());
      carFee.setPaymentMode("微信支付");
      carFee.setPaymentId(id);
      carFee.setUserId(uid);
      carFeeService.modifyById(carFee);
    } else {
      // todo: 会员充值
    }
    return ResponseEntity.status(HttpStatus.OK).body("SUCCESS");
  } else {
    return ResponseEntity.status(HttpStatus.OK).body("FAIL");
  }
}

代码示例来源:origin: liuweijw/fw-cloud-framework

|| !PayConstant.RETURN_VALUE_SUCCESS.equalsIgnoreCase(result.getResultCode())) {
log.error("returnCode={},resultCode={},errCode={},errCodeDes={}", result
    .getReturnCode(), result.getResultCode(), result.getErrCode(), result
    .getErrCodeDes());
return WxPayNotifyResponse.fail("notify data failed");

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com