diff --git a/app/main/api/internal/logic/agent/generatinglinklogic.go b/app/main/api/internal/logic/agent/generatinglinklogic.go index 37a5ac4..ec17ff7 100644 --- a/app/main/api/internal/logic/agent/generatinglinklogic.go +++ b/app/main/api/internal/logic/agent/generatinglinklogic.go @@ -64,6 +64,7 @@ func (l *GeneratingLinkLogic) GeneratingLink(req *types.AgentGeneratingLinkReq) squirrel.Eq{"product_id": productModel.Id}, // 添加 product_id 的匹配条件 squirrel.Eq{"price": price}, // 添加 price 的匹配条件 squirrel.Eq{"agent_id": agentModel.Id}, // 添加 agent_id 的匹配条件 + squirrel.Eq{"show_price": req.ShowPrice}, // 添加 show_price 的匹配条件 }) agentLinkModel, err := l.svcCtx.AgentLinkModel.FindAll(l.ctx, build, "") diff --git a/app/main/api/internal/service/wechatpayService.go b/app/main/api/internal/service/wechatpayService.go index 3ca507d..38f7a30 100644 --- a/app/main/api/internal/service/wechatpayService.go +++ b/app/main/api/internal/service/wechatpayService.go @@ -106,12 +106,12 @@ func newWechatPayServiceWithPlatformCert(c config.Config, userAuthModel model.Us // newWechatPayServiceWithWxPayPubKey 使用微信支付公钥初始化微信支付服务 func newWechatPayServiceWithWxPayPubKey(c config.Config, userAuthModel model.UserAuthModel) *WechatPayService { // 从配置中加载商户信息 - mchID := c.Wxpay.MchID // 商户号 - mchCertificateSerialNumber := c.Wxpay.MchCertificateSerialNumber // 商户证书序列号 - mchAPIv3Key := c.Wxpay.MchApiv3Key // 商户APIv3密钥 - mchPrivateKeyPath := c.Wxpay.MchPrivateKeyPath // 商户私钥路径 - mchPublicKeyID := c.Wxpay.MchPublicKeyID // 商户公钥ID - mchPublicKeyPath := c.Wxpay.MchPublicKeyPath // 商户公钥路径 + mchID := c.Wxpay.MchID + mchCertificateSerialNumber := c.Wxpay.MchCertificateSerialNumber + mchAPIv3Key := c.Wxpay.MchApiv3Key + mchPrivateKeyPath := c.Wxpay.MchPrivateKeyPath + mchPublicKeyID := c.Wxpay.MchPublicKeyID + mchPublicKeyPath := c.Wxpay.MchPublicKeyPath // 从文件中加载商户私钥 mchPrivateKey, err := utils.LoadPrivateKeyWithPath(mchPrivateKeyPath) if err != nil {