feat: 微信回调fix
This commit is contained in:
parent
c2fd9e68f9
commit
24c0c6d36a
|
@ -42,7 +42,7 @@ func WxCallback(c *gin.Context) {
|
|||
c.String(http.StatusBadRequest, "%s", "fail")
|
||||
return
|
||||
}
|
||||
if payChannelModel.ChannelType != common.PAY_CHANNEL_WECHAT_H5 {
|
||||
if !(payChannelModel.ChannelType == common.PAY_CHANNEL_WECHAT_H5 || payChannelModel.ChannelType == common.PAY_CHANNEL_WECHAT_JSAPI) {
|
||||
logger.Error(c, "WxCallback-回调数据解析支付配置错误,查询的数据不是当前渠道")
|
||||
c.String(http.StatusBadRequest, "%s", "fail")
|
||||
return
|
||||
|
|
|
@ -300,7 +300,6 @@ func WxJsApiPay(param front.WxJsApiPayRequest) (response front.WxJsApiPayRespons
|
|||
}
|
||||
|
||||
// 4 签名
|
||||
// 4.1 签名数据
|
||||
signValue, err := task.Sign(response.AppId, response.TimeStamp, response.NonceStr, response.Package)
|
||||
if err != nil {
|
||||
utils.Log(nil, "签名失败", err)
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>微信授权登录</title>
|
||||
<title>微信支付</title>
|
||||
<script src="https://res.wx.qq.com/open/js/jweixin-1.6.0.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
|
|
Loading…
Reference in New Issue