|
|
@@ -203,7 +203,7 @@ func BuyPackageForWx(c *gin.Context, req md.BuyPackageReq) (outTradeNo, total st |
|
|
|
return |
|
|
|
} |
|
|
|
wxSvc := jsapi.JsapiApiService{Client: client} |
|
|
|
sysCfg := sysCfgDb.SysCfgFindWithDb(enum2.WxSpAppId, enum2.WxSpMchId, enum2.WxAppletAppId, enum2.WxMchId, enum2.WxJsapiPayNotifyUrl) |
|
|
|
sysCfg := sysCfgDb.SysCfgFindWithDb(enum2.WxAppletAppId, enum2.WxSpAppId, enum2.WxSpMchId, enum2.WxAppletAppId, enum2.WxMchId, enum2.WxJsapiPayNotifyUrl) |
|
|
|
|
|
|
|
result, _, err := wxSvc.Prepay(c, |
|
|
|
jsapi.PrepayRequest{ |
|
|
@@ -263,7 +263,7 @@ func BuyPackageForWx(c *gin.Context, req md.BuyPackageReq) (outTradeNo, total st |
|
|
|
resp = new(jsapi2.PrepayWithRequestPaymentResponse) |
|
|
|
resp.PrepayId = result.PrepayId |
|
|
|
resp.SignType = core.String("RSA") |
|
|
|
appid := sysCfg[enum2.WxSpAppId] |
|
|
|
appid := sysCfg[enum2.WxAppletAppId] |
|
|
|
resp.Appid = &appid |
|
|
|
resp.TimeStamp = core.String(strconv.FormatInt(time.Now().Unix(), 10)) |
|
|
|
nonce, err := utils2.GenerateNonce() |
|
|
|