mirror of
https://github.com/bufanyun/hotgo.git
synced 2025-08-26 08:36:14 +08:00
发布代码生成、更新20+表单组件,优化数据字典,gf版本更新到2.3.1
This commit is contained in:
@@ -17,3 +17,10 @@ type UploadImageReq struct {
|
||||
}
|
||||
|
||||
type UploadImageRes *sysin.AttachmentListModel
|
||||
|
||||
// UploadFileReq 上传文件
|
||||
type UploadFileReq struct {
|
||||
g.Meta `path:"/upload/file" tags:"上传" method:"post" summary:"上传附件"`
|
||||
}
|
||||
|
||||
type UploadFileRes *sysin.AttachmentListModel
|
||||
|
@@ -8,6 +8,7 @@ package config
|
||||
|
||||
import (
|
||||
"github.com/gogf/gf/v2/frame/g"
|
||||
"hotgo/internal/model/input/form"
|
||||
"hotgo/internal/model/input/sysin"
|
||||
)
|
||||
|
||||
@@ -28,3 +29,9 @@ type UpdateReq struct {
|
||||
}
|
||||
type UpdateRes struct {
|
||||
}
|
||||
|
||||
// TypeSelectReq 数据类型选项
|
||||
type TypeSelectReq struct {
|
||||
g.Meta `path:"/config/typeSelect" method:"get" tags:"配置" summary:"数据类型选项"`
|
||||
}
|
||||
type TypeSelectRes []form.Select
|
||||
|
85
server/api/backend/curddemo/curddemo.go
Normal file
85
server/api/backend/curddemo/curddemo.go
Normal file
@@ -0,0 +1,85 @@
|
||||
// Package curddemo
|
||||
// @Link https://github.com/bufanyun/hotgo
|
||||
// @Copyright Copyright (c) 2023 HotGo CLI
|
||||
// @Author Ms <133814250@qq.com>
|
||||
// @License https://github.com/bufanyun/hotgo/blob/master/LICENSE
|
||||
// @AutoGenerate Version 2.1.0
|
||||
// @AutoGenerate Date 2023-01-18 15:19:42
|
||||
//
|
||||
package curddemo
|
||||
|
||||
import (
|
||||
"hotgo/internal/model/input/form"
|
||||
"hotgo/internal/model/input/sysin"
|
||||
|
||||
"github.com/gogf/gf/v2/frame/g"
|
||||
)
|
||||
|
||||
// ListReq 查询生成演示列表
|
||||
type ListReq struct {
|
||||
g.Meta `path:"/curdDemo/list" method:"get" tags:"生成演示" summary:"获取生成演示列表"`
|
||||
sysin.CurdDemoListInp
|
||||
}
|
||||
|
||||
type ListRes struct {
|
||||
form.PageRes
|
||||
List []*sysin.CurdDemoListModel `json:"list" dc:"数据列表"`
|
||||
}
|
||||
|
||||
// ExportReq 导出生成演示列表
|
||||
type ExportReq struct {
|
||||
g.Meta `path:"/curdDemo/export" method:"get" tags:"生成演示" summary:"导出生成演示列表"`
|
||||
sysin.CurdDemoListInp
|
||||
}
|
||||
|
||||
type ExportRes struct{}
|
||||
|
||||
// ViewReq 获取生成演示指定信息
|
||||
type ViewReq struct {
|
||||
g.Meta `path:"/curdDemo/view" method:"get" tags:"生成演示" summary:"获取生成演示指定信息"`
|
||||
sysin.CurdDemoViewInp
|
||||
}
|
||||
|
||||
type ViewRes struct {
|
||||
*sysin.CurdDemoViewModel
|
||||
}
|
||||
|
||||
// EditReq 修改/新增生成演示
|
||||
type EditReq struct {
|
||||
g.Meta `path:"/curdDemo/edit" method:"post" tags:"生成演示" summary:"修改/新增生成演示"`
|
||||
sysin.CurdDemoEditInp
|
||||
}
|
||||
type EditRes struct{}
|
||||
|
||||
// DeleteReq 删除生成演示
|
||||
type DeleteReq struct {
|
||||
g.Meta `path:"/curdDemo/delete" method:"post" tags:"生成演示" summary:"删除生成演示"`
|
||||
sysin.CurdDemoDeleteInp
|
||||
}
|
||||
|
||||
type DeleteRes struct{}
|
||||
|
||||
// MaxSortReq 获取生成演示最大排序
|
||||
type MaxSortReq struct {
|
||||
g.Meta `path:"/curdDemo/maxSort" method:"get" tags:"生成演示" summary:"获取生成演示最大排序"`
|
||||
}
|
||||
|
||||
type MaxSortRes struct {
|
||||
*sysin.CurdDemoMaxSortModel
|
||||
}
|
||||
|
||||
// StatusReq 更新生成演示状态
|
||||
type StatusReq struct {
|
||||
g.Meta `path:"/curdDemo/status" method:"post" tags:"生成演示" summary:"更新生成演示状态"`
|
||||
sysin.CurdDemoStatusInp
|
||||
}
|
||||
|
||||
type StatusRes struct{}
|
||||
|
||||
// SwitchReq 更新生成演示开关状态
|
||||
type SwitchReq struct {
|
||||
g.Meta `path:"/curdDemo/switch" method:"post" tags:"生成演示" summary:"更新生成演示状态"`
|
||||
sysin.CurdDemoSwitchInp
|
||||
}
|
||||
|
||||
type SwitchRes struct{}
|
@@ -17,7 +17,7 @@ import (
|
||||
type DataEditReq struct {
|
||||
entity.SysDictData
|
||||
TypeID int64 `json:"typeID" dc:"字典类型ID"`
|
||||
g.Meta `path:"/dict_data/edit" method:"post" tags:"字典数据" summary:"修改/新增字典数据"`
|
||||
g.Meta `path:"/dictData/edit" method:"post" tags:"字典数据" summary:"修改/新增字典数据"`
|
||||
}
|
||||
|
||||
type DataEditRes struct{}
|
||||
@@ -25,7 +25,7 @@ type DataEditRes struct{}
|
||||
// DataDeleteReq 删除字典数据
|
||||
type DataDeleteReq struct {
|
||||
Id interface{} `json:"id" v:"required#字典数据ID不能为空" dc:"字典数据ID"`
|
||||
g.Meta `path:"/dict_data/delete" method:"post" tags:"字典数据" summary:"删除字典数据"`
|
||||
g.Meta `path:"/dictData/delete" method:"post" tags:"字典数据" summary:"删除字典数据"`
|
||||
}
|
||||
type DataDeleteRes struct{}
|
||||
|
||||
@@ -37,10 +37,22 @@ type DataListReq struct {
|
||||
TypeID int64 `json:"typeId" v:"required#字典类型ID不能为空" dc:"字典类型ID"` //
|
||||
Type string `json:"type"`
|
||||
Label string `json:"label"`
|
||||
g.Meta `path:"/dict_data/list" method:"get" tags:"字典数据" summary:"获取字典数据列表"`
|
||||
g.Meta `path:"/dictData/list" method:"get" tags:"字典数据" summary:"获取字典数据列表"`
|
||||
}
|
||||
|
||||
type DataListRes struct {
|
||||
List []*sysin.DictDataListModel `json:"list" dc:"数据列表"`
|
||||
form.PageRes
|
||||
}
|
||||
|
||||
type DataSelectReq struct {
|
||||
g.Meta `path:"/dictData/option/{Type}" method:"get" summary:"字典数据" tags:"获取指定字典选项"`
|
||||
Type string `in:"path" v:"required#字典类型不能为空" dc:"字典类型"`
|
||||
}
|
||||
type DataSelectRes sysin.DataSelectModel
|
||||
|
||||
type DataSelectsReq struct {
|
||||
g.Meta `path:"/dictData/options" method:"get" summary:"字典数据" tags:"获取多个字典选项"`
|
||||
Types []string `json:"types"`
|
||||
}
|
||||
type DataSelectsRes map[string]sysin.DataSelectModel
|
||||
|
@@ -14,7 +14,7 @@ import (
|
||||
|
||||
// TypeTreeReq 字典类型树
|
||||
type TypeTreeReq struct {
|
||||
g.Meta `path:"/dict_type/tree" tags:"字典类型" method:"get" summary:"字典类型树列表"`
|
||||
g.Meta `path:"/dictType/tree" tags:"字典类型" method:"get" summary:"字典类型树列表"`
|
||||
}
|
||||
type TypeTreeRes struct {
|
||||
List []map[string]interface{} `json:"list" dc:"数据列表"`
|
||||
@@ -23,7 +23,7 @@ type TypeTreeRes struct {
|
||||
// TypeEditReq 修改/新增字典数据
|
||||
type TypeEditReq struct {
|
||||
entity.AdminDept
|
||||
g.Meta `path:"/dict_type/edit" method:"post" tags:"字典类型" summary:"修改/新增字典类型"`
|
||||
g.Meta `path:"/dictType/edit" method:"post" tags:"字典类型" summary:"修改/新增字典类型"`
|
||||
}
|
||||
|
||||
type TypeEditRes struct{}
|
||||
@@ -31,13 +31,13 @@ type TypeEditRes struct{}
|
||||
// TypeDeleteReq 删除字典类型
|
||||
type TypeDeleteReq struct {
|
||||
Id interface{} `json:"id" v:"required#字典类型ID不能为空" dc:"字典类型ID"`
|
||||
g.Meta `path:"/dict_type/delete" method:"post" tags:"字典类型" summary:"删除字典类型"`
|
||||
g.Meta `path:"/dictType/delete" method:"post" tags:"字典类型" summary:"删除字典类型"`
|
||||
}
|
||||
type TypeDeleteRes struct{}
|
||||
|
||||
// TypeSelectReq 修改/新增字典数据
|
||||
type TypeSelectReq struct {
|
||||
g.Meta `path:"/dict_type/select" method:"get" tags:"字典类型" summary:"字典类型选项"`
|
||||
g.Meta `path:"/dictType/select" method:"get" tags:"字典类型" summary:"字典类型选项"`
|
||||
}
|
||||
|
||||
type TypeSelectRes sysin.DictTypeSelectModel
|
||||
|
108
server/api/backend/gencodes/gencodes.go
Normal file
108
server/api/backend/gencodes/gencodes.go
Normal file
@@ -0,0 +1,108 @@
|
||||
// Package hggen
|
||||
// @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 gencodes
|
||||
|
||||
import (
|
||||
"github.com/gogf/gf/v2/frame/g"
|
||||
"hotgo/internal/model/entity"
|
||||
"hotgo/internal/model/input/form"
|
||||
"hotgo/internal/model/input/sysin"
|
||||
)
|
||||
|
||||
// ListReq 查询列表
|
||||
type ListReq struct {
|
||||
g.Meta `path:"/genCodes/list" method:"get" tags:"生成代码" summary:"获取生成代码列表"`
|
||||
sysin.GenCodesListInp
|
||||
}
|
||||
|
||||
type ListRes struct {
|
||||
List []*sysin.GenCodesListModel `json:"list" dc:"数据列表"`
|
||||
form.PageRes
|
||||
}
|
||||
|
||||
// ViewReq 获取指定信息
|
||||
type ViewReq struct {
|
||||
Id int64 `json:"id" v:"required#生成代码ID不能为空" dc:"生成代码ID"`
|
||||
g.Meta `path:"/genCodes/view" method:"get" tags:"生成代码" summary:"获取指定信息"`
|
||||
}
|
||||
type ViewRes struct {
|
||||
*sysin.GenCodesViewModel
|
||||
}
|
||||
|
||||
// EditReq 修改/新增数据
|
||||
type EditReq struct {
|
||||
entity.SysGenCodes
|
||||
g.Meta `path:"/genCodes/edit" method:"post" tags:"生成代码" summary:"修改/新增生成代码"`
|
||||
}
|
||||
type EditRes struct {
|
||||
*sysin.GenCodesEditModel
|
||||
}
|
||||
|
||||
// DeleteReq 删除
|
||||
type DeleteReq struct {
|
||||
Id interface{} `json:"id" v:"required#生成代码ID不能为空" dc:"生成代码ID"`
|
||||
g.Meta `path:"/genCodes/delete" method:"post" tags:"生成代码" summary:"删除生成代码"`
|
||||
}
|
||||
type DeleteRes struct{}
|
||||
|
||||
// MaxSortReq 最大排序
|
||||
type MaxSortReq struct {
|
||||
Id int64 `json:"id" dc:"生成代码ID"`
|
||||
g.Meta `path:"/genCodes/max_sort" method:"get" tags:"生成代码" summary:"生成代码最大排序"`
|
||||
}
|
||||
type MaxSortRes struct {
|
||||
Sort int `json:"sort" dc:"排序"`
|
||||
}
|
||||
|
||||
// StatusReq 更新状态
|
||||
type StatusReq struct {
|
||||
entity.SysGenCodes
|
||||
g.Meta `path:"/genCodes/status" method:"post" tags:"生成代码" summary:"更新生成代码状态"`
|
||||
}
|
||||
type StatusRes struct{}
|
||||
|
||||
type SelectsReq struct {
|
||||
g.Meta `path:"/genCodes/selects" method:"get" tags:"生成代码" summary:"生成入口选项"`
|
||||
}
|
||||
type SelectsRes struct {
|
||||
*sysin.GenCodesSelectsModel
|
||||
}
|
||||
|
||||
type TableSelectReq struct {
|
||||
g.Meta `path:"/genCodes/tableSelect" method:"get" tags:"生成代码" summary:"数据库表选项"`
|
||||
sysin.GenCodesTableSelectInp
|
||||
}
|
||||
type TableSelectRes []*sysin.GenCodesTableSelectModel
|
||||
|
||||
type ColumnSelectReq struct {
|
||||
g.Meta `path:"/genCodes/columnSelect" method:"get" tags:"生成代码" summary:"表字段选项"`
|
||||
sysin.GenCodesColumnSelectInp
|
||||
}
|
||||
type ColumnSelectRes []*sysin.GenCodesColumnSelectModel
|
||||
|
||||
type ColumnListReq struct {
|
||||
g.Meta `path:"/genCodes/columnList" method:"get" tags:"生成代码" summary:"表字段列表"`
|
||||
sysin.GenCodesColumnListInp
|
||||
}
|
||||
type ColumnListRes []*sysin.GenCodesColumnListModel
|
||||
|
||||
// PreviewReq 生成预览
|
||||
type PreviewReq struct {
|
||||
g.Meta `path:"/genCodes/preview" method:"post" tags:"生成代码" summary:"生成预览"`
|
||||
sysin.GenCodesPreviewInp
|
||||
}
|
||||
type PreviewRes struct {
|
||||
*sysin.GenCodesPreviewModel
|
||||
}
|
||||
|
||||
// BuildReq 提交生成
|
||||
type BuildReq struct {
|
||||
g.Meta `path:"/genCodes/build" method:"post" tags:"生成代码" summary:"提交生成"`
|
||||
sysin.GenCodesPreviewInp
|
||||
}
|
||||
type BuildRes struct {
|
||||
}
|
@@ -16,16 +16,16 @@ import (
|
||||
|
||||
// UpdateProfileReq 更新会员资料
|
||||
type UpdateProfileReq struct {
|
||||
g.Meta `path:"/member/update_profile" method:"post" tags:"会员" summary:"更新会员资料"`
|
||||
g.Meta `path:"/member/updateProfile" method:"post" tags:"会员" summary:"更新会员资料"`
|
||||
Mobile int `json:"mobile" dc:"手机号"`
|
||||
Email string `json:"email" dc:"邮箱"`
|
||||
RealName string `json:"realname" dc:"真实姓名"`
|
||||
RealName string `json:"realName" dc:"真实姓名"`
|
||||
}
|
||||
type UpdateProfileRes struct{}
|
||||
|
||||
// UpdatePwdReq 修改登录密码
|
||||
type UpdatePwdReq struct {
|
||||
g.Meta `path:"/member/update_pwd" method:"post" tags:"会员" summary:"重置密码"`
|
||||
g.Meta `path:"/member/updatePwd" method:"post" tags:"会员" summary:"重置密码"`
|
||||
OldPassword string `json:"oldPassword" v:"required#原密码不能为空" dc:"原密码"`
|
||||
NewPassword string `json:"newPassword" v:"required|length:6,16#新密码不能为空#新密码需在6~16之间" dc:"新密码"`
|
||||
}
|
||||
@@ -47,7 +47,7 @@ type ProfileRes struct {
|
||||
|
||||
// ResetPwdReq 重置密码
|
||||
type ResetPwdReq struct {
|
||||
g.Meta `path:"/member/reset_pwd" method:"post" tags:"会员" summary:"重置密码"`
|
||||
g.Meta `path:"/member/resetPwd" method:"post" tags:"会员" summary:"重置密码"`
|
||||
Password string `json:"password" v:"required#密码不能为空" dc:"密码"`
|
||||
Id int64 `json:"id" dc:"会员ID"`
|
||||
}
|
||||
@@ -55,7 +55,7 @@ type ResetPwdRes struct{}
|
||||
|
||||
// EmailUniqueReq 邮箱是否唯一
|
||||
type EmailUniqueReq struct {
|
||||
g.Meta `path:"/member/email_unique" method:"get" tags:"会员" summary:"邮箱是否唯一"`
|
||||
g.Meta `path:"/member/emailUnique" method:"get" tags:"会员" summary:"邮箱是否唯一"`
|
||||
Email string `json:"email" v:"required#邮箱不能为空" dc:"邮箱"`
|
||||
Id int64 `json:"id" dc:"会员ID"`
|
||||
}
|
||||
@@ -65,7 +65,7 @@ type EmailUniqueRes struct {
|
||||
|
||||
// MobileUniqueReq 手机号是否唯一
|
||||
type MobileUniqueReq struct {
|
||||
g.Meta `path:"/member/mobile_unique" method:"get" tags:"会员" summary:"手机号是否唯一"`
|
||||
g.Meta `path:"/member/mobileUnique" method:"get" tags:"会员" summary:"手机号是否唯一"`
|
||||
Mobile string `json:"mobile" v:"required#手机号不能为空" dc:"手机号"`
|
||||
Id int64 `json:"id" dc:"会员ID"`
|
||||
}
|
||||
@@ -75,7 +75,7 @@ type MobileUniqueRes struct {
|
||||
|
||||
// NameUniqueReq 名称是否唯一
|
||||
type NameUniqueReq struct {
|
||||
g.Meta `path:"/member/name_unique" method:"get" tags:"会员" summary:"会员名称是否唯一"`
|
||||
g.Meta `path:"/member/nameUnique" method:"get" tags:"会员" summary:"会员名称是否唯一"`
|
||||
Username string `json:"username" v:"required#会员名称不能为空" dc:"会员名称"`
|
||||
Id int64 `json:"id" dc:"会员ID"`
|
||||
}
|
||||
@@ -89,13 +89,13 @@ type ListReq struct {
|
||||
form.PageReq
|
||||
form.RangeDateReq
|
||||
form.StatusReq
|
||||
DeptId int `json:"dept_id" dc:"部门ID"`
|
||||
DeptId int `json:"deptId" dc:"部门ID"`
|
||||
Mobile int `json:"mobile" dc:"手机号"`
|
||||
Username string `json:"username" dc:"用户名"`
|
||||
Realname string `json:"realname" dc:"真实姓名"`
|
||||
Realname string `json:"realName" dc:"真实姓名"`
|
||||
Name string `json:"name" dc:"岗位名称"`
|
||||
Code string `json:"code" dc:"岗位编码"`
|
||||
CreatedAt []int64 `json:"created_at" dc:"创建时间"`
|
||||
CreatedAt []int64 `json:"createdAt" dc:"创建时间"`
|
||||
}
|
||||
|
||||
type ListRes struct {
|
||||
@@ -114,7 +114,7 @@ type ViewRes struct {
|
||||
PostIds []int64 `json:"postIds" dc:"当前岗位"`
|
||||
Roles []*adminin.RoleListModel `json:"roles" dc:"可选角色"`
|
||||
RoleIds []int64 `json:"roleIds" dc:"当前角色"`
|
||||
DeptName string `json:"dept_name" dc:"部门名称"`
|
||||
DeptName string `json:"deptName" dc:"部门名称"`
|
||||
}
|
||||
|
||||
// EditReq 修改/新增
|
||||
@@ -147,13 +147,6 @@ type InfoReq struct {
|
||||
|
||||
type InfoRes struct {
|
||||
adminin.MemberLoginModel
|
||||
//DefaultPortalConfig []*PortalConfig `json:"defaultPortalConfig" dc:"默认用户配置"`
|
||||
//LincenseInfo string `json:"lincenseInfo" dc:"应用版本号"`
|
||||
//Permissions []string `json:"permissions" dc:"权限"`
|
||||
//Roles []string `json:"roles" dc:"角色"`
|
||||
//SysNoticeList []*entity.AdminNotice `json:"sysNoticeList" dc:"系统公告"`
|
||||
//UserPortalConfig []*PortalConfig `json:"userPortalConfig" dc:"用户配置"`
|
||||
//User model.Identity `json:"member" dc:"用户信息"`
|
||||
}
|
||||
|
||||
type PortalConfigContentOptions struct {
|
||||
|
@@ -20,7 +20,7 @@ type MemberListReq struct {
|
||||
form.RangeDateReq
|
||||
form.StatusReq
|
||||
Role int `json:"role" description:"角色ID"`
|
||||
DeptId int `json:"dept_id" description:"部门ID"`
|
||||
DeptId int `json:"deptId" description:"部门ID"`
|
||||
Mobile int `json:"mobile" description:"手机号"`
|
||||
Username string `json:"username" description:"用户名"`
|
||||
Realname string `json:"realname" description:"真实姓名"`
|
||||
@@ -41,7 +41,7 @@ type ListReq struct {
|
||||
form.PageReq
|
||||
form.RangeDateReq
|
||||
form.StatusReq
|
||||
DeptId int `json:"dept_id" description:"部门ID"`
|
||||
DeptId int `json:"deptId" description:"部门ID"`
|
||||
Mobile int `json:"mobile" description:"手机号"`
|
||||
Username string `json:"username" description:"用户名"`
|
||||
Realname string `json:"realname" description:"真实姓名"`
|
||||
@@ -129,3 +129,18 @@ type DeleteReq struct {
|
||||
Id int64 `json:"id" v:"required"`
|
||||
}
|
||||
type DeleteRes struct{}
|
||||
|
||||
// DataScopeSelectReq 获取数据权限选项
|
||||
type DataScopeSelectReq struct {
|
||||
g.Meta `path:"/role/dataScope/select" method:"get" summary:"角色" tags:"获取数据权限选项"`
|
||||
}
|
||||
type DataScopeSelectRes struct {
|
||||
List form.Selects `json:"list" dc:"数据选项"`
|
||||
}
|
||||
|
||||
// DataScopeEditReq 修改指定角色的数据权限
|
||||
type DataScopeEditReq struct {
|
||||
g.Meta `path:"/role/dataScope/edit" method:"post" tags:"角色" summary:"修改指定角色的数据权限"`
|
||||
adminin.DataScopeEditInp
|
||||
}
|
||||
type DataScopeEditRes struct{}
|
||||
|
77
server/api/backend/test/test.go
Normal file
77
server/api/backend/test/test.go
Normal file
@@ -0,0 +1,77 @@
|
||||
// Package test
|
||||
// @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 test
|
||||
|
||||
import (
|
||||
"github.com/gogf/gf/v2/frame/g"
|
||||
"hotgo/internal/model/input/adminin"
|
||||
"hotgo/internal/model/input/form"
|
||||
)
|
||||
|
||||
// ListReq 查询列表
|
||||
type ListReq struct {
|
||||
g.Meta `path:"/test/list" method:"get" tags:"测试" summary:"获取测试列表"`
|
||||
adminin.TestListInp
|
||||
}
|
||||
|
||||
type ListRes struct {
|
||||
form.PageRes
|
||||
List []*adminin.TestListModel `json:"list" dc:"数据列表"`
|
||||
}
|
||||
|
||||
// ExportReq 导出列表
|
||||
type ExportReq struct {
|
||||
g.Meta `path:"/test/export" method:"get" tags:"测试" summary:"导出测试列表"`
|
||||
adminin.TestListInp
|
||||
}
|
||||
|
||||
type ExportRes struct{}
|
||||
|
||||
// ViewReq 获取信息
|
||||
type ViewReq struct {
|
||||
g.Meta `path:"/test/view" method:"get" tags:"测试" summary:"获取指定信息"`
|
||||
adminin.TestViewInp
|
||||
}
|
||||
type ViewRes struct {
|
||||
*adminin.TestViewModel
|
||||
}
|
||||
|
||||
// EditReq 修改/新增
|
||||
type EditReq struct {
|
||||
g.Meta `path:"/test/edit" method:"post" tags:"测试" summary:"修改/新增测试"`
|
||||
adminin.TestEditInp
|
||||
}
|
||||
type EditRes struct{}
|
||||
|
||||
// DeleteReq 删除
|
||||
type DeleteReq struct {
|
||||
g.Meta `path:"/test/delete" method:"post" tags:"测试" summary:"删除测试"`
|
||||
adminin.TestDeleteInp
|
||||
}
|
||||
type DeleteRes struct{}
|
||||
|
||||
// MaxSortReq 最大排序
|
||||
type MaxSortReq struct {
|
||||
g.Meta `path:"/test/maxSort" method:"get" tags:"测试" summary:"测试最大排序"`
|
||||
}
|
||||
type MaxSortRes struct {
|
||||
*adminin.TestMaxSortModel
|
||||
}
|
||||
|
||||
// StatusReq 更新状态
|
||||
type StatusReq struct {
|
||||
g.Meta `path:"/test/status" method:"post" tags:"测试" summary:"更新测试状态"`
|
||||
adminin.TestStatusInp
|
||||
}
|
||||
type StatusRes struct{}
|
||||
|
||||
// SwitchReq 更新开关状态
|
||||
type SwitchReq struct {
|
||||
g.Meta `path:"/test/switch" method:"post" tags:"测试" summary:"更新测试状态"`
|
||||
adminin.TestSwitchInp
|
||||
}
|
||||
type SwitchRes struct{}
|
Reference in New Issue
Block a user