feat: change and add models

This commit is contained in:
zchengo
2023-01-25 16:13:07 +08:00
parent def12ca66e
commit 42d264f8ad
2 changed files with 14 additions and 1 deletions
+1 -1
View File
@@ -9,7 +9,7 @@ type Notice struct {
Updated int64 `gorm:"updated"`
}
type NoticeParam struct {
type NoticeCreateParam struct {
Content string `json:"content"`
Creator int64 `gorm:"creator"`
}
+13
View File
@@ -9,6 +9,19 @@ type Subscribe struct {
Updated int64 `gorm:"updated"`
}
type SubscribeCreateParam struct {
Uid int64 `json:"uid"`
Version int `json:"version"`
Expired int64 `json:"expired"`
}
type SubscribeUpdateParam struct {
Id int64 `json:"id"`
Uid int64 `json:"uid"`
Version int `json:"version"`
Expired int64 `json:"expired"`
}
type SubscribePayParam struct {
Uid int64 `json:"uid" binding:"-"`
Version int `json:"version" binding:"required,oneof=2 3"`