增加渠道上传预统计

This commit is contained in:
yml2213
2026-07-25 14:34:03 +08:00
parent 1ea01f7d46
commit 7ca68e6b8b
15 changed files with 689 additions and 63 deletions
+14 -4
View File
@@ -15,6 +15,7 @@ type ListingDTO struct {
OwnerID uint64 `json:"owner_id"`
OwnerPhone string `json:"owner_phone,omitempty"`
OwnerNickname string `json:"owner_nickname,omitempty"`
SourceChannel string `json:"source_channel,omitempty"`
Title string `json:"title"`
Description string `json:"description"`
GameName string `json:"game_name"`
@@ -149,10 +150,12 @@ type AdminActionRequest struct {
type AuditMeta = auditlog.Meta
type ExternalUploadRequest struct {
UploadTime int64 `json:"uploadTime"`
UploaderName string `json:"uploaderName"`
Uploaderame string `json:"uploaderame"`
Data json.RawMessage `json:"data"`
UploadTime int64 `json:"uploadTime"`
UploaderName string `json:"uploaderName"`
Uploaderame string `json:"uploaderame"`
SourceChannel string `json:"sourceChannel"`
SourceChannelSnake string `json:"source_channel"`
Data json.RawMessage `json:"data"`
}
func (r ExternalUploadRequest) normalizedUploaderName() string {
@@ -162,6 +165,13 @@ func (r ExternalUploadRequest) normalizedUploaderName() string {
return strings.TrimSpace(r.Uploaderame)
}
func (r ExternalUploadRequest) normalizedSourceChannel() string {
if channel := normalizeExternalSourceChannel(r.SourceChannel); channel != "" {
return channel
}
return normalizeExternalSourceChannel(r.SourceChannelSnake)
}
type ExternalAccountData struct {
LoginMethod string `json:"loginMethod"`
Rank string `json:"rank"`