feat(sms): add sms login method

This commit is contained in:
2024-10-28 14:41:27 +08:00
parent bb580ff488
commit b5b839fdba
13 changed files with 532 additions and 20 deletions

View File

@ -1,11 +1,14 @@
package models
import "time"
type Check struct {
CheckID int `gorm:"column:check_id"`
UserID int `gorm:"column:user_id"`
CheckDate string `gorm:"column:check_date"`
InsertTime string `gorm:"column:insert_time"`
UpdateTime string `gorm:"column:update_time"`
CheckID int `gorm:"column:check_id"`
UserID int `gorm:"column:user_id"`
CheckDate time.Time `gorm:"column:check_date"`
Hospital int `gorm:"column:check_hospital"`
InsertTime time.Time `gorm:"column:insert_time"`
UpdateTime time.Time `gorm:"column:update_time"`
}
func (Check) TableName() string {
@ -13,10 +16,10 @@ func (Check) TableName() string {
}
type CheckItem struct {
CheckItemID int `gorm:"column:check_item_id"`
CheckID int `gorm:"column:check_id"`
ItemID int `gorm:"column:item_id"`
ItemValue string `gorm:"column:item_value"`
CheckItemID int `gorm:"column:check_item_id"`
CheckID int `gorm:"column:check_id"`
ItemID int `gorm:"column:item_id"`
ItemValue float32 `gorm:"column:item_value"`
}
func (CheckItem) TableName() string {
@ -33,3 +36,20 @@ type Item struct {
func (Item) TableName() string {
return "items"
}
type UserInput struct {
Date string `json:"date"`
Hospital int `json:"checkHospital"`
Ca125 float32 `json:"ca125Value"`
Ca199 float32 `json:"ca199Value"`
Cea float32 `json:"ceaValue"`
Ca153 float32 `json:"ca153Value"`
Ca724 float32 `json:"ca724Value"`
He4 float32 `json:"he4Value"`
Rbc float32 `json:"rbcValue"`
Hb float32 `json:"hbValue"`
Wbc float32 `json:"wbcValue"`
Plt float32 `json:"pltValue"`
Neut float32 `json:"neutValue"`
Weight float32 `json:"weightValue"`
}

View File

@ -6,9 +6,9 @@ type User struct {
UserID int `gorm:"column:user_id"`
UserName string `gorm:"column:user_name"`
Password string `gorm:"column:password"`
Brth time.Time `gorm:"column:brth"`
Birth time.Time `gorm:"column:birth"`
Height float32 `gorm:"column:height"`
Tel string `gorm:"column:tel"`
Tel string `gorm:"column:tel" json:"tel"`
SMSTry int `gorm:"column:SMS_try"`
}