Browse Source

isSuperLove

wfz 3 years ago
parent
commit
bbfa61c460
7 changed files with 892 additions and 1095 deletions
  1. 428 373
      api/chat/chat.pb.go
  2. 6 0
      api/chat/chat.proto
  3. 38 0
      api/chat/chat_grpc.pb.go
  4. 414 722
      api/common/common.pb.go
  5. 1 0
      api/common/common.proto
  6. 3 0
      js/api/chat/chat_pb.ts
  7. 2 0
      js/api/common/common_pb.ts

File diff suppressed because it is too large
+ 428 - 373
api/chat/chat.pb.go


+ 6 - 0
api/chat/chat.proto

@@ -81,6 +81,8 @@ service Chat {
 //  rpc FindPartnerAllUnreadNum (common.PersonIDParam) returns (UnreadNumReply){};
   // 用户查询与某人的房间
   rpc GetUserRoomByPerson (common.UserIDsParam) returns (UserRoomInfo){};
+  // 用户查询对某人是否是超级喜欢
+  rpc GetSuperLoveByPerson (common.UserIDsParam) returns (UserSuperLoveInfo){};
 //  // 接待员查询与某人的房间
 //  rpc GetPartnerRoomByPerson (common.UserIDsParam) returns (PartnerRoomInfo){};
   // 管理员查询房间列表
@@ -212,6 +214,10 @@ message UserRoomInfo{
   int64 roomId = 7; // 房间ID
 }
 
+message UserSuperLoveInfo{
+  bool isSuperLove = 1;
+}
+
 message PartnerFindRoomListReply{
   repeated PartnerRoomInfo list = 1;
   int64 nextId = 2;

+ 38 - 0
api/chat/chat_grpc.pb.go

@@ -89,6 +89,8 @@ type ChatClient interface {
 	//  rpc FindPartnerAllUnreadNum (common.PersonIDParam) returns (UnreadNumReply){};
 	// 用户查询与某人的房间
 	GetUserRoomByPerson(ctx context.Context, in *common.UserIDsParam, opts ...grpc.CallOption) (*UserRoomInfo, error)
+	// 用户查询对某人是否是超级喜欢
+	GetSuperLoveByPerson(ctx context.Context, in *common.UserIDsParam, opts ...grpc.CallOption) (*UserSuperLoveInfo, error)
 	//  // 接待员查询与某人的房间
 	//  rpc GetPartnerRoomByPerson (common.UserIDsParam) returns (PartnerRoomInfo){};
 	// 管理员查询房间列表
@@ -418,6 +420,15 @@ func (c *chatClient) GetUserRoomByPerson(ctx context.Context, in *common.UserIDs
 	return out, nil
 }
 
+func (c *chatClient) GetSuperLoveByPerson(ctx context.Context, in *common.UserIDsParam, opts ...grpc.CallOption) (*UserSuperLoveInfo, error) {
+	out := new(UserSuperLoveInfo)
+	err := c.cc.Invoke(ctx, "/api.chat.Chat/GetSuperLoveByPerson", in, out, opts...)
+	if err != nil {
+		return nil, err
+	}
+	return out, nil
+}
+
 func (c *chatClient) ManagerFindRoomList(ctx context.Context, in *common.ManagerFindRoomListRequest, opts ...grpc.CallOption) (*common.ManagerFindRoomListReply, error) {
 	out := new(common.ManagerFindRoomListReply)
 	err := c.cc.Invoke(ctx, "/api.chat.Chat/ManagerFindRoomList", in, out, opts...)
@@ -581,6 +592,8 @@ type ChatServer interface {
 	//  rpc FindPartnerAllUnreadNum (common.PersonIDParam) returns (UnreadNumReply){};
 	// 用户查询与某人的房间
 	GetUserRoomByPerson(context.Context, *common.UserIDsParam) (*UserRoomInfo, error)
+	// 用户查询对某人是否是超级喜欢
+	GetSuperLoveByPerson(context.Context, *common.UserIDsParam) (*UserSuperLoveInfo, error)
 	//  // 接待员查询与某人的房间
 	//  rpc GetPartnerRoomByPerson (common.UserIDsParam) returns (PartnerRoomInfo){};
 	// 管理员查询房间列表
@@ -709,6 +722,9 @@ func (UnimplementedChatServer) FindUserAllUnreadNum(context.Context, *common.Per
 func (UnimplementedChatServer) GetUserRoomByPerson(context.Context, *common.UserIDsParam) (*UserRoomInfo, error) {
 	return nil, status.Errorf(codes.Unimplemented, "method GetUserRoomByPerson not implemented")
 }
+func (UnimplementedChatServer) GetSuperLoveByPerson(context.Context, *common.UserIDsParam) (*UserSuperLoveInfo, error) {
+	return nil, status.Errorf(codes.Unimplemented, "method GetSuperLoveByPerson not implemented")
+}
 func (UnimplementedChatServer) ManagerFindRoomList(context.Context, *common.ManagerFindRoomListRequest) (*common.ManagerFindRoomListReply, error) {
 	return nil, status.Errorf(codes.Unimplemented, "method ManagerFindRoomList not implemented")
 }
@@ -1346,6 +1362,24 @@ func _Chat_GetUserRoomByPerson_Handler(srv interface{}, ctx context.Context, dec
 	return interceptor(ctx, in, info, handler)
 }
 
+func _Chat_GetSuperLoveByPerson_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
+	in := new(common.UserIDsParam)
+	if err := dec(in); err != nil {
+		return nil, err
+	}
+	if interceptor == nil {
+		return srv.(ChatServer).GetSuperLoveByPerson(ctx, in)
+	}
+	info := &grpc.UnaryServerInfo{
+		Server:     srv,
+		FullMethod: "/api.chat.Chat/GetSuperLoveByPerson",
+	}
+	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
+		return srv.(ChatServer).GetSuperLoveByPerson(ctx, req.(*common.UserIDsParam))
+	}
+	return interceptor(ctx, in, info, handler)
+}
+
 func _Chat_ManagerFindRoomList_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
 	in := new(common.ManagerFindRoomListRequest)
 	if err := dec(in); err != nil {
@@ -1665,6 +1699,10 @@ var Chat_ServiceDesc = grpc.ServiceDesc{
 			MethodName: "GetUserRoomByPerson",
 			Handler:    _Chat_GetUserRoomByPerson_Handler,
 		},
+		{
+			MethodName: "GetSuperLoveByPerson",
+			Handler:    _Chat_GetSuperLoveByPerson_Handler,
+		},
 		{
 			MethodName: "ManagerFindRoomList",
 			Handler:    _Chat_ManagerFindRoomList_Handler,

File diff suppressed because it is too large
+ 414 - 722
api/common/common.pb.go


+ 1 - 0
api/common/common.proto

@@ -100,6 +100,7 @@ message HomeInfo{
   int64 UpdateAvatarUrlNum = 18;// 今日更新头像数
   int64 UpdatePicturesNum = 19;  // 今日更新相册数
   int64 UpdateSignatureNum = 20; // 今日更新签名数
+  bool isSuperLove = 21;// 是否是超级喜欢
 }
 
 message PersonMsg {

+ 3 - 0
js/api/chat/chat_pb.ts

@@ -124,6 +124,9 @@ export interface UserRoomInfo{
     /**  房间ID */
     roomId?:number;
 }
+export interface UserSuperLoveInfo{
+    isSuperLove?:boolean;
+}
 export interface PartnerFindRoomListReply{
     list?:Array<PartnerRoomInfo>;
     nextId?:number;

+ 2 - 0
js/api/common/common_pb.ts

@@ -116,6 +116,8 @@ export interface HomeInfo{
     UpdatePicturesNum?:number;
     /**  今日更新签名数 */
     UpdateSignatureNum?:number;
+    /**  是否是超级喜欢 */
+    isSuperLove?:boolean;
 }
 export interface PersonMsg{
     /**  id */

Some files were not shown because too many files changed in this diff