diff --git a/comm/imodule.go b/comm/imodule.go index 14b4a6d63..7921209b9 100644 --- a/comm/imodule.go +++ b/comm/imodule.go @@ -8,7 +8,7 @@ import ( type ( //红点获取接口 IGetReddot interface { - Reddot(session IUserSession, rid ...ReddotType) (reddot map[ReddotType]bool) + Reddot(session IUserSession, rid ...ReddotType) (reddot map[ReddotType]*pb.ReddotItem) } //埋点中心更新通知 IBuriedUpdateNotify interface { @@ -514,6 +514,6 @@ type ( //红点模块接口 IReddot interface { //推送红点 - PushReddot(session IUserSession, reddot ...ReddotType) (errdata *pb.ErrorData) + PushReddot(session IUserSession, reddot ...*pb.ReddotItem) (errdata *pb.ErrorData) } ) diff --git a/modules/reddot/api_get.go b/modules/reddot/api_get.go index 881c0762b..4b5c9e69a 100644 --- a/modules/reddot/api_get.go +++ b/modules/reddot/api_get.go @@ -14,7 +14,7 @@ func (this *apiComp) GetCheck(session comm.IUserSession, req *pb.ReddotGetReq) ( ///获取系统公告 func (this *apiComp) Get(session comm.IUserSession, req *pb.ReddotGetReq) (errdata *pb.ErrorData) { var ( - reddot map[int32]bool = make(map[int32]bool) + reddot map[int32]*pb.ReddotItem = make(map[int32]*pb.ReddotItem) ) if errdata = this.GetCheck(session, req); errdata != nil { return diff --git a/modules/reddot/api_getall.go b/modules/reddot/api_getall.go index e8683181f..0417465c7 100644 --- a/modules/reddot/api_getall.go +++ b/modules/reddot/api_getall.go @@ -14,7 +14,7 @@ func (this *apiComp) GetAllCheck(session comm.IUserSession, req *pb.ReddotGetAll ///获取系统公告 func (this *apiComp) GetAll(session comm.IUserSession, req *pb.ReddotGetAllReq) (errdata *pb.ErrorData) { var ( - reddot map[int32]bool = make(map[int32]bool) + reddot map[int32]*pb.ReddotItem = make(map[int32]*pb.ReddotItem) ) if errdata = this.GetAllCheck(session, req); errdata != nil { return diff --git a/modules/reddot/module.go b/modules/reddot/module.go index c73bb17cc..86c0a73c7 100644 --- a/modules/reddot/module.go +++ b/modules/reddot/module.go @@ -117,14 +117,10 @@ func (this *Reddot) OnInstallComp() { } //推送红点 -func (this *Reddot) PushReddot(session comm.IUserSession, reddot ...comm.ReddotType) (errdata *pb.ErrorData) { +func (this *Reddot) PushReddot(session comm.IUserSession, reddot ...*pb.ReddotItem) (errdata *pb.ErrorData) { if len(reddot) <= 0 { return } - rids := make([]int32, len(reddot)) - for i, v := range reddot { - rids[i] = int32(v) - } - session.SendMsg(string(this.GetType()), "change", &pb.ReddotChangePush{Rids: rids}) + session.SendMsg(string(this.GetType()), "change", &pb.ReddotChangePush{Rids: reddot}) return } diff --git a/pb/reddot_msg.pb.go b/pb/reddot_msg.pb.go index 8f2e9b3ad..69b4af976 100644 --- a/pb/reddot_msg.pb.go +++ b/pb/reddot_msg.pb.go @@ -20,6 +20,69 @@ const ( _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) ) +type ReddotItem struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Rid int32 `protobuf:"varint,1,opt,name=rid,proto3" json:"rid"` //红点id + Activated bool `protobuf:"varint,2,opt,name=activated,proto3" json:"activated"` //是否激活 + Nextchanagetime int64 `protobuf:"varint,3,opt,name=nextchanagetime,proto3" json:"nextchanagetime"` //下次变化时间 为0 不处理 +} + +func (x *ReddotItem) Reset() { + *x = ReddotItem{} + if protoimpl.UnsafeEnabled { + mi := &file_reddot_reddot_msg_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ReddotItem) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ReddotItem) ProtoMessage() {} + +func (x *ReddotItem) ProtoReflect() protoreflect.Message { + mi := &file_reddot_reddot_msg_proto_msgTypes[0] + 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 ReddotItem.ProtoReflect.Descriptor instead. +func (*ReddotItem) Descriptor() ([]byte, []int) { + return file_reddot_reddot_msg_proto_rawDescGZIP(), []int{0} +} + +func (x *ReddotItem) GetRid() int32 { + if x != nil { + return x.Rid + } + return 0 +} + +func (x *ReddotItem) GetActivated() bool { + if x != nil { + return x.Activated + } + return false +} + +func (x *ReddotItem) GetNextchanagetime() int64 { + if x != nil { + return x.Nextchanagetime + } + return 0 +} + //红点信息请求 type ReddotGetAllReq struct { state protoimpl.MessageState @@ -30,7 +93,7 @@ type ReddotGetAllReq struct { func (x *ReddotGetAllReq) Reset() { *x = ReddotGetAllReq{} if protoimpl.UnsafeEnabled { - mi := &file_reddot_reddot_msg_proto_msgTypes[0] + mi := &file_reddot_reddot_msg_proto_msgTypes[1] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -43,7 +106,7 @@ func (x *ReddotGetAllReq) String() string { func (*ReddotGetAllReq) ProtoMessage() {} func (x *ReddotGetAllReq) ProtoReflect() protoreflect.Message { - mi := &file_reddot_reddot_msg_proto_msgTypes[0] + mi := &file_reddot_reddot_msg_proto_msgTypes[1] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -56,7 +119,7 @@ func (x *ReddotGetAllReq) ProtoReflect() protoreflect.Message { // Deprecated: Use ReddotGetAllReq.ProtoReflect.Descriptor instead. func (*ReddotGetAllReq) Descriptor() ([]byte, []int) { - return file_reddot_reddot_msg_proto_rawDescGZIP(), []int{0} + return file_reddot_reddot_msg_proto_rawDescGZIP(), []int{1} } type ReddotGetAllResp struct { @@ -64,13 +127,13 @@ type ReddotGetAllResp struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Reddot map[int32]bool `protobuf:"bytes,1,rep,name=reddot,proto3" json:"reddot" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3"` //红点信息 + Reddot map[int32]*ReddotItem `protobuf:"bytes,1,rep,name=reddot,proto3" json:"reddot" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` //红点信息 } func (x *ReddotGetAllResp) Reset() { *x = ReddotGetAllResp{} if protoimpl.UnsafeEnabled { - mi := &file_reddot_reddot_msg_proto_msgTypes[1] + mi := &file_reddot_reddot_msg_proto_msgTypes[2] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -83,7 +146,7 @@ func (x *ReddotGetAllResp) String() string { func (*ReddotGetAllResp) ProtoMessage() {} func (x *ReddotGetAllResp) ProtoReflect() protoreflect.Message { - mi := &file_reddot_reddot_msg_proto_msgTypes[1] + mi := &file_reddot_reddot_msg_proto_msgTypes[2] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -96,10 +159,10 @@ func (x *ReddotGetAllResp) ProtoReflect() protoreflect.Message { // Deprecated: Use ReddotGetAllResp.ProtoReflect.Descriptor instead. func (*ReddotGetAllResp) Descriptor() ([]byte, []int) { - return file_reddot_reddot_msg_proto_rawDescGZIP(), []int{1} + return file_reddot_reddot_msg_proto_rawDescGZIP(), []int{2} } -func (x *ReddotGetAllResp) GetReddot() map[int32]bool { +func (x *ReddotGetAllResp) GetReddot() map[int32]*ReddotItem { if x != nil { return x.Reddot } @@ -118,7 +181,7 @@ type ReddotGetReq struct { func (x *ReddotGetReq) Reset() { *x = ReddotGetReq{} if protoimpl.UnsafeEnabled { - mi := &file_reddot_reddot_msg_proto_msgTypes[2] + mi := &file_reddot_reddot_msg_proto_msgTypes[3] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -131,7 +194,7 @@ func (x *ReddotGetReq) String() string { func (*ReddotGetReq) ProtoMessage() {} func (x *ReddotGetReq) ProtoReflect() protoreflect.Message { - mi := &file_reddot_reddot_msg_proto_msgTypes[2] + mi := &file_reddot_reddot_msg_proto_msgTypes[3] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -144,7 +207,7 @@ func (x *ReddotGetReq) ProtoReflect() protoreflect.Message { // Deprecated: Use ReddotGetReq.ProtoReflect.Descriptor instead. func (*ReddotGetReq) Descriptor() ([]byte, []int) { - return file_reddot_reddot_msg_proto_rawDescGZIP(), []int{2} + return file_reddot_reddot_msg_proto_rawDescGZIP(), []int{3} } func (x *ReddotGetReq) GetRids() []int32 { @@ -159,13 +222,13 @@ type ReddotGetResp struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Reddot map[int32]bool `protobuf:"bytes,1,rep,name=reddot,proto3" json:"reddot" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"varint,2,opt,name=value,proto3"` //红点信息 + Reddot map[int32]*ReddotItem `protobuf:"bytes,1,rep,name=reddot,proto3" json:"reddot" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` //红点信息 } func (x *ReddotGetResp) Reset() { *x = ReddotGetResp{} if protoimpl.UnsafeEnabled { - mi := &file_reddot_reddot_msg_proto_msgTypes[3] + mi := &file_reddot_reddot_msg_proto_msgTypes[4] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -178,7 +241,7 @@ func (x *ReddotGetResp) String() string { func (*ReddotGetResp) ProtoMessage() {} func (x *ReddotGetResp) ProtoReflect() protoreflect.Message { - mi := &file_reddot_reddot_msg_proto_msgTypes[3] + mi := &file_reddot_reddot_msg_proto_msgTypes[4] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -191,10 +254,10 @@ func (x *ReddotGetResp) ProtoReflect() protoreflect.Message { // Deprecated: Use ReddotGetResp.ProtoReflect.Descriptor instead. func (*ReddotGetResp) Descriptor() ([]byte, []int) { - return file_reddot_reddot_msg_proto_rawDescGZIP(), []int{3} + return file_reddot_reddot_msg_proto_rawDescGZIP(), []int{4} } -func (x *ReddotGetResp) GetReddot() map[int32]bool { +func (x *ReddotGetResp) GetReddot() map[int32]*ReddotItem { if x != nil { return x.Reddot } @@ -207,13 +270,13 @@ type ReddotChangePush struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Rids []int32 `protobuf:"varint,1,rep,packed,name=rids,proto3" json:"rids"` + Rids []*ReddotItem `protobuf:"bytes,1,rep,name=rids,proto3" json:"rids"` } func (x *ReddotChangePush) Reset() { *x = ReddotChangePush{} if protoimpl.UnsafeEnabled { - mi := &file_reddot_reddot_msg_proto_msgTypes[4] + mi := &file_reddot_reddot_msg_proto_msgTypes[5] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -226,7 +289,7 @@ func (x *ReddotChangePush) String() string { func (*ReddotChangePush) ProtoMessage() {} func (x *ReddotChangePush) ProtoReflect() protoreflect.Message { - mi := &file_reddot_reddot_msg_proto_msgTypes[4] + mi := &file_reddot_reddot_msg_proto_msgTypes[5] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -239,10 +302,10 @@ func (x *ReddotChangePush) ProtoReflect() protoreflect.Message { // Deprecated: Use ReddotChangePush.ProtoReflect.Descriptor instead. func (*ReddotChangePush) Descriptor() ([]byte, []int) { - return file_reddot_reddot_msg_proto_rawDescGZIP(), []int{4} + return file_reddot_reddot_msg_proto_rawDescGZIP(), []int{5} } -func (x *ReddotChangePush) GetRids() []int32 { +func (x *ReddotChangePush) GetRids() []*ReddotItem { if x != nil { return x.Rids } @@ -253,29 +316,38 @@ var File_reddot_reddot_msg_proto protoreflect.FileDescriptor var file_reddot_reddot_msg_proto_rawDesc = []byte{ 0x0a, 0x17, 0x72, 0x65, 0x64, 0x64, 0x6f, 0x74, 0x2f, 0x72, 0x65, 0x64, 0x64, 0x6f, 0x74, 0x5f, - 0x6d, 0x73, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x11, 0x0a, 0x0f, 0x52, 0x65, 0x64, - 0x64, 0x6f, 0x74, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x52, 0x65, 0x71, 0x22, 0x84, 0x01, 0x0a, - 0x10, 0x52, 0x65, 0x64, 0x64, 0x6f, 0x74, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x52, 0x65, 0x73, - 0x70, 0x12, 0x35, 0x0a, 0x06, 0x72, 0x65, 0x64, 0x64, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x03, 0x28, - 0x0b, 0x32, 0x1d, 0x2e, 0x52, 0x65, 0x64, 0x64, 0x6f, 0x74, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, - 0x52, 0x65, 0x73, 0x70, 0x2e, 0x52, 0x65, 0x64, 0x64, 0x6f, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x79, - 0x52, 0x06, 0x72, 0x65, 0x64, 0x64, 0x6f, 0x74, 0x1a, 0x39, 0x0a, 0x0b, 0x52, 0x65, 0x64, 0x64, - 0x6f, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, - 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, - 0x02, 0x38, 0x01, 0x22, 0x22, 0x0a, 0x0c, 0x52, 0x65, 0x64, 0x64, 0x6f, 0x74, 0x47, 0x65, 0x74, - 0x52, 0x65, 0x71, 0x12, 0x12, 0x0a, 0x04, 0x72, 0x69, 0x64, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, - 0x05, 0x52, 0x04, 0x72, 0x69, 0x64, 0x73, 0x22, 0x7e, 0x0a, 0x0d, 0x52, 0x65, 0x64, 0x64, 0x6f, - 0x74, 0x47, 0x65, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x32, 0x0a, 0x06, 0x72, 0x65, 0x64, 0x64, - 0x6f, 0x74, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x52, 0x65, 0x64, 0x64, 0x6f, - 0x74, 0x47, 0x65, 0x74, 0x52, 0x65, 0x73, 0x70, 0x2e, 0x52, 0x65, 0x64, 0x64, 0x6f, 0x74, 0x45, - 0x6e, 0x74, 0x72, 0x79, 0x52, 0x06, 0x72, 0x65, 0x64, 0x64, 0x6f, 0x74, 0x1a, 0x39, 0x0a, 0x0b, - 0x52, 0x65, 0x64, 0x64, 0x6f, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, - 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, - 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x05, 0x76, 0x61, - 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x26, 0x0a, 0x10, 0x52, 0x65, 0x64, 0x64, 0x6f, - 0x74, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x50, 0x75, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x72, - 0x69, 0x64, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x05, 0x52, 0x04, 0x72, 0x69, 0x64, 0x73, 0x42, + 0x6d, 0x73, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x66, 0x0a, 0x0a, 0x52, 0x65, 0x64, + 0x64, 0x6f, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x10, 0x0a, 0x03, 0x72, 0x69, 0x64, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x72, 0x69, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x61, 0x63, 0x74, + 0x69, 0x76, 0x61, 0x74, 0x65, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x61, 0x63, + 0x74, 0x69, 0x76, 0x61, 0x74, 0x65, 0x64, 0x12, 0x28, 0x0a, 0x0f, 0x6e, 0x65, 0x78, 0x74, 0x63, + 0x68, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x0f, 0x6e, 0x65, 0x78, 0x74, 0x63, 0x68, 0x61, 0x6e, 0x61, 0x67, 0x65, 0x74, 0x69, 0x6d, + 0x65, 0x22, 0x11, 0x0a, 0x0f, 0x52, 0x65, 0x64, 0x64, 0x6f, 0x74, 0x47, 0x65, 0x74, 0x41, 0x6c, + 0x6c, 0x52, 0x65, 0x71, 0x22, 0x91, 0x01, 0x0a, 0x10, 0x52, 0x65, 0x64, 0x64, 0x6f, 0x74, 0x47, + 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x12, 0x35, 0x0a, 0x06, 0x72, 0x65, 0x64, + 0x64, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x52, 0x65, 0x64, 0x64, + 0x6f, 0x74, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x2e, 0x52, 0x65, 0x64, + 0x64, 0x6f, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x06, 0x72, 0x65, 0x64, 0x64, 0x6f, 0x74, + 0x1a, 0x46, 0x0a, 0x0b, 0x52, 0x65, 0x64, 0x64, 0x6f, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, + 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6b, 0x65, + 0x79, 0x12, 0x21, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x0b, 0x2e, 0x52, 0x65, 0x64, 0x64, 0x6f, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x05, 0x76, + 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x22, 0x0a, 0x0c, 0x52, 0x65, 0x64, 0x64, + 0x6f, 0x74, 0x47, 0x65, 0x74, 0x52, 0x65, 0x71, 0x12, 0x12, 0x0a, 0x04, 0x72, 0x69, 0x64, 0x73, + 0x18, 0x01, 0x20, 0x03, 0x28, 0x05, 0x52, 0x04, 0x72, 0x69, 0x64, 0x73, 0x22, 0x8b, 0x01, 0x0a, + 0x0d, 0x52, 0x65, 0x64, 0x64, 0x6f, 0x74, 0x47, 0x65, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x32, + 0x0a, 0x06, 0x72, 0x65, 0x64, 0x64, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, + 0x2e, 0x52, 0x65, 0x64, 0x64, 0x6f, 0x74, 0x47, 0x65, 0x74, 0x52, 0x65, 0x73, 0x70, 0x2e, 0x52, + 0x65, 0x64, 0x64, 0x6f, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x06, 0x72, 0x65, 0x64, 0x64, + 0x6f, 0x74, 0x1a, 0x46, 0x0a, 0x0b, 0x52, 0x65, 0x64, 0x64, 0x6f, 0x74, 0x45, 0x6e, 0x74, 0x72, + 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, + 0x6b, 0x65, 0x79, 0x12, 0x21, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x52, 0x65, 0x64, 0x64, 0x6f, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x52, + 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x33, 0x0a, 0x10, 0x52, 0x65, + 0x64, 0x64, 0x6f, 0x74, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x50, 0x75, 0x73, 0x68, 0x12, 0x1f, + 0x0a, 0x04, 0x72, 0x69, 0x64, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x52, + 0x65, 0x64, 0x64, 0x6f, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x04, 0x72, 0x69, 0x64, 0x73, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } @@ -291,24 +363,28 @@ func file_reddot_reddot_msg_proto_rawDescGZIP() []byte { return file_reddot_reddot_msg_proto_rawDescData } -var file_reddot_reddot_msg_proto_msgTypes = make([]protoimpl.MessageInfo, 7) +var file_reddot_reddot_msg_proto_msgTypes = make([]protoimpl.MessageInfo, 8) var file_reddot_reddot_msg_proto_goTypes = []interface{}{ - (*ReddotGetAllReq)(nil), // 0: ReddotGetAllReq - (*ReddotGetAllResp)(nil), // 1: ReddotGetAllResp - (*ReddotGetReq)(nil), // 2: ReddotGetReq - (*ReddotGetResp)(nil), // 3: ReddotGetResp - (*ReddotChangePush)(nil), // 4: ReddotChangePush - nil, // 5: ReddotGetAllResp.ReddotEntry - nil, // 6: ReddotGetResp.ReddotEntry + (*ReddotItem)(nil), // 0: ReddotItem + (*ReddotGetAllReq)(nil), // 1: ReddotGetAllReq + (*ReddotGetAllResp)(nil), // 2: ReddotGetAllResp + (*ReddotGetReq)(nil), // 3: ReddotGetReq + (*ReddotGetResp)(nil), // 4: ReddotGetResp + (*ReddotChangePush)(nil), // 5: ReddotChangePush + nil, // 6: ReddotGetAllResp.ReddotEntry + nil, // 7: ReddotGetResp.ReddotEntry } var file_reddot_reddot_msg_proto_depIdxs = []int32{ - 5, // 0: ReddotGetAllResp.reddot:type_name -> ReddotGetAllResp.ReddotEntry - 6, // 1: ReddotGetResp.reddot:type_name -> ReddotGetResp.ReddotEntry - 2, // [2:2] is the sub-list for method output_type - 2, // [2:2] is the sub-list for method input_type - 2, // [2:2] is the sub-list for extension type_name - 2, // [2:2] is the sub-list for extension extendee - 0, // [0:2] is the sub-list for field type_name + 6, // 0: ReddotGetAllResp.reddot:type_name -> ReddotGetAllResp.ReddotEntry + 7, // 1: ReddotGetResp.reddot:type_name -> ReddotGetResp.ReddotEntry + 0, // 2: ReddotChangePush.rids:type_name -> ReddotItem + 0, // 3: ReddotGetAllResp.ReddotEntry.value:type_name -> ReddotItem + 0, // 4: ReddotGetResp.ReddotEntry.value:type_name -> ReddotItem + 5, // [5:5] is the sub-list for method output_type + 5, // [5:5] is the sub-list for method input_type + 5, // [5:5] is the sub-list for extension type_name + 5, // [5:5] is the sub-list for extension extendee + 0, // [0:5] is the sub-list for field type_name } func init() { file_reddot_reddot_msg_proto_init() } @@ -318,7 +394,7 @@ func file_reddot_reddot_msg_proto_init() { } if !protoimpl.UnsafeEnabled { file_reddot_reddot_msg_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ReddotGetAllReq); i { + switch v := v.(*ReddotItem); i { case 0: return &v.state case 1: @@ -330,7 +406,7 @@ func file_reddot_reddot_msg_proto_init() { } } file_reddot_reddot_msg_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ReddotGetAllResp); i { + switch v := v.(*ReddotGetAllReq); i { case 0: return &v.state case 1: @@ -342,7 +418,7 @@ func file_reddot_reddot_msg_proto_init() { } } file_reddot_reddot_msg_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ReddotGetReq); i { + switch v := v.(*ReddotGetAllResp); i { case 0: return &v.state case 1: @@ -354,7 +430,7 @@ func file_reddot_reddot_msg_proto_init() { } } file_reddot_reddot_msg_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ReddotGetResp); i { + switch v := v.(*ReddotGetReq); i { case 0: return &v.state case 1: @@ -366,6 +442,18 @@ func file_reddot_reddot_msg_proto_init() { } } file_reddot_reddot_msg_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ReddotGetResp); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_reddot_reddot_msg_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*ReddotChangePush); i { case 0: return &v.state @@ -384,7 +472,7 @@ func file_reddot_reddot_msg_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_reddot_reddot_msg_proto_rawDesc, NumEnums: 0, - NumMessages: 7, + NumMessages: 8, NumExtensions: 0, NumServices: 0, },