init: web_hgdjc_server
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
package srv_announcement
|
||||
|
||||
import (
|
||||
"videoweb/pub/models/announcementmod"
|
||||
"videoweb/pub/pubdef"
|
||||
)
|
||||
|
||||
type GetAnnouncementListReq struct {
|
||||
Title *string `json:"title"` // 标题,模糊搜索
|
||||
Status *bool `json:"status"` // 是否启用
|
||||
pubdef.Page
|
||||
}
|
||||
|
||||
type GetAnnouncementListResp struct {
|
||||
Total int64 `json:"total"`
|
||||
List announcementmod.AnnouncementList `json:"list"`
|
||||
}
|
||||
|
||||
type AddAnnouncementReq struct {
|
||||
Title string `json:"title" binding:"required"` // 标题
|
||||
Content string `json:"content"` // 内容
|
||||
Sort int64 `json:"sort"` // 排序,越大越靠前
|
||||
Status *bool `json:"status"` // 是否启用
|
||||
}
|
||||
|
||||
type UpdateAnnouncementReq struct {
|
||||
Id int64 `json:"id" binding:"required"`
|
||||
Param UpdateAnnouncementParam `json:"param"`
|
||||
}
|
||||
|
||||
type UpdateAnnouncementParam struct {
|
||||
Title *string `json:"title"`
|
||||
Content *string `json:"content"`
|
||||
Sort *int64 `json:"sort"`
|
||||
Status *bool `json:"status"`
|
||||
}
|
||||
|
||||
type DelAnnouncementReq struct {
|
||||
Id int64 `json:"id" binding:"required"`
|
||||
}
|
||||
Reference in New Issue
Block a user