CasaOS/model/person.go

39 lines
976 B
Go
Raw Normal View History

2022-02-17 10:43:25 +00:00
package model
import "time"
type PersionModel struct {
Token string `json:"token"`
Ips []string `json:"ips"`
2022-02-18 11:06:03 +00:00
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
2022-02-17 10:43:25 +00:00
}
//记录链接状态
type ConnectState struct {
From string `json:"from"`
To string `json:"to"`
Type string `json:"type"` //current state 1:ready 2:ok
CreatedAt time.Time `json:"created_at"`
UUId string `json:"uuid"` //对接标识
}
2022-02-18 11:06:03 +00:00
type MessageModel struct {
Type string `json:"type"`
Data interface{} `json:"data"`
UUId string `json:"uuid"`
2022-02-28 06:14:39 +00:00
From string `json:"from"`
}
type TranFileModel struct {
Hash string `json:"hash"` //Verify current fragment integrity
Data []byte `json:"data"`
Index int `json:"index"`
}
type FileSummaryModel struct {
Hash string `json:"hash"` //Verify file
Name string `json:"name"`
Path string `json:"path"`
BlockSize int `json:"block_size"`
2022-02-18 11:06:03 +00:00
}