支持微信支付宝独立支付渠道
This commit is contained in:
@@ -64,7 +64,7 @@ func (s *Service) Delete(ctx context.Context, id uint64, actorID uint64, meta Au
|
||||
return s.repo.Delete(ctx, id, actorID, meta)
|
||||
}
|
||||
|
||||
// GetDefaultConfig 获取默认配置(用于支付模块调用)
|
||||
// GetDefaultConfig 获取指定服务商的默认配置,保留给管理工具或兼容调用使用。
|
||||
func (s *Service) GetDefaultConfig(ctx context.Context, provider string) (*ConfigDTO, error) {
|
||||
config, err := s.repo.FindDefault(ctx, provider)
|
||||
if err != nil {
|
||||
@@ -76,3 +76,8 @@ func (s *Service) GetDefaultConfig(ctx context.Context, provider string) (*Confi
|
||||
}
|
||||
return &dto, nil
|
||||
}
|
||||
|
||||
// GetDefaultConfigByPayWay 获取指定支付方式的默认配置,供新支付链路按微信/支付宝选渠道。
|
||||
func (s *Service) GetDefaultConfigByPayWay(ctx context.Context, payWay string) (*ConfigDTO, error) {
|
||||
return s.repo.FindDefaultByPayWay(ctx, payWay, true)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user