获取用户信息

This commit is contained in:
2023-11-20 23:56:49 +08:00
parent 9186827b51
commit c8a8da2e25
2 changed files with 65 additions and 59 deletions

View File

@@ -2,23 +2,21 @@ package api
import (
"time"
"git.satori.love/gameui/webp/models"
)
type Image struct {
Id int `json:"id" db:"id"`
Width int `json:"width" db:"width"`
Height int `json:"height" db:"height"`
Content string `json:"content" db:"content"`
ArticleCategoryTopId int `json:"article_category_top_id" db:"article_category_top_id"`
PraiseCount int `json:"praise_count" db:"praise_count"`
CollectCount int `json:"collect_count" db:"collect_count"`
UserID int `json:"user_id" db:"user_id"`
User models.User `json:"user" db:"user"`
Article models.Article `json:"article" db:"article"`
CreateTime time.Time `json:"createTime" db:"createTime"`
UpdateTime time.Time `json:"updateTime" db:"updateTime"`
Id int `json:"id" db:"id"`
Width int `json:"width" db:"width"`
Height int `json:"height" db:"height"`
Content string `json:"content" db:"content"`
ArticleCategoryTopId int `json:"article_category_top_id" db:"article_category_top_id"`
PraiseCount int `json:"praise_count" db:"praise_count"`
CollectCount int `json:"collect_count" db:"collect_count"`
UserID int `json:"user_id" db:"user_id"`
User User `json:"user" db:"user"`
Article Article `json:"article" db:"article"`
CreateTime time.Time `json:"create_time" db:"create_time"`
UpdateTime time.Time `json:"update_time" db:"update_time"`
}
type User struct {
@@ -29,3 +27,11 @@ type User struct {
CreateTime time.Time `json:"create_time" db:"create_time"`
UpdateTime time.Time `json:"update_time" db:"update_time"`
}
type Article struct {
Id int `json:"id" db:"id"`
Title string `json:"title" db:"title"`
Tags string `json:"tags" db:"tags"`
CreateTime time.Time `json:"create_time" db:"create_time"`
UpdateTime time.Time `json:"update_time" db:"update_time"`
}