mirror of
https://github.com/bufanyun/hotgo.git
synced 2025-11-16 14:13:46 +08:00
gf2版本同步升级到v2.0.4,修复验证器兼容问题
This commit is contained in:
@@ -1,3 +1,9 @@
|
||||
//
|
||||
// @Link https://github.com/bufanyun/hotgo
|
||||
// @Copyright Copyright (c) 2022 HotGo CLI
|
||||
// @Author Ms <133814250@qq.com>
|
||||
// @License https://github.com/bufanyun/hotgo/blob/master/LICENSE
|
||||
//
|
||||
package adminForm
|
||||
|
||||
import (
|
||||
@@ -9,32 +15,32 @@ import (
|
||||
|
||||
// 名称是否唯一
|
||||
type NoticeNameUniqueReq struct {
|
||||
Title string `json:"name" v:"required#公告名称不能为空" description:"公告名称"`
|
||||
Id int64 `json:"id" description:"公告ID"`
|
||||
g.Meta `path:"/notice/name_unique" method:"get" tags:"公告" summary:"公告名称是否唯一"`
|
||||
Title string `json:"name" v:"required#公告名称不能为空" dc:"公告名称"`
|
||||
Id int64 `json:"id" dc:"公告ID"`
|
||||
}
|
||||
type NoticeNameUniqueRes struct {
|
||||
IsUnique bool `json:"is_unique" description:"是否唯一"`
|
||||
IsUnique bool `json:"is_unique" dc:"是否唯一"`
|
||||
}
|
||||
|
||||
// 查询列表
|
||||
type NoticeListReq struct {
|
||||
g.Meta `path:"/notice/list" method:"get" tags:"公告" summary:"获取公告列表"`
|
||||
form.PageReq
|
||||
form.RangeDateReq
|
||||
form.StatusReq
|
||||
Name string `json:"name" description:"公告名称"`
|
||||
g.Meta `path:"/notice/list" method:"get" tags:"公告" summary:"获取公告列表"`
|
||||
Name string `json:"name" dc:"公告名称"`
|
||||
}
|
||||
|
||||
type NoticeListRes struct {
|
||||
List []*input.AdminNoticeListModel `json:"list" description:"数据列表"`
|
||||
List []*input.AdminNoticeListModel `json:"list" dc:"数据列表"`
|
||||
form.PageRes
|
||||
}
|
||||
|
||||
// 获取指定信息
|
||||
type NoticeViewReq struct {
|
||||
Id string `json:"id" v:"required#公告ID不能为空" description:"公告ID"`
|
||||
g.Meta `path:"/notice/view" method:"get" tags:"公告" summary:"获取指定信息"`
|
||||
Id string `json:"id" v:"required#公告ID不能为空" dc:"公告ID"`
|
||||
}
|
||||
type NoticeViewRes struct {
|
||||
*input.AdminNoticeViewModel
|
||||
@@ -42,23 +48,23 @@ type NoticeViewRes struct {
|
||||
|
||||
// 修改/新增
|
||||
type NoticeEditReq struct {
|
||||
entity.AdminNotice
|
||||
g.Meta `path:"/notice/edit" method:"post" tags:"公告" summary:"修改/新增公告"`
|
||||
entity.AdminNotice
|
||||
}
|
||||
type NoticeEditRes struct{}
|
||||
|
||||
// 删除
|
||||
type NoticeDeleteReq struct {
|
||||
Id interface{} `json:"id" v:"required#公告ID不能为空" description:"公告ID"`
|
||||
g.Meta `path:"/notice/delete" method:"post" tags:"公告" summary:"删除公告"`
|
||||
Id interface{} `json:"id" v:"required#公告ID不能为空" dc:"公告ID"`
|
||||
}
|
||||
type NoticeDeleteRes struct{}
|
||||
|
||||
// 最大排序
|
||||
type NoticeMaxSortReq struct {
|
||||
Id int64 `json:"id" description:"公告ID"`
|
||||
g.Meta `path:"/notice/max_sort" method:"get" tags:"公告" summary:"公告最大排序"`
|
||||
Id int64 `json:"id" dc:"公告ID"`
|
||||
}
|
||||
type NoticeMaxSortRes struct {
|
||||
Sort int `json:"sort" description:"排序"`
|
||||
Sort int `json:"sort" dc:"排序"`
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user