Files
hfb_sys/backend/internal/modules/qualityowner/service.go
T
yml2213 98174c0e33 feat(quality-owner): 增加优质号主、极品专区与无忧租号保险
- 支持保证金余额支付、在线支付开通及后台手动设置审计
- 新增极品专区发布权限、赔付方案与保险结算费率快照
- 优化首页、商品卡和个人中心的优质号主身份展示
2026-11-04 15:04:35 +08:00

33 lines
825 B
Go

package qualityowner
import "context"
type Service struct {
repo *Repository
}
func NewService(repo *Repository) *Service {
return &Service{repo: repo}
}
func (s *Service) Status(ctx context.Context, userID uint64) (*StatusDTO, error) {
if s == nil || s.repo == nil {
return nil, ErrDependencyUnavailable
}
return s.repo.Status(ctx, userID)
}
func (s *Service) Activate(ctx context.Context, userID uint64) (*StatusDTO, error) {
if s == nil || s.repo == nil {
return nil, ErrDependencyUnavailable
}
return s.repo.Activate(ctx, userID)
}
func (s *Service) AdminSet(ctx context.Context, adminID uint64, userID uint64, req AdminSetRequest, meta AuditMeta) (*StatusDTO, error) {
if s == nil || s.repo == nil {
return nil, ErrDependencyUnavailable
}
return s.repo.AdminSet(ctx, adminID, userID, req, meta)
}