You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
54 lines
1.4 KiB
54 lines
1.4 KiB
6 months ago
|
package model
|
||
|
|
||
|
type Breadcrumb struct { //面包屑
|
||
|
ID uint `json:"id"`
|
||
|
Name string `json:"name"`
|
||
|
Pid uint `json:"pid"` //父id
|
||
|
IsLeaf bool `json:"is_leaf"` //是否叶子分类
|
||
|
Parent *Breadcrumb `gorm:"-" json:"-"` //上级/下级
|
||
|
}
|
||
|
|
||
|
type Coordinate struct {
|
||
|
Format string `json:"x"`
|
||
|
Value float64 `json:"y"`
|
||
|
}
|
||
|
|
||
|
type CoordinateFormat struct {
|
||
|
Label string `json:"label"` //显示名称
|
||
|
Key string `json:"key"` //唯一键
|
||
|
}
|
||
|
|
||
|
type CoordinateObj struct {
|
||
|
Format CoordinateFormat `json:"x"` //x坐标
|
||
|
Value float64 `json:"y"` //值
|
||
|
}
|
||
|
|
||
|
type CoordinateData struct {
|
||
|
X []string `json:"x"` //x坐标取值数组
|
||
|
Y []float64 `json:"y"` //y坐标取值数组 组件自动
|
||
|
Values []Coordinate `json:"values"` //坐标中的点
|
||
|
}
|
||
|
|
||
|
type CoordinateObjData struct {
|
||
|
X []string `json:"x"` //x坐标取值数组
|
||
|
Y []float64 `json:"y"` //y坐标取值数组 组件自动
|
||
|
Values []CoordinateObj `json:"values"` //坐标中的点
|
||
|
}
|
||
|
|
||
|
type RankData struct {
|
||
|
Rank int64 `json:"rank"` //名次
|
||
|
Format string `json:"format"` //
|
||
|
Value float64 `json:"value"`
|
||
|
}
|
||
|
|
||
|
type RankDataObj struct {
|
||
|
Rank int64 `json:"rank"` //名次
|
||
|
Format CoordinateFormat `json:"format"` //排名内容
|
||
|
Value float64 `json:"value"` //值
|
||
|
}
|
||
|
|
||
|
type CountMap struct {
|
||
|
ID uint `json:"id"`
|
||
|
Count int64 `json:"count"`
|
||
|
}
|