فهرست منبع

fix:添加数据导出条件保存修改

duxin 2 سال پیش
والد
کامیت
935f1f49db

+ 3 - 0
jyBXSubscribe/api/bxsubscribe.api

@@ -29,6 +29,7 @@ type (
 		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"`
 	}
 	//
 	someInfoReq {
@@ -67,4 +68,6 @@ service bxsubscribe-api {
 	post /jybx/subscribe/:userType/someInfo(someInfoReq) returns (commonResp)
 	@handler subscribeUpdate
 	post /jybx/subscribe/:userType/update(subscribeUpdateReq) returns (commonResp)
+	@handler ByPushHistory
+	post /jybx/subscribe/:userType/byPushHistory(subscribeReq) returns (commonResp)
 }

+ 28 - 0
jyBXSubscribe/api/internal/handler/byPushHistoryHandler.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 ByPushHistoryHandler(svcCtx *svc.ServiceContext) http.HandlerFunc {
+	return func(w http.ResponseWriter, r *http.Request) {
+		var req types.SubscribeReq
+		if err := httpx.Parse(r, &req); err != nil {
+			httpx.Error(w, err)
+			return
+		}
+
+		l := logic.NewByPushHistoryLogic(r.Context(), svcCtx)
+		resp, err := l.ByPushHistory(&req)
+		if err != nil {
+			httpx.Error(w, err)
+		} else {
+			httpx.OkJson(w, resp)
+		}
+	}
+}

+ 5 - 0
jyBXSubscribe/api/internal/handler/routes.go

@@ -27,6 +27,11 @@ func RegisterHandlers(server *rest.Server, serverCtx *svc.ServiceContext) {
 				Path:    "/jybx/subscribe/:userType/update",
 				Handler: subscribeUpdateHandler(serverCtx),
 			},
+			{
+				Method:  http.MethodPost,
+				Path:    "/jybx/subscribe/:userType/byPushHistory",
+				Handler: ByPushHistoryHandler(serverCtx),
+			},
 		},
 	)
 }

+ 62 - 0
jyBXSubscribe/api/internal/logic/byPushHistoryLogic.go

@@ -0,0 +1,62 @@
+package logic
+
+import (
+	"context"
+	"jyBXSubscribe/rpc/type/bxsubscribe"
+
+	"jyBXSubscribe/api/internal/svc"
+	"jyBXSubscribe/api/internal/types"
+
+	"github.com/zeromicro/go-zero/core/logx"
+)
+
+type ByPushHistoryLogic struct {
+	logx.Logger
+	ctx    context.Context
+	svcCtx *svc.ServiceContext
+}
+
+func NewByPushHistoryLogic(ctx context.Context, svcCtx *svc.ServiceContext) *ByPushHistoryLogic {
+	return &ByPushHistoryLogic{
+		Logger: logx.WithContext(ctx),
+		ctx:    ctx,
+		svcCtx: svcCtx,
+	}
+}
+
+func (l *ByPushHistoryLogic) ByPushHistory(req *types.SubscribeReq) (resp *types.CommonResp, err error) {
+	res, err := l.svcCtx.Suscribe.ByPushHistory(l.ctx, &bxsubscribe.SubscribeInfosReq{
+		PageNum:    req.PageNum,
+		PageSize:   req.PageSize,
+		SelectTime: req.SelectTime,
+		Area:       req.Area,
+		City:       req.City,
+		Industry:   req.Industry,
+		BuyerClass: req.BuyerClass,
+		KeyWords:   req.KeyWords,
+		Subtype:    req.Subtype,
+		UserType:   req.UserType,
+		Price:      req.Price,
+		FileExists: req.FileExists,
+		UserId:     req.UserId,
+		EntId:      req.EntId,
+		EntUserId:  req.EntUserId,
+		DeptId:     req.DeptId,
+		NewUserId:  req.NewUserId,
+		IsEnt:      req.IsEnt,
+		SelectIds:  req.SelectIds,
+	})
+	if err != nil {
+		return &types.CommonResp{
+			Err_code: res.ErrorCode,
+			Err_msg:  res.ErrorMsg,
+			Data:     nil,
+		}, nil
+	}
+	return &types.CommonResp{
+		Err_code: res.ErrorCode,
+		Err_msg:  res.ErrorMsg,
+		Data:     res.Data,
+	}, nil
+	return
+}

+ 1 - 0
jyBXSubscribe/api/internal/types/types.go

