init: radio init commit

This commit is contained in:
Blizzard
2026-02-28 15:56:26 +08:00
parent fc585fa4df
commit d79beb4663
63 changed files with 2540 additions and 6399 deletions
+32
View File
@@ -0,0 +1,32 @@
package request
import common "sundynix-go/model/commom/request"
// GetCategoryList 获取分类列表请求
type GetCategoryList struct {
common.PageInfo
Name string `json:"name" form:"name"` // 分类名称
Status int `json:"status" form:"status"` // 状态
}
// SaveCategory 保存分类请求
type SaveCategory struct {
Id string `json:"id" form:"id"` // 分类ID(更新时使用)
Name string `json:"name" binding:"required"` // 分类名称
Description string `json:"description"` // 分类描述
IconId string `json:"iconId"` // 图标URL
CoverId string `json:"coverId"` // 封面图URL
Sort int `json:"sort"` // 排序
Status int `json:"status"` // 状态
}
// UpdateCategory 更新分类请求
type UpdateCategory struct {
Id string `json:"id" binding:"required"` // 分类ID
Name string `json:"name"` // 分类名称
Description string `json:"description"` // 分类描述
IconId string `json:"iconId"` // 图标URL
CoverId string `json:"coverId"` // 封面图URL
Sort int `json:"sort"` // 排序
Status int `json:"status"` // 状态
}
+37
View File
@@ -0,0 +1,37 @@
package request
import common "sundynix-go/model/commom/request"
// GetChannelList 获取频道列表请求
type GetChannelList struct {
common.PageInfo
CategoryId string `json:"categoryId" form:"categoryId"` // 分类ID
Name string `json:"name" form:"name"` // 频道名称
Status int `json:"status" form:"status"` // 状态
}
// SaveChannel 保存频道请求
type SaveChannel struct {
Id string `json:"id" form:"id"` // 频道ID(更新时使用)
CategoryId string `json:"categoryId" binding:"required"` // 分类ID
Name string `json:"name" binding:"required"` // 频道名称
Description string `json:"description"` // 频道描述
CoverId string `json:"coverId"` // 封面图URL
Tags string `json:"tags"` // 标签
IsVipOnly int `json:"isVipOnly"` // 是否VIP专享
Sort int `json:"sort"` // 排序
Status int `json:"status"` // 状态
}
// UpdateChannel 更新频道请求
type UpdateChannel struct {
Id string `json:"id" binding:"required"` // 频道ID
CategoryId string `json:"categoryId"` // 分类ID
Name string `json:"name"` // 频道名称
Description string `json:"description"` // 频道描述
CoverId string `json:"coverId"` // 封面图URL
Tags string `json:"tags"` // 标签
IsVipOnly int `json:"isVipOnly"` // 是否VIP专享
Sort int `json:"sort"` // 排序
Status int `json:"status"` // 状态
}
+68
View File
@@ -0,0 +1,68 @@
package request
import common "sundynix-go/model/commom/request"
// SubscribeChannel 订阅频道请求
type SubscribeChannel struct {
ChannelId string `json:"channelId" binding:"required"` // 频道ID
}
// UnsubscribeChannel 退订频道请求
type UnsubscribeChannel struct {
ChannelId string `json:"channelId" binding:"required"` // 频道ID
}
// AddHistory 添加收听历史请求
type AddHistory struct {
ProgramId string `json:"programId" binding:"required"` // 节目ID
Progress int `json:"progress"` // 播放进度(秒)
Duration int `json:"duration"` // 节目总时长(秒)
}
// ToggleLike 切换点赞请求
type ToggleLike struct {
ProgramId string `json:"programId" binding:"required"` // 节目ID
}
// AddFavorite 添加收藏请求
type AddFavorite struct {
ProgramId string `json:"programId" binding:"required"` // 节目ID
}
// RemoveFavorite 移除收藏请求
type RemoveFavorite struct {
ProgramId string `json:"programId" binding:"required"` // 节目ID
}
// AddComment 添加评论请求
type AddComment struct {
ProgramId string `json:"programId" binding:"required"` // 节目ID
ParentId string `json:"parentId"` // 父评论ID
Content string `json:"content" binding:"required"` // 评论内容
}
// DeleteComment 删除评论请求
type DeleteComment struct {
CommentId string `json:"commentId" binding:"required"` // 评论ID
}
// GetHistoryList 获取收听历史列表请求
type GetHistoryList struct {
common.PageInfo
}
// GetFavoriteList 获取收藏列表请求
type GetFavoriteList struct {
common.PageInfo
}
// GetCommentList 获取评论列表请求
type GetCommentList struct {
common.PageInfo
ProgramId string `json:"programId" form:"programId"` // 节目ID
}
// GetSubscriptionList 获取订阅列表请求
type GetSubscriptionList struct {
common.PageInfo
}
+39
View File
@@ -0,0 +1,39 @@
package request
import common "sundynix-go/model/commom/request"
// GetProgramList 获取节目列表请求
type GetProgramList struct {
common.PageInfo
ChannelId string `json:"channelId" form:"channelId"` // 频道ID
Title string `json:"title" form:"title"` // 节目标题
Status int `json:"status" form:"status"` // 状态
}
// SaveProgram 保存节目请求
type SaveProgram struct {
Id string `json:"id" form:"id"` // 节目ID(更新时使用)
ChannelId string `json:"channelId" binding:"required"` // 频道ID
Title string `json:"title" binding:"required"` // 节目标题
Description string `json:"description"` // 节目描述
Content string `json:"content"`
CoverId string `json:"coverId"` // 封面图URL
AudioId string `json:"audioId"` // 音频URL
Duration int `json:"duration"` // 时长(秒)
Tags string `json:"tags"` // 标签
Status int `json:"status"` // 状态
}
// UpdateProgram 更新节目请求
type UpdateProgram struct {
Id string `json:"id" binding:"required"` // 节目ID
ChannelId string `json:"channelId"` // 频道ID
Title string `json:"title"` // 节目标题
Description string `json:"description"` // 节目描述
Content string `json:"content"`
CoverId string `json:"coverId"` // 封面图URL
AudioId string `json:"audioId"` // 音频URL
Duration int `json:"duration"` // 时长(秒)
Tags string `json:"tags"` // 标签
Status int `json:"status"` // 状态
}