Files
lone-services/services/aiserver/internal/dao/setting.go
T
gjs cc23c30c9e
CI / changes (push) Successful in 1m34s
CI / ad (push) Successful in 27s
CI / admin (push) Successful in 17s
CI / aiserver (push) Successful in 26s
CI / analysis (push) Successful in 22s
CI / bff (push) Successful in 21s
CI / chore (push) Successful in 20s
CI / equipment (push) Successful in 19s
CI / express (push) Successful in 19s
CI / factory (push) Successful in 19s
CI / message (push) Successful in 18s
CI / order (push) Successful in 19s
CI / payment (push) Successful in 17s
CI / percutaneous (push) Successful in 17s
CI / product (push) Successful in 19s
CI / record (push) Successful in 19s
CI / sale (push) Successful in 19s
CI / store (push) Successful in 20s
CI / support (push) Successful in 19s
CI / task (push) Successful in 21s
CI / user (push) Successful in 22s
CI / water (push) Successful in 25s
CI / wecom (push) Successful in 21s
CI / ws (push) Successful in 9s
add apis
2026-10-30 18:02:20 +08:00

33 lines
2.8 KiB
Go

package dao
import "lone-services/pkg/utils"
// SettingCreate 权限表
type SettingCreate struct {
Id int64 `gorm:"column:id;type:int;not null;autoIncrement" json:"id"`
UserId int64 `gorm:"column:user_id;type:int;not null" json:"user_id"` // 用户ID
Lang int32 `gorm:"column:lang;type:tinyint(1);not null;default:1" json:"lang"` // 语言:1为中文,2为英文
Wifi int32 `gorm:"column:wifi;type:tinyint(1);not null;default:2" json:"wifi"` // wifi:1为设置过,2为没有设置过
Screen int32 `gorm:"column:screen;type:tinyint;not null" json:"screen"` // 屏幕亮度
Sound int32 `gorm:"column:sound;type:tinyint;not null" json:"sound"` // 声音
LightOpen int32 `gorm:"column:light_open;type:tinyint(1);not null;default:1" json:"light_open"` // 是否开灯,1为开灯,2为不开灯
LightWorkTime string `gorm:"column:light_work_time;type:char(50);default:NULL" json:"light_work_time"` // 灯工作时间
ScreenSleepTime int32 `gorm:"column:screen_sleep_time;type:smallint;default:NULL" json:"screen_sleep_time"` // 屏幕休眠时间
LightBrightness int32 `gorm:"column:light_brightness;type:tinyint;default:NULL" json:"light_brightness"` // 灯亮度
}
type SettingInfo struct {
Id int64 `gorm:"column:id;type:int;not null;autoIncrement" json:"id"`
UserId int64 `gorm:"column:user_id;type:int;not null" json:"user_id"` // 用户ID
Lang int32 `gorm:"column:lang;type:tinyint(1);not null;default:1" json:"lang"` // 语言:1为中文,2为英文
Wifi int32 `gorm:"column:wifi;type:tinyint(1);not null;default:2" json:"wifi"` // wifi:1为设置过,2为没有设置过
Screen int32 `gorm:"column:screen;type:tinyint;not null" json:"screen"` // 屏幕亮度
Sound int32 `gorm:"column:sound;type:tinyint;not null" json:"sound"` // 声音
LightOpen int32 `gorm:"column:light_open;type:tinyint(1);not null;default:1" json:"light_open"` // 是否开灯,1为开灯,2为不开灯
LightWorkTime string `gorm:"column:light_work_time;type:char(50);default:NULL" json:"light_work_time"` // 灯工作时间
ScreenSleepTime int32 `gorm:"column:screen_sleep_time;type:smallint;default:NULL" json:"screen_sleep_time"` // 屏幕休眠时间
LightBrightness int32 `gorm:"column:light_brightness;type:tinyint;default:NULL" json:"light_brightness"` // 灯亮度
CreateTime utils.CustomTime `json:"create_time"`
}