4ec529e860
- Implemented user token secret generation and retrieval in channel service. - Added ResetUserTokenSecret method to reset the user token secret for channels. - Updated channel configuration parsing to include user token secret. - Enhanced WebSocket service to utilize user token secret for external info retrieval. - Modified dashboard channel edit component to support user token secret display and reset functionality. - Introduced API endpoint for resetting user token secret. - Updated IM and SDK configurations to include user token. - Added tests for user token verification logic.
34 lines
826 B
Go
34 lines
826 B
Go
package dto
|
|
|
|
import "cs-agent/internal/pkg/enums"
|
|
|
|
type AuthPrincipal struct {
|
|
UserID int64
|
|
Username string
|
|
Nickname string
|
|
Avatar string
|
|
Status enums.Status
|
|
Roles []string
|
|
Permissions []string
|
|
}
|
|
|
|
type WxWorkKFChannelConfig struct {
|
|
OpenKfID string `json:"openKfId"`
|
|
}
|
|
|
|
type WebChannelConfig struct {
|
|
Title string `json:"title"`
|
|
Subtitle string `json:"subtitle"`
|
|
ThemeColor string `json:"themeColor"`
|
|
Position string `json:"position"`
|
|
Width string `json:"width"`
|
|
UserTokenSecret string `json:"userTokenSecret,omitempty"`
|
|
}
|
|
|
|
type WechatMPChannelConfig struct {
|
|
Title string `json:"title"`
|
|
Subtitle string `json:"subtitle"`
|
|
ThemeColor string `json:"themeColor"`
|
|
UserTokenSecret string `json:"userTokenSecret,omitempty"`
|
|
}
|