84 lines
1.3 KiB
Go
84 lines
1.3 KiB
Go
package proto
|
|
|
|
import (
|
|
"service/api/base"
|
|
"service/dbstruct"
|
|
)
|
|
|
|
// op 创建
|
|
type OpCreateReq struct {
|
|
base.BaseRequest
|
|
FootPrints []*dbstruct.FootPrint `json:"footprints"`
|
|
}
|
|
|
|
type OpCreateData struct {
|
|
}
|
|
|
|
type OpCreateResp struct {
|
|
base.BaseResponse
|
|
Data *OpCreateData `json:"data"`
|
|
}
|
|
|
|
// op 删除
|
|
type OpDeleteReq struct {
|
|
base.BaseRequest
|
|
FootPrints []*dbstruct.FootPrint `json:"footprints"`
|
|
}
|
|
|
|
type OpDeleteData struct {
|
|
}
|
|
|
|
type OpDeleteResp struct {
|
|
base.BaseResponse
|
|
Data *OpDeleteData `json:"data"`
|
|
}
|
|
|
|
// op 更新
|
|
type OpUpdateReq struct {
|
|
base.BaseRequest
|
|
*dbstruct.FootPrint
|
|
}
|
|
|
|
type OpUpdateData struct {
|
|
}
|
|
|
|
type OpUpdateResp struct {
|
|
base.BaseResponse
|
|
Data *OpUpdateData `json:"data"`
|
|
}
|
|
|
|
// op 列表
|
|
type OpListReq struct {
|
|
base.BaseRequest
|
|
Mid int64 `json:"mid"`
|
|
Offset int `json:"offset"`
|
|
Limit int `json:"limit"`
|
|
}
|
|
|
|
type OpListData struct {
|
|
List []*dbstruct.FootPrint `json:"list"`
|
|
Offset int `json:"offset"`
|
|
More int `json:"more"`
|
|
}
|
|
|
|
type OpListResp struct {
|
|
base.BaseResponse
|
|
Data *OpListData `json:"data"`
|
|
}
|
|
|
|
// 计数
|
|
type OpCountReq struct {
|
|
base.BaseRequest
|
|
Mid int64 `json:"mid"`
|
|
}
|
|
|
|
type OpCountData struct {
|
|
ViewCount int64 `json:"view_count"`
|
|
IsViewedCount int64 `json:"is_viewed_count"`
|
|
}
|
|
|
|
type OpCountResp struct {
|
|
base.BaseResponse
|
|
Data *OpListData `json:"data"`
|
|
}
|