diff --git a/gen/go/sso/account.pb.go b/gen/go/sso/account.pb.go index 1ef3a00..231dc0d 100644 --- a/gen/go/sso/account.pb.go +++ b/gen/go/sso/account.pb.go @@ -1949,6 +1949,94 @@ func (x *UnblockIpResponse) GetMessage() string { return "" } +type SyncUsersToSearchRequest struct { + state protoimpl.MessageState `protogen:"open.v1"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *SyncUsersToSearchRequest) Reset() { + *x = SyncUsersToSearchRequest{} + mi := &file_sso_account_proto_msgTypes[32] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *SyncUsersToSearchRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*SyncUsersToSearchRequest) ProtoMessage() {} + +func (x *SyncUsersToSearchRequest) ProtoReflect() protoreflect.Message { + mi := &file_sso_account_proto_msgTypes[32] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use SyncUsersToSearchRequest.ProtoReflect.Descriptor instead. +func (*SyncUsersToSearchRequest) Descriptor() ([]byte, []int) { + return file_sso_account_proto_rawDescGZIP(), []int{32} +} + +type SyncUsersToSearchResponse struct { + state protoimpl.MessageState `protogen:"open.v1"` + Success bool `protobuf:"varint,1,opt,name=success,proto3" json:"success,omitempty"` + Message string `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *SyncUsersToSearchResponse) Reset() { + *x = SyncUsersToSearchResponse{} + mi := &file_sso_account_proto_msgTypes[33] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *SyncUsersToSearchResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*SyncUsersToSearchResponse) ProtoMessage() {} + +func (x *SyncUsersToSearchResponse) ProtoReflect() protoreflect.Message { + mi := &file_sso_account_proto_msgTypes[33] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use SyncUsersToSearchResponse.ProtoReflect.Descriptor instead. +func (*SyncUsersToSearchResponse) Descriptor() ([]byte, []int) { + return file_sso_account_proto_rawDescGZIP(), []int{33} +} + +func (x *SyncUsersToSearchResponse) GetSuccess() bool { + if x != nil { + return x.Success + } + return false +} + +func (x *SyncUsersToSearchResponse) GetMessage() string { + if x != nil { + return x.Message + } + return "" +} + var File_sso_account_proto protoreflect.FileDescriptor const file_sso_account_proto_rawDesc = "" + @@ -2113,7 +2201,12 @@ const file_sso_account_proto_rawDesc = "" + "\badmin_id\x18\x02 \x01(\tR\aadminId\"G\n" + "\x11UnblockIpResponse\x12\x18\n" + "\asuccess\x18\x01 \x01(\bR\asuccess\x12\x18\n" + - "\amessage\x18\x02 \x01(\tR\amessage2\xec\t\n" + + "\amessage\x18\x02 \x01(\tR\amessage\"\x1a\n" + + "\x18SyncUsersToSearchRequest\"O\n" + + "\x19SyncUsersToSearchResponse\x12\x18\n" + + "\asuccess\x18\x01 \x01(\bR\asuccess\x12\x18\n" + + "\amessage\x18\x02 \x01(\tR\amessage2\xce\n" + + "\n" + "\x0eAccountService\x12K\n" + "\n" + "GetAccount\x12\x1d.account.v1.GetAccountRequest\x1a\x1e.account.v1.GetAccountResponse\x12W\n" + @@ -2136,7 +2229,8 @@ const file_sso_account_proto_rawDesc = "" + "\tBlockUser\x12\x1c.account.v1.BlockUserRequest\x1a\x1d.account.v1.BlockUserResponse\x12N\n" + "\vUnblockUser\x12\x1e.account.v1.UnblockUserRequest\x1a\x1f.account.v1.UnblockUserResponse\x12B\n" + "\aBlockIp\x12\x1a.account.v1.BlockIpRequest\x1a\x1b.account.v1.BlockIpResponse\x12H\n" + - "\tUnblockIp\x12\x1c.account.v1.UnblockIpRequest\x1a\x1d.account.v1.UnblockIpResponseB*Z(git.lendry.ru/lendry-erp/proto.git/go;pbb\x06proto3" + "\tUnblockIp\x12\x1c.account.v1.UnblockIpRequest\x1a\x1d.account.v1.UnblockIpResponse\x12`\n" + + "\x11SyncUsersToSearch\x12$.account.v1.SyncUsersToSearchRequest\x1a%.account.v1.SyncUsersToSearchResponseB*Z(git.lendry.ru/lendry-erp/proto.git/go;pbb\x06proto3" var ( file_sso_account_proto_rawDescOnce sync.Once @@ -2150,7 +2244,7 @@ func file_sso_account_proto_rawDescGZIP() []byte { return file_sso_account_proto_rawDescData } -var file_sso_account_proto_msgTypes = make([]protoimpl.MessageInfo, 32) +var file_sso_account_proto_msgTypes = make([]protoimpl.MessageInfo, 34) var file_sso_account_proto_goTypes = []any{ (*GetAccountRequest)(nil), // 0: account.v1.GetAccountRequest (*GetAccountResponse)(nil), // 1: account.v1.GetAccountResponse @@ -2184,6 +2278,8 @@ var file_sso_account_proto_goTypes = []any{ (*BlockIpResponse)(nil), // 29: account.v1.BlockIpResponse (*UnblockIpRequest)(nil), // 30: account.v1.UnblockIpRequest (*UnblockIpResponse)(nil), // 31: account.v1.UnblockIpResponse + (*SyncUsersToSearchRequest)(nil), // 32: account.v1.SyncUsersToSearchRequest + (*SyncUsersToSearchResponse)(nil), // 33: account.v1.SyncUsersToSearchResponse } var file_sso_account_proto_depIdxs = []int32{ 0, // 0: account.v1.AccountService.GetAccount:input_type -> account.v1.GetAccountRequest @@ -2202,24 +2298,26 @@ var file_sso_account_proto_depIdxs = []int32{ 26, // 13: account.v1.AccountService.UnblockUser:input_type -> account.v1.UnblockUserRequest 28, // 14: account.v1.AccountService.BlockIp:input_type -> account.v1.BlockIpRequest 30, // 15: account.v1.AccountService.UnblockIp:input_type -> account.v1.UnblockIpRequest - 1, // 16: account.v1.AccountService.GetAccount:output_type -> account.v1.GetAccountResponse - 3, // 17: account.v1.AccountService.ChangePassword:output_type -> account.v1.ChangePasswordResponse - 15, // 18: account.v1.AccountService.AdminResetPassword:output_type -> account.v1.AdminResetPasswordResponse - 5, // 19: account.v1.AccountService.CreateUser:output_type -> account.v1.CreateUserResponse - 7, // 20: account.v1.AccountService.DeleteUser:output_type -> account.v1.DeleteUserResponse - 9, // 21: account.v1.AccountService.ChangeData:output_type -> account.v1.ChangeDataResponse - 11, // 22: account.v1.AccountService.AssignRole:output_type -> account.v1.AssignRoleResponse - 13, // 23: account.v1.AccountService.RevokeRole:output_type -> account.v1.RevokeRoleResponse - 17, // 24: account.v1.AccountService.SetPin:output_type -> account.v1.SetPinResponse - 19, // 25: account.v1.AccountService.UnlockPin:output_type -> account.v1.UnlockPinResponse - 21, // 26: account.v1.AccountService.GetPinStatus:output_type -> account.v1.GetPinStatusResponse - 23, // 27: account.v1.AccountService.RemovePin:output_type -> account.v1.RemovePinResponse - 25, // 28: account.v1.AccountService.BlockUser:output_type -> account.v1.BlockUserResponse - 27, // 29: account.v1.AccountService.UnblockUser:output_type -> account.v1.UnblockUserResponse - 29, // 30: account.v1.AccountService.BlockIp:output_type -> account.v1.BlockIpResponse - 31, // 31: account.v1.AccountService.UnblockIp:output_type -> account.v1.UnblockIpResponse - 16, // [16:32] is the sub-list for method output_type - 0, // [0:16] is the sub-list for method input_type + 32, // 16: account.v1.AccountService.SyncUsersToSearch:input_type -> account.v1.SyncUsersToSearchRequest + 1, // 17: account.v1.AccountService.GetAccount:output_type -> account.v1.GetAccountResponse + 3, // 18: account.v1.AccountService.ChangePassword:output_type -> account.v1.ChangePasswordResponse + 15, // 19: account.v1.AccountService.AdminResetPassword:output_type -> account.v1.AdminResetPasswordResponse + 5, // 20: account.v1.AccountService.CreateUser:output_type -> account.v1.CreateUserResponse + 7, // 21: account.v1.AccountService.DeleteUser:output_type -> account.v1.DeleteUserResponse + 9, // 22: account.v1.AccountService.ChangeData:output_type -> account.v1.ChangeDataResponse + 11, // 23: account.v1.AccountService.AssignRole:output_type -> account.v1.AssignRoleResponse + 13, // 24: account.v1.AccountService.RevokeRole:output_type -> account.v1.RevokeRoleResponse + 17, // 25: account.v1.AccountService.SetPin:output_type -> account.v1.SetPinResponse + 19, // 26: account.v1.AccountService.UnlockPin:output_type -> account.v1.UnlockPinResponse + 21, // 27: account.v1.AccountService.GetPinStatus:output_type -> account.v1.GetPinStatusResponse + 23, // 28: account.v1.AccountService.RemovePin:output_type -> account.v1.RemovePinResponse + 25, // 29: account.v1.AccountService.BlockUser:output_type -> account.v1.BlockUserResponse + 27, // 30: account.v1.AccountService.UnblockUser:output_type -> account.v1.UnblockUserResponse + 29, // 31: account.v1.AccountService.BlockIp:output_type -> account.v1.BlockIpResponse + 31, // 32: account.v1.AccountService.UnblockIp:output_type -> account.v1.UnblockIpResponse + 33, // 33: account.v1.AccountService.SyncUsersToSearch:output_type -> account.v1.SyncUsersToSearchResponse + 17, // [17:34] is the sub-list for method output_type + 0, // [0:17] is the sub-list for method input_type 0, // [0:0] is the sub-list for extension type_name 0, // [0:0] is the sub-list for extension extendee 0, // [0:0] is the sub-list for field type_name @@ -2241,7 +2339,7 @@ func file_sso_account_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: unsafe.Slice(unsafe.StringData(file_sso_account_proto_rawDesc), len(file_sso_account_proto_rawDesc)), NumEnums: 0, - NumMessages: 32, + NumMessages: 34, NumExtensions: 0, NumServices: 1, }, diff --git a/gen/go/sso/account_grpc.pb.go b/gen/go/sso/account_grpc.pb.go index e714732..9a08e5b 100644 --- a/gen/go/sso/account_grpc.pb.go +++ b/gen/go/sso/account_grpc.pb.go @@ -35,6 +35,7 @@ const ( AccountService_UnblockUser_FullMethodName = "/account.v1.AccountService/UnblockUser" AccountService_BlockIp_FullMethodName = "/account.v1.AccountService/BlockIp" AccountService_UnblockIp_FullMethodName = "/account.v1.AccountService/UnblockIp" + AccountService_SyncUsersToSearch_FullMethodName = "/account.v1.AccountService/SyncUsersToSearch" ) // AccountServiceClient is the client API for AccountService service. @@ -57,6 +58,7 @@ type AccountServiceClient interface { UnblockUser(ctx context.Context, in *UnblockUserRequest, opts ...grpc.CallOption) (*UnblockUserResponse, error) BlockIp(ctx context.Context, in *BlockIpRequest, opts ...grpc.CallOption) (*BlockIpResponse, error) UnblockIp(ctx context.Context, in *UnblockIpRequest, opts ...grpc.CallOption) (*UnblockIpResponse, error) + SyncUsersToSearch(ctx context.Context, in *SyncUsersToSearchRequest, opts ...grpc.CallOption) (*SyncUsersToSearchResponse, error) } type accountServiceClient struct { @@ -227,6 +229,16 @@ func (c *accountServiceClient) UnblockIp(ctx context.Context, in *UnblockIpReque return out, nil } +func (c *accountServiceClient) SyncUsersToSearch(ctx context.Context, in *SyncUsersToSearchRequest, opts ...grpc.CallOption) (*SyncUsersToSearchResponse, error) { + cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) + out := new(SyncUsersToSearchResponse) + err := c.cc.Invoke(ctx, AccountService_SyncUsersToSearch_FullMethodName, in, out, cOpts...) + if err != nil { + return nil, err + } + return out, nil +} + // AccountServiceServer is the server API for AccountService service. // All implementations must embed UnimplementedAccountServiceServer // for forward compatibility. @@ -247,6 +259,7 @@ type AccountServiceServer interface { UnblockUser(context.Context, *UnblockUserRequest) (*UnblockUserResponse, error) BlockIp(context.Context, *BlockIpRequest) (*BlockIpResponse, error) UnblockIp(context.Context, *UnblockIpRequest) (*UnblockIpResponse, error) + SyncUsersToSearch(context.Context, *SyncUsersToSearchRequest) (*SyncUsersToSearchResponse, error) mustEmbedUnimplementedAccountServiceServer() } @@ -305,6 +318,9 @@ func (UnimplementedAccountServiceServer) BlockIp(context.Context, *BlockIpReques func (UnimplementedAccountServiceServer) UnblockIp(context.Context, *UnblockIpRequest) (*UnblockIpResponse, error) { return nil, status.Error(codes.Unimplemented, "method UnblockIp not implemented") } +func (UnimplementedAccountServiceServer) SyncUsersToSearch(context.Context, *SyncUsersToSearchRequest) (*SyncUsersToSearchResponse, error) { + return nil, status.Error(codes.Unimplemented, "method SyncUsersToSearch not implemented") +} func (UnimplementedAccountServiceServer) mustEmbedUnimplementedAccountServiceServer() {} func (UnimplementedAccountServiceServer) testEmbeddedByValue() {} @@ -614,6 +630,24 @@ func _AccountService_UnblockIp_Handler(srv interface{}, ctx context.Context, dec return interceptor(ctx, in, info, handler) } +func _AccountService_SyncUsersToSearch_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(SyncUsersToSearchRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(AccountServiceServer).SyncUsersToSearch(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: AccountService_SyncUsersToSearch_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(AccountServiceServer).SyncUsersToSearch(ctx, req.(*SyncUsersToSearchRequest)) + } + return interceptor(ctx, in, info, handler) +} + // AccountService_ServiceDesc is the grpc.ServiceDesc for AccountService service. // It's only intended for direct use with grpc.RegisterService, // and not to be introspected or modified (even as a copy) @@ -685,6 +719,10 @@ var AccountService_ServiceDesc = grpc.ServiceDesc{ MethodName: "UnblockIp", Handler: _AccountService_UnblockIp_Handler, }, + { + MethodName: "SyncUsersToSearch", + Handler: _AccountService_SyncUsersToSearch_Handler, + }, }, Streams: []grpc.StreamDesc{}, Metadata: "sso/account.proto", diff --git a/gen/sso/account.ts b/gen/sso/account.ts index 829a801..f9fff9c 100644 --- a/gen/sso/account.ts +++ b/gen/sso/account.ts @@ -207,6 +207,15 @@ export interface UnblockIpResponse { message: string; } +/** Можно оставить пустым, так как нам не нужны входные данные */ +export interface SyncUsersToSearchRequest { +} + +export interface SyncUsersToSearchResponse { + success: boolean; + message: string; +} + export const ACCOUNT_V1_PACKAGE_NAME = "account.v1"; export interface AccountServiceClient { @@ -241,6 +250,8 @@ export interface AccountServiceClient { blockIp(request: BlockIpRequest, metadata?: Metadata): Observable; unblockIp(request: UnblockIpRequest, metadata?: Metadata): Observable; + + syncUsersToSearch(request: SyncUsersToSearchRequest, metadata?: Metadata): Observable; } export interface AccountServiceController { @@ -323,6 +334,11 @@ export interface AccountServiceController { request: UnblockIpRequest, metadata?: Metadata, ): Promise | Observable | UnblockIpResponse; + + syncUsersToSearch( + request: SyncUsersToSearchRequest, + metadata?: Metadata, + ): Promise | Observable | SyncUsersToSearchResponse; } export function AccountServiceControllerMethods() { @@ -344,6 +360,7 @@ export function AccountServiceControllerMethods() { "unblockUser", "blockIp", "unblockIp", + "syncUsersToSearch", ]; for (const method of grpcMethods) { const descriptor: any = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);