We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
/** * 微信退款 * @param request * @return */ public RefundResponse refund(RefundRequest request) { WxPayRefundRequest wxRequest = new WxPayRefundRequest(); wxRequest.setOutTradeNo(request.getOrderId()); wxRequest.setOutRefundNo(request.getOrderId()); wxRequest.setTotalFee(MoneyUtil.Yuan2Fen(request.getOrderAmount())); wxRequest.setRefundFee(MoneyUtil.Yuan2Fen(request.getOrderAmount())); wxRequest.setAppid(wxPayConfig.getAppId()); wxRequest.setMchId(wxPayConfig.getMchId()); wxRequest.setNonceStr(RandomUtil.getRandomStr()); wxRequest.setSign(WxPaySignature.sign(MapUtil.buildMap(wxRequest), wxPayConfig.getMchKey())); }
/** * 微信退款 * @param request * @return */ public RefundResponse refund(RefundRequest request) { WxPayRefundRequest wxRequest = new WxPayRefundRequest(); wxRequest.setOutTradeNo(request.getOrderId()); wxRequest.setOutRefundNo(request.getOrderId()); wxRequest.setTotalFee(MoneyUtil.Yuan2Fen(request.getOrderAmount())); wxRequest.setRefundFee(MoneyUtil.Yuan2Fen(request.getOrderAmount()));
wxRequest.setAppid(wxPayConfig.getAppId()); wxRequest.setMchId(wxPayConfig.getMchId()); wxRequest.setNonceStr(RandomUtil.getRandomStr()); wxRequest.setSign(WxPaySignature.sign(MapUtil.buildMap(wxRequest), wxPayConfig.getMchKey()));
}
支付时是这么写的 //小程序和app支付有独立的appid,公众号、h5、native都是公众号的appid if (request.getPayTypeEnum() == BestPayTypeEnum.WXPAY_MINI){ wxRequest.setAppid(wxPayConfig.getMiniAppId()); }else if (request.getPayTypeEnum() == BestPayTypeEnum.WXPAY_APP){ wxRequest.setAppid(wxPayConfig.getAppAppId()); }else { wxRequest.setAppid(wxPayConfig.getAppId()); }
The text was updated successfully, but these errors were encountered:
No branches or pull requests
The text was updated successfully, but these errors were encountered: