Files
lone-services/services/user/internal/dao/user.go
T
zzw f8c7419964
CI / changes (push) Successful in 37s
CI / ad (push) Successful in 0s
CI / admin (push) Successful in 0s
CI / bff (push) Successful in 1s
CI / chore (push) Successful in 0s
CI / equipment (push) Successful in 0s
CI / express (push) Successful in 1s
CI / product (push) Successful in 0s
CI / record (push) Successful in 0s
CI / sale (push) Successful in 21s
CI / task (push) Successful in 0s
CI / user (push) Successful in 18s
CI / wecom (push) Successful in 0s
feat: backuser list
2026-09-04 15:56:12 +08:00

46 lines
1.8 KiB
Go
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
package dao
import "lone-services/pkg/utils"
// UserRow 主用户(表 users
type UserRow struct {
Id int64 `gorm:"column:id;primaryKey;autoIncrement" json:"id"`
Mobile string `gorm:"column:mobile" json:"mobile"`
Name string `gorm:"column:name" json:"name"`
Avatar string `gorm:"column:avatar" json:"avatar"`
Gender uint8 `gorm:"column:gender" json:"gender"`
Birthday utils.CustomTime `gorm:"column:birthday;type:date" json:"birthday"`
Status uint8 `gorm:"column:status" json:"status"`
CreatedAt utils.CustomTime `gorm:"column:created_at" json:"created_at"`
UpdatedAt utils.CustomTime `gorm:"column:updated_at" json:"updated_at"`
}
// UserCreate 新建用户
type UserCreate struct {
Id int64 `gorm:"column:id;primaryKey;autoIncrement" json:"id"`
Mobile string `gorm:"column:mobile" json:"mobile"`
Name string `gorm:"column:name" json:"name"`
Avatar string `gorm:"column:avatar" json:"avatar"`
Gender uint8 `gorm:"column:gender" json:"gender"`
Birthday utils.CustomTime `gorm:"column:birthday;type:date" json:"birthday"`
Status uint8 `gorm:"column:status" json:"status"`
}
type UserListItem struct {
Id int64 `json:"id"`
Name string `json:"name"`
Avatar string `json:"avatar"`
Mobile string `json:"mobile"`
OriginMobile string `json:"origin_mobile"`
Gender uint8 `json:"gender"`
Birthday string `json:"birthday"`
Status uint8 `json:"status"`
CreatedAt utils.CustomTime `json:"created_at"`
UpdatedAt utils.CustomTime `json:"updated_at"`
}
type UserItemsData struct {
Count int64 `json:"count"`
Items []UserListItem `json:"items"`
}