Jianghan 1 жил өмнө
parent
commit
6de420c217

+ 59 - 32
jyBXSubscribe/api/bxsubscribe.api

@@ -1,10 +1,10 @@
 syntax = "v1"
 
 info (
-	title: "剑鱼标讯" // TODO: add title
-	desc: "订阅模块"// TODO: add description
+	title:  "剑鱼标讯" // TODO: add title
+	desc:   "订阅模块" // TODO: add description
 	author: "wangshan"
-	email: "wangshan@topnet.net.cn"
+	email:  "wangshan@topnet.net.cn"
 )
 
 type (
@@ -26,9 +26,9 @@ type (
 		Subtype        string                 `json:"subtype,optional"`
 		Price          string                 `json:"price,optional"`
 		FileExists     string                 `json:"fileExists,optional"`
-		Source         string                 `json:"source,optional"`                                        //信息来源
-		IsRead         string                 `json:"isRead,optional"`                                        //是否已读
-		Staffs         string                 `json:"staffs,optional"`                                        //分发的员工
+		Source         string                 `json:"source,optional"` //信息来源
+		IsRead         string                 `json:"isRead,optional"` //是否已读
+		Staffs         string                 `json:"staffs,optional"` //分发的员工
 		UserType       string                 `path:"userType,default=fType,options=fType|vType|mType|eType"` //fType:普通用户;vType:超级订阅用户;mType:大会员用户;eType:商机管理用户;
 		NewUserId      int64                  `header:"newUserId"`
 		IsEnt          bool                   `json:"isEnt,optional"`
@@ -62,16 +62,16 @@ type (
 	}
 	//
 	subscribeUpdateReq {
-		Area            map[string]interface{}   `json:"area,optional"`            //地区
-		Buyerclass      []string                 `json:"buyerclass,optional"`      //采购单位类型
-		Items           []map[string]interface{} `json:"items,optional"`           //关键词
-		Infotype        []string                 `json:"infotype,optional"`        //信息类型
-		Matchway        string                   `json:"matchway,optional"`        //匹配方式 1标题 2正文
-		Projectmatch    string                   `json:"projectmatch,optional"`    //项目匹配 1开始 0关闭
-		Ratemode        string                   `json:"ratemode,optional"`        // 1:实时推送,2:每天9点推送,3:每周推送,4:每月推送 5:每日推送两次
-		Apppush         string                   `json:"apppush,optional"`         //app推送 1开启 0关闭
-		Mailpush        string                   `json:"mailpush,optional"`        //邮箱推送 1开启 0关闭
-		Mail            string                   `json:"mail,optional"`            //邮箱
+		Area            map[string]interface{}   `json:"area,optional"` //地区
+		Buyerclass      []string                 `json:"buyerclass,optional"` //采购单位类型
+		Items           []map[string]interface{} `json:"items,optional"` //关键词
+		Infotype        []string                 `json:"infotype,optional"` //信息类型
+		Matchway        string                   `json:"matchway,optional"` //匹配方式 1标题 2正文
+		Projectmatch    string                   `json:"projectmatch,optional"` //项目匹配 1开始 0关闭
+		Ratemode        string                   `json:"ratemode,optional"` // 1:实时推送,2:每天9点推送,3:每周推送,4:每月推送 5:每日推送两次
+		Apppush         string                   `json:"apppush,optional"` //app推送 1开启 0关闭
+		Mailpush        string                   `json:"mailpush,optional"` //邮箱推送 1开启 0关闭
+		Mail            string                   `json:"mail,optional"` //邮箱
 		Otherbuyerclass string                   `json:"otherbuyerclass,optional"` //匹配未分类类型 1匹配 0不匹配
 		AppId           string                   `header:"appId,optional"`
 		UserType        string                   `path:"userType,optional"`
@@ -188,7 +188,6 @@ type (
 		Err_msg  string      `json:"error_msg"`
 		Data     interface{} `json:"data"`
 	}
-
 	BidDistributor {
 		AppId     string   `header:"appId"`
 		EntId     string   `header:"entId,optional"`
@@ -196,38 +195,66 @@ type (
 		Infoids   []string `json:"infoids"`
 		Staffs    string   `json:"staffs"`
 	}
+	BidRecListReq {
+		AppId        string `header:"appId"`
+		UserId       string `header:"userId"`
+		EntId        string `header:"entId,optional"`
+		EntUserId    string `header:"entUserId,optional"`
+		Spath        string `json:"spath"` // 页面入口,1: 订阅更多;2:模版消息
+		PositionType int64  `header:"positionType,optional"`
+	}
 )
+
 service bxsubscribe-api {
 	@handler subscribeList
-	post /jybx/subscribe/:userType/list(subscribeReq) returns (commonResp)
+	post /jybx/subscribe/:userType/list (subscribeReq) returns (commonResp)
+
 	@handler someInfo
-	post /jybx/subscribe/:userType/someInfo(someInfoReq) returns (commonResp)
+	post /jybx/subscribe/:userType/someInfo (someInfoReq) returns (commonResp)
+
 	@handler subscribeUpdate
-	post /jybx/subscribe/:userType/update(subscribeUpdateReq) returns (commonResp)
+	post /jybx/subscribe/:userType/update (subscribeUpdateReq) returns (commonResp)
+
 	@handler ByPushHistory
-	post /jybx/subscribe/:userType/byPushHistory(subscribeReq) returns (commonResp)
+	post /jybx/subscribe/:userType/byPushHistory (subscribeReq) returns (commonResp)
+
 	@handler SetRead
-	post /jybx/subscribe/:userType/setRead(SetReadReq) returns (commonResp)
+	post /jybx/subscribe/:userType/setRead (SetReadReq) returns (commonResp)
+
 	@handler getKey
-	post /jybx/subscribe/:userType/getKey(GetKeyReq) returns (commonResp)
+	post /jybx/subscribe/:userType/getKey (GetKeyReq) returns (commonResp)
+
 	@handler distributor
-	post /jybx/subscribe/:userType/distributor(DistributorReq) returns (commonResp)
+	post /jybx/subscribe/:userType/distributor (DistributorReq) returns (commonResp)
+
 	@handler viewStatus
-	post /jybx/subscribe/:userType/viewStatus(viewStatusReq) returns (commonResp)
+	post /jybx/subscribe/:userType/viewStatus (viewStatusReq) returns (commonResp)
+
 	@handler msgDistributor
-	post /jybx/subscribe/msgDistributor(msgDistributor) returns (commonResp)
+	post /jybx/subscribe/msgDistributor (msgDistributor) returns (commonResp)
+
 	@handler getUser //查询用户信息
 	post /jybx/subscribe/getUser (GetUserReq) returns (commonResp)
-	@handler setUser  //设置用户信息
+
+	@handler setUser //设置用户信息
 	post /jybx/subscribe/setUser (SetUserReq) returns (commonResp)
-	@handler getPushSet  //推送设置查询
+
+	@handler getPushSet //推送设置查询
 	post /jybx/subscribe/getPushSet (GetUserReq) returns (commonResp)
-	@handler setPushSet  //推送设置修改
+
+	@handler setPushSet //推送设置修改
 	post /jybx/subscribe/setPushSet (SetPushSetReq) returns (commonResp)
+
 	@handler getStaffSubscribeList //查询企业员工订阅状态
 	post /jybx/subscribe/getStaffSubscribe (GetStaffSubscribeListReq) returns (StaffSubscribeCommonResp)
+
 	@handler getStaffSubscribeDetail //查询企业员工订阅详情
 	post /jybx/subscribe/getStaffSubscribeDetail (GetStaffSubscribeDetailReq) returns (StaffSubscribeCommonResp)
-	@handler bidDistributor  //标讯分发
-	post /jybx/subscribe/bidDistributor(BidDistributor) returns (commonResp)
-}
+
+	@handler bidDistributor //标讯分发
+	post /jybx/subscribe/bidDistributor (BidDistributor) returns (commonResp)
+
+	@handler bidRecList // 订阅推荐列表
+	post /jybx/subscribe/getRecList (BidRecListReq) returns (commonResp)
+}
+

+ 28 - 0
jyBXSubscribe/api/internal/handler/bidRecListHandler.go

@@ -0,0 +1,28 @@
+package handler
+
+import (
+	"net/http"
+
+	"github.com/zeromicro/go-zero/rest/httpx"
+	"jyBXSubscribe/api/internal/logic"
+	"jyBXSubscribe/api/internal/svc"
+	"jyBXSubscribe/api/internal/types"
+)
+
+func bidRecListHandler(svcCtx *svc.ServiceContext) http.HandlerFunc {
+	return func(w http.ResponseWriter, r *http.Request) {
+		var req types.BidRecListReq
+		if err := httpx.Parse(r, &req); err != nil {
+			httpx.ErrorCtx(r.Context(), w, err)
+			return
+		}
+
+		l := logic.NewBidRecListLogic(r.Context(), svcCtx)
+		resp, err := l.BidRecList(&req)
+		if err != nil {
+			httpx.ErrorCtx(r.Context(), w, err)
+		} else {
+			httpx.OkJsonCtx(r.Context(), w, resp)
+		}
+	}
+}

+ 33 - 28
jyBXSubscribe/api/internal/handler/routes.go

@@ -14,23 +14,23 @@ func RegisterHandlers(server *rest.Server, serverCtx *svc.ServiceContext) {
 		[]rest.Route{
 			{
 				Method:  http.MethodPost,
-				Path:    "/jybx/subscribe/:userType/list",
-				Handler: subscribeListHandler(serverCtx),
+				Path:    "/jybx/subscribe/:userType/byPushHistory",
+				Handler: ByPushHistoryHandler(serverCtx),
 			},
 			{
 				Method:  http.MethodPost,
-				Path:    "/jybx/subscribe/:userType/someInfo",
-				Handler: someInfoHandler(serverCtx),
+				Path:    "/jybx/subscribe/:userType/distributor",
+				Handler: distributorHandler(serverCtx),
 			},
 			{
 				Method:  http.MethodPost,
-				Path:    "/jybx/subscribe/:userType/update",
-				Handler: subscribeUpdateHandler(serverCtx),
+				Path:    "/jybx/subscribe/:userType/getKey",
+				Handler: getKeyHandler(serverCtx),
 			},
 			{
 				Method:  http.MethodPost,
-				Path:    "/jybx/subscribe/:userType/byPushHistory",
-				Handler: ByPushHistoryHandler(serverCtx),
+				Path:    "/jybx/subscribe/:userType/list",
+				Handler: subscribeListHandler(serverCtx),
 			},
 			{
 				Method:  http.MethodPost,
@@ -39,13 +39,13 @@ func RegisterHandlers(server *rest.Server, serverCtx *svc.ServiceContext) {
 			},
 			{
 				Method:  http.MethodPost,
-				Path:    "/jybx/subscribe/:userType/getKey",
-				Handler: getKeyHandler(serverCtx),
+				Path:    "/jybx/subscribe/:userType/someInfo",
+				Handler: someInfoHandler(serverCtx),
 			},
 			{
 				Method:  http.MethodPost,
-				Path:    "/jybx/subscribe/:userType/distributor",
-				Handler: distributorHandler(serverCtx),
+				Path:    "/jybx/subscribe/:userType/update",
+				Handler: subscribeUpdateHandler(serverCtx),
 			},
 			{
 				Method:  http.MethodPost,
@@ -54,18 +54,8 @@ func RegisterHandlers(server *rest.Server, serverCtx *svc.ServiceContext) {
 			},
 			{
 				Method:  http.MethodPost,
-				Path:    "/jybx/subscribe/msgDistributor",
-				Handler: msgDistributorHandler(serverCtx),
-			},
-			{
-				Method:  http.MethodPost,
-				Path:    "/jybx/subscribe/getUser",
-				Handler: getUserHandler(serverCtx),
-			},
-			{
-				Method:  http.MethodPost,
-				Path:    "/jybx/subscribe/setUser",
-				Handler: setUserHandler(serverCtx),
+				Path:    "/jybx/subscribe/bidDistributor",
+				Handler: bidDistributorHandler(serverCtx),
 			},
 			{
 				Method:  http.MethodPost,
@@ -74,8 +64,8 @@ func RegisterHandlers(server *rest.Server, serverCtx *svc.ServiceContext) {
 			},
 			{
 				Method:  http.MethodPost,
-				Path:    "/jybx/subscribe/setPushSet",
-				Handler: setPushSetHandler(serverCtx),
+				Path:    "/jybx/subscribe/getRecList",
+				Handler: bidRecListHandler(serverCtx),
 			},
 			{
 				Method:  http.MethodPost,
@@ -89,8 +79,23 @@ func RegisterHandlers(server *rest.Server, serverCtx *svc.ServiceContext) {
 			},
 			{
 				Method:  http.MethodPost,
-				Path:    "/jybx/subscribe/bidDistributor",
-				Handler: bidDistributorHandler(serverCtx),
+				Path:    "/jybx/subscribe/getUser",
+				Handler: getUserHandler(serverCtx),
+			},
+			{
+				Method:  http.MethodPost,
+				Path:    "/jybx/subscribe/msgDistributor",
+				Handler: msgDistributorHandler(serverCtx),
+			},
+			{
+				Method:  http.MethodPost,
+				Path:    "/jybx/subscribe/setPushSet",
+				Handler: setPushSetHandler(serverCtx),
+			},
+			{
+				Method:  http.MethodPost,
+				Path:    "/jybx/subscribe/setUser",
+				Handler: setUserHandler(serverCtx),
 			},
 		},
 	)

+ 43 - 0
jyBXSubscribe/api/internal/logic/bidRecListLogic.go

@@ -0,0 +1,43 @@
+package logic
+
+import (
+	"context"
+	"jyBXSubscribe/rpc/bxsubscribe"
+
+	"jyBXSubscribe/api/internal/svc"
+	"jyBXSubscribe/api/internal/types"
+
+	"github.com/zeromicro/go-zero/core/logx"
+)
+
+type BidRecListLogic struct {
+	logx.Logger
+	ctx    context.Context
+	svcCtx *svc.ServiceContext
+}
+
+func NewBidRecListLogic(ctx context.Context, svcCtx *svc.ServiceContext) *BidRecListLogic {
+	return &BidRecListLogic{
+		Logger: logx.WithContext(ctx),
+		ctx:    ctx,
+		svcCtx: svcCtx,
+	}
+}
+
+func (l *BidRecListLogic) BidRecList(req *types.BidRecListReq) (resp *types.CommonResp, err error) {
+	res, err := l.svcCtx.Suscribe.BidRecList(l.ctx, &bxsubscribe.BidRecListReq{
+		AppId:        req.AppId,
+		EntId:        req.EntId,
+		SPath:        req.Spath,
+		UserId:       req.UserId,
+		EntUserId:    req.EntUserId,
+		PositionType: req.PositionType,
+	})
+	return &types.CommonResp{
+		Err_code: res.ErrCode,
+		Err_msg:  res.ErrMsg,
+		Data:     res.Data,
+	}, err
+
+	return
+}

+ 137 - 128
jyBXSubscribe/api/internal/types/types.go

@@ -1,94 +1,33 @@
 // Code generated by goctl. DO NOT EDIT.
 package types
 
-type SubscribeReq struct {
-	AppId          string                 `header:"appId"`
-	UserId         string                 `header:"userId"`
-	EntId          string                 `header:"entId,optional"`
-	EntUserId      string                 `header:"entUserId,optional"`
-	DeptId         string                 `header:"deptId,optional"` //部门id
-	PageNum        int64                  `json:"pageNum,optional"`
-	PageSize       int64                  `json:"pageSize,optional"`
-	SelectTime     string                 `json:"selectTime,optional"`
-	Area           string                 `json:"area,optional"`
-	City           string                 `json:"city,optional"`
-	Industry       string                 `json:"industry,optional"`
-	BuyerClass     string                 `json:"buyerClass,optional"`
-	KeyWords       string                 `json:"keyWords,optional"`
-	Subtype        string                 `json:"subtype,optional"`
-	Price          string                 `json:"price,optional"`
-	FileExists     string                 `json:"fileExists,optional"`
-	Source         string                 `json:"source,optional"`                                        //信息来源
-	IsRead         string                 `json:"isRead,optional"`                                        //是否已读
-	Staffs         string                 `json:"staffs,optional"`                                        //分发的员工
-	UserType       string                 `path:"userType,default=fType,options=fType|vType|mType|eType"` //fType:普通用户;vType:超级订阅用户;mType:大会员用户;eType:商机管理用户;
-	NewUserId      int64                  `header:"newUserId"`
-	IsEnt          bool                   `json:"isEnt,optional"`
-	SelectIds      string                 `json:"selectIds,optional"`
-	SelectKeys     string                 `json:"selectKeys,optional"`
-	PositionType   int64                  `header:"positionType,optional"`
-	NotReturnCount int64                  `json:"notReturnCount,optional"`
-	Item           map[string]interface{} `json:"item,optional"`
-	AccountId      string                 `header:"accountId,optional"`
-	PositionId     string                 `header:"positionId,optional"`
-	MgoUserId      string                 `header:"mgoUserId,optional"` //原userId
-	District       string                 `json:"district,optional"`
-}
-
-type SomeInfoReq struct {
-	AppId        string `header:"appId"`
-	UserType     string `path:"userType"`
-	UserId       string `header:"userId,optional"`
-	NewUserId    string `header:"newUserId,optional"`
-	EntId        string `header:"entId,optional"`
-	AccountId    string `header:"accountId,optional"`
-	PositionType string `header:"positionType,optional"`
-	PositionId   string `header:"positionId,optional"`
-}
-
-type CommonResp struct {
-	Err_code int64       `json:"error_code"`
-	Err_msg  string      `json:"error_msg"`
-	Data     interface{} `json:"data"`
-	TimeData interface{} `json:"timeData"`
-}
-
-type SubscribeUpdateReq struct {
-	Area            map[string]interface{}   `json:"area,optional"`            //地区
-	Buyerclass      []string                 `json:"buyerclass,optional"`      //采购单位类型
-	Items           []map[string]interface{} `json:"items,optional"`           //关键词
-	Infotype        []string                 `json:"infotype,optional"`        //信息类型
-	Matchway        string                   `json:"matchway,optional"`        //匹配方式 1标题 2正文
-	Projectmatch    string                   `json:"projectmatch,optional"`    //项目匹配 1开始 0关闭
-	Ratemode        string                   `json:"ratemode,optional"`        // 1:实时推送,2:每天9点推送,3:每周推送,4:每月推送 5:每日推送两次
-	Apppush         string                   `json:"apppush,optional"`         //app推送 1开启 0关闭
-	Mailpush        string                   `json:"mailpush,optional"`        //邮箱推送 1开启 0关闭
-	Mail            string                   `json:"mail,optional"`            //邮箱
-	Otherbuyerclass string                   `json:"otherbuyerclass,optional"` //匹配未分类类型 1匹配 0不匹配
-	AppId           string                   `header:"appId,optional"`
-	UserType        string                   `path:"userType,optional"`
-	UserId          string                   `header:"userId,optional"`
-	PositionType    int64                    `header:"positionType,optional"`
-	NewUserId       int64                    `header:"newUserId,optional"`
-	EntId           int64                    `header:"entId,optional"`
-	AccountId       int64                    `header:"accountId,optional"`
-	PositionId      int64                    `header:"positionId,optional"`
-	District        map[string]interface{}   `json:"district,optional"`
+type BidDistributor struct {
+	AppId     string   `header:"appId"`
+	EntId     string   `header:"entId,optional"`
+	EntUserId string   `header:"entUserId,optional"`
+	Infoids   []string `json:"infoids"`
+	Staffs    string   `json:"staffs"`
 }
 
-type SetReadReq struct {
+type BidRecListReq struct {
 	AppId        string `header:"appId"`
 	UserId       string `header:"userId"`
 	EntId        string `header:"entId,optional"`
 	EntUserId    string `header:"entUserId,optional"`
-	DeptId       string `header:"deptId,optional"` //部门id
-	Vsid         int64  `form:"vsid"`
-	NewUserId    int64  `header:"newUserId"`
-	IsEnt        bool   `form:"isEnt,optional"`
-	UserType     string `path:"userType,optional"`
+	Spath        string `json:"spath"` // 页面入口,1: 订阅更多;2:模版消息
 	PositionType int64  `header:"positionType,optional"`
 }
 
+type DistributorReq struct {
+	AppId     string `header:"appId"`
+	EntId     string `header:"entId,optional"`
+	EntUserId string `header:"entUserId,optional"`
+	UserType  string `path:"userType,optional"`
+	Region    string `json:"region,optional"`
+	SelectIds string `json:"selectIds,optional"`
+	QueryType string `json:"queryType,optional"`
+}
+
 type GetKeyReq struct {
 	AppId        string `header:"appId"`
 	UserId       string `header:"userId"`
@@ -105,30 +44,22 @@ type GetKeyReq struct {
 	PositionType int64  `header:"positionType,optional"`
 }
 
-type DistributorReq struct {
-	AppId     string `header:"appId"`
-	EntId     string `header:"entId,optional"`
-	EntUserId string `header:"entUserId,optional"`
-	UserType  string `path:"userType,optional"`
-	Region    string `json:"region,optional"`
-	SelectIds string `json:"selectIds,optional"`
-	QueryType string `json:"queryType,optional"`
-}
-
-type ViewStatusReq struct {
+type GetStaffSubscribeDetailReq struct {
 	AppId     string `header:"appId"`
-	EntId     string `header:"entId,optional"`
-	EntUserId string `header:"entUserId,optional"`
-	UserType  string `path:"userType,optional"`
-	InfoId    string `json:"infoId,optional"`
+	EntId     int64  `header:"entId,optional"`
+	EntUserId int64  `header:"entUserId,optional"`
+	Token     string `json:"token,optional"`
 }
 
-type MsgDistributor struct {
+type GetStaffSubscribeListReq struct {
 	AppId     string `header:"appId"`
-	EntId     string `header:"entId,optional"`
-	EntUserId string `header:"entUserId,optional"`
-	MessageId string `json:"messageId"`
-	Staffs    string `json:"staffs"`
+	EntId     int64  `header:"entId,optional"`
+	EntUserId int64  `header:"entUserId,optional"`
+	EStatus   int64  `json:"e_status,optional"`
+	PStatus   int64  `json:"p_status,optional"`
+	Search    string `json:"search,optional"`
+	PageNum   int64  `json:"pageNum,optional"`
+	PageSize  int64  `json:"pageSize,optional"`
 }
 
 type GetUserReq struct {
@@ -144,15 +75,6 @@ type GetUserReq struct {
 	MgoUserId    string `header:"mgoUserId,optional"` //原userId
 }
 
-type SetUserReq struct {
-	AppId        string `header:"appId"`
-	EntId        int64  `header:"entId,optional"`
-	EntUserId    int64  `header:"entUserId,optional"`
-	PositionType int64  `header:"positionType,optional"`
-	UserId       string `header:"userId,optional"`
-	Mail         string `json:"mail,optional"`
-}
-
 type SetPushSetReq struct {
 	AppId        string   `header:"appId"`
 	EntId        int64    `header:"entId,optional"`
@@ -168,22 +90,26 @@ type SetPushSetReq struct {
 	Interested   int64    `json:"interested,optional"`
 }
 
-type GetStaffSubscribeListReq struct {
-	AppId     string `header:"appId"`
-	EntId     int64  `header:"entId,optional"`
-	EntUserId int64  `header:"entUserId,optional"`
-	EStatus   int64  `json:"e_status,optional"`
-	PStatus   int64  `json:"p_status,optional"`
-	Search    string `json:"search,optional"`
-	PageNum   int64  `json:"pageNum,optional"`
-	PageSize  int64  `json:"pageSize,optional"`
+type SetReadReq struct {
+	AppId        string `header:"appId"`
+	UserId       string `header:"userId"`
+	EntId        string `header:"entId,optional"`
+	EntUserId    string `header:"entUserId,optional"`
+	DeptId       string `header:"deptId,optional"` //部门id
+	Vsid         int64  `form:"vsid"`
+	NewUserId    int64  `header:"newUserId"`
+	IsEnt        bool   `form:"isEnt,optional"`
+	UserType     string `path:"userType,optional"`
+	PositionType int64  `header:"positionType,optional"`
 }
 
-type GetStaffSubscribeDetailReq struct {
-	AppId     string `header:"appId"`
-	EntId     int64  `header:"entId,optional"`
-	EntUserId int64  `header:"entUserId,optional"`
-	Token     string `json:"token,optional"`
+type SetUserReq struct {
+	AppId        string `header:"appId"`
+	EntId        int64  `header:"entId,optional"`
+	EntUserId    int64  `header:"entUserId,optional"`
+	PositionType int64  `header:"positionType,optional"`
+	UserId       string `header:"userId,optional"`
+	Mail         string `json:"mail,optional"`
 }
 
 type StaffSubscribeCommonResp struct {
@@ -192,10 +118,93 @@ type StaffSubscribeCommonResp struct {
 	Data     interface{} `json:"data"`
 }
 
-type BidDistributor struct {
-	AppId     string   `header:"appId"`
-	EntId     string   `header:"entId,optional"`
-	EntUserId string   `header:"entUserId,optional"`
-	Infoids   []string `json:"infoids"`
-	Staffs    string   `json:"staffs"`
+type CommonResp struct {
+	Err_code int64       `json:"error_code"`
+	Err_msg  string      `json:"error_msg"`
+	Data     interface{} `json:"data"`
+	TimeData interface{} `json:"timeData"`
+}
+
+type MsgDistributor struct {
+	AppId     string `header:"appId"`
+	EntId     string `header:"entId,optional"`
+	EntUserId string `header:"entUserId,optional"`
+	MessageId string `json:"messageId"`
+	Staffs    string `json:"staffs"`
+}
+
+type SomeInfoReq struct {
+	AppId        string `header:"appId"`
+	UserType     string `path:"userType"`
+	UserId       string `header:"userId,optional"`
+	NewUserId    string `header:"newUserId,optional"`
+	EntId        string `header:"entId,optional"`
+	AccountId    string `header:"accountId,optional"`
+	PositionType string `header:"positionType,optional"`
+	PositionId   string `header:"positionId,optional"`
+}
+
+type SubscribeReq struct {
+	AppId          string                 `header:"appId"`
+	UserId         string                 `header:"userId"`
+	EntId          string                 `header:"entId,optional"`
+	EntUserId      string                 `header:"entUserId,optional"`
+	DeptId         string                 `header:"deptId,optional"` //部门id
+	PageNum        int64                  `json:"pageNum,optional"`
+	PageSize       int64                  `json:"pageSize,optional"`
+	SelectTime     string                 `json:"selectTime,optional"`
+	Area           string                 `json:"area,optional"`
+	City           string                 `json:"city,optional"`
+	Industry       string                 `json:"industry,optional"`
+	BuyerClass     string                 `json:"buyerClass,optional"`
+	KeyWords       string                 `json:"keyWords,optional"`
+	Subtype        string                 `json:"subtype,optional"`
+	Price          string                 `json:"price,optional"`
+	FileExists     string                 `json:"fileExists,optional"`
+	Source         string                 `json:"source,optional"`                                        //信息来源
+	IsRead         string                 `json:"isRead,optional"`                                        //是否已读
+	Staffs         string                 `json:"staffs,optional"`                                        //分发的员工
+	UserType       string                 `path:"userType,default=fType,options=fType|vType|mType|eType"` //fType:普通用户;vType:超级订阅用户;mType:大会员用户;eType:商机管理用户;
+	NewUserId      int64                  `header:"newUserId"`
+	IsEnt          bool                   `json:"isEnt,optional"`
+	SelectIds      string                 `json:"selectIds,optional"`
+	SelectKeys     string                 `json:"selectKeys,optional"`
+	PositionType   int64                  `header:"positionType,optional"`
+	NotReturnCount int64                  `json:"notReturnCount,optional"`
+	Item           map[string]interface{} `json:"item,optional"`
+	AccountId      string                 `header:"accountId,optional"`
+	PositionId     string                 `header:"positionId,optional"`
+	MgoUserId      string                 `header:"mgoUserId,optional"` //原userId
+	District       string                 `json:"district,optional"`
+}
+
+type SubscribeUpdateReq struct {
+	Area            map[string]interface{}   `json:"area,optional"`            //地区
+	Buyerclass      []string                 `json:"buyerclass,optional"`      //采购单位类型
+	Items           []map[string]interface{} `json:"items,optional"`           //关键词
+	Infotype        []string                 `json:"infotype,optional"`        //信息类型
+	Matchway        string                   `json:"matchway,optional"`        //匹配方式 1标题 2正文
+	Projectmatch    string                   `json:"projectmatch,optional"`    //项目匹配 1开始 0关闭
+	Ratemode        string                   `json:"ratemode,optional"`        // 1:实时推送,2:每天9点推送,3:每周推送,4:每月推送 5:每日推送两次
+	Apppush         string                   `json:"apppush,optional"`         //app推送 1开启 0关闭
+	Mailpush        string                   `json:"mailpush,optional"`        //邮箱推送 1开启 0关闭
+	Mail            string                   `json:"mail,optional"`            //邮箱
+	Otherbuyerclass string                   `json:"otherbuyerclass,optional"` //匹配未分类类型 1匹配 0不匹配
+	AppId           string                   `header:"appId,optional"`
+	UserType        string                   `path:"userType,optional"`
+	UserId          string                   `header:"userId,optional"`
+	PositionType    int64                    `header:"positionType,optional"`
+	NewUserId       int64                    `header:"newUserId,optional"`
+	EntId           int64                    `header:"entId,optional"`
+	AccountId       int64                    `header:"accountId,optional"`
+	PositionId      int64                    `header:"positionId,optional"`
+	District        map[string]interface{}   `json:"district,optional"`
+}
+
+type ViewStatusReq struct {
+	AppId     string `header:"appId"`
+	EntId     string `header:"entId,optional"`
+	EntUserId string `header:"entUserId,optional"`
+	UserType  string `path:"userType,optional"`
+	InfoId    string `json:"infoId,optional"`
 }

+ 4 - 5
jyBXSubscribe/entity/db.go

@@ -6,7 +6,6 @@ type Mongo struct {
 	Bidding *MongoStruct `json:"bidding,optional"`
 }
 
-//
 type MongoStruct struct {
 	Address        string `json:"address"`
 	Size           int    `json:"size"`
@@ -19,14 +18,14 @@ type MongoStruct struct {
 	MaxIdleConns   int    `json:"maxIdleConns,optional"`
 }
 
-//
 type Mysql struct {
 	Main             *MysqlStruct `json:"main,omitempty"`
 	BaseService      *MysqlStruct `json:"baseService,omitempty"`
 	GlobalCommonData *MysqlStruct `json:"globalCommonData,omitempty"`
+	JyCk             *MysqlStruct `json:"jyCk"`
 }
 
-//mysql
+// mysql
 type MysqlStruct struct {
 	DbName       string `json:"dbName"`
 	Address      string `json:"address"`
@@ -36,12 +35,12 @@ type MysqlStruct struct {
 	MaxIdleConns int    `json:"maxIdleConns"`
 }
 
-//redis
+// redis
 type RedisStuct struct {
 	Addr []string `json:"addr"`
 }
 
-//es
+// es
 type EsStruct struct {
 	Addr     string `json:"addr"`
 	Size     int    `json:"size"`

+ 1 - 1
jyBXSubscribe/go.mod

@@ -3,7 +3,7 @@ module jyBXSubscribe
 go 1.19
 
 require (
-	app.yhyue.com/moapp/jybase v0.0.0-20240205092729-2959d78b7619
+	app.yhyue.com/moapp/jybase v0.0.0-20240226084952-7e7b38ef8a66
 	app.yhyue.com/moapp/jylogx v0.0.0-20230522075659-ae6fbedb92bc
 	app.yhyue.com/moapp/jypkg v1.1.7
 	bp.jydev.jianyu360.cn/BaseService/gateway v1.3.4

+ 8 - 0
jyBXSubscribe/go.sum

@@ -1,5 +1,6 @@
 app.yhyue.com/moapp/esv1 v0.0.0-20220414031211-3da4123e648d h1:WPsYuuptAd3UEgN+jPzpnsDe/OvcshDUUtOTZPYGSJ8=
 app.yhyue.com/moapp/esv1 v0.0.0-20220414031211-3da4123e648d/go.mod h1:91/lSD/hS+ckMVP3WdidRzDhC60lLMdyce9QHy0cSMA=
+app.yhyue.com/moapp/jyInfo v1.0.0/go.mod h1:+RjyGNvk7PT1P8cglkVlaj1lLlBXuPB+f5LipoOtgPs=
 app.yhyue.com/moapp/jyMarketing v0.0.2-0.20230304035551-21bb1eedf547 h1:cCmWQW8DUBD2nuZNDz9aIe6MrlioxTbdaA2YiJhlzjY=
 app.yhyue.com/moapp/jyMarketing v0.0.2-0.20230304035551-21bb1eedf547/go.mod h1:JvIs8uKjdT963+7JnZGIEcL4ctBiBjwkoz0kNyigE78=
 app.yhyue.com/moapp/jyPoints v1.1.1/go.mod h1:SvP8p5L3jGrejHiH2LXfgCg/NPlFiKBC5Yd0gsI12FU=
@@ -11,6 +12,8 @@ app.yhyue.com/moapp/jybase v0.0.0-20220427020729-974c1a148186/go.mod h1:qNRA0sHu
 app.yhyue.com/moapp/jybase v0.0.0-20230117032034-ad7c00ffe11a/go.mod h1:zB47XTeJvpcbtBRYgkQuxOICWNexiZfbUO+7aUf6mNs=
 app.yhyue.com/moapp/jybase v0.0.0-20240205092729-2959d78b7619 h1:rzjJ4pK1P+DcoOYA4+hCOJUoLdSInQa3EHsYY2DKWqA=
 app.yhyue.com/moapp/jybase v0.0.0-20240205092729-2959d78b7619/go.mod h1:fjaD11Z3FIk9EyfOpdKAMQNs7nPZCpT/qKIw1oVsb9w=
+app.yhyue.com/moapp/jybase v0.0.0-20240226084952-7e7b38ef8a66 h1:kCRYqzclN4dtGuGC89ID2w5lGrJgqZC8bNL8mRR+tiU=
+app.yhyue.com/moapp/jybase v0.0.0-20240226084952-7e7b38ef8a66/go.mod h1:XHNATN6tsJKHdCB0DbUtFdPPHXexTUFyB3RlO+lUUoM=
 app.yhyue.com/moapp/jylog v0.0.0-20230522075550-05d7230ca545 h1:+Lak4m1zgsigQloOsvp8AJ+0XeX/+PGp9QP550xlbBQ=
 app.yhyue.com/moapp/jylog v0.0.0-20230522075550-05d7230ca545/go.mod h1:uFrsdUBFbETiJlEmr4PtJWPsZlUpPj2bHQRhryu6ggk=
 app.yhyue.com/moapp/jylogx v0.0.0-20230522075659-ae6fbedb92bc h1:QEwc+V6ZTvk3VMFiMgPYJpsAVqRvTeIMupVfpO5PQYk=
@@ -222,6 +225,7 @@ github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYF
 github.com/fatih/color v1.15.0 h1:kOqh6YHBtK8aywxGerMG2Eq3H6Qgoqeo13Bk2Mv/nBs=
 github.com/fatih/color v1.15.0/go.mod h1:0h5ZqXfHYED7Bhv2ZJamyIOUej9KtShiJESRwBDUSsw=
 github.com/fatih/structtag v1.2.0/go.mod h1:mBJUNpUnHmRKrKlQQlmCrh5PuhftFbNv8Ys4/aAZl94=
+github.com/felixge/fgprof v0.9.3/go.mod h1:RdbpDgzqYVh/T9fPELJyV7EYJuHB55UTEULNun8eiPw=
 github.com/form3tech-oss/jwt-go v3.2.2+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k=
 github.com/form3tech-oss/jwt-go v3.2.3+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k=
 github.com/fortytw2/leaktest v1.3.0 h1:u8491cBMTQ8ft8aeV+adlcytMZylmA5nnwwkRZjI8vw=
@@ -234,6 +238,7 @@ github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4
 github.com/fsnotify/fsnotify v1.5.1/go.mod h1:T3375wBYaZdLLcVNkcVbzGHY7f1l/uK5T5Ai1i3InKU=
 github.com/fsnotify/fsnotify v1.6.0 h1:n+5WquG0fcWoWp6xPWfHdbskMCQaFnG6PfBrh1Ky4HY=
 github.com/fsnotify/fsnotify v1.6.0/go.mod h1:sl3t1tCWJFWoRz9R8WJCbQihKKwmorjAbSClcnxKAGw=
+github.com/fullstorydev/grpcurl v1.8.7/go.mod h1:pVtM4qe3CMoLaIzYS8uvTuDj2jVYmXqMUkZeijnXp/E=
 github.com/garyburd/redigo v1.6.2 h1:yE/pwKCrbLpLpQICzYTeZ7JsTA/C53wFTJHaEtRqniM=
 github.com/garyburd/redigo v1.6.2/go.mod h1:NR3MbYisc3/PwhQ00EMzDiPmrwpPxAn5GI05/YaO1SY=
 github.com/ghodss/yaml v0.0.0-20150909031657-73d445a93680/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04=
@@ -251,6 +256,7 @@ github.com/go-kit/log v0.1.0/go.mod h1:zbhenjAZHb184qTLMA9ZjW7ThYL0H2mk7Q6pNt4vb
 github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE=
 github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk=
 github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG1KdI/P7A=
+github.com/go-logfmt/logfmt v0.5.1/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs=
 github.com/go-logr/logr v0.1.0/go.mod h1:ixOQHD9gLJUVQQ2ZOR7zLEifBX6tGkNJF4QyIY7sIas=
 github.com/go-logr/logr v0.2.0/go.mod h1:z6/tIYblkpsD+a4lm/fGIIU9mZ+XfAiaFtq7xTgseGU=
 github.com/go-logr/logr v0.4.0/go.mod h1:z6/tIYblkpsD+a4lm/fGIIU9mZ+XfAiaFtq7xTgseGU=
@@ -420,6 +426,7 @@ github.com/google/pprof v0.0.0-20201023163331-3e6fc7fc9c4c/go.mod h1:kpwsk12EmLe
 github.com/google/pprof v0.0.0-20201203190320-1bf35d6f28c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
 github.com/google/pprof v0.0.0-20201218002935-b9804c9f04c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
 github.com/google/pprof v0.0.0-20210407192527-94a9f03dee38/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
+github.com/google/pprof v0.0.0-20211214055906-6f57359322fd/go.mod h1:KgnwoLYCZ8IQu3XUZ8Nc/bM9CCZFOyjUNOSygVozoDg=
 github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI=
 github.com/google/uuid v1.0.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
 github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
@@ -1286,6 +1293,7 @@ golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8T
 golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
 golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
 golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
+golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8=
 google.golang.org/api v0.3.1/go.mod h1:6wY9I6uQWHQ8EM57III9mq/AjF+i8G65rmVagqKMtkk=
 google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE=
 google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M=

+ 11 - 0
jyBXSubscribe/rpc/bxsubscribe.proto

@@ -410,6 +410,15 @@ message BidDistributorReq{
   string  staffs = 5; //分发的员工
 }
 
+message BidRecListReq {
+  string  appId = 1;
+  string  entId = 2;
+  string  sPath = 3;
+  string  userId = 4;
+  string  entUserId = 5;
+  int64  positionType = 6;
+}
+
 
 service Bxsubscribe {
   //获取订阅推送列表
@@ -446,4 +455,6 @@ service Bxsubscribe {
   rpc getStaffSubscribeDetail(StaffSubscribeDetailReq)returns(StaffSubscribeDetail);
   //标讯信息分发
   rpc bidDistributor(BidDistributorReq)returns(StatusResp);
+  // 订阅推荐列表
+  rpc bidRecList(BidRecListReq)returns(SubscribeInfosResp);
 }

+ 9 - 0
jyBXSubscribe/rpc/bxsubscribe/bxsubscribe.go

@@ -14,6 +14,7 @@ import (
 
 type (
 	BidDistributorReq       = bxsubscribe.BidDistributorReq
+	BidRecListReq           = bxsubscribe.BidRecListReq
 	ByPushHistoryResp       = bxsubscribe.ByPushHistoryResp
 	CityList                = bxsubscribe.CityList
 	DistributorResp         = bxsubscribe.DistributorResp
@@ -94,6 +95,8 @@ type (
 		GetStaffSubscribeDetail(ctx context.Context, in *StaffSubscribeDetailReq, opts ...grpc.CallOption) (*StaffSubscribeDetail, error)
 		// 标讯信息分发
 		BidDistributor(ctx context.Context, in *BidDistributorReq, opts ...grpc.CallOption) (*StatusResp, error)
+		// 订阅推荐列表
+		BidRecList(ctx context.Context, in *BidRecListReq, opts ...grpc.CallOption) (*SubscribeInfosResp, error)
 	}
 
 	defaultBxsubscribe struct {
@@ -208,3 +211,9 @@ func (m *defaultBxsubscribe) BidDistributor(ctx context.Context, in *BidDistribu
 	client := bxsubscribe.NewBxsubscribeClient(m.cli.Conn())
 	return client.BidDistributor(ctx, in, opts...)
 }
+
+// 订阅推荐列表
+func (m *defaultBxsubscribe) BidRecList(ctx context.Context, in *BidRecListReq, opts ...grpc.CallOption) (*SubscribeInfosResp, error) {
+	client := bxsubscribe.NewBxsubscribeClient(m.cli.Conn())
+	return client.BidRecList(ctx, in, opts...)
+}

+ 7 - 0
jyBXSubscribe/rpc/etc/db.yaml

@@ -20,6 +20,13 @@ mysql:
         password: '=PDT49#80Z!RVv52_z'
         maxOpenConns: 5
         maxIdleConns: 5
+    jyCk:
+        address: 192.168.3.207:19000
+        dbName: jianyu
+        userName: jytop
+        password: 'pwdTopJy123'
+        maxOpenConns: 5
+        maxIdleConns: 5
 redis:
     addr:
         - other=192.168.3.149:1712

+ 11 - 4
jyBXSubscribe/rpc/init/db.go

@@ -4,6 +4,7 @@
 package init
 
 import (
+	"fmt"
 	"strings"
 
 	elastic "app.yhyue.com/moapp/jybase/es"
@@ -26,11 +27,11 @@ var (
 	MgoBidding       mongodb.MongodbSim
 	GlobalCommonData *mysql.Mysql
 	MgoLog           mongodb.MongodbSim
+	CkJy             *mysql.Mysql
 )
 var Middleground *middleground.Middleground
 var Compatible *compatible.Compatible
 
-//
 func MongoDBInit(em *entity.Mongo) {
 	//初始化 mongodb
 	if em.Main.Address != "" {
@@ -68,7 +69,6 @@ func MongoDBInit(em *entity.Mongo) {
 	}
 }
 
-//
 func MysqlInit(mm *entity.Mysql) {
 	//初始化 mysql-main
 	if mm.Main.Address != "" {
@@ -112,7 +112,6 @@ func MysqlInit(mm *entity.Mysql) {
 	P.BidCodeMapping.Init(BaseServiceMysql)
 }
 
-//
 func RedisInit(rm *entity.RedisStuct) {
 	//初始化 redis
 	if len(rm.Addr) > 0 {
@@ -121,7 +120,6 @@ func RedisInit(rm *entity.RedisStuct) {
 	}
 }
 
-//
 func EsInit(es *entity.EsStruct) {
 	//初始化 elasticsearch
 	if es.Addr != "" {
@@ -129,3 +127,12 @@ func EsInit(es *entity.EsStruct) {
 		elastic.NewEs(es.Version, es.Addr, es.Size, es.UserName, es.Password)
 	}
 }
+
+// clickhouse init
+func CkInit(ck *entity.Mysql) {
+	if ck.JyCk.Address != "" {
+		logx.Info("--初始化 jy clickhouse--")
+		CkJy = mysql.NewInit(mysql.CLICKHOUSE, fmt.Sprintf("%s:%s@tcp(%s)/%s?charset=utf8mb4", ck.JyCk.UserName, ck.JyCk.Password, ck.JyCk.Address, ck.JyCk.DbName),
+			ck.JyCk.MaxOpenConns, ck.JyCk.MaxIdleConns)
+	}
+}

+ 1 - 0
jyBXSubscribe/rpc/init/init.go

@@ -26,6 +26,7 @@ func InitC() {
 	RedisInit(&DB.Redis)
 	//初始es
 	EsInit(&DB.Es)
+	CkInit(&DB.Mysql)
 	Middleground = middleground.NewMiddleground(C.CodeServiceConf.Etcd.Hosts).
 		RegUserCenter(C.UserCenterKey).
 		RegPowerCheckCenter(C.PowerCheckCenterKey).

+ 5 - 4
jyBXSubscribe/rpc/internal/config/config.go

@@ -25,8 +25,9 @@ type Config struct {
 }
 
 type Db struct {
-	Mysql entity.Mysql      `json:"mysql"`
-	Redis entity.RedisStuct `json:"redis"`
-	Es    entity.EsStruct   `json:"es"`
-	Mongo entity.Mongo      `json:"mongo"`
+	Mysql      entity.Mysql      `json:"mysql"`
+	Redis      entity.RedisStuct `json:"redis"`
+	Es         entity.EsStruct   `json:"es"`
+	Mongo      entity.Mongo      `json:"mongo"`
+	ClickHouse entity.Mysql      `json:"clickhouse"`
 }

+ 43 - 0
jyBXSubscribe/rpc/internal/logic/bidreclistlogic.go

@@ -0,0 +1,43 @@
+package logic
+
+import (
+	"app.yhyue.com/moapp/jybase/common"
+	"context"
+	"jyBXSubscribe/rpc/internal/svc"
+	"jyBXSubscribe/rpc/model"
+	"jyBXSubscribe/rpc/type/bxsubscribe"
+
+	"github.com/zeromicro/go-zero/core/logx"
+)
+
+type BidRecListLogic struct {
+	ctx    context.Context
+	svcCtx *svc.ServiceContext
+	logx.Logger
+}
+
+func NewBidRecListLogic(ctx context.Context, svcCtx *svc.ServiceContext) *BidRecListLogic {
+	return &BidRecListLogic{
+		ctx:    ctx,
+		svcCtx: svcCtx,
+		Logger: logx.WithContext(ctx),
+	}
+}
+
+// 订阅推荐列表
+func (l *BidRecListLogic) BidRecList(in *bxsubscribe.BidRecListReq) (*bxsubscribe.SubscribeInfosResp, error) {
+	var list []*bxsubscribe.SubscribeInfo
+	hasNextPage, total, list := model.NewSubscribePush("").SubRecList(common.ObjToString(common.If(in.PositionType == 0, in.UserId, in.EntUserId)), []model.ViewKeyWord{})
+	if len(list) == 0 && in.SPath == "1" { // 订阅更多
+		hasNextPage, total, list = model.NewSubscribePush("").GetRecListByEs()
+	}
+	return &bxsubscribe.SubscribeInfosResp{
+		ErrCode: 0,
+		ErrMsg:  "",
+		Data: &bxsubscribe.SubscribeData{
+			List:        list,
+			Count:       total,
+			HasNextPage: hasNextPage,
+		},
+	}, nil
+}

+ 6 - 0
jyBXSubscribe/rpc/internal/logic/getsublistlogic.go

@@ -117,6 +117,12 @@ func (l *GetSubListLogic) GetSubList(in *bxsubscribe.SubscribeInfosReq) (*bxsubs
 	 */
 	if in.PageNum == 1 && spqp.IsEmpty() && (len(list) == 0 || (in.PositionType == 0 && spqp.SubPushInactive == -1)) && in.IsEnt == false {
 		hasNextPage, total, list = model.NewSubscribePush(in.UserType).DefaultDatas(spqp, bsp, in.UserType)
+		if len(list) == 0 {
+			hasNextPage, total, list = model.NewSubscribePush(in.UserType).SubRecList(common.ObjToString(common.If(in.PositionType == 0, spqp.UserId, spqp.EntUserId)), bsp.Keyword)
+		}
+		if len(list) == 0 {
+			hasNextPage, total, list = model.NewSubscribePush(in.UserType).GetRecListByEs()
+		}
 	}
 	start2 := time.Now().Unix()
 	logx.Info("2、查询数据用户", start2-start1)

+ 6 - 0
jyBXSubscribe/rpc/internal/server/bxsubscribeserver.go

@@ -123,3 +123,9 @@ func (s *BxsubscribeServer) BidDistributor(ctx context.Context, in *bxsubscribe.
 	l := logic.NewBidDistributorLogic(ctx, s.svcCtx)
 	return l.BidDistributor(in)
 }
+
+// 订阅推荐列表
+func (s *BxsubscribeServer) BidRecList(ctx context.Context, in *bxsubscribe.BidRecListReq) (*bxsubscribe.SubscribeInfosResp, error) {
+	l := logic.NewBidRecListLogic(ctx, s.svcCtx)
+	return l.BidRecList(in)
+}

+ 70 - 0
jyBXSubscribe/rpc/model/push.go

@@ -2239,3 +2239,73 @@ func (s *SubPushQueryParam) ExportPushFormat() (ids, keyWords []string) {
 	}
 	return
 }
+
+// @Author jianghan
+// @Description	clickhouse获取推荐的列表数据
+// @Date 2024/3/11
+func (s *subscribePush) SubRecList(userId string, keyword []ViewKeyWord) (hasNextPage bool, total int64, resultList []*bxsubscribe.SubscribeInfo) {
+	sql := "select bitmapToArray(infoids) infoids, userid from jianyu.sub_recommend_list where userid = ?"
+	infos := IC.CkJy.SelectBySql(sql, userId)
+	if infos != nil && len(*infos) > 0 {
+		if ids, ok := (*infos)[0]["infoids"].([]interface{}); ok && len(ids) > 0 {
+			length := len(ids)
+			resultList = make([]*bxsubscribe.SubscribeInfo, length)
+			for i, id := range ids {
+				info, b := IC.MgoBidding.FindOneByField("bidding", bson.M{"autoid": id}, bidField)
+				if b && info != nil && len(*info) > 0 {
+					title := strings.Replace(common.ObjToString((*info)["title"]), " ", "", -1)
+					matchkeys := getKeys(title, keyword)
+					resultList[i] = s.InfoFormat(&PushCa{
+						InfoId:     mongodb.BsonIdToSId((*info)["_id"]),
+						Date:       time.Now().Unix(),
+						Keys:       matchkeys,
+						FileExists: (*info)["filetext"] != nil,
+					}, info, false)
+				}
+			}
+			total = int64(len(resultList))
+			if total > pageSize {
+				resultList = resultList[:pageSize]
+				hasNextPage = true
+			}
+		}
+	}
+	return
+}
+
+// @Author jianghan
+// @Description es获取最新10条数据
+// @Date 2024/3/13
+func (s *subscribePush) GetRecListByEs() (hasNextPage bool, total int64, resultList []*bxsubscribe.SubscribeInfo) {
+	resultList = make([]*bxsubscribe.SubscribeInfo, 10)
+	if jsonStr := redis.GetStr("pushcache_2_c", "bid_sub_recommend"); jsonStr != "" {
+		var data []map[string]interface{}
+		_ = json.Unmarshal([]byte(jsonStr), &data)
+		for i := 0; i < 10; i++ {
+			resultList[i] = s.InfoFormat(&PushCa{
+				InfoId:     common.ObjToString(data[i]["_id"]),
+				Date:       time.Now().Unix(),
+				Keys:       []string{},
+				FileExists: data[i]["filetext"] != nil,
+			}, &data[i], false)
+		}
+	} else {
+		qstr := `{"query": {"bool": {"must": [{"match_all": {}}]}},"sort": {"publishtime": {"order": "desc"}},"from": 0,"size": 10}`
+		list := elastic.GetAllByNgram(INDEX, TYPE, qstr, findfields, bidSort, bidField, 0, 10, 10, false)
+		redis.Put("pushcache_2_c", "bid_sub_recommend", 1, 86400)
+		for i := 0; i < len(*list); i++ {
+			resultList[i] = s.InfoFormat(&PushCa{
+				InfoId:     common.ObjToString((*list)[i]["_id"]),
+				Date:       time.Now().Unix(),
+				Keys:       []string{},
+				FileExists: (*list)[i]["filetext"] != nil,
+			}, &(*list)[i], false)
+		}
+	}
+	total = int64(len(resultList))
+	if total > pageSize {
+		resultList = resultList[:pageSize]
+		hasNextPage = true
+	}
+	return
+}

+ 228 - 121
jyBXSubscribe/rpc/type/bxsubscribe/bxsubscribe.pb.go

@@ -1,7 +1,7 @@
 // Code generated by protoc-gen-go. DO NOT EDIT.
 // versions:
-// 	protoc-gen-go v1.31.0
-// 	protoc        v3.15.1
+// 	protoc-gen-go v1.32.0
+// 	protoc        v4.25.2
 // source: bxsubscribe.proto
 
 //import "google/protobuf/struct.proto";
@@ -3347,7 +3347,6 @@ type PushSet struct {
 	IRatemode   int64    `protobuf:"varint,5,opt,name=i_ratemode,json=iRatemode,proto3" json:"i_ratemode,omitempty"`
 	IsWxShow    int64    `protobuf:"varint,6,opt,name=isWxShow,proto3" json:"isWxShow,omitempty"`
 	Interested  int64    `protobuf:"varint,7,opt,name=interested,proto3" json:"interested,omitempty"`
-	IsMailShow  int64    `protobuf:"varint,8,opt,name=isMailShow,proto3" json:"isMailShow,omitempty"`
 	INomsgtip   int64    `protobuf:"varint,9,opt,name=i_nomsgtip,json=iNomsgtip,proto3" json:"i_nomsgtip,omitempty"`
 	IApppushTip int64    `protobuf:"varint,10,opt,name=i_apppush_tip,json=iApppushTip,proto3" json:"i_apppush_tip,omitempty"`
 }
@@ -3433,13 +3432,6 @@ func (x *PushSet) GetInterested() int64 {
 	return 0
 }
 
-func (x *PushSet) GetIsMailShow() int64 {
-	if x != nil {
-		return x.IsMailShow
-	}
-	return 0
-}
-
 func (x *PushSet) GetINomsgtip() int64 {
 	if x != nil {
 		return x.INomsgtip
@@ -4047,6 +4039,93 @@ func (x *BidDistributorReq) GetStaffs() string {
 	return ""
 }
 
+type BidRecListReq struct {
+	state         protoimpl.MessageState
+	sizeCache     protoimpl.SizeCache
+	unknownFields protoimpl.UnknownFields
+
+	AppId        string `protobuf:"bytes,1,opt,name=appId,proto3" json:"appId,omitempty"`
+	EntId        string `protobuf:"bytes,2,opt,name=entId,proto3" json:"entId,omitempty"`
+	SPath        string `protobuf:"bytes,3,opt,name=sPath,proto3" json:"sPath,omitempty"`
+	UserId       string `protobuf:"bytes,4,opt,name=userId,proto3" json:"userId,omitempty"`
+	EntUserId    string `protobuf:"bytes,5,opt,name=entUserId,proto3" json:"entUserId,omitempty"`
+	PositionType int64  `protobuf:"varint,6,opt,name=positionType,proto3" json:"positionType,omitempty"`
+}
+
+func (x *BidRecListReq) Reset() {
+	*x = BidRecListReq{}
+	if protoimpl.UnsafeEnabled {
+		mi := &file_bxsubscribe_proto_msgTypes[45]
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		ms.StoreMessageInfo(mi)
+	}
+}
+
+func (x *BidRecListReq) String() string {
+	return protoimpl.X.MessageStringOf(x)
+}
+
+func (*BidRecListReq) ProtoMessage() {}
+
+func (x *BidRecListReq) ProtoReflect() protoreflect.Message {
+	mi := &file_bxsubscribe_proto_msgTypes[45]
+	if protoimpl.UnsafeEnabled && x != nil {
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		if ms.LoadMessageInfo() == nil {
+			ms.StoreMessageInfo(mi)
+		}
+		return ms
+	}
+	return mi.MessageOf(x)
+}
+
+// Deprecated: Use BidRecListReq.ProtoReflect.Descriptor instead.
+func (*BidRecListReq) Descriptor() ([]byte, []int) {
+	return file_bxsubscribe_proto_rawDescGZIP(), []int{45}
+}
+
+func (x *BidRecListReq) GetAppId() string {
+	if x != nil {
+		return x.AppId
+	}
+	return ""
+}
+
+func (x *BidRecListReq) GetEntId() string {
+	if x != nil {
+		return x.EntId
+	}
+	return ""
+}
+
+func (x *BidRecListReq) GetSPath() string {
+	if x != nil {
+		return x.SPath
+	}
+	return ""
+}
+
+func (x *BidRecListReq) GetUserId() string {
+	if x != nil {
+		return x.UserId
+	}
+	return ""
+}
+
+func (x *BidRecListReq) GetEntUserId() string {
+	if x != nil {
+		return x.EntUserId
+	}
+	return ""
+}
+
+func (x *BidRecListReq) GetPositionType() int64 {
+	if x != nil {
+		return x.PositionType
+	}
+	return 0
+}
+
 var File_bxsubscribe_proto protoreflect.FileDescriptor
 
 var file_bxsubscribe_proto_rawDesc = []byte{
@@ -4518,7 +4597,7 @@ var file_bxsubscribe_proto_rawDesc = []byte{
 	0x6e, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x23, 0x0a, 0x08,
 	0x54, 0x69, 0x6d, 0x65, 0x4a, 0x73, 0x6f, 0x6e, 0x12, 0x17, 0x0a, 0x07, 0x61, 0x5f, 0x74, 0x69,
 	0x6d, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x06, 0x61, 0x54, 0x69, 0x6d, 0x65,
-	0x73, 0x22, 0xb7, 0x02, 0x0a, 0x07, 0x50, 0x75, 0x73, 0x68, 0x53, 0x65, 0x74, 0x12, 0x17, 0x0a,
+	0x73, 0x22, 0x97, 0x02, 0x0a, 0x07, 0x50, 0x75, 0x73, 0x68, 0x53, 0x65, 0x74, 0x12, 0x17, 0x0a,
 	0x07, 0x61, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x06,
 	0x61, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x12, 0x19, 0x0a, 0x08, 0x69, 0x5f, 0x77, 0x78, 0x70, 0x75,
 	0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x69, 0x57, 0x78, 0x70, 0x75, 0x73,
@@ -4531,9 +4610,7 @@ var file_bxsubscribe_proto_rawDesc = []byte{
 	0x69, 0x73, 0x57, 0x78, 0x53, 0x68, 0x6f, 0x77, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08,
 	0x69, 0x73, 0x57, 0x78, 0x53, 0x68, 0x6f, 0x77, 0x12, 0x1e, 0x0a, 0x0a, 0x69, 0x6e, 0x74, 0x65,
 	0x72, 0x65, 0x73, 0x74, 0x65, 0x64, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x69, 0x6e,
-	0x74, 0x65, 0x72, 0x65, 0x73, 0x74, 0x65, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x69, 0x73, 0x4d, 0x61,
-	0x69, 0x6c, 0x53, 0x68, 0x6f, 0x77, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x69, 0x73,
-	0x4d, 0x61, 0x69, 0x6c, 0x53, 0x68, 0x6f, 0x77, 0x12, 0x1d, 0x0a, 0x0a, 0x69, 0x5f, 0x6e, 0x6f,
+	0x74, 0x65, 0x72, 0x65, 0x73, 0x74, 0x65, 0x64, 0x12, 0x1d, 0x0a, 0x0a, 0x69, 0x5f, 0x6e, 0x6f,
 	0x6d, 0x73, 0x67, 0x74, 0x69, 0x70, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x69, 0x4e,
 	0x6f, 0x6d, 0x73, 0x67, 0x74, 0x69, 0x70, 0x12, 0x22, 0x0a, 0x0d, 0x69, 0x5f, 0x61, 0x70, 0x70,
 	0x70, 0x75, 0x73, 0x68, 0x5f, 0x74, 0x69, 0x70, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b,
@@ -4612,89 +4689,104 @@ var file_bxsubscribe_proto_rawDesc = []byte{
 	0x64, 0x12, 0x18, 0x0a, 0x07, 0x69, 0x6e, 0x66, 0x6f, 0x49, 0x64, 0x73, 0x18, 0x04, 0x20, 0x03,
 	0x28, 0x09, 0x52, 0x07, 0x69, 0x6e, 0x66, 0x6f, 0x49, 0x64, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x73,
 	0x74, 0x61, 0x66, 0x66, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x73, 0x74, 0x61,
-	0x66, 0x66, 0x73, 0x32, 0x86, 0x0a, 0x0a, 0x0b, 0x42, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72,
-	0x69, 0x62, 0x65, 0x12, 0x4d, 0x0a, 0x0a, 0x47, 0x65, 0x74, 0x53, 0x75, 0x62, 0x4c, 0x69, 0x73,
-	0x74, 0x12, 0x1e, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e,
-	0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x73, 0x52, 0x65,
-	0x71, 0x1a, 0x1f, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e,
-	0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x73, 0x52, 0x65,
-	0x73, 0x70, 0x12, 0x45, 0x0a, 0x0e, 0x47, 0x65, 0x74, 0x53, 0x75, 0x62, 0x53, 0x6f, 0x6d, 0x65,
-	0x49, 0x6e, 0x66, 0x6f, 0x12, 0x18, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69,
-	0x62, 0x65, 0x2e, 0x53, 0x6f, 0x6d, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x71, 0x1a, 0x19,
-	0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x6f, 0x6d,
-	0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x73, 0x70, 0x12, 0x53, 0x0a, 0x13, 0x55, 0x70, 0x64,
-	0x61, 0x74, 0x65, 0x53, 0x75, 0x62, 0x53, 0x63, 0x72, 0x69, 0x62, 0x65, 0x49, 0x6e, 0x66, 0x6f,
-	0x12, 0x23, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x55,
-	0x70, 0x64, 0x61, 0x74, 0x65, 0x53, 0x75, 0x62, 0x53, 0x63, 0x72, 0x69, 0x62, 0x65, 0x49, 0x6e,
-	0x66, 0x6f, 0x52, 0x65, 0x71, 0x1a, 0x17, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72,
-	0x69, 0x62, 0x65, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x70, 0x12, 0x4f,
-	0x0a, 0x0d, 0x42, 0x79, 0x50, 0x75, 0x73, 0x68, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x12,
+	0x66, 0x66, 0x73, 0x22, 0xab, 0x01, 0x0a, 0x0d, 0x42, 0x69, 0x64, 0x52, 0x65, 0x63, 0x4c, 0x69,
+	0x73, 0x74, 0x52, 0x65, 0x71, 0x12, 0x14, 0x0a, 0x05, 0x61, 0x70, 0x70, 0x49, 0x64, 0x18, 0x01,
+	0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x61, 0x70, 0x70, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x65,
+	0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x65, 0x6e, 0x74, 0x49,
+	0x64, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x50, 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09,
+	0x52, 0x05, 0x73, 0x50, 0x61, 0x74, 0x68, 0x12, 0x16, 0x0a, 0x06, 0x75, 0x73, 0x65, 0x72, 0x49,
+	0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x75, 0x73, 0x65, 0x72, 0x49, 0x64, 0x12,
+	0x1c, 0x0a, 0x09, 0x65, 0x6e, 0x74, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x18, 0x05, 0x20, 0x01,
+	0x28, 0x09, 0x52, 0x09, 0x65, 0x6e, 0x74, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x12, 0x22, 0x0a,
+	0x0c, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x18, 0x06, 0x20,
+	0x01, 0x28, 0x03, 0x52, 0x0c, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x79, 0x70,
+	0x65, 0x32, 0xd1, 0x0a, 0x0a, 0x0b, 0x42, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62,
+	0x65, 0x12, 0x4d, 0x0a, 0x0a, 0x47, 0x65, 0x74, 0x53, 0x75, 0x62, 0x4c, 0x69, 0x73, 0x74, 0x12,
 	0x1e, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x75,
 	0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x73, 0x52, 0x65, 0x71, 0x1a,
-	0x1e, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x42, 0x79,
-	0x50, 0x75, 0x73, 0x68, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x52, 0x65, 0x73, 0x70, 0x12,
-	0x3b, 0x0a, 0x07, 0x53, 0x65, 0x74, 0x52, 0x65, 0x61, 0x64, 0x12, 0x17, 0x2e, 0x62, 0x78, 0x73,
-	0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x65, 0x74, 0x52, 0x65, 0x61, 0x64,
-	0x52, 0x65, 0x71, 0x1a, 0x17, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62,
-	0x65, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x70, 0x12, 0x36, 0x0a, 0x06,
-	0x47, 0x65, 0x74, 0x4b, 0x65, 0x79, 0x12, 0x16, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63,
-	0x72, 0x69, 0x62, 0x65, 0x2e, 0x47, 0x65, 0x74, 0x4b, 0x65, 0x79, 0x52, 0x65, 0x71, 0x1a, 0x14,
-	0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x4b, 0x65, 0x79,
-	0x52, 0x65, 0x73, 0x70, 0x12, 0x3f, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x53, 0x75, 0x62, 0x53, 0x63,
-	0x72, 0x69, 0x62, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x14, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62,
-	0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x55, 0x73, 0x65, 0x72, 0x52, 0x65, 0x71, 0x1a, 0x15,
-	0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x55, 0x73, 0x65,
-	0x72, 0x52, 0x65, 0x73, 0x71, 0x12, 0x49, 0x0a, 0x0e, 0x4d, 0x73, 0x67, 0x44, 0x69, 0x73, 0x74,
-	0x72, 0x69, 0x62, 0x75, 0x74, 0x6f, 0x72, 0x12, 0x1e, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73,
-	0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x4d, 0x73, 0x67, 0x44, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62,
-	0x75, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x71, 0x1a, 0x17, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73,
-	0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x70,
-	0x12, 0x4e, 0x0a, 0x0e, 0x47, 0x65, 0x74, 0x44, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74,
-	0x6f, 0x72, 0x12, 0x1e, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65,
-	0x2e, 0x47, 0x65, 0x74, 0x44, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x6f, 0x72, 0x52,
-	0x65, 0x71, 0x1a, 0x1c, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65,
-	0x2e, 0x44, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x70,
-	0x12, 0x4b, 0x0a, 0x0d, 0x47, 0x65, 0x74, 0x56, 0x69, 0x65, 0x77, 0x53, 0x74, 0x61, 0x74, 0x75,
-	0x73, 0x12, 0x1d, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e,
-	0x47, 0x65, 0x74, 0x56, 0x69, 0x65, 0x77, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x71,
-	0x1a, 0x1b, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x56,
-	0x69, 0x65, 0x77, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x70, 0x12, 0x45, 0x0a,
-	0x08, 0x75, 0x73, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x1b, 0x2e, 0x62, 0x78, 0x73, 0x75,
-	0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x47, 0x65, 0x74, 0x55, 0x73, 0x65, 0x72, 0x49,
-	0x6e, 0x66, 0x6f, 0x52, 0x65, 0x71, 0x1a, 0x1c, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63,
-	0x72, 0x69, 0x62, 0x65, 0x2e, 0x47, 0x65, 0x74, 0x55, 0x73, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f,
-	0x52, 0x65, 0x73, 0x71, 0x12, 0x3f, 0x0a, 0x07, 0x73, 0x65, 0x74, 0x55, 0x73, 0x65, 0x72, 0x12,
-	0x1b, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x65,
-	0x74, 0x55, 0x73, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x71, 0x1a, 0x17, 0x2e, 0x62,
-	0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x75,
-	0x73, 0x52, 0x65, 0x73, 0x70, 0x12, 0x45, 0x0a, 0x0a, 0x67, 0x65, 0x74, 0x50, 0x75, 0x73, 0x68,
-	0x53, 0x65, 0x74, 0x12, 0x1a, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62,
-	0x65, 0x2e, 0x47, 0x65, 0x74, 0x50, 0x75, 0x73, 0x68, 0x53, 0x65, 0x74, 0x52, 0x65, 0x71, 0x1a,
-	0x1b, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x47, 0x65,
-	0x74, 0x50, 0x75, 0x73, 0x68, 0x53, 0x65, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x41, 0x0a, 0x0a,
-	0x73, 0x65, 0x74, 0x50, 0x75, 0x73, 0x68, 0x53, 0x65, 0x74, 0x12, 0x1a, 0x2e, 0x62, 0x78, 0x73,
-	0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x65, 0x74, 0x50, 0x75, 0x73, 0x68,
-	0x53, 0x65, 0x74, 0x52, 0x65, 0x71, 0x1a, 0x17, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63,
-	0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x70, 0x12,
-	0x5c, 0x0a, 0x15, 0x67, 0x65, 0x74, 0x53, 0x74, 0x61, 0x66, 0x66, 0x53, 0x75, 0x62, 0x73, 0x63,
-	0x72, 0x69, 0x62, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x1e, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62,
-	0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x74, 0x61, 0x66, 0x66, 0x53, 0x75, 0x62, 0x73,
-	0x63, 0x72, 0x69, 0x62, 0x65, 0x52, 0x65, 0x71, 0x1a, 0x23, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62,
-	0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x74, 0x61, 0x66, 0x66, 0x53, 0x75, 0x62, 0x73,
-	0x63, 0x72, 0x69, 0x62, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x62, 0x0a,
-	0x17, 0x67, 0x65, 0x74, 0x53, 0x74, 0x61, 0x66, 0x66, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69,
-	0x62, 0x65, 0x44, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x12, 0x24, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62,
-	0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x74, 0x61, 0x66, 0x66, 0x53, 0x75, 0x62, 0x73,
-	0x63, 0x72, 0x69, 0x62, 0x65, 0x44, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x52, 0x65, 0x71, 0x1a, 0x21,
-	0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x74, 0x61,
-	0x66, 0x66, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x44, 0x65, 0x74, 0x61, 0x69,
-	0x6c, 0x12, 0x49, 0x0a, 0x0e, 0x62, 0x69, 0x64, 0x44, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75,
-	0x74, 0x6f, 0x72, 0x12, 0x1e, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62,
-	0x65, 0x2e, 0x42, 0x69, 0x64, 0x44, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x6f, 0x72,
+	0x1f, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x75,
+	0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x73, 0x52, 0x65, 0x73, 0x70,
+	0x12, 0x45, 0x0a, 0x0e, 0x47, 0x65, 0x74, 0x53, 0x75, 0x62, 0x53, 0x6f, 0x6d, 0x65, 0x49, 0x6e,
+	0x66, 0x6f, 0x12, 0x18, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65,
+	0x2e, 0x53, 0x6f, 0x6d, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x71, 0x1a, 0x19, 0x2e, 0x62,
+	0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x6f, 0x6d, 0x65, 0x49,
+	0x6e, 0x66, 0x6f, 0x52, 0x65, 0x73, 0x70, 0x12, 0x53, 0x0a, 0x13, 0x55, 0x70, 0x64, 0x61, 0x74,
+	0x65, 0x53, 0x75, 0x62, 0x53, 0x63, 0x72, 0x69, 0x62, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x23,
+	0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x55, 0x70, 0x64,
+	0x61, 0x74, 0x65, 0x53, 0x75, 0x62, 0x53, 0x63, 0x72, 0x69, 0x62, 0x65, 0x49, 0x6e, 0x66, 0x6f,
 	0x52, 0x65, 0x71, 0x1a, 0x17, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62,
-	0x65, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x70, 0x42, 0x0f, 0x5a, 0x0d,
-	0x2e, 0x2f, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x62, 0x06, 0x70,
-	0x72, 0x6f, 0x74, 0x6f, 0x33,
+	0x65, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x70, 0x12, 0x4f, 0x0a, 0x0d,
+	0x42, 0x79, 0x50, 0x75, 0x73, 0x68, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x12, 0x1e, 0x2e,
+	0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x75, 0x62, 0x73,
+	0x63, 0x72, 0x69, 0x62, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x73, 0x52, 0x65, 0x71, 0x1a, 0x1e, 0x2e,
+	0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x42, 0x79, 0x50, 0x75,
+	0x73, 0x68, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x52, 0x65, 0x73, 0x70, 0x12, 0x3b, 0x0a,
+	0x07, 0x53, 0x65, 0x74, 0x52, 0x65, 0x61, 0x64, 0x12, 0x17, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62,
+	0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x65, 0x74, 0x52, 0x65, 0x61, 0x64, 0x52, 0x65,
+	0x71, 0x1a, 0x17, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e,
+	0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x70, 0x12, 0x36, 0x0a, 0x06, 0x47, 0x65,
+	0x74, 0x4b, 0x65, 0x79, 0x12, 0x16, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69,
+	0x62, 0x65, 0x2e, 0x47, 0x65, 0x74, 0x4b, 0x65, 0x79, 0x52, 0x65, 0x71, 0x1a, 0x14, 0x2e, 0x62,
+	0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x4b, 0x65, 0x79, 0x52, 0x65,
+	0x73, 0x70, 0x12, 0x3f, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x53, 0x75, 0x62, 0x53, 0x63, 0x72, 0x69,
+	0x62, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x14, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63,
+	0x72, 0x69, 0x62, 0x65, 0x2e, 0x55, 0x73, 0x65, 0x72, 0x52, 0x65, 0x71, 0x1a, 0x15, 0x2e, 0x62,
+	0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x55, 0x73, 0x65, 0x72, 0x52,
+	0x65, 0x73, 0x71, 0x12, 0x49, 0x0a, 0x0e, 0x4d, 0x73, 0x67, 0x44, 0x69, 0x73, 0x74, 0x72, 0x69,
+	0x62, 0x75, 0x74, 0x6f, 0x72, 0x12, 0x1e, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72,
+	0x69, 0x62, 0x65, 0x2e, 0x4d, 0x73, 0x67, 0x44, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74,
+	0x6f, 0x72, 0x52, 0x65, 0x71, 0x1a, 0x17, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72,
+	0x69, 0x62, 0x65, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x70, 0x12, 0x4e,
+	0x0a, 0x0e, 0x47, 0x65, 0x74, 0x44, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x6f, 0x72,
+	0x12, 0x1e, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x47,
+	0x65, 0x74, 0x44, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x71,
+	0x1a, 0x1c, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x44,
+	0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x70, 0x12, 0x4b,
+	0x0a, 0x0d, 0x47, 0x65, 0x74, 0x56, 0x69, 0x65, 0x77, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12,
+	0x1d, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x47, 0x65,
+	0x74, 0x56, 0x69, 0x65, 0x77, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x71, 0x1a, 0x1b,
+	0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x56, 0x69, 0x65,
+	0x77, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x70, 0x12, 0x45, 0x0a, 0x08, 0x75,
+	0x73, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x1b, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73,
+	0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x47, 0x65, 0x74, 0x55, 0x73, 0x65, 0x72, 0x49, 0x6e, 0x66,
+	0x6f, 0x52, 0x65, 0x71, 0x1a, 0x1c, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69,
+	0x62, 0x65, 0x2e, 0x47, 0x65, 0x74, 0x55, 0x73, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65,
+	0x73, 0x71, 0x12, 0x3f, 0x0a, 0x07, 0x73, 0x65, 0x74, 0x55, 0x73, 0x65, 0x72, 0x12, 0x1b, 0x2e,
+	0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x65, 0x74, 0x55,
+	0x73, 0x65, 0x72, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x71, 0x1a, 0x17, 0x2e, 0x62, 0x78, 0x73,
+	0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52,
+	0x65, 0x73, 0x70, 0x12, 0x45, 0x0a, 0x0a, 0x67, 0x65, 0x74, 0x50, 0x75, 0x73, 0x68, 0x53, 0x65,
+	0x74, 0x12, 0x1a, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e,
+	0x47, 0x65, 0x74, 0x50, 0x75, 0x73, 0x68, 0x53, 0x65, 0x74, 0x52, 0x65, 0x71, 0x1a, 0x1b, 0x2e,
+	0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x47, 0x65, 0x74, 0x50,
+	0x75, 0x73, 0x68, 0x53, 0x65, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x41, 0x0a, 0x0a, 0x73, 0x65,
+	0x74, 0x50, 0x75, 0x73, 0x68, 0x53, 0x65, 0x74, 0x12, 0x1a, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62,
+	0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x65, 0x74, 0x50, 0x75, 0x73, 0x68, 0x53, 0x65,
+	0x74, 0x52, 0x65, 0x71, 0x1a, 0x17, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69,
+	0x62, 0x65, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x70, 0x12, 0x5c, 0x0a,
+	0x15, 0x67, 0x65, 0x74, 0x53, 0x74, 0x61, 0x66, 0x66, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69,
+	0x62, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x1e, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63,
+	0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x74, 0x61, 0x66, 0x66, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72,
+	0x69, 0x62, 0x65, 0x52, 0x65, 0x71, 0x1a, 0x23, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63,
+	0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x74, 0x61, 0x66, 0x66, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72,
+	0x69, 0x62, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x62, 0x0a, 0x17, 0x67,
+	0x65, 0x74, 0x53, 0x74, 0x61, 0x66, 0x66, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65,
+	0x44, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x12, 0x24, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63,
+	0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x74, 0x61, 0x66, 0x66, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72,
+	0x69, 0x62, 0x65, 0x44, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x52, 0x65, 0x71, 0x1a, 0x21, 0x2e, 0x62,
+	0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x74, 0x61, 0x66, 0x66,
+	0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x44, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x12,
+	0x49, 0x0a, 0x0e, 0x62, 0x69, 0x64, 0x44, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x6f,
+	0x72, 0x12, 0x1e, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e,
+	0x42, 0x69, 0x64, 0x44, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x6f, 0x72, 0x52, 0x65,
+	0x71, 0x1a, 0x17, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e,
+	0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x70, 0x12, 0x49, 0x0a, 0x0a, 0x62, 0x69,
+	0x64, 0x52, 0x65, 0x63, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x1a, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62,
+	0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x42, 0x69, 0x64, 0x52, 0x65, 0x63, 0x4c, 0x69, 0x73,
+	0x74, 0x52, 0x65, 0x71, 0x1a, 0x1f, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69,
+	0x62, 0x65, 0x2e, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x49, 0x6e, 0x66, 0x6f,
+	0x73, 0x52, 0x65, 0x73, 0x70, 0x42, 0x0f, 0x5a, 0x0d, 0x2e, 0x2f, 0x62, 0x78, 0x73, 0x75, 0x62,
+	0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
 }
 
 var (
@@ -4709,7 +4801,7 @@ func file_bxsubscribe_proto_rawDescGZIP() []byte {
 	return file_bxsubscribe_proto_rawDescData
 }
 
-var file_bxsubscribe_proto_msgTypes = make([]protoimpl.MessageInfo, 48)
+var file_bxsubscribe_proto_msgTypes = make([]protoimpl.MessageInfo, 49)
 var file_bxsubscribe_proto_goTypes = []interface{}{
 	(*SubscribeInfosReq)(nil),       // 0: bxsubscribe.SubscribeInfosReq
 	(*SubscribeInfosResp)(nil),      // 1: bxsubscribe.SubscribeInfosResp
@@ -4756,9 +4848,10 @@ var file_bxsubscribe_proto_goTypes = []interface{}{
 	(*StaffSubscribeDetailReq)(nil), // 42: bxsubscribe.StaffSubscribeDetailReq
 	(*StaffSubscribeDetail)(nil),    // 43: bxsubscribe.StaffSubscribeDetail
 	(*BidDistributorReq)(nil),       // 44: bxsubscribe.BidDistributorReq
-	nil,                             // 45: bxsubscribe.Subscribe.AreaEntry
-	nil,                             // 46: bxsubscribe.GetPushSetResp.DataEntry
-	nil,                             // 47: bxsubscribe.GetPushSetResp.TimeDataEntry
+	(*BidRecListReq)(nil),           // 45: bxsubscribe.BidRecListReq
+	nil,                             // 46: bxsubscribe.Subscribe.AreaEntry
+	nil,                             // 47: bxsubscribe.GetPushSetResp.DataEntry
+	nil,                             // 48: bxsubscribe.GetPushSetResp.TimeDataEntry
 }
 var file_bxsubscribe_proto_depIdxs = []int32{
 	2,  // 0: bxsubscribe.SubscribeInfosResp.data:type_name -> bxsubscribe.subscribeData
@@ -4768,14 +4861,14 @@ var file_bxsubscribe_proto_depIdxs = []int32{
 	13, // 4: bxsubscribe.Items.a_key:type_name -> bxsubscribe.Keys
 	15, // 5: bxsubscribe.KeyItems.a_key:type_name -> bxsubscribe.Key
 	14, // 6: bxsubscribe.KeyResp.items:type_name -> bxsubscribe.KeyItems
-	45, // 7: bxsubscribe.Subscribe.area:type_name -> bxsubscribe.Subscribe.AreaEntry
+	46, // 7: bxsubscribe.Subscribe.area:type_name -> bxsubscribe.Subscribe.AreaEntry
 	12, // 8: bxsubscribe.Subscribe.items:type_name -> bxsubscribe.Items
 	22, // 9: bxsubscribe.UserResq.data:type_name -> bxsubscribe.Subscribe
 	26, // 10: bxsubscribe.DistributorResp.items:type_name -> bxsubscribe.userResp
 	29, // 11: bxsubscribe.ViewStatusResp.items:type_name -> bxsubscribe.UserStatus
 	32, // 12: bxsubscribe.GetUserInfoResq.data:type_name -> bxsubscribe.GetUserInfo
-	46, // 13: bxsubscribe.GetPushSetResp.data:type_name -> bxsubscribe.GetPushSetResp.DataEntry
-	47, // 14: bxsubscribe.GetPushSetResp.timeData:type_name -> bxsubscribe.GetPushSetResp.TimeDataEntry
+	47, // 13: bxsubscribe.GetPushSetResp.data:type_name -> bxsubscribe.GetPushSetResp.DataEntry
+	48, // 14: bxsubscribe.GetPushSetResp.timeData:type_name -> bxsubscribe.GetPushSetResp.TimeDataEntry
 	41, // 15: bxsubscribe.StaffSubscribeListResp.items:type_name -> bxsubscribe.StaffSubscribe
 	21, // 16: bxsubscribe.Subscribe.AreaEntry.value:type_name -> bxsubscribe.List
 	37, // 17: bxsubscribe.GetPushSetResp.DataEntry.value:type_name -> bxsubscribe.PushSet
@@ -4797,25 +4890,27 @@ var file_bxsubscribe_proto_depIdxs = []int32{
 	39, // 33: bxsubscribe.Bxsubscribe.getStaffSubscribeList:input_type -> bxsubscribe.StaffSubscribeReq
 	42, // 34: bxsubscribe.Bxsubscribe.getStaffSubscribeDetail:input_type -> bxsubscribe.StaffSubscribeDetailReq
 	44, // 35: bxsubscribe.Bxsubscribe.bidDistributor:input_type -> bxsubscribe.BidDistributorReq
-	1,  // 36: bxsubscribe.Bxsubscribe.GetSubList:output_type -> bxsubscribe.SubscribeInfosResp
-	6,  // 37: bxsubscribe.Bxsubscribe.GetSubSomeInfo:output_type -> bxsubscribe.SomeInfoResp
-	8,  // 38: bxsubscribe.Bxsubscribe.UpdateSubScribeInfo:output_type -> bxsubscribe.StatusResp
-	9,  // 39: bxsubscribe.Bxsubscribe.ByPushHistory:output_type -> bxsubscribe.ByPushHistoryResp
-	8,  // 40: bxsubscribe.Bxsubscribe.SetRead:output_type -> bxsubscribe.StatusResp
-	20, // 41: bxsubscribe.Bxsubscribe.GetKey:output_type -> bxsubscribe.KeyResp
-	24, // 42: bxsubscribe.Bxsubscribe.GetSubScribeInfo:output_type -> bxsubscribe.UserResq
-	8,  // 43: bxsubscribe.Bxsubscribe.MsgDistributor:output_type -> bxsubscribe.StatusResp
-	25, // 44: bxsubscribe.Bxsubscribe.GetDistributor:output_type -> bxsubscribe.DistributorResp
-	28, // 45: bxsubscribe.Bxsubscribe.GetViewStatus:output_type -> bxsubscribe.ViewStatusResp
-	31, // 46: bxsubscribe.Bxsubscribe.userInfo:output_type -> bxsubscribe.GetUserInfoResq
-	8,  // 47: bxsubscribe.Bxsubscribe.setUser:output_type -> bxsubscribe.StatusResp
-	35, // 48: bxsubscribe.Bxsubscribe.getPushSet:output_type -> bxsubscribe.GetPushSetResp
-	8,  // 49: bxsubscribe.Bxsubscribe.setPushSet:output_type -> bxsubscribe.StatusResp
-	40, // 50: bxsubscribe.Bxsubscribe.getStaffSubscribeList:output_type -> bxsubscribe.StaffSubscribeListResp
-	43, // 51: bxsubscribe.Bxsubscribe.getStaffSubscribeDetail:output_type -> bxsubscribe.StaffSubscribeDetail
-	8,  // 52: bxsubscribe.Bxsubscribe.bidDistributor:output_type -> bxsubscribe.StatusResp
-	36, // [36:53] is the sub-list for method output_type
-	19, // [19:36] is the sub-list for method input_type
+	45, // 36: bxsubscribe.Bxsubscribe.bidRecList:input_type -> bxsubscribe.BidRecListReq
+	1,  // 37: bxsubscribe.Bxsubscribe.GetSubList:output_type -> bxsubscribe.SubscribeInfosResp
+	6,  // 38: bxsubscribe.Bxsubscribe.GetSubSomeInfo:output_type -> bxsubscribe.SomeInfoResp
+	8,  // 39: bxsubscribe.Bxsubscribe.UpdateSubScribeInfo:output_type -> bxsubscribe.StatusResp
+	9,  // 40: bxsubscribe.Bxsubscribe.ByPushHistory:output_type -> bxsubscribe.ByPushHistoryResp
+	8,  // 41: bxsubscribe.Bxsubscribe.SetRead:output_type -> bxsubscribe.StatusResp
+	20, // 42: bxsubscribe.Bxsubscribe.GetKey:output_type -> bxsubscribe.KeyResp
+	24, // 43: bxsubscribe.Bxsubscribe.GetSubScribeInfo:output_type -> bxsubscribe.UserResq
+	8,  // 44: bxsubscribe.Bxsubscribe.MsgDistributor:output_type -> bxsubscribe.StatusResp
+	25, // 45: bxsubscribe.Bxsubscribe.GetDistributor:output_type -> bxsubscribe.DistributorResp
+	28, // 46: bxsubscribe.Bxsubscribe.GetViewStatus:output_type -> bxsubscribe.ViewStatusResp
+	31, // 47: bxsubscribe.Bxsubscribe.userInfo:output_type -> bxsubscribe.GetUserInfoResq
+	8,  // 48: bxsubscribe.Bxsubscribe.setUser:output_type -> bxsubscribe.StatusResp
+	35, // 49: bxsubscribe.Bxsubscribe.getPushSet:output_type -> bxsubscribe.GetPushSetResp
+	8,  // 50: bxsubscribe.Bxsubscribe.setPushSet:output_type -> bxsubscribe.StatusResp
+	40, // 51: bxsubscribe.Bxsubscribe.getStaffSubscribeList:output_type -> bxsubscribe.StaffSubscribeListResp
+	43, // 52: bxsubscribe.Bxsubscribe.getStaffSubscribeDetail:output_type -> bxsubscribe.StaffSubscribeDetail
+	8,  // 53: bxsubscribe.Bxsubscribe.bidDistributor:output_type -> bxsubscribe.StatusResp
+	1,  // 54: bxsubscribe.Bxsubscribe.bidRecList:output_type -> bxsubscribe.SubscribeInfosResp
+	37, // [37:55] is the sub-list for method output_type
+	19, // [19:37] is the sub-list for method input_type
 	19, // [19:19] is the sub-list for extension type_name
 	19, // [19:19] is the sub-list for extension extendee
 	0,  // [0:19] is the sub-list for field type_name
@@ -5367,6 +5462,18 @@ func file_bxsubscribe_proto_init() {
 				return nil
 			}
 		}
+		file_bxsubscribe_proto_msgTypes[45].Exporter = func(v interface{}, i int) interface{} {
+			switch v := v.(*BidRecListReq); i {
+			case 0:
+				return &v.state
+			case 1:
+				return &v.sizeCache
+			case 2:
+				return &v.unknownFields
+			default:
+				return nil
+			}
+		}
 	}
 	type x struct{}
 	out := protoimpl.TypeBuilder{
@@ -5374,7 +5481,7 @@ func file_bxsubscribe_proto_init() {
 			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
 			RawDescriptor: file_bxsubscribe_proto_rawDesc,
 			NumEnums:      0,
-			NumMessages:   48,
+			NumMessages:   49,
 			NumExtensions: 0,
 			NumServices:   1,
 		},

+ 40 - 1
jyBXSubscribe/rpc/type/bxsubscribe/bxsubscribe_grpc.pb.go

@@ -1,7 +1,7 @@
 // Code generated by protoc-gen-go-grpc. DO NOT EDIT.
 // versions:
 // - protoc-gen-go-grpc v1.3.0
-// - protoc             v3.15.1
+// - protoc             v4.25.2
 // source: bxsubscribe.proto
 
 //import "google/protobuf/struct.proto";
@@ -38,6 +38,7 @@ const (
 	Bxsubscribe_GetStaffSubscribeList_FullMethodName   = "/bxsubscribe.Bxsubscribe/getStaffSubscribeList"
 	Bxsubscribe_GetStaffSubscribeDetail_FullMethodName = "/bxsubscribe.Bxsubscribe/getStaffSubscribeDetail"
 	Bxsubscribe_BidDistributor_FullMethodName          = "/bxsubscribe.Bxsubscribe/bidDistributor"
+	Bxsubscribe_BidRecList_FullMethodName              = "/bxsubscribe.Bxsubscribe/bidRecList"
 )
 
 // BxsubscribeClient is the client API for Bxsubscribe service.
@@ -78,6 +79,8 @@ type BxsubscribeClient interface {
 	GetStaffSubscribeDetail(ctx context.Context, in *StaffSubscribeDetailReq, opts ...grpc.CallOption) (*StaffSubscribeDetail, error)
 	// 标讯信息分发
 	BidDistributor(ctx context.Context, in *BidDistributorReq, opts ...grpc.CallOption) (*StatusResp, error)
+	// 订阅推荐列表
+	BidRecList(ctx context.Context, in *BidRecListReq, opts ...grpc.CallOption) (*SubscribeInfosResp, error)
 }
 
 type bxsubscribeClient struct {
@@ -241,6 +244,15 @@ func (c *bxsubscribeClient) BidDistributor(ctx context.Context, in *BidDistribut
 	return out, nil
 }
 
+func (c *bxsubscribeClient) BidRecList(ctx context.Context, in *BidRecListReq, opts ...grpc.CallOption) (*SubscribeInfosResp, error) {
+	out := new(SubscribeInfosResp)
+	err := c.cc.Invoke(ctx, Bxsubscribe_BidRecList_FullMethodName, in, out, opts...)
+	if err != nil {
+		return nil, err
+	}
+	return out, nil
+}
+
 // BxsubscribeServer is the server API for Bxsubscribe service.
 // All implementations must embed UnimplementedBxsubscribeServer
 // for forward compatibility
@@ -279,6 +291,8 @@ type BxsubscribeServer interface {
 	GetStaffSubscribeDetail(context.Context, *StaffSubscribeDetailReq) (*StaffSubscribeDetail, error)
 	// 标讯信息分发
 	BidDistributor(context.Context, *BidDistributorReq) (*StatusResp, error)
+	// 订阅推荐列表
+	BidRecList(context.Context, *BidRecListReq) (*SubscribeInfosResp, error)
 	mustEmbedUnimplementedBxsubscribeServer()
 }
 
@@ -337,6 +351,9 @@ func (UnimplementedBxsubscribeServer) GetStaffSubscribeDetail(context.Context, *
 func (UnimplementedBxsubscribeServer) BidDistributor(context.Context, *BidDistributorReq) (*StatusResp, error) {
 	return nil, status.Errorf(codes.Unimplemented, "method BidDistributor not implemented")
 }
+func (UnimplementedBxsubscribeServer) BidRecList(context.Context, *BidRecListReq) (*SubscribeInfosResp, error) {
+	return nil, status.Errorf(codes.Unimplemented, "method BidRecList not implemented")
+}
 func (UnimplementedBxsubscribeServer) mustEmbedUnimplementedBxsubscribeServer() {}
 
 // UnsafeBxsubscribeServer may be embedded to opt out of forward compatibility for this service.
@@ -656,6 +673,24 @@ func _Bxsubscribe_BidDistributor_Handler(srv interface{}, ctx context.Context, d
 	return interceptor(ctx, in, info, handler)
 }
 
+func _Bxsubscribe_BidRecList_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
+	in := new(BidRecListReq)
+	if err := dec(in); err != nil {
+		return nil, err
+	}
+	if interceptor == nil {
+		return srv.(BxsubscribeServer).BidRecList(ctx, in)
+	}
+	info := &grpc.UnaryServerInfo{
+		Server:     srv,
+		FullMethod: Bxsubscribe_BidRecList_FullMethodName,
+	}
+	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
+		return srv.(BxsubscribeServer).BidRecList(ctx, req.(*BidRecListReq))
+	}
+	return interceptor(ctx, in, info, handler)
+}
+
 // Bxsubscribe_ServiceDesc is the grpc.ServiceDesc for Bxsubscribe service.
 // It's only intended for direct use with grpc.RegisterService,
 // and not to be introspected or modified (even as a copy)
@@ -731,6 +766,10 @@ var Bxsubscribe_ServiceDesc = grpc.ServiceDesc{
 			MethodName: "bidDistributor",
 			Handler:    _Bxsubscribe_BidDistributor_Handler,
 		},
+		{
+			MethodName: "bidRecList",
+			Handler:    _Bxsubscribe_BidRecList_Handler,
+		},
 	},
 	Streams:  []grpc.StreamDesc{},
 	Metadata: "bxsubscribe.proto",