支持客服入口按业务场景分流到客服分组

联系客服支持 scene(general/mohong),按用户与场景复用会话;摸大红入口走摸大红分组选人。
This commit is contained in:
yml2213
2026-07-16 20:05:10 +08:00
parent e07532a188
commit 66ca2693b3
17 changed files with 224 additions and 21 deletions
+2 -2
View File
@@ -54,14 +54,14 @@ func (s *Service) FindOrderConversation(ctx context.Context, userID uint64, orde
return s.repo.FindOrderConversation(ctx, userID, orderID)
}
func (s *Service) EnsureSupportConversation(ctx context.Context, userID uint64) (*ConversationDTO, error) {
func (s *Service) EnsureSupportConversation(ctx context.Context, userID uint64, scene string) (*ConversationDTO, error) {
if s.repo == nil {
return nil, ErrDependencyUnavailable
}
if userID == 0 {
return nil, ErrPermissionDenied
}
return s.repo.EnsureSupportConversation(ctx, userID)
return s.repo.EnsureSupportConversation(ctx, userID, scene)
}
func (s *Service) Messages(ctx context.Context, principal Principal, conversationID uint64, page, pageSize int) (*PaginatedResult, error) {