diff --git a/app/main/api/internal/service/alipayService.go b/app/main/api/internal/service/alipayService.go index bb8d8b7..ccd2036 100644 --- a/app/main/api/internal/service/alipayService.go +++ b/app/main/api/internal/service/alipayService.go @@ -28,10 +28,10 @@ func NewAliPayService(c config.Config) *AliPayService { panic(fmt.Sprintf("创建支付宝客户端失败: %v", err)) } // 加载支付宝公钥 - err = client.LoadAliPayPublicKey(c.Alipay.AlipayPublicKey) - if err != nil { - panic(fmt.Sprintf("加载支付宝公钥失败: %v", err)) - } + // err = client.LoadAliPayPublicKey(c.Alipay.AlipayPublicKey) + // if err != nil { + // panic(fmt.Sprintf("加载支付宝公钥失败: %v", err)) + // } // 加载证书 if err = client.LoadAppCertPublicKeyFromFile(c.Alipay.AppCertPath); err != nil { diff --git a/app/main/api/internal/svc/servicecontext.go b/app/main/api/internal/svc/servicecontext.go index 2ced8d0..5fc0d8b 100644 --- a/app/main/api/internal/svc/servicecontext.go +++ b/app/main/api/internal/svc/servicecontext.go @@ -45,20 +45,20 @@ type ServiceContext struct { QueryCleanupConfigModel model.QueryCleanupConfigModel // 代理相关模型 - AgentModel model.AgentModel - AgentAuditModel model.AgentAuditModel - AgentCommissionModel model.AgentCommissionModel - AgentWalletModel model.AgentWalletModel - AgentLinkModel model.AgentLinkModel - AgentOrderModel model.AgentOrderModel - AgentProductConfigModel model.AgentProductConfigModel - AgentPlatformDeductionModel model.AgentPlatformDeductionModel - AgentWithdrawalModel model.AgentWithdrawalModel - AgentRealNameModel model.AgentRealNameModel - AgentWithdrawalTaxModel model.AgentWithdrawalTaxModel - AgentWithdrawalTaxExemptionModel model.AgentWithdrawalTaxExemptionModel - AgentWalletTransactionModel model.AgentWalletTransactionModel - AgentConfigModel model.AgentConfigModel + AgentModel model.AgentModel + AgentAuditModel model.AgentAuditModel + AgentCommissionModel model.AgentCommissionModel + AgentWalletModel model.AgentWalletModel + AgentLinkModel model.AgentLinkModel + AgentOrderModel model.AgentOrderModel + AgentProductConfigModel model.AgentProductConfigModel + AgentPlatformDeductionModel model.AgentPlatformDeductionModel + AgentWithdrawalModel model.AgentWithdrawalModel + AgentRealNameModel model.AgentRealNameModel + AgentWithdrawalTaxModel model.AgentWithdrawalTaxModel + AgentWithdrawalTaxExemptionModel model.AgentWithdrawalTaxExemptionModel + AgentWalletTransactionModel model.AgentWalletTransactionModel + AgentConfigModel model.AgentConfigModel // 管理后台相关模型 AdminApiModel model.AdminApiModel @@ -176,7 +176,7 @@ func NewServiceContext(c config.Config) *ServiceContext { // ============================== 业务服务初始化 ============================== alipayService := service.NewAliPayService(c) - wechatPayService := service.NewWechatPayService(c, userAuthModel, service.InitTypePlatformCert) + wechatPayService := service.NewWechatPayService(c, userAuthModel, service.InitTypeWxPayPubKey) applePayService := service.NewApplePayService(c) authorizationService := service.NewAuthorizationService(c, authorizationDocumentModel) apiRequestService := service.NewApiRequestService(c, featureModel, productFeatureModel, tianyuanapi, authorizationService) @@ -234,20 +234,20 @@ func NewServiceContext(c config.Config) *ServiceContext { QueryCleanupConfigModel: queryCleanupConfigModel, // 代理相关模型 - AgentModel: agentModel, - AgentAuditModel: agentAuditModel, - AgentCommissionModel: agentCommissionModel, - AgentWalletModel: agentWalletModel, - AgentLinkModel: agentLinkModel, - AgentOrderModel: agentOrderModel, - AgentProductConfigModel: agentProductConfigModel, - AgentPlatformDeductionModel: agentPlatformDeductionModel, - AgentWithdrawalModel: agentWithdrawalModel, - AgentRealNameModel: agentRealNameModel, - AgentWithdrawalTaxModel: agentWithdrawalTaxModel, - AgentWithdrawalTaxExemptionModel: agentWithdrawalTaxExemptionModel, - AgentWalletTransactionModel: agentWalletTransactionModel, - AgentConfigModel: agentConfigModel, + AgentModel: agentModel, + AgentAuditModel: agentAuditModel, + AgentCommissionModel: agentCommissionModel, + AgentWalletModel: agentWalletModel, + AgentLinkModel: agentLinkModel, + AgentOrderModel: agentOrderModel, + AgentProductConfigModel: agentProductConfigModel, + AgentPlatformDeductionModel: agentPlatformDeductionModel, + AgentWithdrawalModel: agentWithdrawalModel, + AgentRealNameModel: agentRealNameModel, + AgentWithdrawalTaxModel: agentWithdrawalTaxModel, + AgentWithdrawalTaxExemptionModel: agentWithdrawalTaxExemptionModel, + AgentWalletTransactionModel: agentWalletTransactionModel, + AgentConfigModel: agentConfigModel, // 管理后台相关模型 AdminApiModel: adminApiModel,