2023-01-06 10:09:23 +08:00
|
|
|
package proto
|
|
|
|
|
|
|
|
// BaseResponse 基础返回结构
|
|
|
|
type BaseResponse struct {
|
2023-01-06 16:10:18 +08:00
|
|
|
Code int `json:"code"`
|
|
|
|
Message string `json:"message"`
|
|
|
|
Data interface{} `json:"result,omitempty"`
|
|
|
|
Status string `json:"type,omitempty"`
|
|
|
|
Err error `json:"error,omitempty"` // 错误堆栈
|
|
|
|
//Page int64 `json:"page,omitempty"` //当前页码
|
|
|
|
//PageSize int64 `json:"pageSize,omitempty"` // 单页显示记录数--前端参数2
|
|
|
|
//PageCount int64 `json:"totalPage,omitempty"` // 总页数
|
|
|
|
//TotalSize int64 `json:"total,omitempty"` // 总记录数
|
2023-01-06 10:09:23 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
type UserLoginResponse struct {
|
|
|
|
UserId int64 `json:"userId"`
|
|
|
|
Token string `json:"token"`
|
|
|
|
RealName string `json:"realName"`
|
|
|
|
UserName string `json:"userName"`
|
|
|
|
Roles []RoleItem `json:"roles"`
|
|
|
|
Avatar string `json:"avatar"`
|
|
|
|
Desc string `json:"desc"`
|
|
|
|
HomePath string `json:"homePath"`
|
|
|
|
}
|
|
|
|
|
|
|
|
type RoleItem struct {
|
|
|
|
RoleId int64 `json:"roleId"`
|
|
|
|
RoleName string `json:"roleName"`
|
|
|
|
Value string `json:"value"`
|
|
|
|
}
|
|
|
|
|
|
|
|
type OwnerItem struct {
|
|
|
|
OwnerId int `json:"ownerId"`
|
|
|
|
OwnerName string `json:"ownerName"`
|
|
|
|
ChargeUser string `json:"chargeUser"`
|
|
|
|
Phone string `json:"phone"`
|
|
|
|
}
|
2023-01-12 10:21:40 +08:00
|
|
|
|
|
|
|
type UploadResponse struct {
|
|
|
|
Url string `json:"url"`
|
|
|
|
}
|
2023-01-13 11:26:39 +08:00
|
|
|
|
|
|
|
type OwnerProjectItem struct {
|
|
|
|
OwnerId int `json:"key"`
|
|
|
|
OwnerName string `json:"title"`
|
|
|
|
ProjectList []ProjectItem `json:"children"`
|
|
|
|
}
|
|
|
|
|
|
|
|
type ProjectItem struct {
|
|
|
|
ProjectId string `json:"key"`
|
|
|
|
ProjectName string `json:"title"`
|
|
|
|
}
|
|
|
|
|
|
|
|
type DatasetItem struct {
|
|
|
|
DatasetId int64 `json:"datasetId"`
|
|
|
|
DatasetName string `json:"datasetName"`
|
|
|
|
DatasetDesc string `json:"datasetDesc"`
|
|
|
|
CategoryId int `json:"categoryId"`
|
|
|
|
ProjectId int64 `json:"projectId"`
|
|
|
|
OwnerId int64 `json:"ownerId"`
|
|
|
|
Creator int64 `json:"creator"`
|
|
|
|
CreateAt int64 `json:"createAt"`
|
|
|
|
DatasetCount int64 `json:"datasetCount"`
|
|
|
|
}
|