This commit is contained in:
2026-10-04 13:23:26 +07:00
parent 88307ed402
commit c663fbb504
20 changed files with 2125 additions and 502 deletions
+114
View File
@@ -84,6 +84,9 @@ const (
EveningDetectiveServer_SetScreenMode_FullMethodName = "/crabs.evening_detective_server.EveningDetectiveServer/SetScreenMode"
EveningDetectiveServer_SetScreenTimer_FullMethodName = "/crabs.evening_detective_server.EveningDetectiveServer/SetScreenTimer"
EveningDetectiveServer_SendScreenCommand_FullMethodName = "/crabs.evening_detective_server.EveningDetectiveServer/SendScreenCommand"
EveningDetectiveServer_GetScreenPlan_FullMethodName = "/crabs.evening_detective_server.EveningDetectiveServer/GetScreenPlan"
EveningDetectiveServer_SaveScreenPlan_FullMethodName = "/crabs.evening_detective_server.EveningDetectiveServer/SaveScreenPlan"
EveningDetectiveServer_SetScreenPlanStep_FullMethodName = "/crabs.evening_detective_server.EveningDetectiveServer/SetScreenPlanStep"
EveningDetectiveServer_GetScreenResults_FullMethodName = "/crabs.evening_detective_server.EveningDetectiveServer/GetScreenResults"
EveningDetectiveServer_DownloadTeamQR_FullMethodName = "/crabs.evening_detective_server.EveningDetectiveServer/DownloadTeamQR"
EveningDetectiveServer_GetGameAnswers_FullMethodName = "/crabs.evening_detective_server.EveningDetectiveServer/GetGameAnswers"
@@ -185,6 +188,9 @@ type EveningDetectiveServerClient interface {
SetScreenTimer(ctx context.Context, in *SetScreenTimerReq, opts ...grpc.CallOption) (*SetScreenTimerRsp, error)
// Отправить общую команду экранам игры.
SendScreenCommand(ctx context.Context, in *SendScreenCommandReq, opts ...grpc.CallOption) (*SendScreenCommandRsp, error)
GetScreenPlan(ctx context.Context, in *GetScreenPlanReq, opts ...grpc.CallOption) (*GetScreenPlanRsp, error)
SaveScreenPlan(ctx context.Context, in *SaveScreenPlanReq, opts ...grpc.CallOption) (*SaveScreenPlanRsp, error)
SetScreenPlanStep(ctx context.Context, in *SetScreenPlanStepReq, opts ...grpc.CallOption) (*SetScreenPlanStepRsp, error)
GetScreenResults(ctx context.Context, in *GetScreenResultsReq, opts ...grpc.CallOption) (*GetScreenResultsRsp, error)
DownloadTeamQR(ctx context.Context, in *GetGameReq, opts ...grpc.CallOption) (*httpbody.HttpBody, error)
GetGameAnswers(ctx context.Context, in *GetGameAnswersReq, opts ...grpc.CallOption) (*GetGameAnswersRsp, error)
@@ -802,6 +808,36 @@ func (c *eveningDetectiveServerClient) SendScreenCommand(ctx context.Context, in
return out, nil
}
func (c *eveningDetectiveServerClient) GetScreenPlan(ctx context.Context, in *GetScreenPlanReq, opts ...grpc.CallOption) (*GetScreenPlanRsp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(GetScreenPlanRsp)
err := c.cc.Invoke(ctx, EveningDetectiveServer_GetScreenPlan_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *eveningDetectiveServerClient) SaveScreenPlan(ctx context.Context, in *SaveScreenPlanReq, opts ...grpc.CallOption) (*SaveScreenPlanRsp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(SaveScreenPlanRsp)
err := c.cc.Invoke(ctx, EveningDetectiveServer_SaveScreenPlan_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *eveningDetectiveServerClient) SetScreenPlanStep(ctx context.Context, in *SetScreenPlanStepReq, opts ...grpc.CallOption) (*SetScreenPlanStepRsp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(SetScreenPlanStepRsp)
err := c.cc.Invoke(ctx, EveningDetectiveServer_SetScreenPlanStep_FullMethodName, in, out, cOpts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *eveningDetectiveServerClient) GetScreenResults(ctx context.Context, in *GetScreenResultsReq, opts ...grpc.CallOption) (*GetScreenResultsRsp, error) {
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
out := new(GetScreenResultsRsp)
@@ -1144,6 +1180,9 @@ type EveningDetectiveServerServer interface {
SetScreenTimer(context.Context, *SetScreenTimerReq) (*SetScreenTimerRsp, error)
// Отправить общую команду экранам игры.
SendScreenCommand(context.Context, *SendScreenCommandReq) (*SendScreenCommandRsp, error)
GetScreenPlan(context.Context, *GetScreenPlanReq) (*GetScreenPlanRsp, error)
SaveScreenPlan(context.Context, *SaveScreenPlanReq) (*SaveScreenPlanRsp, error)
SetScreenPlanStep(context.Context, *SetScreenPlanStepReq) (*SetScreenPlanStepRsp, error)
GetScreenResults(context.Context, *GetScreenResultsReq) (*GetScreenResultsRsp, error)
DownloadTeamQR(context.Context, *GetGameReq) (*httpbody.HttpBody, error)
GetGameAnswers(context.Context, *GetGameAnswersReq) (*GetGameAnswersRsp, error)
@@ -1355,6 +1394,15 @@ func (UnimplementedEveningDetectiveServerServer) SetScreenTimer(context.Context,
func (UnimplementedEveningDetectiveServerServer) SendScreenCommand(context.Context, *SendScreenCommandReq) (*SendScreenCommandRsp, error) {
return nil, status.Error(codes.Unimplemented, "method SendScreenCommand not implemented")
}
func (UnimplementedEveningDetectiveServerServer) GetScreenPlan(context.Context, *GetScreenPlanReq) (*GetScreenPlanRsp, error) {
return nil, status.Error(codes.Unimplemented, "method GetScreenPlan not implemented")
}
func (UnimplementedEveningDetectiveServerServer) SaveScreenPlan(context.Context, *SaveScreenPlanReq) (*SaveScreenPlanRsp, error) {
return nil, status.Error(codes.Unimplemented, "method SaveScreenPlan not implemented")
}
func (UnimplementedEveningDetectiveServerServer) SetScreenPlanStep(context.Context, *SetScreenPlanStepReq) (*SetScreenPlanStepRsp, error) {
return nil, status.Error(codes.Unimplemented, "method SetScreenPlanStep not implemented")
}
func (UnimplementedEveningDetectiveServerServer) GetScreenResults(context.Context, *GetScreenResultsReq) (*GetScreenResultsRsp, error) {
return nil, status.Error(codes.Unimplemented, "method GetScreenResults not implemented")
}
@@ -2502,6 +2550,60 @@ func _EveningDetectiveServer_SendScreenCommand_Handler(srv interface{}, ctx cont
return interceptor(ctx, in, info, handler)
}
func _EveningDetectiveServer_GetScreenPlan_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(GetScreenPlanReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(EveningDetectiveServerServer).GetScreenPlan(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: EveningDetectiveServer_GetScreenPlan_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(EveningDetectiveServerServer).GetScreenPlan(ctx, req.(*GetScreenPlanReq))
}
return interceptor(ctx, in, info, handler)
}
func _EveningDetectiveServer_SaveScreenPlan_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(SaveScreenPlanReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(EveningDetectiveServerServer).SaveScreenPlan(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: EveningDetectiveServer_SaveScreenPlan_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(EveningDetectiveServerServer).SaveScreenPlan(ctx, req.(*SaveScreenPlanReq))
}
return interceptor(ctx, in, info, handler)
}
func _EveningDetectiveServer_SetScreenPlanStep_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(SetScreenPlanStepReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(EveningDetectiveServerServer).SetScreenPlanStep(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: EveningDetectiveServer_SetScreenPlanStep_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(EveningDetectiveServerServer).SetScreenPlanStep(ctx, req.(*SetScreenPlanStepReq))
}
return interceptor(ctx, in, info, handler)
}
func _EveningDetectiveServer_GetScreenResults_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(GetScreenResultsReq)
if err := dec(in); err != nil {
@@ -3227,6 +3329,18 @@ var EveningDetectiveServer_ServiceDesc = grpc.ServiceDesc{
MethodName: "SendScreenCommand",
Handler: _EveningDetectiveServer_SendScreenCommand_Handler,
},
{
MethodName: "GetScreenPlan",
Handler: _EveningDetectiveServer_GetScreenPlan_Handler,
},
{
MethodName: "SaveScreenPlan",
Handler: _EveningDetectiveServer_SaveScreenPlan_Handler,
},
{
MethodName: "SetScreenPlanStep",
Handler: _EveningDetectiveServer_SetScreenPlanStep_Handler,
},
{
MethodName: "GetScreenResults",
Handler: _EveningDetectiveServer_GetScreenResults_Handler,