f
This commit is contained in:
@@ -1,12 +1,12 @@
|
||||
package svc
|
||||
|
||||
import (
|
||||
"time"
|
||||
"bdqr-server/app/main/api/internal/config"
|
||||
"bdqr-server/app/main/api/internal/middleware"
|
||||
"bdqr-server/app/main/api/internal/service"
|
||||
tianyuanapi "bdqr-server/app/main/api/internal/service/tianyuanapi_sdk"
|
||||
"bdqr-server/app/main/model"
|
||||
"time"
|
||||
|
||||
"github.com/hibiken/asynq"
|
||||
"github.com/zeromicro/go-zero/core/logx"
|
||||
@@ -90,6 +90,7 @@ type ServiceContext struct {
|
||||
DictService *service.DictService
|
||||
ImageService *service.ImageService
|
||||
AuthorizationService *service.AuthorizationService
|
||||
TencentCloudService *service.TencentCloudService
|
||||
}
|
||||
|
||||
// NewServiceContext 创建服务上下文
|
||||
@@ -170,7 +171,7 @@ func NewServiceContext(c config.Config) *ServiceContext {
|
||||
|
||||
// ============================== 业务服务初始化 ==============================
|
||||
alipayService := service.NewAliPayService(c)
|
||||
wechatPayService := service.NewWechatPayService(c, userAuthModel, service.InitTypeWxPayPubKey)
|
||||
wechatPayService := service.NewWechatPayService(c, userAuthModel, service.InitTypeWxPayPubKeyPure)
|
||||
applePayService := service.NewApplePayService(c)
|
||||
apiRequestService := service.NewApiRequestService(c, featureModel, productFeatureModel, tianyuanapi)
|
||||
verificationService := service.NewVerificationService(c, tianyuanapi, apiRequestService)
|
||||
@@ -183,7 +184,7 @@ func NewServiceContext(c config.Config) *ServiceContext {
|
||||
dictService := service.NewDictService(adminDictTypeModel, adminDictDataModel)
|
||||
imageService := service.NewImageService()
|
||||
authorizationService := service.NewAuthorizationService(c, authorizationDocumentModel)
|
||||
|
||||
tencentCloudService := service.NewTencentCloudService(c)
|
||||
// ============================== 异步任务服务 ==============================
|
||||
asynqServer := asynq.NewServer(
|
||||
asynq.RedisClientOpt{Addr: c.CacheRedis[0].Host, Password: c.CacheRedis[0].Pass},
|
||||
@@ -270,6 +271,7 @@ func NewServiceContext(c config.Config) *ServiceContext {
|
||||
DictService: dictService,
|
||||
ImageService: imageService,
|
||||
AuthorizationService: authorizationService,
|
||||
TencentCloudService: tencentCloudService,
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user