refactor: train.
This commit is contained in:
@ -28,6 +28,7 @@ type BeltAnalysis struct {
|
||||
Avg4min float64 `gorm:"type:double precision"` // 第4分钟平均心率
|
||||
Avg6min float64 `gorm:"type:double precision"` // 第6分钟平均心率
|
||||
CurveParamA float64 `gorm:"type:double precision"` // 拟合参数a值
|
||||
CurveParamB float64 `gorm:"type:double precision"` // 拟合参数a值
|
||||
}
|
||||
|
||||
// 中间计算结构(无需持久化)
|
||||
@ -47,9 +48,10 @@ type HeartRate struct {
|
||||
// 对应Flutter的TrainRecord结构
|
||||
type TrainRecord struct {
|
||||
gorm.Model
|
||||
TrainId uint `gorm:"uniqueIndex" json:"tid"` // 对应Dart的tid字段
|
||||
StartTime int64 `gorm:"type:bigint" json:"time"` // 开始时间戳
|
||||
EndTime int64 `gorm:"type:bigint" json:"endTime"` // 结束时间戳[3](@ref)
|
||||
TrainId uint `gorm:"uniqueIndex" json:"tid"` // 对应Dart的tid字段
|
||||
StartTime int64 `gorm:"type:bigint" json:"time"` // 开始时间戳
|
||||
TestTime int64 `gorm:"type:bigint" json:"testTime"` // 开始时间戳
|
||||
EndTime int64 `gorm:"type:bigint" json:"endTime"` // 结束时间戳[3](@ref)
|
||||
Name string `gorm:"size:100" json:"name"`
|
||||
RunType string `gorm:"size:100" json:"RunType"`
|
||||
MaxHeartRate int `gorm:"type:int" json:"maxHeartRate"`
|
||||
|
||||
Reference in New Issue
Block a user