feat: add swagger

This commit is contained in:
landaiqing
2024-07-31 18:05:47 +08:00
parent ff0fddd5c3
commit c187b102ed
9 changed files with 214 additions and 26 deletions

View File

@@ -1,6 +1,7 @@
package models
import (
"go-chat/utils"
"gorm.io/gorm"
"time"
)
@@ -24,3 +25,9 @@ type UserBasic struct {
func (table *UserBasic) TableName() string {
return "user_basic"
}
func GetUserList() []*UserBasic {
data := make([]*UserBasic, 10)
utils.InitMySQL().Find(&data)
return data
}