@@ -21,6 +21,7 @@ type SubscribeReq struct {
 	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"`
 }
 
 type SomeInfoReq struct {

+ 9 - 0
jyBXSubscribe/rpc/bxsubscribe.proto

@@ -23,6 +23,7 @@ message SubscribeInfosReq {
   string deptId = 17;
   int64 newUserId = 18;
   bool IsEnt=19;
+  string SelectIds=20;
 }
 
 message SubscribeInfosResp {
@@ -92,6 +93,12 @@ message StatusResp{
 	int64 error_code=2;
   	int64 status = 3;
 }
+message ByPushHistoryResp{
+  string error_msg =1;
+  int64 error_code=2;
+  string data = 3;
+}
+
 
 message UpdateSubScribeInfoReq{
 	map<string,CityList> area = 1; //地区
@@ -137,4 +144,6 @@ service Bxsubscribe {
   rpc GetSubSomeInfo(SomeInfoReq) returns(SomeInfoResp);
   //修改订阅信息接口
   rpc UpdateSubScribeInfo(UpdateSubScribeInfoReq)returns(StatusResp);
+  //推送页面筛选导出
+  rpc ByPushHistory(SubscribeInfosReq)returns(ByPushHistoryResp);
 }

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

@@ -13,6 +13,7 @@ import (
 )
 
 type (
+	ByPushHistoryResp      = bxsubscribe.ByPushHistoryResp
 	CityList               = bxsubscribe.CityList
 	Items                  = bxsubscribe.Items
 	Keys                   = bxsubscribe.Keys
@@ -33,6 +34,8 @@ type (
 		GetSubSomeInfo(ctx context.Context, in *SomeInfoReq, opts ...grpc.CallOption) (*SomeInfoResp, error)
 		// 修改订阅信息接口
 		UpdateSubScribeInfo(ctx context.Context, in *UpdateSubScribeInfoReq, opts ...grpc.CallOption) (*StatusResp, error)
+		// 推送页面筛选导出
+		ByPushHistory(ctx context.Context, in *SubscribeInfosReq, opts ...grpc.CallOption) (*ByPushHistoryResp, error)
 	}
 
 	defaultBxsubscribe struct {
@@ -63,3 +66,9 @@ func (m *defaultBxsubscribe) UpdateSubScribeInfo(ctx context.Context, in *Update
 	client := bxsubscribe.NewBxsubscribeClient(m.cli.Conn())
 	return client.UpdateSubScribeInfo(ctx, in, opts...)
 }
+
+// 推送页面筛选导出
+func (m *defaultBxsubscribe) ByPushHistory(ctx context.Context, in *SubscribeInfosReq, opts ...grpc.CallOption) (*ByPushHistoryResp, error) {
+	client := bxsubscribe.NewBxsubscribeClient(m.cli.Conn())
+	return client.ByPushHistory(ctx, in, opts...)
+}

+ 95 - 0
jyBXSubscribe/rpc/internal/logic/bypushhistorylogic.go

@@ -0,0 +1,95 @@
+package logic
+
+import (
+	"context"
+	"fmt"
+	"github.com/zeromicro/go-zero/core/logx"
+	IC "jyBXSubscribe/rpc/init"
+	"jyBXSubscribe/rpc/internal/svc"
+	"jyBXSubscribe/rpc/model"
+	"jyBXSubscribe/rpc/type/bxsubscribe"
+	"jyBXSubscribe/rpc/util"
+	"strings"
+	"time"
+)
+
+type ByPushHistoryLogic struct {
+	ctx    context.Context
+	svcCtx *svc.ServiceContext
+	logx.Logger
+}
+
+func NewByPushHistoryLogic(ctx context.Context, svcCtx *svc.ServiceContext) *ByPushHistoryLogic {
+	return &ByPushHistoryLogic{
+		ctx:    ctx,
+		svcCtx: svcCtx,
+		Logger: logx.WithContext(ctx),
+	}
+}
+
+// 推送页面筛选导出
+func (l *ByPushHistoryLogic) ByPushHistory(in *bxsubscribe.SubscribeInfosReq) (*bxsubscribe.ByPushHistoryResp, error) {
+	// todo: add your logic here and delete this line
+	vipType := in.UserType
+	spqp := &model.SubPushQueryParam{
+		Mgo_bidding:   IC.MgoBidding,                      //mongo
+		Bidding:       IC.DB.Mongo.Bidding.Collection,     //招标信息 表
+		Bidding_back:  IC.DB.Mongo.Bidding.CollectionBack, //招标信息备份数据 表名
+		UserId:        in.UserId,                          //用户id
+		PageNum:       1,                                  //当前页码
+		PageSize:      20000,
+		Export:        true,
+		SelectTime:    in.SelectTime, //时间跨度
+		Area:          in.Area,       //省份
+		City:          in.City,       //城市
+		Buyerclass:    in.BuyerClass, //采购单位类型
+		Subtype:       in.Subtype,    //信息类型
+		Subscopeclass: in.Industry,   //行业
+		Key:           in.KeyWords,   //关键词
+		Price:         in.Price,      //价格区间
+		FileExists:    in.FileExists, //是否有附件
+	}
+	if selectIds := strings.TrimSpace(in.SelectIds); selectIds != "" {
+		encodeArr := strings.Split(selectIds, ",")
+		idArr := make([]string, 0, len(encodeArr))
+		for _, encodeId := range encodeArr {
+			if tmp := util.DecodeId(encodeId); tmp != "" {
+				idArr = append(idArr, tmp)
+			}
+		}
+		spqp.SelectInfoIds = idArr
+	}
+	_, _, list := model.NewSubscribePush(vipType).Datas(spqp)
+	if list == nil || len(list) == 0 {
+		return nil, fmt.Errorf("未匹配到导出数据")
+	}
+	ids := make([]string, 0, len(list))
+	keyWords := make([]string, len(list), len(list))
+	for _, pushData := range list {
+		if pushData.XId != "" {
+			if xid := util.EncodeId(pushData.XId); len(xid) > 0 {
+				ids = append(ids, xid)
+				keyWords = append(keyWords, strings.Join(pushData.MatchKeys, ","))
+			}
+		}
+	}
+	saveData := map[string]interface{}{
+		"s_userid":     in.UserId,
+		"comeinfrom":   "pushHistory",
+		"comeintime":   time.Now().Unix(),
+		"selectIds":    ids,
+		"pushKeyWords": keyWords,
+	}
+
+	_id := IC.Mgo.Save("export_search", saveData)
+	if _id == "" {
+		return &bxsubscribe.ByPushHistoryResp{
+			ErrorCode: 1,
+			ErrorMsg:  "创建导出异常",
+		}, nil
+	}
+
+	return &bxsubscribe.ByPushHistoryResp{
+		Data: util.EncodeId(_id),
+	}, nil
+}

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

@@ -39,3 +39,9 @@ func (s *BxsubscribeServer) UpdateSubScribeInfo(ctx context.Context, in *bxsubsc
 	l := logic.NewUpdateSubScribeInfoLogic(ctx, s.svcCtx)
 	return l.UpdateSubScribeInfo(in)
 }
+
+// 推送页面筛选导出
+func (s *BxsubscribeServer) ByPushHistory(ctx context.Context, in *bxsubscribe.SubscribeInfosReq) (*bxsubscribe.ByPushHistoryResp, error) {
+	l := logic.NewByPushHistoryLogic(ctx, s.svcCtx)
+	return l.ByPushHistory(in)
+}

+ 155 - 151
jyBXSubscribe/rpc/model/push.go

@@ -25,7 +25,6 @@ import (
 	"time"
 )
 
-//
 const (
 	pageSize            = 100
 	AllSubPushCacheSize = 250
@@ -76,7 +75,7 @@ type PushCa struct {
 	FileExists bool
 }
 
-//查询参数
+// 查询参数
 type SubPushQueryParam struct {
 	Mgo_bidding      mongodb.MongodbSim //
 	Bidding          string             //
@@ -100,6 +99,7 @@ type SubPushQueryParam struct {
 	BaseServiceMysql *mysql.Mysql
 	NewUserId        int64
 	IsEnt            bool
+	SelectInfoIds    []string
 }
 
 func (spqp *SubPushQueryParam) IsEmpty() bool {
@@ -118,7 +118,7 @@ func NewSubscribePush(module ...string) *subscribePush {
 	return &subscribePush{m}
 }
 
-//从pushcache_2_a中取
+// 从pushcache_2_a中取
 func (s *subscribePush) GetTodayCache(userId string) (*SubPush, error) {
 	pc_a, err := redis.GetNewBytes("pushcache_2_b", s.todayKey(userId))
 	if err != nil {
@@ -134,12 +134,12 @@ func (s *subscribePush) GetTodayCache(userId string) (*SubPush, error) {
 	return p, nil
 }
 
-//往pushcache_2_a中放
+// 往pushcache_2_a中放
 func (s *subscribePush) PutTodayCache(userId string, pc_a *SubPush) {
 	redis.Put("pushcache_2_b", s.todayKey(userId), pc_a, oneDay)
 }
 
-//获取redis key
+// 获取redis key
 func (s *subscribePush) todayKey(userId string) string {
 	return fmt.Sprintf("%s_%s", aboutDbMsg[s.ModuleFlag].RedisKeyFlag, userId)
 }
@@ -147,7 +147,7 @@ func (s *subscribePush) allKey(userId string) string {
 	return fmt.Sprintf("all_%s_%s", aboutDbMsg[s.ModuleFlag].RedisKeyFlag, userId)
 }
 
-//历史推送记录中单条信息格式化
+// 历史推送记录中单条信息格式化
 func (s *subscribePush) InfoFormat(p *PushCa, info *map[string]interface{}) *bxsubscribe.SubscribeInfo {
 	area := common.ObjToString((*info)["area"])
 	if area == "A" {
@@ -267,7 +267,7 @@ func (s *subscribePush) Datas(spqp *SubPushQueryParam) (hasNextPage bool, total
 			result = subPush.Datas[start:end]
 		}
 		total = int64(length)
-	} else if spqp.IsEmpty() && (spqp.PageNum-1)*spqp.PageSize < 250 { //全部,没有过滤条件 之前缓存5页*50条=250
+	} else if spqp.IsEmpty() && (spqp.PageNum-1)*spqp.PageSize < 250 && len(spqp.SelectInfoIds) == 0 { //全部,没有过滤条件 之前缓存5页*50条=250
 		logx.Info("a2:", s.allKey(spqp.UserId))
 		allCache := &SubPush{}
 		var err error
@@ -311,151 +311,155 @@ func (s *subscribePush) Datas(spqp *SubPushQueryParam) (hasNextPage bool, total
 	return
 }
 
-//
 func (s *subscribePush) getDatasFromMysql(spqp *SubPushQueryParam, starttime, endtime int64, size int, isLimit bool) (result []*bxsubscribe.SubscribeInfo, count int64) {
 	querys := []string{}
-	if spqp.IsEnt {
-		querys = []string{fmt.Sprintf("a.entid='%s'", spqp.EntId)}
+	if len(spqp.SelectInfoIds) != 0 {
+		querys = append(querys, fmt.Sprintf("id in ('%s')", strings.Join(spqp.SelectInfoIds, "','")))
 	} else {
-		querys = []string{fmt.Sprintf("a.userid='%s'", common.If(s.ModuleFlag == "eType", spqp.EntUserId, common.InterfaceToStr(spqp.NewUserId)))}
+		if spqp.IsEnt {
+			querys = []string{fmt.Sprintf("a.entid='%s'", spqp.EntId)}
+		} else {
+			querys = []string{fmt.Sprintf("a.userid='%s'", common.If(s.ModuleFlag == "eType", spqp.EntUserId, common.InterfaceToStr(spqp.NewUserId)))}
 
-	}
-	codeMap, err := IC.CodeLib.CodeTransformation(context.Background(), &codeservice.Request{})
-	if codeMap.Data == nil || err != nil {
-		logx.Error("代码表获取失败")
-		return result, count
-	}
-	//时间
-	if starttime > 0 && endtime > 0 {
-		querys = append(querys, fmt.Sprintf("a.date>=%d and date<=%d", starttime, endtime))
-	} else if starttime > 0 && endtime == 0 {
-		querys = append(querys, fmt.Sprintf("a.date>=%d", starttime))
-	} else if starttime == 0 && endtime > 0 {
-		querys = append(querys, fmt.Sprintf("a.date<=%d", endtime))
-	}
-	if spqp.Area != "" || spqp.City != "" {
-		var sqlAreaCity = ""
-		//城市
-		city := []string{}
-		for _, v := range strings.Split(spqp.City, ",") {
-			if codeMap.Data.City[v] != "" {
-				city = append(city, fmt.Sprint(codeMap.Data.City[v]))
-			} else {
-				city = append(city, "-1")
-			}
-		}
-		if len(city) == 1 {
-			city = append(city, "9999")
 		}
-		if len(city) > 0 {
-			sqlAreaCity = fmt.Sprintf("b.city_code in (%s)", strings.Join(city, ","))
-		}
-		//区域
-		var sqlArea = ""
-		area := []string{}
-		for _, v := range strings.Split(spqp.Area, ",") {
-			if codeMap.Data.Area[v] != "" {
-				area = append(area, fmt.Sprint(codeMap.Data.Area[v]))
-			} else {
-				area = append(area, "-1")
+		codeMap, err := IC.CodeLib.CodeTransformation(context.Background(), &codeservice.Request{})
+		if codeMap.Data == nil || err != nil {
+			logx.Error("代码表获取失败")
+			return result, count
+		}
+		//时间
+		if starttime > 0 && endtime > 0 {
+			querys = append(querys, fmt.Sprintf("a.date>=%d and date<=%d", starttime, endtime))
+		} else if starttime > 0 && endtime == 0 {
+			querys = append(querys, fmt.Sprintf("a.date>=%d", starttime))
+		} else if starttime == 0 && endtime > 0 {
+			querys = append(querys, fmt.Sprintf("a.date<=%d", endtime))
+		}
+		if spqp.Area != "" || spqp.City != "" {
+			var sqlAreaCity = ""
+			//城市
+			city := []string{}
+			for _, v := range strings.Split(spqp.City, ",") {
+				if codeMap.Data.City[v] != "" {
+					city = append(city, fmt.Sprint(codeMap.Data.City[v]))
+				} else {
+					city = append(city, "-1")
+				}
 			}
-		}
-		if len(area) == 1 {
-			area = append(area, "9999")
-		}
-		if len(area) > 0 {
-			sqlArea = fmt.Sprintf("b.area_code in (%s)", strings.Join(area, ","))
-		}
-		if sqlAreaCity != "" && sqlArea != "" {
-			sqlAreaCity = "( " + sqlAreaCity + " or " + sqlArea + " )"
-		} else if sqlAreaCity == "" && sqlArea != "" {
-			sqlAreaCity = sqlArea
-		}
-		if sqlAreaCity != "" {
-			querys = append(querys, sqlAreaCity)
-		}
-	}
-	//采购单位行业
-	if spqp.Buyerclass != "" {
-		buyerclass := []string{}
-		for _, v := range strings.Split(spqp.Buyerclass, ",") {
-			if codeMap.Data.Buyerclass[v] != "" {
-				buyerclass = append(buyerclass, fmt.Sprint(codeMap.Data.Buyerclass[v]))
+			if len(city) == 1 {
+				city = append(city, "9999")
+			}
+			if len(city) > 0 {
+				sqlAreaCity = fmt.Sprintf("b.city_code in (%s)", strings.Join(city, ","))
+			}
+			//区域
+			var sqlArea = ""
+			area := []string{}
+			for _, v := range strings.Split(spqp.Area, ",") {
+				if codeMap.Data.Area[v] != "" {
+					area = append(area, fmt.Sprint(codeMap.Data.Area[v]))
+				} else {
+					area = append(area, "-1")
+				}
+			}
+			if len(area) == 1 {
+				area = append(area, "9999")
+			}
+			if len(area) > 0 {
+				sqlArea = fmt.Sprintf("b.area_code in (%s)", strings.Join(area, ","))
+			}
+			if sqlAreaCity != "" && sqlArea != "" {
+				sqlAreaCity = "( " + sqlAreaCity + " or " + sqlArea + " )"
+			} else if sqlAreaCity == "" && sqlArea != "" {
+				sqlAreaCity = sqlArea
+			}
+			if sqlAreaCity != "" {
+				querys = append(querys, sqlAreaCity)
 			}
 		}
-		if len(buyerclass) == 1 {
-			buyerclass = append(buyerclass, "9999")
-		}
-		if len(buyerclass) > 0 {
-			querys = append(querys, fmt.Sprintf("b.buyerclass_code in (%s)", strings.Join(buyerclass, ",")))
-		}
-
-	}
-	//信息类型
-	if spqp.Subtype != "" {
-		subtype := []string{}
-		for _, v := range strings.Split(spqp.Subtype, ",") {
-			if codeMap.Data.Subtype[v] != "" {
-				subtype = append(subtype, fmt.Sprint(codeMap.Data.Subtype[v]))
+		//采购单位行业
+		if spqp.Buyerclass != "" {
+			buyerclass := []string{}
+			for _, v := range strings.Split(spqp.Buyerclass, ",") {
+				if codeMap.Data.Buyerclass[v] != "" {
+					buyerclass = append(buyerclass, fmt.Sprint(codeMap.Data.Buyerclass[v]))
+				}
+			}
+			if len(buyerclass) == 1 {
+				buyerclass = append(buyerclass, "9999")
+			}
+			if len(buyerclass) > 0 {
+				querys = append(querys, fmt.Sprintf("b.buyerclass_code in (%s)", strings.Join(buyerclass, ",")))
 			}
 
 		}
-		if len(subtype) == 1 {
-			subtype = append(subtype, "9999")
-		}
-		if len(subtype) > 0 {
-			querys = append(querys, fmt.Sprintf("b.subtype_code in (%s)", strings.Join(subtype, ",")))
-		}
+		//信息类型
+		if spqp.Subtype != "" {
+			subtype := []string{}
+			for _, v := range strings.Split(spqp.Subtype, ",") {
+				if codeMap.Data.Subtype[v] != "" {
+					subtype = append(subtype, fmt.Sprint(codeMap.Data.Subtype[v]))
+				}
 
-	}
-	//信息行业
-	if spqp.Subscopeclass != "" {
-		find_in_set := []string{}
-		for _, v := range strings.Split(spqp.Subscopeclass, ",") {
-			if codeMap.Data.Subscopeclass[v] != "" {
-				find_in_set = append(find_in_set, codeMap.Data.Subscopeclass[v])
+			}
+			if len(subtype) == 1 {
+				subtype = append(subtype, "9999")
+			}
+			if len(subtype) > 0 {
+				querys = append(querys, fmt.Sprintf("b.subtype_code in (%s)", strings.Join(subtype, ",")))
 			}
 
 		}
-		if len(find_in_set) == 1 {
-			querys = append(querys, find_in_set[0])
-		} else if len(find_in_set) > 1 {
-			querys = append(querys, fmt.Sprintf(" t.labelvalues in (%s)", strings.Join(find_in_set, ",")))
-		}
-	}
-	//关键词
-	if spqp.Key != "" {
-		find_in_set := []string{}
-		for _, v := range strings.Split(spqp.Key, ",") {
-			find_in_set = append(find_in_set, fmt.Sprintf("find_in_set('%s',replace(replace(a.matchkeys,'+',','),' ',','))", v))
+		//信息行业
+		if spqp.Subscopeclass != "" {
+			find_in_set := []string{}
+			for _, v := range strings.Split(spqp.Subscopeclass, ",") {
+				if codeMap.Data.Subscopeclass[v] != "" {
+					find_in_set = append(find_in_set, codeMap.Data.Subscopeclass[v])
+				}
+
+			}
+			if len(find_in_set) == 1 {
+				querys = append(querys, find_in_set[0])
+			} else if len(find_in_set) > 1 {
+				querys = append(querys, fmt.Sprintf(" t.labelvalues in (%s)", strings.Join(find_in_set, ",")))
+			}
 		}
-		if len(find_in_set) == 1 {
-			querys = append(querys, find_in_set[0])
-		} else if len(find_in_set) > 1 {
-			querys = append(querys, fmt.Sprintf("(%s)", strings.Join(find_in_set, " or ")))
+		//关键词
+		if spqp.Key != "" {
+			find_in_set := []string{}
+			for _, v := range strings.Split(spqp.Key, ",") {
+				find_in_set = append(find_in_set, fmt.Sprintf("find_in_set('%s',replace(replace(a.matchkeys,'+',','),' ',','))", v))
+			}
+			if len(find_in_set) == 1 {
+				querys = append(querys, find_in_set[0])
+			} else if len(find_in_set) > 1 {
+				querys = append(querys, fmt.Sprintf("(%s)", strings.Join(find_in_set, " or ")))
+			}
 		}
-	}
-	//价格- 预算和中标金额
-	if spqp.Price != "" && strings.Contains(spqp.Price, "-") {
-		minPriceStr, maxPriceStr := strings.Split(spqp.Price, "-")[0], strings.Split(spqp.Price, "-")[1]
-		minPrice := common.Int64All(common.Float64All(minPriceStr) * 10000) //换成元
-		maxPrice := common.Int64All(common.Float64All(maxPriceStr) * 10000) //换成元
-		if minPriceStr != "" && maxPriceStr != "" {
-			querys = append(querys, fmt.Sprintf("((b.bidamount>=%d and b.bidamount<=%d) or (b.budget>=%d and b.budget<=%d and b.bidamount is null))", minPrice, maxPrice, minPrice, maxPrice))
-		} else if minPriceStr != "" {
-			querys = append(querys, fmt.Sprintf("(b.bidamount>=%d  or (b.budget>=%d and b.bidamount is null))", minPrice, minPrice))
-		} else if maxPriceStr != "" {
-			querys = append(querys, fmt.Sprintf("(b.bidamount<=%d or (b.budget<=%d and b.bidamount is null))", maxPrice, maxPrice))
+		//价格- 预算和中标金额
+		if spqp.Price != "" && strings.Contains(spqp.Price, "-") {
+			minPriceStr, maxPriceStr := strings.Split(spqp.Price, "-")[0], strings.Split(spqp.Price, "-")[1]
+			minPrice := common.Int64All(common.Float64All(minPriceStr) * 10000) //换成元
+			maxPrice := common.Int64All(common.Float64All(maxPriceStr) * 10000) //换成元
+			if minPriceStr != "" && maxPriceStr != "" {
+				querys = append(querys, fmt.Sprintf("((b.bidamount>=%d and b.bidamount<=%d) or (b.budget>=%d and b.budget<=%d and b.bidamount is null))", minPrice, maxPrice, minPrice, maxPrice))
+			} else if minPriceStr != "" {
+				querys = append(querys, fmt.Sprintf("(b.bidamount>=%d  or (b.budget>=%d and b.bidamount is null))", minPrice, minPrice))
+			} else if maxPriceStr != "" {
+				querys = append(querys, fmt.Sprintf("(b.bidamount<=%d or (b.budget<=%d and b.bidamount is null))", maxPrice, maxPrice))
+			}
 		}
-	}
-	//附件
-	if spqp.FileExists != "" {
-		if spqp.FileExists == "1" {
-			querys = append(querys, fmt.Sprintf("b.isvalidfile =1 "))
-		} else if spqp.FileExists == "-1" {
-			querys = append(querys, fmt.Sprintf("b.isvalidfile =0 "))
+		//附件
+		if spqp.FileExists != "" {
+			if spqp.FileExists == "1" {
+				querys = append(querys, fmt.Sprintf("b.isvalidfile =1 "))
+			} else if spqp.FileExists == "-1" {
+				querys = append(querys, fmt.Sprintf("b.isvalidfile =0 "))
+			}
 		}
 	}
+
 	searchSql := fmt.Sprintf(" from %s  a LEFT JOIN %s b ON a.infoid = b.infoid LEFT JOIN %s t on t.infoid = b.infoid and t.labelcode=2  where %s"+
 		" order by a.id desc", aboutDbMsg[s.ModuleFlag].MysqlTable, Baseinfo, BidTags, strings.Join(querys, " and "))
 	fmt.Println("searchSql", searchSql)
@@ -481,7 +485,7 @@ func (s *subscribePush) getDatasFromMysql(spqp *SubPushQueryParam, starttime, en
 	return
 }
 
-//根据id取内容
+// 根据id取内容
 func (s *subscribePush) GetInfoByIds(Mgo_bidding mongodb.MongodbSim, bidding, bidding_back string, pushCas []*PushCa) []*bxsubscribe.SubscribeInfo {
 	array := make([]*bxsubscribe.SubscribeInfo, len(pushCas))
 	if len(pushCas) == 0 {
@@ -566,7 +570,7 @@ func (s *subscribePush) GetInfoByIds(Mgo_bidding mongodb.MongodbSim, bidding, bi
 	return array
 }
 
-//获取历史推送
+// 获取历史推送
 func (s *subscribePush) GetJyPushs(datas []map[string]interface{}) (pushCas []*PushCa) {
 	pushCas = []*PushCa{}
 	for _, v := range datas {
@@ -588,7 +592,7 @@ func (s *subscribePush) GetJyPushs(datas []map[string]interface{}) (pushCas []*P
 	return
 }
 
-//查看全部列表缓存
+// 查看全部列表缓存
 func (s *subscribePush) PutAllCache(userId string, datas *SubPush) {
 	log.Println(s.allKey(userId), datas, oneDay)
 	redis.Put("pushcache_2_a", s.allKey(userId), datas, oneDay)
@@ -613,7 +617,7 @@ func (s *subscribePush) GetCache(code, key string) (*SubPush, error) {
 	return p, nil
 }
 
-//是否收藏
+// 是否收藏
 func (s *subscribePush) MakeCollection(userId string, list []*bxsubscribe.SubscribeInfo) {
 	if list == nil || len(list) == 0 {
 		return
@@ -643,7 +647,7 @@ func (s *subscribePush) MakeCollection(userId string, list []*bxsubscribe.Subscr
 	}
 }
 
-//仅移动端首页使用,历史推送7天信息
+// 仅移动端首页使用,历史推送7天信息
 func (s *subscribePush) sevenDayKey(userId string) string {
 	return fmt.Sprintf("7day_subpush_%s", userId)
 }
@@ -652,7 +656,7 @@ func (s *subscribePush) PutSevenDayCache(userId string, datas []*bxsubscribe.Sub
 	redis.Put("pushcache_2_a", s.sevenDayKey(userId), SubPush{Datas: datas}, 7*24*60*60)
 }
 
-//从pushcache_2_a中取
+// 从pushcache_2_a中取
 func (s *subscribePush) GetSevenDayCache(userId string) ([]*bxsubscribe.SubscribeInfo, error) {
 	allPush, _ := s.GetCache("pushcache_2_a", s.sevenDayKey(userId))
 	if allPush != nil && allPush.Datas != nil && len(allPush.Datas) > 0 {
@@ -661,7 +665,7 @@ func (s *subscribePush) GetSevenDayCache(userId string) ([]*bxsubscribe.Subscrib
 	return nil, nil
 }
 
-//历史推送记录中单条信息格式化
+// 历史推送记录中单条信息格式化
 func InfoFormats(info map[string]interface{}, tmp map[string]interface{}) map[string]interface{} {
 	area := common.ObjToString(info["area"])
 	if area == "A" {
@@ -694,7 +698,7 @@ func InfoFormats(info map[string]interface{}, tmp map[string]interface{}) map[st
 	return info
 }
 
-//UpdateUserPushUnread 更新app未读标识为已读
+// UpdateUserPushUnread 更新app未读标识为已读
 func UpdateUserPushUnread(userid string, vt string) {
 	if vt == MemberFlag {
 		IC.Mgo.UpdateById("user", userid, map[string]interface{}{"$set": map[string]interface{}{"i_member_apppushunread": 0}})
@@ -707,7 +711,7 @@ func UpdateUserPushUnread(userid string, vt string) {
 
 //
 
-//获取用户信息
+// 获取用户信息
 func (s *subscribePush) UserInfo(userId string) (*map[string]interface{}, int64) {
 	user, ok := IC.Mgo.FindById("user", userId, `{"s_m_openid":1,"a_m_openid":1,"s_phone":1,"a_mergeorder":1,"o_jy":1,"l_firstpushtime":1,"i_vip_status":1,"l_vip_endtime":1,"o_vipjy":1,"i_member_status":1,"o_member_jy":1}`)
 	if !ok || user == nil {
@@ -716,7 +720,7 @@ func (s *subscribePush) UserInfo(userId string) (*map[string]interface{}, int64)
 	return user, common.Int64All((*user)["l_firstpushtime"])
 }
 
-//是否有订阅词
+// 是否有订阅词
 func GetKeySet(t string, u *map[string]interface{}, data []string) (bool, []string) {
 	var industry_ = []string{}
 	if u != nil {
@@ -764,8 +768,8 @@ const (
 	findfields = `"title"`
 )
 
-//首次访问推送页面 默认生成推送数据
-//默认匹配es 7天内数据
+// 首次访问推送页面 默认生成推送数据
+// 默认匹配es 7天内数据
 func (s *subscribePush) DefaultDatas(spqp *SubPushQueryParam) (hasNextPage bool, total int64, result []*bxsubscribe.SubscribeInfo) {
 	if spqp.UserId == "" {
 		return false, 0, nil
@@ -802,7 +806,7 @@ func (s *subscribePush) DefaultDatas(spqp *SubPushQueryParam) (hasNextPage bool,
 	return
 }
 
-//保存推送表
+// 保存推送表
 func (s *subscribePush) listManager(spqp *SubPushQueryParam, list []map[string]interface{}, keyword []ViewKeyWord, ccount int) (resultList []*bxsubscribe.SubscribeInfo) {
 	t2 := time.Now()
 	now := time.Now().Unix()
@@ -866,7 +870,7 @@ func (s *subscribePush) listManager(spqp *SubPushQueryParam, list []map[string]i
 	return
 }
 
-//获取匹配得关键词
+// 获取匹配得关键词
 func getKeys(title string, keywords []ViewKeyWord) (str []string) {
 	if len(keywords) > 0 {
 	L:
@@ -888,7 +892,7 @@ func getKeys(title string, keywords []ViewKeyWord) (str []string) {
 	return
 }
 
-//获取查询语句
+// 获取查询语句
 func (s *subscribePush) getDefaultDatasSQL(bsp *ViewCondition) (str string) {
 	query := `{"query":{"bool":{"must":[%s],"should":[%s],"minimum_should_match": %d}}}`
 	query_bool_should := `{"bool":{"should":[%s],"minimum_should_match": 1}}`
@@ -1024,7 +1028,7 @@ type ViewCondition struct {
 	Size       int           //数量
 }
 
-//获取用户信息
+// 获取用户信息
 func (s *subscribePush) getUserInfo(spqp *SubPushQueryParam) (vc *ViewCondition) {
 	var isPayBool = false
 	var tmpInfo = struct {
@@ -1113,7 +1117,7 @@ func (s *subscribePush) getUserInfo(spqp *SubPushQueryParam) (vc *ViewCondition)
 	return
 }
 
-//关键词 附加词 排除词
+// 关键词 附加词 排除词
 func getKeyWordArrFromDbResult(a_items []interface{}, item string, index int) (arr []ViewKeyWord) {
 	if a_items == nil {
 		return
@@ -1188,7 +1192,7 @@ func getKeyWordArrFromDbResultByFree(a_items []interface{}, item string, index i
 	return
 }
 
-//地区格式化
+// 地区格式化
 func getStringArrFromDbResult(area map[string]interface{}, i int) (arr []string) {
 	if area == nil {
 		return
@@ -1210,7 +1214,7 @@ func getStringArrFromDbResult(area map[string]interface{}, i int) (arr []string)
 	return
 }
 
-//IsInTsGuide 是否进入向导
+// IsInTsGuide 是否进入向导
 func (s *subscribePush) IsInTsGuide(userid string) bool {
 	if userid == "" {
 		return false

+ 292 - 195
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.28.0
-// 	protoc        v3.15.1
+// 	protoc-gen-go v1.28.1
+// 	protoc        v3.19.4
 // source: bxsubscribe.proto
 
 package bxsubscribe
@@ -44,6 +44,7 @@ type SubscribeInfosReq struct {
 	DeptId     string `protobuf:"bytes,17,opt,name=deptId,proto3" json:"deptId,omitempty"`
 	NewUserId  int64  `protobuf:"varint,18,opt,name=newUserId,proto3" json:"newUserId,omitempty"`
 	IsEnt      bool   `protobuf:"varint,19,opt,name=IsEnt,proto3" json:"IsEnt,omitempty"`
+	SelectIds  string `protobuf:"bytes,20,opt,name=SelectIds,proto3" json:"SelectIds,omitempty"`
 }
 
 func (x *SubscribeInfosReq) Reset() {
@@ -211,6 +212,13 @@ func (x *SubscribeInfosReq) GetIsEnt() bool {
 	return false
 }
 
+func (x *SubscribeInfosReq) GetSelectIds() string {
+	if x != nil {
+		return x.SelectIds
+	}
+	return ""
+}
+
 type SubscribeInfosResp struct {
 	state         protoimpl.MessageState
 	sizeCache     protoimpl.SizeCache
@@ -544,7 +552,6 @@ func (x *SubscribeInfo) GetCaFileExists() bool {
 	return false
 }
 
-//
 type SomeInfoReq struct {
 	state         protoimpl.MessageState
 	sizeCache     protoimpl.SizeCache
@@ -790,7 +797,6 @@ func (x *SomeInfo) GetUserId() string {
 	return ""
 }
 
-//
 type StatusResp struct {
 	state         protoimpl.MessageState
 	sizeCache     protoimpl.SizeCache
@@ -854,6 +860,69 @@ func (x *StatusResp) GetStatus() int64 {
 	return 0
 }
 
+type ByPushHistoryResp struct {
+	state         protoimpl.MessageState
+	sizeCache     protoimpl.SizeCache
+	unknownFields protoimpl.UnknownFields
+
+	ErrorMsg  string `protobuf:"bytes,1,opt,name=error_msg,json=errorMsg,proto3" json:"error_msg,omitempty"`
+	ErrorCode int64  `protobuf:"varint,2,opt,name=error_code,json=errorCode,proto3" json:"error_code,omitempty"`
+	Data      string `protobuf:"bytes,3,opt,name=data,proto3" json:"data,omitempty"`
+}
+
+func (x *ByPushHistoryResp) Reset() {
+	*x = ByPushHistoryResp{}
+	if protoimpl.UnsafeEnabled {
+		mi := &file_bxsubscribe_proto_msgTypes[8]
+		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
+		ms.StoreMessageInfo(mi)
+	}
+}
+
+func (x *ByPushHistoryResp) String() string {
+	return protoimpl.X.MessageStringOf(x)
+}
+
+func (*ByPushHistoryResp) ProtoMessage() {}
+
+func (x *ByPushHistoryResp) ProtoReflect() protoreflect.Message {
+	mi := &file_bxsubscribe_proto_msgTypes[8]
+	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 ByPushHistoryResp.ProtoReflect.Descriptor instead.
+func (*ByPushHistoryResp) Descriptor() ([]byte, []int) {
+	return file_bxsubscribe_proto_rawDescGZIP(), []int{8}
+}
+
+func (x *ByPushHistoryResp) GetErrorMsg() string {
+	if x != nil {
+		return x.ErrorMsg
+	}
+	return ""
+}
+
+func (x *ByPushHistoryResp) GetErrorCode() int64 {
+	if x != nil {
+		return x.ErrorCode
+	}
+	return 0
+}
+
+func (x *ByPushHistoryResp) GetData() string {
+	if x != nil {
+		return x.Data
+	}
+	return ""
+}
+
 type UpdateSubScribeInfoReq struct {
 	state         protoimpl.MessageState
 	sizeCache     protoimpl.SizeCache
@@ -876,7 +945,7 @@ type UpdateSubScribeInfoReq struct {
 func (x *UpdateSubScribeInfoReq) Reset() {
 	*x = UpdateSubScribeInfoReq{}
 	if protoimpl.UnsafeEnabled {
-		mi := &file_bxsubscribe_proto_msgTypes[8]
+		mi := &file_bxsubscribe_proto_msgTypes[9]
 		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
 		ms.StoreMessageInfo(mi)
 	}
@@ -889,7 +958,7 @@ func (x *UpdateSubScribeInfoReq) String() string {
 func (*UpdateSubScribeInfoReq) ProtoMessage() {}
 
 func (x *UpdateSubScribeInfoReq) ProtoReflect() protoreflect.Message {
-	mi := &file_bxsubscribe_proto_msgTypes[8]
+	mi := &file_bxsubscribe_proto_msgTypes[9]
 	if protoimpl.UnsafeEnabled && x != nil {
 		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
 		if ms.LoadMessageInfo() == nil {
@@ -902,7 +971,7 @@ func (x *UpdateSubScribeInfoReq) ProtoReflect() protoreflect.Message {
 
 // Deprecated: Use UpdateSubScribeInfoReq.ProtoReflect.Descriptor instead.
 func (*UpdateSubScribeInfoReq) Descriptor() ([]byte, []int) {
-	return file_bxsubscribe_proto_rawDescGZIP(), []int{8}
+	return file_bxsubscribe_proto_rawDescGZIP(), []int{9}
 }
 
 func (x *UpdateSubScribeInfoReq) GetArea() map[string]*CityList {
@@ -989,7 +1058,7 @@ func (x *UpdateSubScribeInfoReq) GetUserId() string {
 	return ""
 }
 
-//城市
+// 城市
 type CityList struct {
 	state         protoimpl.MessageState
 	sizeCache     protoimpl.SizeCache
@@ -1001,7 +1070,7 @@ type CityList struct {
 func (x *CityList) Reset() {
 	*x = CityList{}
 	if protoimpl.UnsafeEnabled {
-		mi := &file_bxsubscribe_proto_msgTypes[9]
+		mi := &file_bxsubscribe_proto_msgTypes[10]
 		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
 		ms.StoreMessageInfo(mi)
 	}
@@ -1014,7 +1083,7 @@ func (x *CityList) String() string {
 func (*CityList) ProtoMessage() {}
 
 func (x *CityList) ProtoReflect() protoreflect.Message {
-	mi := &file_bxsubscribe_proto_msgTypes[9]
+	mi := &file_bxsubscribe_proto_msgTypes[10]
 	if protoimpl.UnsafeEnabled && x != nil {
 		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
 		if ms.LoadMessageInfo() == nil {
@@ -1027,7 +1096,7 @@ func (x *CityList) ProtoReflect() protoreflect.Message {
 
 // Deprecated: Use CityList.ProtoReflect.Descriptor instead.
 func (*CityList) Descriptor() ([]byte, []int) {
-	return file_bxsubscribe_proto_rawDescGZIP(), []int{9}
+	return file_bxsubscribe_proto_rawDescGZIP(), []int{10}
 }
 
 func (x *CityList) GetCity() []string {
@@ -1037,7 +1106,7 @@ func (x *CityList) GetCity() []string {
 	return nil
 }
 
-//分类
+// 分类
 type Items struct {
 	state         protoimpl.MessageState
 	sizeCache     protoimpl.SizeCache
@@ -1051,7 +1120,7 @@ type Items struct {
 func (x *Items) Reset() {
 	*x = Items{}
 	if protoimpl.UnsafeEnabled {
-		mi := &file_bxsubscribe_proto_msgTypes[10]
+		mi := &file_bxsubscribe_proto_msgTypes[11]
 		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
 		ms.StoreMessageInfo(mi)
 	}
@@ -1064,7 +1133,7 @@ func (x *Items) String() string {
 func (*Items) ProtoMessage() {}
 
 func (x *Items) ProtoReflect() protoreflect.Message {
-	mi := &file_bxsubscribe_proto_msgTypes[10]
+	mi := &file_bxsubscribe_proto_msgTypes[11]
 	if protoimpl.UnsafeEnabled && x != nil {
 		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
 		if ms.LoadMessageInfo() == nil {
@@ -1077,7 +1146,7 @@ func (x *Items) ProtoReflect() protoreflect.Message {
 
 // Deprecated: Use Items.ProtoReflect.Descriptor instead.
 func (*Items) Descriptor() ([]byte, []int) {
-	return file_bxsubscribe_proto_rawDescGZIP(), []int{10}
+	return file_bxsubscribe_proto_rawDescGZIP(), []int{11}
 }
 
 func (x *Items) GetSItem() string {
@@ -1101,7 +1170,7 @@ func (x *Items) GetAKey() []*Keys {
 	return nil
 }
 
-//关键词
+// 关键词
 type Keys struct {
 	state         protoimpl.MessageState
 	sizeCache     protoimpl.SizeCache
@@ -1117,7 +1186,7 @@ type Keys struct {
 func (x *Keys) Reset() {
 	*x = Keys{}
 	if protoimpl.UnsafeEnabled {
-		mi := &file_bxsubscribe_proto_msgTypes[11]
+		mi := &file_bxsubscribe_proto_msgTypes[12]
 		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
 		ms.StoreMessageInfo(mi)
 	}
@@ -1130,7 +1199,7 @@ func (x *Keys) String() string {
 func (*Keys) ProtoMessage() {}
 
 func (x *Keys) ProtoReflect() protoreflect.Message {
-	mi := &file_bxsubscribe_proto_msgTypes[11]
+	mi := &file_bxsubscribe_proto_msgTypes[12]
 	if protoimpl.UnsafeEnabled && x != nil {
 		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
 		if ms.LoadMessageInfo() == nil {
@@ -1143,7 +1212,7 @@ func (x *Keys) ProtoReflect() protoreflect.Message {
 
 // Deprecated: Use Keys.ProtoReflect.Descriptor instead.
 func (*Keys) Descriptor() ([]byte, []int) {
-	return file_bxsubscribe_proto_rawDescGZIP(), []int{11}
+	return file_bxsubscribe_proto_rawDescGZIP(), []int{12}
 }
 
 func (x *Keys) GetKey() []string {
@@ -1186,7 +1255,7 @@ var File_bxsubscribe_proto protoreflect.FileDescriptor
 var file_bxsubscribe_proto_rawDesc = []byte{
 	0x0a, 0x11, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x70, 0x72,
 	0x6f, 0x74, 0x6f, 0x12, 0x0b, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65,
-	0x22, 0x83, 0x04, 0x0a, 0x11, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x49, 0x6e,
+	0x22, 0xa1, 0x04, 0x0a, 0x11, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x49, 0x6e,
 	0x66, 0x6f, 0x73, 0x52, 0x65, 0x71, 0x12, 0x18, 0x0a, 0x07, 0x70, 0x61, 0x67, 0x65, 0x4e, 0x75,
 	0x6d, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x70, 0x61, 0x67, 0x65, 0x4e, 0x75, 0x6d,
 	0x12, 0x1a, 0x0a, 0x08, 0x70, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x02, 0x20, 0x01,
@@ -1218,163 +1287,176 @@ var file_bxsubscribe_proto_rawDesc = []byte{
 	0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x6e, 0x65, 0x77, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x18,
 	0x12, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x6e, 0x65, 0x77, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64,
 	0x12, 0x14, 0x0a, 0x05, 0x49, 0x73, 0x45, 0x6e, 0x74, 0x18, 0x13, 0x20, 0x01, 0x28, 0x08, 0x52,
-	0x05, 0x49, 0x73, 0x45, 0x6e, 0x74, 0x22, 0x78, 0x0a, 0x12, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72,
-	0x69, 0x62, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x73, 0x52, 0x65, 0x73, 0x70, 0x12, 0x19, 0x0a, 0x08,
-	0x65, 0x72, 0x72, 0x5f, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07,
-	0x65, 0x72, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x17, 0x0a, 0x07, 0x65, 0x72, 0x72, 0x5f, 0x6d,
-	0x73, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x65, 0x72, 0x72, 0x4d, 0x73, 0x67,
-	0x12, 0x2e, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a,
-	0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x73, 0x75, 0x62,
-	0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x44, 0x61, 0x74, 0x61, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61,
-	0x22, 0x77, 0x0a, 0x0d, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x44, 0x61, 0x74,
-	0x61, 0x12, 0x14, 0x0a, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03,
-	0x52, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x68, 0x61, 0x73, 0x4e, 0x65,
-	0x78, 0x74, 0x50, 0x61, 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0b, 0x68, 0x61,
-	0x73, 0x4e, 0x65, 0x78, 0x74, 0x50, 0x61, 0x67, 0x65, 0x12, 0x2e, 0x0a, 0x04, 0x6c, 0x69, 0x73,
-	0x74, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73,
-	0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x49,
-	0x6e, 0x66, 0x6f, 0x52, 0x04, 0x6c, 0x69, 0x73, 0x74, 0x22, 0xd4, 0x04, 0x0a, 0x0d, 0x73, 0x75,
-	0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x0f, 0x0a, 0x03, 0x5f,
-	0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05,
-	0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x69, 0x74,
-	0x6c, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x61, 0x72, 0x65, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09,
-	0x52, 0x04, 0x61, 0x72, 0x65, 0x61, 0x12, 0x1e, 0x0a, 0x0a, 0x62, 0x75, 0x79, 0x65, 0x72, 0x43,
-	0x6c, 0x61, 0x73, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x62, 0x75, 0x79, 0x65,
-	0x72, 0x43, 0x6c, 0x61, 0x73, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x75, 0x62, 0x74, 0x79, 0x70,
-	0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x73, 0x75, 0x62, 0x74, 0x79, 0x70, 0x65,
-	0x12, 0x1a, 0x0a, 0x08, 0x69, 0x6e, 0x64, 0x75, 0x73, 0x74, 0x72, 0x79, 0x18, 0x06, 0x20, 0x01,
-	0x28, 0x09, 0x52, 0x08, 0x69, 0x6e, 0x64, 0x75, 0x73, 0x74, 0x72, 0x79, 0x12, 0x20, 0x0a, 0x0b,
-	0x70, 0x75, 0x62, 0x6c, 0x69, 0x73, 0x68, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28,
-	0x03, 0x52, 0x0b, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x73, 0x68, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x19,
-	0x0a, 0x08, 0x63, 0x61, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03,
-	0x52, 0x07, 0x63, 0x61, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x12, 0x17, 0x0a, 0x07, 0x63, 0x61, 0x5f,
-	0x64, 0x61, 0x74, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x63, 0x61, 0x44, 0x61,
-	0x74, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x63, 0x61, 0x5f, 0x69, 0x73, 0x76, 0x69, 0x73, 0x69, 0x74,
-	0x18, 0x0a, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x63, 0x61, 0x49, 0x73, 0x76, 0x69, 0x73, 0x69,
-	0x74, 0x12, 0x17, 0x0a, 0x07, 0x63, 0x61, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x0b, 0x20, 0x01,
-	0x28, 0x03, 0x52, 0x06, 0x63, 0x61, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x6d, 0x61,
-	0x74, 0x63, 0x68, 0x4b, 0x65, 0x79, 0x73, 0x18, 0x0c, 0x20, 0x03, 0x28, 0x09, 0x52, 0x09, 0x6d,
-	0x61, 0x74, 0x63, 0x68, 0x4b, 0x65, 0x79, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x62, 0x75, 0x64, 0x67,
-	0x65, 0x74, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x62, 0x75, 0x64, 0x67, 0x65, 0x74,
-	0x12, 0x1c, 0x0a, 0x09, 0x62, 0x69, 0x64, 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x0e, 0x20,
-	0x01, 0x28, 0x09, 0x52, 0x09, 0x62, 0x69, 0x64, 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x1e,
-	0x0a, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x0f, 0x20, 0x01,
-	0x28, 0x03, 0x52, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x14,
-	0x0a, 0x05, 0x62, 0x75, 0x79, 0x65, 0x72, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x62,
-	0x75, 0x79, 0x65, 0x72, 0x12, 0x20, 0x0a, 0x0b, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x4e,
-	0x61, 0x6d, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x70, 0x72, 0x6f, 0x6a, 0x65,
-	0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x77, 0x69, 0x6e, 0x6e, 0x65, 0x72,
-	0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x77, 0x69, 0x6e, 0x6e, 0x65, 0x72, 0x12, 0x20,
-	0x0a, 0x0b, 0x62, 0x69, 0x64, 0x4f, 0x70, 0x65, 0x6e, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x13, 0x20,
-	0x01, 0x28, 0x09, 0x52, 0x0b, 0x62, 0x69, 0x64, 0x4f, 0x70, 0x65, 0x6e, 0x54, 0x69, 0x6d, 0x65,
-	0x12, 0x19, 0x0a, 0x08, 0x63, 0x61, 0x5f, 0x69, 0x73, 0x76, 0x69, 0x70, 0x18, 0x14, 0x20, 0x01,
-	0x28, 0x03, 0x52, 0x07, 0x63, 0x61, 0x49, 0x73, 0x76, 0x69, 0x70, 0x12, 0x23, 0x0a, 0x0d, 0x63,
-	0x61, 0x5f, 0x66, 0x69, 0x6c, 0x65, 0x45, 0x78, 0x69, 0x73, 0x74, 0x73, 0x18, 0x15, 0x20, 0x01,
-	0x28, 0x08, 0x52, 0x0c, 0x63, 0x61, 0x46, 0x69, 0x6c, 0x65, 0x45, 0x78, 0x69, 0x73, 0x74, 0x73,
-	0x22, 0x75, 0x0a, 0x0b, 0x53, 0x6f, 0x6d, 0x65, 0x49, 0x6e, 0x66, 0x6f, 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, 0x16, 0x0a, 0x06, 0x75, 0x73, 0x65, 0x72, 0x49, 0x64, 0x18,
-	0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x75, 0x73, 0x65, 0x72, 0x49, 0x64, 0x12, 0x1a, 0x0a,
-	0x08, 0x75, 0x73, 0x65, 0x72, 0x54, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52,
-	0x08, 0x75, 0x73, 0x65, 0x72, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x6e, 0x65, 0x77,
-	0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x6e, 0x65,
-	0x77, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x22, 0x6d, 0x0a, 0x0c, 0x53, 0x6f, 0x6d, 0x65, 0x49,
-	0x6e, 0x66, 0x6f, 0x52, 0x65, 0x73, 0x70, 0x12, 0x19, 0x0a, 0x08, 0x65, 0x72, 0x72, 0x5f, 0x63,
-	0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x65, 0x72, 0x72, 0x43, 0x6f,
-	0x64, 0x65, 0x12, 0x17, 0x0a, 0x07, 0x65, 0x72, 0x72, 0x5f, 0x6d, 0x73, 0x67, 0x18, 0x02, 0x20,
-	0x01, 0x28, 0x09, 0x52, 0x06, 0x65, 0x72, 0x72, 0x4d, 0x73, 0x67, 0x12, 0x29, 0x0a, 0x04, 0x64,
-	0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x15, 0x2e, 0x62, 0x78, 0x73, 0x75,
-	0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x6f, 0x6d, 0x65, 0x49, 0x6e, 0x66, 0x6f,
-	0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x22, 0x88, 0x02, 0x0a, 0x08, 0x53, 0x6f, 0x6d, 0x65, 0x49,
-	0x6e, 0x66, 0x6f, 0x12, 0x16, 0x0a, 0x06, 0x68, 0x61, 0x73, 0x4b, 0x65, 0x79, 0x18, 0x01, 0x20,
-	0x01, 0x28, 0x08, 0x52, 0x06, 0x68, 0x61, 0x73, 0x4b, 0x65, 0x79, 0x12, 0x20, 0x0a, 0x0b, 0x69,
-	0x73, 0x49, 0x6e, 0x54, 0x53, 0x67, 0x75, 0x69, 0x64, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08,
-	0x52, 0x0b, 0x69, 0x73, 0x49, 0x6e, 0x54, 0x53, 0x67, 0x75, 0x69, 0x64, 0x65, 0x12, 0x1a, 0x0a,
-	0x08, 0x69, 0x73, 0x45, 0x78, 0x70, 0x69, 0x72, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52,
-	0x08, 0x69, 0x73, 0x45, 0x78, 0x70, 0x69, 0x72, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x69, 0x73, 0x4f,
-	0x6e, 0x54, 0x61, 0x69, 0x6c, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x69, 0x73, 0x4f,
-	0x6e, 0x54, 0x61, 0x69, 0x6c, 0x12, 0x20, 0x0a, 0x0b, 0x69, 0x73, 0x50, 0x61, 0x73, 0x73, 0x43,
-	0x6f, 0x75, 0x6e, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0b, 0x69, 0x73, 0x50, 0x61,
-	0x73, 0x73, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x6f, 0x74, 0x68, 0x65, 0x72,
-	0x46, 0x6c, 0x61, 0x67, 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x6f, 0x74, 0x68, 0x65,
-	0x72, 0x46, 0x6c, 0x61, 0x67, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x73, 0x52, 0x65, 0x61, 0x64, 0x18,
-	0x07, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x69, 0x73, 0x52, 0x65, 0x61, 0x64, 0x12, 0x1a, 0x0a,
-	0x08, 0x69, 0x6e, 0x64, 0x75, 0x73, 0x74, 0x72, 0x79, 0x18, 0x08, 0x20, 0x03, 0x28, 0x09, 0x52,
-	0x08, 0x69, 0x6e, 0x64, 0x75, 0x73, 0x74, 0x72, 0x79, 0x12, 0x16, 0x0a, 0x06, 0x75, 0x73, 0x65,
-	0x72, 0x49, 0x64, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x75, 0x73, 0x65, 0x72, 0x49,
-	0x64, 0x22, 0x60, 0x0a, 0x0a, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x70, 0x12,
-	0x1b, 0x0a, 0x09, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x5f, 0x6d, 0x73, 0x67, 0x18, 0x01, 0x20, 0x01,
-	0x28, 0x09, 0x52, 0x08, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x4d, 0x73, 0x67, 0x12, 0x1d, 0x0a, 0x0a,
-	0x65, 0x72, 0x72, 0x6f, 0x72, 0x5f, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03,
-	0x52, 0x09, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x73,
-	0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x73, 0x74, 0x61,
-	0x74, 0x75, 0x73, 0x22, 0xf9, 0x03, 0x0a, 0x16, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x53, 0x75,
-	0x62, 0x53, 0x63, 0x72, 0x69, 0x62, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x71, 0x12, 0x41,
-	0x0a, 0x04, 0x61, 0x72, 0x65, 0x61, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2d, 0x2e, 0x62,
-	0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74,
+	0x05, 0x49, 0x73, 0x45, 0x6e, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x53, 0x65, 0x6c, 0x65, 0x63, 0x74,
+	0x49, 0x64, 0x73, 0x18, 0x14, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x53, 0x65, 0x6c, 0x65, 0x63,
+	0x74, 0x49, 0x64, 0x73, 0x22, 0x78, 0x0a, 0x12, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62,
+	0x65, 0x49, 0x6e, 0x66, 0x6f, 0x73, 0x52, 0x65, 0x73, 0x70, 0x12, 0x19, 0x0a, 0x08, 0x65, 0x72,
+	0x72, 0x5f, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x65, 0x72,
+	0x72, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x17, 0x0a, 0x07, 0x65, 0x72, 0x72, 0x5f, 0x6d, 0x73, 0x67,
+	0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x65, 0x72, 0x72, 0x4d, 0x73, 0x67, 0x12, 0x2e,
+	0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x62,
+	0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x73, 0x75, 0x62, 0x73, 0x63,
+	0x72, 0x69, 0x62, 0x65, 0x44, 0x61, 0x74, 0x61, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x22, 0x77,
+	0x0a, 0x0d, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x44, 0x61, 0x74, 0x61, 0x12,
+	0x14, 0x0a, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05,
+	0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x68, 0x61, 0x73, 0x4e, 0x65, 0x78, 0x74,
+	0x50, 0x61, 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0b, 0x68, 0x61, 0x73, 0x4e,
+	0x65, 0x78, 0x74, 0x50, 0x61, 0x67, 0x65, 0x12, 0x2e, 0x0a, 0x04, 0x6c, 0x69, 0x73, 0x74, 0x18,
+	0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72,
+	0x69, 0x62, 0x65, 0x2e, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x49, 0x6e, 0x66,
+	0x6f, 0x52, 0x04, 0x6c, 0x69, 0x73, 0x74, 0x22, 0xd4, 0x04, 0x0a, 0x0d, 0x73, 0x75, 0x62, 0x73,
+	0x63, 0x72, 0x69, 0x62, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x0f, 0x0a, 0x03, 0x5f, 0x69, 0x64,
+	0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x69,
+	0x74, 0x6c, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65,
+	0x12, 0x12, 0x0a, 0x04, 0x61, 0x72, 0x65, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04,
+	0x61, 0x72, 0x65, 0x61, 0x12, 0x1e, 0x0a, 0x0a, 0x62, 0x75, 0x79, 0x65, 0x72, 0x43, 0x6c, 0x61,
+	0x73, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x62, 0x75, 0x79, 0x65, 0x72, 0x43,
+	0x6c, 0x61, 0x73, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x75, 0x62, 0x74, 0x79, 0x70, 0x65, 0x18,
+	0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x73, 0x75, 0x62, 0x74, 0x79, 0x70, 0x65, 0x12, 0x1a,
+	0x0a, 0x08, 0x69, 0x6e, 0x64, 0x75, 0x73, 0x74, 0x72, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09,
+	0x52, 0x08, 0x69, 0x6e, 0x64, 0x75, 0x73, 0x74, 0x72, 0x79, 0x12, 0x20, 0x0a, 0x0b, 0x70, 0x75,
+	0x62, 0x6c, 0x69, 0x73, 0x68, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52,
+	0x0b, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x73, 0x68, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x19, 0x0a, 0x08,
+	0x63, 0x61, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07,
+	0x63, 0x61, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x12, 0x17, 0x0a, 0x07, 0x63, 0x61, 0x5f, 0x64, 0x61,
+	0x74, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x63, 0x61, 0x44, 0x61, 0x74, 0x65,
+	0x12, 0x1d, 0x0a, 0x0a, 0x63, 0x61, 0x5f, 0x69, 0x73, 0x76, 0x69, 0x73, 0x69, 0x74, 0x18, 0x0a,
+	0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x63, 0x61, 0x49, 0x73, 0x76, 0x69, 0x73, 0x69, 0x74, 0x12,
+	0x17, 0x0a, 0x07, 0x63, 0x61, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x03,
+	0x52, 0x06, 0x63, 0x61, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x6d, 0x61, 0x74, 0x63,
+	0x68, 0x4b, 0x65, 0x79, 0x73, 0x18, 0x0c, 0x20, 0x03, 0x28, 0x09, 0x52, 0x09, 0x6d, 0x61, 0x74,
+	0x63, 0x68, 0x4b, 0x65, 0x79, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x62, 0x75, 0x64, 0x67, 0x65, 0x74,
+	0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x62, 0x75, 0x64, 0x67, 0x65, 0x74, 0x12, 0x1c,
+	0x0a, 0x09, 0x62, 0x69, 0x64, 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x0e, 0x20, 0x01, 0x28,
+	0x09, 0x52, 0x09, 0x62, 0x69, 0x64, 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x1e, 0x0a, 0x0a,
+	0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03,
+	0x52, 0x0a, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x14, 0x0a, 0x05,
+	0x62, 0x75, 0x79, 0x65, 0x72, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x62, 0x75, 0x79,
+	0x65, 0x72, 0x12, 0x20, 0x0a, 0x0b, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x4e, 0x61, 0x6d,
+	0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74,
+	0x4e, 0x61, 0x6d, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x77, 0x69, 0x6e, 0x6e, 0x65, 0x72, 0x18, 0x12,
+	0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x77, 0x69, 0x6e, 0x6e, 0x65, 0x72, 0x12, 0x20, 0x0a, 0x0b,
+	0x62, 0x69, 0x64, 0x4f, 0x70, 0x65, 0x6e, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x13, 0x20, 0x01, 0x28,
+	0x09, 0x52, 0x0b, 0x62, 0x69, 0x64, 0x4f, 0x70, 0x65, 0x6e, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x19,
+	0x0a, 0x08, 0x63, 0x61, 0x5f, 0x69, 0x73, 0x76, 0x69, 0x70, 0x18, 0x14, 0x20, 0x01, 0x28, 0x03,
+	0x52, 0x07, 0x63, 0x61, 0x49, 0x73, 0x76, 0x69, 0x70, 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x61, 0x5f,
+	0x66, 0x69, 0x6c, 0x65, 0x45, 0x78, 0x69, 0x73, 0x74, 0x73, 0x18, 0x15, 0x20, 0x01, 0x28, 0x08,
+	0x52, 0x0c, 0x63, 0x61, 0x46, 0x69, 0x6c, 0x65, 0x45, 0x78, 0x69, 0x73, 0x74, 0x73, 0x22, 0x75,
+	0x0a, 0x0b, 0x53, 0x6f, 0x6d, 0x65, 0x49, 0x6e, 0x66, 0x6f, 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, 0x16, 0x0a, 0x06, 0x75, 0x73, 0x65, 0x72, 0x49, 0x64, 0x18, 0x02, 0x20,
+	0x01, 0x28, 0x09, 0x52, 0x06, 0x75, 0x73, 0x65, 0x72, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x75,
+	0x73, 0x65, 0x72, 0x54, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x75,
+	0x73, 0x65, 0x72, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x6e, 0x65, 0x77, 0x55, 0x73,
+	0x65, 0x72, 0x49, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x6e, 0x65, 0x77, 0x55,
+	0x73, 0x65, 0x72, 0x49, 0x64, 0x22, 0x6d, 0x0a, 0x0c, 0x53, 0x6f, 0x6d, 0x65, 0x49, 0x6e, 0x66,
+	0x6f, 0x52, 0x65, 0x73, 0x70, 0x12, 0x19, 0x0a, 0x08, 0x65, 0x72, 0x72, 0x5f, 0x63, 0x6f, 0x64,
+	0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x65, 0x72, 0x72, 0x43, 0x6f, 0x64, 0x65,
+	0x12, 0x17, 0x0a, 0x07, 0x65, 0x72, 0x72, 0x5f, 0x6d, 0x73, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28,
+	0x09, 0x52, 0x06, 0x65, 0x72, 0x72, 0x4d, 0x73, 0x67, 0x12, 0x29, 0x0a, 0x04, 0x64, 0x61, 0x74,
+	0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x15, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73,
+	0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x53, 0x6f, 0x6d, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x04,
+	0x64, 0x61, 0x74, 0x61, 0x22, 0x88, 0x02, 0x0a, 0x08, 0x53, 0x6f, 0x6d, 0x65, 0x49, 0x6e, 0x66,
+	0x6f, 0x12, 0x16, 0x0a, 0x06, 0x68, 0x61, 0x73, 0x4b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28,
+	0x08, 0x52, 0x06, 0x68, 0x61, 0x73, 0x4b, 0x65, 0x79, 0x12, 0x20, 0x0a, 0x0b, 0x69, 0x73, 0x49,
+	0x6e, 0x54, 0x53, 0x67, 0x75, 0x69, 0x64, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0b,
+	0x69, 0x73, 0x49, 0x6e, 0x54, 0x53, 0x67, 0x75, 0x69, 0x64, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x69,
+	0x73, 0x45, 0x78, 0x70, 0x69, 0x72, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x69,
+	0x73, 0x45, 0x78, 0x70, 0x69, 0x72, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x69, 0x73, 0x4f, 0x6e, 0x54,
+	0x61, 0x69, 0x6c, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x69, 0x73, 0x4f, 0x6e, 0x54,
+	0x61, 0x69, 0x6c, 0x12, 0x20, 0x0a, 0x0b, 0x69, 0x73, 0x50, 0x61, 0x73, 0x73, 0x43, 0x6f, 0x75,
+	0x6e, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0b, 0x69, 0x73, 0x50, 0x61, 0x73, 0x73,
+	0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x6f, 0x74, 0x68, 0x65, 0x72, 0x46, 0x6c,
+	0x61, 0x67, 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x6f, 0x74, 0x68, 0x65, 0x72, 0x46,
+	0x6c, 0x61, 0x67, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x73, 0x52, 0x65, 0x61, 0x64, 0x18, 0x07, 0x20,
+	0x01, 0x28, 0x08, 0x52, 0x06, 0x69, 0x73, 0x52, 0x65, 0x61, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x69,
+	0x6e, 0x64, 0x75, 0x73, 0x74, 0x72, 0x79, 0x18, 0x08, 0x20, 0x03, 0x28, 0x09, 0x52, 0x08, 0x69,
+	0x6e, 0x64, 0x75, 0x73, 0x74, 0x72, 0x79, 0x12, 0x16, 0x0a, 0x06, 0x75, 0x73, 0x65, 0x72, 0x49,
+	0x64, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x75, 0x73, 0x65, 0x72, 0x49, 0x64, 0x22,
+	0x60, 0x0a, 0x0a, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x70, 0x12, 0x1b, 0x0a,
+	0x09, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x5f, 0x6d, 0x73, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
+	0x52, 0x08, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x4d, 0x73, 0x67, 0x12, 0x1d, 0x0a, 0x0a, 0x65, 0x72,
+	0x72, 0x6f, 0x72, 0x5f, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09,
+	0x65, 0x72, 0x72, 0x6f, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x74, 0x61,
+	0x74, 0x75, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75,
+	0x73, 0x22, 0x63, 0x0a, 0x11, 0x42, 0x79, 0x50, 0x75, 0x73, 0x68, 0x48, 0x69, 0x73, 0x74, 0x6f,
+	0x72, 0x79, 0x52, 0x65, 0x73, 0x70, 0x12, 0x1b, 0x0a, 0x09, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x5f,
+	0x6d, 0x73, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x65, 0x72, 0x72, 0x6f, 0x72,
+	0x4d, 0x73, 0x67, 0x12, 0x1d, 0x0a, 0x0a, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x5f, 0x63, 0x6f, 0x64,
+	0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x43, 0x6f,
+	0x64, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09,
+	0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x22, 0xf9, 0x03, 0x0a, 0x16, 0x55, 0x70, 0x64, 0x61, 0x74,
 	0x65, 0x53, 0x75, 0x62, 0x53, 0x63, 0x72, 0x69, 0x62, 0x65, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65,
-	0x71, 0x2e, 0x41, 0x72, 0x65, 0x61, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x04, 0x61, 0x72, 0x65,
-	0x61, 0x12, 0x1e, 0x0a, 0x0a, 0x62, 0x75, 0x79, 0x65, 0x72, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x18,
-	0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x0a, 0x62, 0x75, 0x79, 0x65, 0x72, 0x63, 0x6c, 0x61, 0x73,
-	0x73, 0x12, 0x28, 0x0a, 0x05, 0x69, 0x74, 0x65, 0x6d, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b,
-	0x32, 0x12, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x49,
-	0x74, 0x65, 0x6d, 0x73, 0x52, 0x05, 0x69, 0x74, 0x65, 0x6d, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x69,
-	0x6e, 0x66, 0x6f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x04, 0x20, 0x03, 0x28, 0x09, 0x52, 0x08, 0x69,
-	0x6e, 0x66, 0x6f, 0x74, 0x79, 0x70, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x6d, 0x61, 0x74, 0x63, 0x68,
-	0x77, 0x61, 0x79, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x6d, 0x61, 0x74, 0x63, 0x68,
-	0x77, 0x61, 0x79, 0x12, 0x22, 0x0a, 0x0c, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x6d, 0x61,
-	0x74, 0x63, 0x68, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x70, 0x72, 0x6f, 0x6a, 0x65,
-	0x63, 0x74, 0x6d, 0x61, 0x74, 0x63, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x72, 0x61, 0x74, 0x65, 0x6d,
-	0x6f, 0x64, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x72, 0x61, 0x74, 0x65, 0x6d,
-	0x6f, 0x64, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x61, 0x70, 0x70, 0x70, 0x75, 0x73, 0x68, 0x18, 0x08,
-	0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x61, 0x70, 0x70, 0x70, 0x75, 0x73, 0x68, 0x12, 0x1a, 0x0a,
-	0x08, 0x6d, 0x61, 0x69, 0x6c, 0x70, 0x75, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52,
-	0x08, 0x6d, 0x61, 0x69, 0x6c, 0x70, 0x75, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x6d, 0x61, 0x69,
-	0x6c, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6d, 0x61, 0x69, 0x6c, 0x12, 0x28, 0x0a,
-	0x0f, 0x6f, 0x74, 0x68, 0x65, 0x72, 0x62, 0x75, 0x79, 0x65, 0x72, 0x63, 0x6c, 0x61, 0x73, 0x73,
-	0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0f, 0x6f, 0x74, 0x68, 0x65, 0x72, 0x62, 0x75, 0x79,
-	0x65, 0x72, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x75, 0x73, 0x65, 0x72, 0x49,
-	0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x75, 0x73, 0x65, 0x72, 0x49, 0x64, 0x1a,
-	0x4e, 0x0a, 0x09, 0x41, 0x72, 0x65, 0x61, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03,
-	0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x2b,
-	0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x15, 0x2e,
-	0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x43, 0x69, 0x74, 0x79,
-	0x4c, 0x69, 0x73, 0x74, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22,
-	0x1e, 0x0a, 0x08, 0x43, 0x69, 0x74, 0x79, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x63,
-	0x69, 0x74, 0x79, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x04, 0x63, 0x69, 0x74, 0x79, 0x22,
-	0x66, 0x0a, 0x05, 0x49, 0x74, 0x65, 0x6d, 0x73, 0x12, 0x15, 0x0a, 0x06, 0x73, 0x5f, 0x69, 0x74,
-	0x65, 0x6d, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x73, 0x49, 0x74, 0x65, 0x6d, 0x12,
-	0x1e, 0x0a, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x02, 0x20,
-	0x01, 0x28, 0x03, 0x52, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12,
-	0x26, 0x0a, 0x05, 0x61, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x11,
-	0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x4b, 0x65, 0x79,
-	0x73, 0x52, 0x04, 0x61, 0x4b, 0x65, 0x79, 0x22, 0x8a, 0x01, 0x0a, 0x04, 0x4b, 0x65, 0x79, 0x73,
-	0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x03, 0x6b,
-	0x65, 0x79, 0x12, 0x16, 0x0a, 0x06, 0x6e, 0x6f, 0x74, 0x6b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x03,
-	0x28, 0x09, 0x52, 0x06, 0x6e, 0x6f, 0x74, 0x6b, 0x65, 0x79, 0x12, 0x1e, 0x0a, 0x0a, 0x75, 0x70,
-	0x64, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a,
-	0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x6d, 0x61,
-	0x74, 0x63, 0x68, 0x77, 0x61, 0x79, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x6d, 0x61,
-	0x74, 0x63, 0x68, 0x77, 0x61, 0x79, 0x12, 0x1c, 0x0a, 0x09, 0x61, 0x70, 0x70, 0x65, 0x6e, 0x64,
-	0x4b, 0x65, 0x79, 0x18, 0x05, 0x20, 0x03, 0x28, 0x09, 0x52, 0x09, 0x61, 0x70, 0x70, 0x65, 0x6e,
-	0x64, 0x4b, 0x65, 0x79, 0x32, 0xf8, 0x01, 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,
+	0x71, 0x12, 0x41, 0x0a, 0x04, 0x61, 0x72, 0x65, 0x61, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32,
+	0x2d, 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, 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,
+	0x6f, 0x52, 0x65, 0x71, 0x2e, 0x41, 0x72, 0x65, 0x61, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x04,
+	0x61, 0x72, 0x65, 0x61, 0x12, 0x1e, 0x0a, 0x0a, 0x62, 0x75, 0x79, 0x65, 0x72, 0x63, 0x6c, 0x61,
+	0x73, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x0a, 0x62, 0x75, 0x79, 0x65, 0x72, 0x63,
+	0x6c, 0x61, 0x73, 0x73, 0x12, 0x28, 0x0a, 0x05, 0x69, 0x74, 0x65, 0x6d, 0x73, 0x18, 0x03, 0x20,
+	0x03, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62,
+	0x65, 0x2e, 0x49, 0x74, 0x65, 0x6d, 0x73, 0x52, 0x05, 0x69, 0x74, 0x65, 0x6d, 0x73, 0x12, 0x1a,
+	0x0a, 0x08, 0x69, 0x6e, 0x66, 0x6f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x04, 0x20, 0x03, 0x28, 0x09,
+	0x52, 0x08, 0x69, 0x6e, 0x66, 0x6f, 0x74, 0x79, 0x70, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x6d, 0x61,
+	0x74, 0x63, 0x68, 0x77, 0x61, 0x79, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x6d, 0x61,
+	0x74, 0x63, 0x68, 0x77, 0x61, 0x79, 0x12, 0x22, 0x0a, 0x0c, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63,
+	0x74, 0x6d, 0x61, 0x74, 0x63, 0x68, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x70, 0x72,
+	0x6f, 0x6a, 0x65, 0x63, 0x74, 0x6d, 0x61, 0x74, 0x63, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x72, 0x61,
+	0x74, 0x65, 0x6d, 0x6f, 0x64, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x72, 0x61,
+	0x74, 0x65, 0x6d, 0x6f, 0x64, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x61, 0x70, 0x70, 0x70, 0x75, 0x73,
+	0x68, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x61, 0x70, 0x70, 0x70, 0x75, 0x73, 0x68,
+	0x12, 0x1a, 0x0a, 0x08, 0x6d, 0x61, 0x69, 0x6c, 0x70, 0x75, 0x73, 0x68, 0x18, 0x09, 0x20, 0x01,
+	0x28, 0x09, 0x52, 0x08, 0x6d, 0x61, 0x69, 0x6c, 0x70, 0x75, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04,
+	0x6d, 0x61, 0x69, 0x6c, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6d, 0x61, 0x69, 0x6c,
+	0x12, 0x28, 0x0a, 0x0f, 0x6f, 0x74, 0x68, 0x65, 0x72, 0x62, 0x75, 0x79, 0x65, 0x72, 0x63, 0x6c,
+	0x61, 0x73, 0x73, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0f, 0x6f, 0x74, 0x68, 0x65, 0x72,
+	0x62, 0x75, 0x79, 0x65, 0x72, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x75, 0x73,
+	0x65, 0x72, 0x49, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x75, 0x73, 0x65, 0x72,
+	0x49, 0x64, 0x1a, 0x4e, 0x0a, 0x09, 0x41, 0x72, 0x65, 0x61, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12,
+	0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65,
+	0x79, 0x12, 0x2b, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b,
+	0x32, 0x15, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e, 0x43,
+	0x69, 0x74, 0x79, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02,
+	0x38, 0x01, 0x22, 0x1e, 0x0a, 0x08, 0x43, 0x69, 0x74, 0x79, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x12,
+	0x0a, 0x04, 0x63, 0x69, 0x74, 0x79, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x04, 0x63, 0x69,
+	0x74, 0x79, 0x22, 0x66, 0x0a, 0x05, 0x49, 0x74, 0x65, 0x6d, 0x73, 0x12, 0x15, 0x0a, 0x06, 0x73,
+	0x5f, 0x69, 0x74, 0x65, 0x6d, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x73, 0x49, 0x74,
+	0x65, 0x6d, 0x12, 0x1e, 0x0a, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65,
+	0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, 0x69,
+	0x6d, 0x65, 0x12, 0x26, 0x0a, 0x05, 0x61, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x03, 0x20, 0x03, 0x28,
+	0x0b, 0x32, 0x11, 0x2e, 0x62, 0x78, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2e,
+	0x4b, 0x65, 0x79, 0x73, 0x52, 0x04, 0x61, 0x4b, 0x65, 0x79, 0x22, 0x8a, 0x01, 0x0a, 0x04, 0x4b,
+	0x65, 0x79, 0x73, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09,
+	0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x16, 0x0a, 0x06, 0x6e, 0x6f, 0x74, 0x6b, 0x65, 0x79, 0x18,
+	0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x06, 0x6e, 0x6f, 0x74, 0x6b, 0x65, 0x79, 0x12, 0x1e, 0x0a,
+	0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28,
+	0x03, 0x52, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x1a, 0x0a,
+	0x08, 0x6d, 0x61, 0x74, 0x63, 0x68, 0x77, 0x61, 0x79, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52,
+	0x08, 0x6d, 0x61, 0x74, 0x63, 0x68, 0x77, 0x61, 0x79, 0x12, 0x1c, 0x0a, 0x09, 0x61, 0x70, 0x70,
+	0x65, 0x6e, 0x64, 0x4b, 0x65, 0x79, 0x18, 0x05, 0x20, 0x03, 0x28, 0x09, 0x52, 0x09, 0x61, 0x70,
+	0x70, 0x65, 0x6e, 0x64, 0x4b, 0x65, 0x79, 0x32, 0xc9, 0x02, 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, 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, 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 (
@@ -1389,7 +1471,7 @@ func file_bxsubscribe_proto_rawDescGZIP() []byte {
 	return file_bxsubscribe_proto_rawDescData
 }
 
-var file_bxsubscribe_proto_msgTypes = make([]protoimpl.MessageInfo, 13)
+var file_bxsubscribe_proto_msgTypes = make([]protoimpl.MessageInfo, 14)
 var file_bxsubscribe_proto_goTypes = []interface{}{
 	(*SubscribeInfosReq)(nil),      // 0: bxsubscribe.SubscribeInfosReq
 	(*SubscribeInfosResp)(nil),     // 1: bxsubscribe.SubscribeInfosResp
@@ -1399,28 +1481,31 @@ var file_bxsubscribe_proto_goTypes = []interface{}{
 	(*SomeInfoResp)(nil),           // 5: bxsubscribe.SomeInfoResp
 	(*SomeInfo)(nil),               // 6: bxsubscribe.SomeInfo
 	(*StatusResp)(nil),             // 7: bxsubscribe.StatusResp
-	(*UpdateSubScribeInfoReq)(nil), // 8: bxsubscribe.UpdateSubScribeInfoReq
-	(*CityList)(nil),               // 9: bxsubscribe.CityList
-	(*Items)(nil),                  // 10: bxsubscribe.Items
-	(*Keys)(nil),                   // 11: bxsubscribe.Keys
-	nil,                            // 12: bxsubscribe.UpdateSubScribeInfoReq.AreaEntry
+	(*ByPushHistoryResp)(nil),      // 8: bxsubscribe.ByPushHistoryResp
+	(*UpdateSubScribeInfoReq)(nil), // 9: bxsubscribe.UpdateSubScribeInfoReq
+	(*CityList)(nil),               // 10: bxsubscribe.CityList
+	(*Items)(nil),                  // 11: bxsubscribe.Items
+	(*Keys)(nil),                   // 12: bxsubscribe.Keys
+	nil,                            // 13: bxsubscribe.UpdateSubScribeInfoReq.AreaEntry
 }
 var file_bxsubscribe_proto_depIdxs = []int32{
 	2,  // 0: bxsubscribe.SubscribeInfosResp.data:type_name -> bxsubscribe.subscribeData
 	3,  // 1: bxsubscribe.subscribeData.list:type_name -> bxsubscribe.subscribeInfo
 	6,  // 2: bxsubscribe.SomeInfoResp.data:type_name -> bxsubscribe.SomeInfo
-	12, // 3: bxsubscribe.UpdateSubScribeInfoReq.area:type_name -> bxsubscribe.UpdateSubScribeInfoReq.AreaEntry
-	10, // 4: bxsubscribe.UpdateSubScribeInfoReq.items:type_name -> bxsubscribe.Items
-	11, // 5: bxsubscribe.Items.a_key:type_name -> bxsubscribe.Keys
-	9,  // 6: bxsubscribe.UpdateSubScribeInfoReq.AreaEntry.value:type_name -> bxsubscribe.CityList
+	13, // 3: bxsubscribe.UpdateSubScribeInfoReq.area:type_name -> bxsubscribe.UpdateSubScribeInfoReq.AreaEntry
+	11, // 4: bxsubscribe.UpdateSubScribeInfoReq.items:type_name -> bxsubscribe.Items
+	12, // 5: bxsubscribe.Items.a_key:type_name -> bxsubscribe.Keys
+	10, // 6: bxsubscribe.UpdateSubScribeInfoReq.AreaEntry.value:type_name -> bxsubscribe.CityList
 	0,  // 7: bxsubscribe.Bxsubscribe.GetSubList:input_type -> bxsubscribe.SubscribeInfosReq
 	4,  // 8: bxsubscribe.Bxsubscribe.GetSubSomeInfo:input_type -> bxsubscribe.SomeInfoReq
-	8,  // 9: bxsubscribe.Bxsubscribe.UpdateSubScribeInfo:input_type -> bxsubscribe.UpdateSubScribeInfoReq
-	1,  // 10: bxsubscribe.Bxsubscribe.GetSubList:output_type -> bxsubscribe.SubscribeInfosResp
-	5,  // 11: bxsubscribe.Bxsubscribe.GetSubSomeInfo:output_type -> bxsubscribe.SomeInfoResp
-	7,  // 12: bxsubscribe.Bxsubscribe.UpdateSubScribeInfo:output_type -> bxsubscribe.StatusResp
-	10, // [10:13] is the sub-list for method output_type
-	7,  // [7:10] is the sub-list for method input_type
+	9,  // 9: bxsubscribe.Bxsubscribe.UpdateSubScribeInfo:input_type -> bxsubscribe.UpdateSubScribeInfoReq
+	0,  // 10: bxsubscribe.Bxsubscribe.ByPushHistory:input_type -> bxsubscribe.SubscribeInfosReq
+	1,  // 11: bxsubscribe.Bxsubscribe.GetSubList:output_type -> bxsubscribe.SubscribeInfosResp
+	5,  // 12: bxsubscribe.Bxsubscribe.GetSubSomeInfo:output_type -> bxsubscribe.SomeInfoResp
+	7,  // 13: bxsubscribe.Bxsubscribe.UpdateSubScribeInfo:output_type -> bxsubscribe.StatusResp
+	8,  // 14: bxsubscribe.Bxsubscribe.ByPushHistory:output_type -> bxsubscribe.ByPushHistoryResp
+	11, // [11:15] is the sub-list for method output_type
+	7,  // [7:11] is the sub-list for method input_type
 	7,  // [7:7] is the sub-list for extension type_name
 	7,  // [7:7] is the sub-list for extension extendee
 	0,  // [0:7] is the sub-list for field type_name
@@ -1529,7 +1614,7 @@ func file_bxsubscribe_proto_init() {
 			}
 		}
 		file_bxsubscribe_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} {
-			switch v := v.(*UpdateSubScribeInfoReq); i {
+			switch v := v.(*ByPushHistoryResp); i {
 			case 0:
 				return &v.state
 			case 1:
@@ -1541,7 +1626,7 @@ func file_bxsubscribe_proto_init() {
 			}
 		}
 		file_bxsubscribe_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} {
-			switch v := v.(*CityList); i {
+			switch v := v.(*UpdateSubScribeInfoReq); i {
 			case 0:
 				return &v.state
 			case 1:
@@ -1553,7 +1638,7 @@ func file_bxsubscribe_proto_init() {
 			}
 		}
 		file_bxsubscribe_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} {
-			switch v := v.(*Items); i {
+			switch v := v.(*CityList); i {
 			case 0:
 				return &v.state
 			case 1:
@@ -1565,6 +1650,18 @@ func file_bxsubscribe_proto_init() {
 			}
 		}
 		file_bxsubscribe_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} {
+			switch v := v.(*Items); i {
+			case 0:
+				return &v.state
+			case 1:
+				return &v.sizeCache
+			case 2:
+				return &v.unknownFields
+			default:
+				return nil
+			}
+		}
+		file_bxsubscribe_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} {
 			switch v := v.(*Keys); i {
 			case 0:
 				return &v.state
@@ -1583,7 +1680,7 @@ func file_bxsubscribe_proto_init() {
 			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
 			RawDescriptor: file_bxsubscribe_proto_rawDesc,
 			NumEnums:      0,
-			NumMessages:   13,
+			NumMessages:   14,
 			NumExtensions: 0,
 			NumServices:   1,
 		},

+ 45 - 7
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.2.0
-// - protoc             v3.15.1
+// - protoc             v3.19.4
 // source: bxsubscribe.proto
 
 package bxsubscribe
@@ -22,12 +22,14 @@ const _ = grpc.SupportPackageIsVersion7
 //
 // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
 type BxsubscribeClient interface {
-	//获取订阅推送列表
+	// 获取订阅推送列表
 	GetSubList(ctx context.Context, in *SubscribeInfosReq, opts ...grpc.CallOption) (*SubscribeInfosResp, error)
-	//获取订阅推送相关信息
+	// 获取订阅推送相关信息
 	GetSubSomeInfo(ctx context.Context, in *SomeInfoReq, opts ...grpc.CallOption) (*SomeInfoResp, error)
-	//修改订阅信息接口
+	// 修改订阅信息接口
 	UpdateSubScribeInfo(ctx context.Context, in *UpdateSubScribeInfoReq, opts ...grpc.CallOption) (*StatusResp, error)
+	// 推送页面筛选导出
+	ByPushHistory(ctx context.Context, in *SubscribeInfosReq, opts ...grpc.CallOption) (*ByPushHistoryResp, error)
 }
 
 type bxsubscribeClient struct {
@@ -65,16 +67,27 @@ func (c *bxsubscribeClient) UpdateSubScribeInfo(ctx context.Context, in *UpdateS
 	return out, nil
 }
 
+func (c *bxsubscribeClient) ByPushHistory(ctx context.Context, in *SubscribeInfosReq, opts ...grpc.CallOption) (*ByPushHistoryResp, error) {
+	out := new(ByPushHistoryResp)
+	err := c.cc.Invoke(ctx, "/bxsubscribe.Bxsubscribe/ByPushHistory", 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
 type BxsubscribeServer interface {
-	//获取订阅推送列表
+	// 获取订阅推送列表
 	GetSubList(context.Context, *SubscribeInfosReq) (*SubscribeInfosResp, error)
-	//获取订阅推送相关信息
+	// 获取订阅推送相关信息
 	GetSubSomeInfo(context.Context, *SomeInfoReq) (*SomeInfoResp, error)
-	//修改订阅信息接口
+	// 修改订阅信息接口
 	UpdateSubScribeInfo(context.Context, *UpdateSubScribeInfoReq) (*StatusResp, error)
+	// 推送页面筛选导出
+	ByPushHistory(context.Context, *SubscribeInfosReq) (*ByPushHistoryResp, error)
 	mustEmbedUnimplementedBxsubscribeServer()
 }
 
@@ -91,6 +104,9 @@ func (UnimplementedBxsubscribeServer) GetSubSomeInfo(context.Context, *SomeInfoR
 func (UnimplementedBxsubscribeServer) UpdateSubScribeInfo(context.Context, *UpdateSubScribeInfoReq) (*StatusResp, error) {
 	return nil, status.Errorf(codes.Unimplemented, "method UpdateSubScribeInfo not implemented")
 }
+func (UnimplementedBxsubscribeServer) ByPushHistory(context.Context, *SubscribeInfosReq) (*ByPushHistoryResp, error) {
+	return nil, status.Errorf(codes.Unimplemented, "method ByPushHistory not implemented")
+}
 func (UnimplementedBxsubscribeServer) mustEmbedUnimplementedBxsubscribeServer() {}
 
 // UnsafeBxsubscribeServer may be embedded to opt out of forward compatibility for this service.
@@ -158,6 +174,24 @@ func _Bxsubscribe_UpdateSubScribeInfo_Handler(srv interface{}, ctx context.Conte
 	return interceptor(ctx, in, info, handler)
 }
 
+func _Bxsubscribe_ByPushHistory_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
+	in := new(SubscribeInfosReq)
+	if err := dec(in); err != nil {
+		return nil, err
+	}
+	if interceptor == nil {
+		return srv.(BxsubscribeServer).ByPushHistory(ctx, in)
+	}
+	info := &grpc.UnaryServerInfo{
+		Server:     srv,
+		FullMethod: "/bxsubscribe.Bxsubscribe/ByPushHistory",
+	}
+	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
+		return srv.(BxsubscribeServer).ByPushHistory(ctx, req.(*SubscribeInfosReq))
+	}
+	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)
@@ -177,6 +211,10 @@ var Bxsubscribe_ServiceDesc = grpc.ServiceDesc{
 			MethodName: "UpdateSubScribeInfo",
 			Handler:    _Bxsubscribe_UpdateSubScribeInfo_Handler,
 		},
+		{
+			MethodName: "ByPushHistory",
+			Handler:    _Bxsubscribe_ByPushHistory_Handler,
+		},
 	},
 	Streams:  []grpc.StreamDesc{},
 	Metadata: "bxsubscribe.proto",

+ 21 - 0
jyBXSubscribe/rpc/util/util.go

@@ -0,0 +1,21 @@
+package util
+
+import (
+	"app.yhyue.com/moapp/jybase/encrypt"
+)
+
+// 加密
+func EncodeId(sid string) string {
+	if sid == "" {
+		return ""
+	}
+	return encrypt.EncodeArticleId2ByCheck(sid)
+}
+
+// 解密
+func DecodeId(eid string) string {
+	if eid == "" {
+		return ""
+	}
+	return encrypt.DecodeArticleId2ByCheck(eid)[0]
+}