Files
gjs 4725649e33
CI / changes (push) Successful in 1m31s
CI / ad (push) Successful in 0s
CI / admin (push) Successful in 1s
CI / bff (push) Successful in 0s
CI / chore (push) Successful in 0s
CI / equipment (push) Successful in 32s
CI / express (push) Successful in 0s
CI / factory (push) Successful in 0s
CI / message (push) Successful in 1s
CI / order (push) Successful in 0s
CI / payment (push) Successful in 0s
CI / percutaneous (push) Successful in 0s
CI / product (push) Successful in 0s
CI / record (push) Successful in 1s
CI / sale (push) Successful in 0s
CI / support (push) Successful in 0s
CI / task (push) Successful in 1s
CI / user (push) Successful in 0s
CI / water (push) Successful in 0s
CI / wecom (push) Successful in 0s
save
2026-10-21 09:51:48 +08:00

54 lines
4.0 KiB
Go

package dao
import (
"lone-services/pkg/utils"
)
type BindCreate struct {
Id int64 `gorm:"column:id;type:bigint(20);primary_key;AUTO_INCREMENT" json:"id"`
HostCode string `gorm:"column:host_code;type:varchar(64);comment:主机编号;NOT NULL" json:"host_code"`
HostNickname string `gorm:"column:host_nickname;type:varchar(128);comment:主机昵称;NOT NULL" json:"host_nickname"`
UserId int64 `gorm:"column:user_id;type:int(11);comment:用户ID;NOT NULL" json:"user_id"`
UserNickname string `gorm:"column:user_nickname;type:varchar(128);comment:用户昵称;NOT NULL" json:"user_nickname"`
Type int32 `json:"type" gorm:"type"` // 类型。1为圆屏,2为卵型屏,3为皮肤分析仪,4为经皮湿水仪,5为AI化妆盒,6为软水机,7为制氧机,8老圆屏,9祛痘,10老圆屏
SkinType int32 `gorm:"column:skin_type" json:"skin_type"` // 1用户 2门店
Image string `gorm:"column:image;type:varchar(128);comment:图片地址;NOT NULL" json:"image"`
IsSpeciality int32 `gorm:"column:is_speciality;type:tinyint(1);default:0;comment:1是专业版;NOT NULL" json:"is_speciality"`
Status int32 `gorm:"column:status;type:tinyint(1);default:1;comment:状态,1为正常,2为禁用" json:"status"`
BindTime utils.CustomTime `gorm:"column:bind_time;type:datetime;comment:绑定时间" json:"bind_time"`
}
type BindInfo struct {
Id int64 `gorm:"column:id;type:bigint(20);primary_key;AUTO_INCREMENT" json:"id"`
HostCode string `gorm:"column:host_code;type:varchar(64);comment:主机编号;NOT NULL" json:"host_code"`
HostNickname string `gorm:"column:host_nickname;type:varchar(128);comment:主机昵称;NOT NULL" json:"host_nickname"`
UserId int64 `gorm:"column:user_id;type:int(11);comment:用户ID;NOT NULL" json:"user_id"`
UserNickname string `gorm:"column:user_nickname;type:varchar(128);comment:用户昵称;NOT NULL" json:"user_nickname"`
Image string `gorm:"column:image;type:varchar(128);comment:图片地址;NOT NULL" json:"image"`
Type int32 `json:"type" gorm:"type"` // 类型。1为圆屏,2为卵型屏,3为皮肤分析仪,4为经皮湿水仪,5为AI化妆盒,6为软水机,7为制氧机
SkinType int32 `gorm:"column:skin_type" json:"skin_type"` // 1用户 2门店
IsSpeciality int32 `gorm:"column:is_speciality;type:tinyint(1);default:0;comment:1是专业版;NOT NULL" json:"is_speciality"`
ExpiryTime string `gorm:"column:expiry_time;type:char(11);comment:过期时间" json:"expiry_time"`
Status uint8 `gorm:"column:status;type:tinyint(1);default:1;comment:状态,1为正常,2为禁用" json:"status"`
BindTime utils.CustomTime `gorm:"column:bind_time;type:datetime;comment:绑定时间" json:"bind_time"`
UpdatedTime utils.CustomTime `gorm:"column:updated_time;type:timestamp;default:CURRENT_TIMESTAMP;NOT NULL" json:"updated_time"`
}
type DeviceInfo struct {
Id int64 `json:"id"`
DeviceNo string `json:"device_no"`
DeviceName string `json:"device_name"`
Status uint8 `json:"status"`
CreatedAt utils.CustomTime `json:"created_at"`
UpdatedAt utils.CustomTime `json:"updated_at"`
}
type BindExpiry struct {
Id int64 `gorm:"column:id;type:bigint(20);primary_key;AUTO_INCREMENT" json:"id"`
HostCode string `gorm:"column:host_code;type:varchar(64);comment:主机编号;NOT NULL" json:"host_code"`
ExpiryTime string `gorm:"column:expiry_time;type:char(11);comment:过期时间" json:"expiry_time"`
Reason string `gorm:"column:reason;type:varchar(255);comment:理由" json:"reason"`
AdminId int64 `gorm:"column:admin_id;type:int(11)" json:"admin_id"`
AdminName string `gorm:"column:admin_name;type:varchar(255)" json:"admin_name"`
}