235 lines
4.5 KiB
Go
235 lines
4.5 KiB
Go
package proto
|
||
|
||
import (
|
||
"service/api/base"
|
||
"service/dbstruct"
|
||
)
|
||
|
||
// op 创建
|
||
type OpCreateReq struct {
|
||
base.BaseRequest
|
||
*dbstruct.Streamer
|
||
}
|
||
|
||
type OpCreateData struct {
|
||
}
|
||
|
||
type OpCreateResp struct {
|
||
base.BaseResponse
|
||
Data *OpCreateData `json:"data"`
|
||
}
|
||
|
||
// op 删除
|
||
type OpDeleteReq struct {
|
||
base.BaseRequest
|
||
Id int64 `json:"id"`
|
||
}
|
||
|
||
type OpDeleteData struct {
|
||
}
|
||
|
||
type OpDeleteResp struct {
|
||
base.BaseResponse
|
||
Data *OpDeleteData `json:"data"`
|
||
}
|
||
|
||
// op 更新
|
||
type OpUpdateReq struct {
|
||
base.BaseRequest
|
||
*dbstruct.Streamer
|
||
}
|
||
|
||
type OpUpdateData struct {
|
||
}
|
||
|
||
type OpUpdateResp struct {
|
||
base.BaseResponse
|
||
Data *OpUpdateData `json:"data"`
|
||
}
|
||
|
||
// op 列表
|
||
type OpListReq struct {
|
||
base.BaseRequest
|
||
Offset int `json:"offset"`
|
||
Limit int `json:"limit"`
|
||
Sort []string
|
||
}
|
||
|
||
type OpListData struct {
|
||
List []*dbstruct.Streamer
|
||
Offset int `json:"offset"`
|
||
More int `json:"more"`
|
||
}
|
||
|
||
type OpListResp struct {
|
||
base.BaseResponse
|
||
Data *OpListData `json:"data"`
|
||
}
|
||
|
||
// op 单个mid查询
|
||
type OpListByMidReq struct {
|
||
base.BaseRequest
|
||
Mid *int64 `json:"mid"`
|
||
}
|
||
|
||
type OpListByMidData struct {
|
||
Streamer *dbstruct.Streamer `json:"streamer"`
|
||
}
|
||
|
||
type OpListByMidResp struct {
|
||
base.BaseResponse
|
||
Data *OpListByMidData `json:"data"`
|
||
}
|
||
|
||
// op 多个mid查询
|
||
type OpListByMidsReq struct {
|
||
base.BaseRequest
|
||
Mids []int64 `json:"mids"`
|
||
Offset int `json:"offset"`
|
||
Limit int `json:"limit"`
|
||
Sort []string
|
||
}
|
||
|
||
type OpListByMidsData struct {
|
||
List []*dbstruct.Streamer `json:"list"`
|
||
}
|
||
|
||
type OpListByMidsResp struct {
|
||
base.BaseResponse
|
||
Data *OpListByMidData `json:"data"`
|
||
}
|
||
|
||
// op 高级查询-单个mid
|
||
type OpListExtByMidReq struct {
|
||
base.BaseRequest
|
||
Mid *int64 `json:"mid"` // 单个mid查询
|
||
}
|
||
|
||
type OpListExtByMidData struct {
|
||
StreamerExt *OpListExtVO `json:"streamer_ext"`
|
||
WechatLockType string `json:"wechat_lock_type"` // 主播的微信上锁类型
|
||
IsUnlockWechat int32 `json:"is_unlock_wechat"` // 是否解锁微信, 0:未解锁,1:已解锁
|
||
}
|
||
|
||
type OpListExtByMidResp struct {
|
||
base.BaseResponse
|
||
Data *OpListExtByMidData `json:"data"`
|
||
}
|
||
|
||
// op 高级查询-多个mid
|
||
type OpListExtByMidsReq struct {
|
||
base.BaseRequest
|
||
Mids []int64 `json:"mids"` // 多个mid查询
|
||
Offset int `json:"offset"`
|
||
Limit int `json:"limit"`
|
||
}
|
||
|
||
type OpListExtByMidsData struct {
|
||
List []*OpListExtVO `json:"list"`
|
||
Offset int `json:"offset"`
|
||
More int `json:"more"`
|
||
}
|
||
|
||
type OpListExtByMidsResp struct {
|
||
base.BaseResponse
|
||
Data *OpListExtByMidsData `json:"data"`
|
||
}
|
||
|
||
// op 高级查询-user_id精确查询
|
||
type OpListExtByUserIdReq struct {
|
||
base.BaseRequest
|
||
UserId *int64 `json:"user_id"` // 单个mid查询
|
||
}
|
||
|
||
type OpListExtByUserIdData struct {
|
||
StreamerExt *OpListExtVO `json:"streamer_ext"`
|
||
}
|
||
|
||
type OpListExtByUserIdResp struct {
|
||
base.BaseResponse
|
||
Data *OpListExtByUserIdData `json:"data"`
|
||
}
|
||
|
||
// op 高级查询-user_id模糊查询
|
||
type OpListExtFuzzilyByUserIdReq struct {
|
||
base.BaseRequest
|
||
UserId *int64 `json:"user_id"` // user_id模糊查询
|
||
Offset int `json:"offset"`
|
||
Limit int `json:"limit"`
|
||
}
|
||
|
||
type OpListExtFuzzilyByUserIdData struct {
|
||
List []*OpListExtVO `json:"list"`
|
||
Offset int `json:"offset"`
|
||
More int `json:"more"`
|
||
}
|
||
|
||
type OpListExtFuzzilyByUserIdResp struct {
|
||
base.BaseResponse
|
||
Data *OpListExtFuzzilyByUserIdData `json:"data"`
|
||
}
|
||
|
||
// op 高级查询-name模糊查询
|
||
type OpListExtFuzzilyByNameReq struct {
|
||
base.BaseRequest
|
||
Name string `json:"name"` // name模糊查询
|
||
Offset int `json:"offset"`
|
||
Limit int `json:"limit"`
|
||
}
|
||
|
||
type OpListExtFuzzilyByNameData struct {
|
||
List []*OpListExtVO `json:"list"`
|
||
Offset int `json:"offset"`
|
||
More int `json:"more"`
|
||
}
|
||
|
||
type OpListExtFuzzilyByNameResp struct {
|
||
base.BaseResponse
|
||
Data *OpListExtFuzzilyByNameData `json:"data"`
|
||
}
|
||
|
||
// op 查询微信
|
||
type OpListStreamerWxIdReq struct {
|
||
base.BaseRequest
|
||
Mid *int64 `json:"mid"`
|
||
}
|
||
|
||
type OpListStreamerWxIdData struct {
|
||
WxIdVO *OpListWxIdVO `json:"wx_id_vo"`
|
||
}
|
||
|
||
type OpListStreamerWxIdResp struct {
|
||
base.BaseResponse
|
||
Data *OpListStreamerWxIdData `json:"data"`
|
||
}
|
||
|
||
// op 推荐
|
||
type OpRecommListReq struct {
|
||
base.BaseRequest
|
||
Offset int `json:"offset"`
|
||
Limit int `json:"limit"`
|
||
}
|
||
|
||
type OpRecommListData struct {
|
||
RecommList []int64 `json:"recomm_list"`
|
||
}
|
||
|
||
type OpRecommListResp struct {
|
||
base.BaseResponse
|
||
Data *OpRecommListData `json:"data"`
|
||
}
|
||
|
||
// op 批量创建
|
||
type OpCreateBatchReq struct {
|
||
base.BaseRequest
|
||
Streamers []*dbstruct.Streamer `json:"streamers"`
|
||
}
|
||
|
||
type OpCreateBatchData struct {
|
||
}
|
||
|
||
type OpCreateBatchResp struct {
|
||
base.BaseResponse
|
||
Data *OpCreateData `json:"data"`
|
||
}
|