This commit is contained in:
Владимир Фёдоров 2025-06-17 03:10:31 +07:00
parent be8e7fa482
commit 9cc6646fe3
15 changed files with 432 additions and 131 deletions

View File

@ -71,6 +71,12 @@ service EveningDetective {
body: "*"
};
}
rpc DownloadTeamsQrCodesFile(DownloadTeamsQrCodesFileReq) returns (DownloadTeamsQrCodesFileRsp) {
option (google.api.http) = {
get: "/teams/pdf"
};
}
}
message PingReq {}
@ -167,3 +173,9 @@ message GiveApplicationsReq {
}
message GiveApplicationsRsp {}
message DownloadTeamsQrCodesFileReq {}
message DownloadTeamsQrCodesFileRsp {
bytes result = 1;
}

View File

@ -57,3 +57,7 @@ POST http://localhost:8090/teams/1/applications
}
]
}
### Qr коды команд в pdf
GET http://localhost:8090/teams/pdf

Binary file not shown.

View File

@ -59,3 +59,7 @@ func (s *Server) GameStop(ctx context.Context, req *proto.GameStopReq) (*proto.G
func (s *Server) GiveApplications(ctx context.Context, req *proto.GiveApplicationsReq) (*proto.GiveApplicationsRsp, error) {
return s.services.GiveApplications(ctx, req)
}
func (s *Server) DownloadTeamsQrCodesFile(ctx context.Context, req *proto.DownloadTeamsQrCodesFileReq) (*proto.DownloadTeamsQrCodesFileRsp, error) {
return s.services.DownloadTeamsQrCodesFile(ctx, req)
}

View File

@ -12,7 +12,7 @@ import (
func CreateTeamsPdf(teams []*models.Team) ([]byte, error) {
pdf := &gopdf.GoPdf{}
pdf.Start(gopdf.Config{PageSize: *gopdf.PageSizeA4}) // W: 595, H: 842
if err := pdf.AddTTFFont("main", "JetBrainsMono-Medium.ttf"); err != nil {
if err := pdf.AddTTFFont("main", "data/JetBrainsMono-Medium.ttf"); err != nil {
return nil, err
}
if err := pdf.SetFont("main", "", 10); err != nil {

View File

@ -6,9 +6,11 @@ import (
"encoding/json"
"evening_detective/internal/models"
"evening_detective/internal/modules/password"
"evening_detective/internal/services/pdf_service"
"evening_detective/internal/services/story_service"
"evening_detective/proto"
"fmt"
"time"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/metadata"
@ -184,6 +186,20 @@ func (s *Services) AddTeams(ctx context.Context, req *proto.AddTeamsReq) (*proto
return &proto.AddTeamsRsp{Teams: res}, err
}
func (s *Services) DownloadTeamsQrCodesFile(ctx context.Context, req *proto.DownloadTeamsQrCodesFileReq) (*proto.DownloadTeamsQrCodesFileRsp, error) {
ctx, cancel := context.WithTimeout(context.Background(), 3*time.Second)
defer cancel()
teams, err := s.repository.GetTeams(ctx)
if err != nil {
return nil, err
}
b, err := pdf_service.CreateTeamsPdf(teams)
if err != nil {
return nil, err
}
return &proto.DownloadTeamsQrCodesFileRsp{Result: b}, nil
}
func (s *Services) getTeam(ctx context.Context) (*models.Team, error) {
md, ok := metadata.FromIncomingContext(ctx)
if !ok {

View File

@ -1233,6 +1233,91 @@ func (*GiveApplicationsRsp) Descriptor() ([]byte, []int) {
return file_main_proto_rawDescGZIP(), []int{24}
}
type DownloadTeamsQrCodesFileReq struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
}
func (x *DownloadTeamsQrCodesFileReq) Reset() {
*x = DownloadTeamsQrCodesFileReq{}
if protoimpl.UnsafeEnabled {
mi := &file_main_proto_msgTypes[25]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *DownloadTeamsQrCodesFileReq) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*DownloadTeamsQrCodesFileReq) ProtoMessage() {}
func (x *DownloadTeamsQrCodesFileReq) ProtoReflect() protoreflect.Message {
mi := &file_main_proto_msgTypes[25]
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 DownloadTeamsQrCodesFileReq.ProtoReflect.Descriptor instead.
func (*DownloadTeamsQrCodesFileReq) Descriptor() ([]byte, []int) {
return file_main_proto_rawDescGZIP(), []int{25}
}
type DownloadTeamsQrCodesFileRsp struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
Result []byte `protobuf:"bytes,1,opt,name=result,proto3" json:"result,omitempty"`
}
func (x *DownloadTeamsQrCodesFileRsp) Reset() {
*x = DownloadTeamsQrCodesFileRsp{}
if protoimpl.UnsafeEnabled {
mi := &file_main_proto_msgTypes[26]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *DownloadTeamsQrCodesFileRsp) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*DownloadTeamsQrCodesFileRsp) ProtoMessage() {}
func (x *DownloadTeamsQrCodesFileRsp) ProtoReflect() protoreflect.Message {
mi := &file_main_proto_msgTypes[26]
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 DownloadTeamsQrCodesFileRsp.ProtoReflect.Descriptor instead.
func (*DownloadTeamsQrCodesFileRsp) Descriptor() ([]byte, []int) {
return file_main_proto_rawDescGZIP(), []int{26}
}
func (x *DownloadTeamsQrCodesFileRsp) GetResult() []byte {
if x != nil {
return x.Result
}
return nil
}
var File_main_proto protoreflect.FileDescriptor
var file_main_proto_rawDesc = []byte{
@ -1324,79 +1409,94 @@ var file_main_proto_rawDesc = []byte{
0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x41, 0x70, 0x70, 0x6c, 0x69, 0x63,
0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0c, 0x61, 0x70, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69,
0x6f, 0x6e, 0x73, 0x22, 0x15, 0x0a, 0x13, 0x47, 0x69, 0x76, 0x65, 0x41, 0x70, 0x70, 0x6c, 0x69,
0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x73, 0x70, 0x32, 0xe8, 0x08, 0x0a, 0x10, 0x45,
0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x44, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x12,
0x59, 0x0a, 0x04, 0x50, 0x69, 0x6e, 0x67, 0x12, 0x20, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e,
0x65, 0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76,
0x65, 0x2e, 0x50, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x1a, 0x20, 0x2e, 0x63, 0x72, 0x61, 0x62,
0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74,
0x69, 0x76, 0x65, 0x2e, 0x50, 0x69, 0x6e, 0x67, 0x52, 0x73, 0x70, 0x22, 0x0d, 0x82, 0xd3, 0xe4,
0x93, 0x02, 0x07, 0x12, 0x05, 0x2f, 0x70, 0x69, 0x6e, 0x67, 0x12, 0x69, 0x0a, 0x08, 0x41, 0x64,
0x64, 0x54, 0x65, 0x61, 0x6d, 0x73, 0x12, 0x24, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65,
0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65,
0x2e, 0x41, 0x64, 0x64, 0x54, 0x65, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x71, 0x1a, 0x24, 0x2e, 0x63,
0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x73, 0x70, 0x22, 0x1d, 0x0a, 0x1b, 0x44, 0x6f,
0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x54, 0x65, 0x61, 0x6d, 0x73, 0x51, 0x72, 0x43, 0x6f, 0x64,
0x65, 0x73, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x22, 0x35, 0x0a, 0x1b, 0x44, 0x6f, 0x77,
0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x54, 0x65, 0x61, 0x6d, 0x73, 0x51, 0x72, 0x43, 0x6f, 0x64, 0x65,
0x73, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x73, 0x70, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x65, 0x73, 0x75,
0x6c, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74,
0x32, 0x85, 0x0a, 0x0a, 0x10, 0x45, 0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x44, 0x65, 0x74, 0x65,
0x63, 0x74, 0x69, 0x76, 0x65, 0x12, 0x59, 0x0a, 0x04, 0x50, 0x69, 0x6e, 0x67, 0x12, 0x20, 0x2e,
0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65,
0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x50, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x1a,
0x20, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f,
0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x50, 0x69, 0x6e, 0x67, 0x52, 0x73,
0x70, 0x22, 0x0d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x07, 0x12, 0x05, 0x2f, 0x70, 0x69, 0x6e, 0x67,
0x12, 0x69, 0x0a, 0x08, 0x41, 0x64, 0x64, 0x54, 0x65, 0x61, 0x6d, 0x73, 0x12, 0x24, 0x2e, 0x63,
0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74,
0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x41, 0x64, 0x64, 0x54, 0x65, 0x61, 0x6d, 0x73, 0x52,
0x73, 0x70, 0x22, 0x11, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x0b, 0x3a, 0x01, 0x2a, 0x22, 0x06, 0x2f,
0x74, 0x65, 0x61, 0x6d, 0x73, 0x12, 0x66, 0x0a, 0x08, 0x47, 0x65, 0x74, 0x54, 0x65, 0x61, 0x6d,
0x73, 0x12, 0x24, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x69, 0x6e,
0x67, 0x5f, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x47, 0x65, 0x74, 0x54,
0x65, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x71, 0x1a, 0x24, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e,
0x65, 0x71, 0x1a, 0x24, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x69,
0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x41, 0x64, 0x64,
0x54, 0x65, 0x61, 0x6d, 0x73, 0x52, 0x73, 0x70, 0x22, 0x11, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x0b,
0x3a, 0x01, 0x2a, 0x22, 0x06, 0x2f, 0x74, 0x65, 0x61, 0x6d, 0x73, 0x12, 0x66, 0x0a, 0x08, 0x47,
0x65, 0x74, 0x54, 0x65, 0x61, 0x6d, 0x73, 0x12, 0x24, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e,
0x65, 0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76,
0x65, 0x2e, 0x47, 0x65, 0x74, 0x54, 0x65, 0x61, 0x6d, 0x73, 0x52, 0x73, 0x70, 0x22, 0x0e, 0x82,
0xd3, 0xe4, 0x93, 0x02, 0x08, 0x12, 0x06, 0x2f, 0x74, 0x65, 0x61, 0x6d, 0x73, 0x12, 0x6d, 0x0a,
0x0b, 0x47, 0x65, 0x74, 0x54, 0x65, 0x61, 0x6d, 0x73, 0x43, 0x53, 0x56, 0x12, 0x27, 0x2e, 0x63,
0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74,
0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x47, 0x65, 0x74, 0x54, 0x65, 0x61, 0x6d, 0x73, 0x43,
0x53, 0x56, 0x52, 0x65, 0x71, 0x1a, 0x27, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76,
0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e,
0x47, 0x65, 0x74, 0x54, 0x65, 0x61, 0x6d, 0x73, 0x43, 0x53, 0x56, 0x52, 0x73, 0x70, 0x22, 0x0c,
0x82, 0xd3, 0xe4, 0x93, 0x02, 0x06, 0x12, 0x04, 0x2f, 0x63, 0x73, 0x76, 0x12, 0x62, 0x0a, 0x07,
0x47, 0x65, 0x74, 0x54, 0x65, 0x61, 0x6d, 0x12, 0x23, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e,
0x65, 0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76,
0x65, 0x2e, 0x47, 0x65, 0x74, 0x54, 0x65, 0x61, 0x6d, 0x52, 0x65, 0x71, 0x1a, 0x23, 0x2e, 0x63,
0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74,
0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x47, 0x65, 0x74, 0x54, 0x65, 0x61, 0x6d, 0x52, 0x73,
0x70, 0x22, 0x0d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x07, 0x12, 0x05, 0x2f, 0x74, 0x65, 0x61, 0x6d,
0x12, 0x73, 0x0a, 0x09, 0x41, 0x64, 0x64, 0x41, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x25, 0x2e,
0x65, 0x2e, 0x47, 0x65, 0x74, 0x54, 0x65, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x71, 0x1a, 0x24, 0x2e,
0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65,
0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x41, 0x64, 0x64, 0x41, 0x63, 0x74, 0x69, 0x6f,
0x6e, 0x52, 0x65, 0x71, 0x1a, 0x25, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65,
0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x41,
0x64, 0x64, 0x41, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x73, 0x70, 0x22, 0x18, 0x82, 0xd3, 0xe4,
0x93, 0x02, 0x12, 0x3a, 0x01, 0x2a, 0x22, 0x0d, 0x2f, 0x74, 0x65, 0x61, 0x6d, 0x2f, 0x61, 0x63,
0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x62, 0x0a, 0x07, 0x47, 0x65, 0x74, 0x47, 0x61, 0x6d, 0x65,
0x12, 0x23, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67,
0x5f, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x47, 0x65, 0x74, 0x47, 0x61,
0x6d, 0x65, 0x52, 0x65, 0x71, 0x1a, 0x23, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76,
0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e,
0x47, 0x65, 0x74, 0x47, 0x61, 0x6d, 0x65, 0x52, 0x73, 0x70, 0x22, 0x0d, 0x82, 0xd3, 0xe4, 0x93,
0x02, 0x07, 0x12, 0x05, 0x2f, 0x67, 0x61, 0x6d, 0x65, 0x12, 0x71, 0x0a, 0x09, 0x47, 0x61, 0x6d,
0x65, 0x53, 0x74, 0x61, 0x72, 0x74, 0x12, 0x25, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65,
0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x47, 0x65, 0x74, 0x54, 0x65, 0x61, 0x6d, 0x73,
0x52, 0x73, 0x70, 0x22, 0x0e, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x08, 0x12, 0x06, 0x2f, 0x74, 0x65,
0x61, 0x6d, 0x73, 0x12, 0x6d, 0x0a, 0x0b, 0x47, 0x65, 0x74, 0x54, 0x65, 0x61, 0x6d, 0x73, 0x43,
0x53, 0x56, 0x12, 0x27, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x69,
0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x47, 0x65, 0x74,
0x54, 0x65, 0x61, 0x6d, 0x73, 0x43, 0x53, 0x56, 0x52, 0x65, 0x71, 0x1a, 0x27, 0x2e, 0x63, 0x72,
0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74, 0x65,
0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x47, 0x65, 0x74, 0x54, 0x65, 0x61, 0x6d, 0x73, 0x43, 0x53,
0x56, 0x52, 0x73, 0x70, 0x22, 0x0c, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x06, 0x12, 0x04, 0x2f, 0x63,
0x73, 0x76, 0x12, 0x62, 0x0a, 0x07, 0x47, 0x65, 0x74, 0x54, 0x65, 0x61, 0x6d, 0x12, 0x23, 0x2e,
0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65,
0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x47, 0x65, 0x74, 0x54, 0x65, 0x61, 0x6d, 0x52,
0x65, 0x71, 0x1a, 0x23, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x69,
0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x47, 0x65, 0x74,
0x54, 0x65, 0x61, 0x6d, 0x52, 0x73, 0x70, 0x22, 0x0d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x07, 0x12,
0x05, 0x2f, 0x74, 0x65, 0x61, 0x6d, 0x12, 0x73, 0x0a, 0x09, 0x41, 0x64, 0x64, 0x41, 0x63, 0x74,
0x69, 0x6f, 0x6e, 0x12, 0x25, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e,
0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x41, 0x64,
0x64, 0x41, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x71, 0x1a, 0x25, 0x2e, 0x63, 0x72, 0x61,
0x62, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74, 0x65, 0x63,
0x74, 0x69, 0x76, 0x65, 0x2e, 0x41, 0x64, 0x64, 0x41, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x73,
0x70, 0x22, 0x18, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x12, 0x3a, 0x01, 0x2a, 0x22, 0x0d, 0x2f, 0x74,
0x65, 0x61, 0x6d, 0x2f, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x62, 0x0a, 0x07, 0x47,
0x65, 0x74, 0x47, 0x61, 0x6d, 0x65, 0x12, 0x23, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65,
0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65,
0x2e, 0x47, 0x61, 0x6d, 0x65, 0x53, 0x74, 0x61, 0x72, 0x74, 0x52, 0x65, 0x71, 0x1a, 0x25, 0x2e,
0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65,
0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x47, 0x61, 0x6d, 0x65, 0x53, 0x74, 0x61, 0x72,
0x74, 0x52, 0x73, 0x70, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x10, 0x3a, 0x01, 0x2a, 0x22,
0x0b, 0x2f, 0x67, 0x61, 0x6d, 0x65, 0x2f, 0x73, 0x74, 0x61, 0x72, 0x74, 0x12, 0x6d, 0x0a, 0x08,
0x47, 0x61, 0x6d, 0x65, 0x53, 0x74, 0x6f, 0x70, 0x12, 0x24, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73,
0x2e, 0x65, 0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69,
0x76, 0x65, 0x2e, 0x47, 0x61, 0x6d, 0x65, 0x53, 0x74, 0x6f, 0x70, 0x52, 0x65, 0x71, 0x1a, 0x24,
0x2e, 0x47, 0x65, 0x74, 0x47, 0x61, 0x6d, 0x65, 0x52, 0x65, 0x71, 0x1a, 0x23, 0x2e, 0x63, 0x72,
0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74, 0x65,
0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x47, 0x65, 0x74, 0x47, 0x61, 0x6d, 0x65, 0x52, 0x73, 0x70,
0x22, 0x0d, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x07, 0x12, 0x05, 0x2f, 0x67, 0x61, 0x6d, 0x65, 0x12,
0x71, 0x0a, 0x09, 0x47, 0x61, 0x6d, 0x65, 0x53, 0x74, 0x61, 0x72, 0x74, 0x12, 0x25, 0x2e, 0x63,
0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74,
0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x47, 0x61, 0x6d, 0x65, 0x53, 0x74, 0x61, 0x72, 0x74,
0x52, 0x65, 0x71, 0x1a, 0x25, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e,
0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x47, 0x61,
0x6d, 0x65, 0x53, 0x74, 0x61, 0x72, 0x74, 0x52, 0x73, 0x70, 0x22, 0x16, 0x82, 0xd3, 0xe4, 0x93,
0x02, 0x10, 0x3a, 0x01, 0x2a, 0x22, 0x0b, 0x2f, 0x67, 0x61, 0x6d, 0x65, 0x2f, 0x73, 0x74, 0x61,
0x72, 0x74, 0x12, 0x6d, 0x0a, 0x08, 0x47, 0x61, 0x6d, 0x65, 0x53, 0x74, 0x6f, 0x70, 0x12, 0x24,
0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64,
0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x47, 0x61, 0x6d, 0x65, 0x53, 0x74, 0x6f,
0x70, 0x52, 0x73, 0x70, 0x22, 0x15, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x0f, 0x3a, 0x01, 0x2a, 0x22,
0x0a, 0x2f, 0x67, 0x61, 0x6d, 0x65, 0x2f, 0x73, 0x74, 0x6f, 0x70, 0x12, 0x97, 0x01, 0x0a, 0x10,
0x47, 0x69, 0x76, 0x65, 0x41, 0x70, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73,
0x12, 0x2c, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67,
0x5f, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x47, 0x69, 0x76, 0x65, 0x41,
0x70, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x65, 0x71, 0x1a, 0x2c,
0x70, 0x52, 0x65, 0x71, 0x1a, 0x24, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65,
0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x47,
0x61, 0x6d, 0x65, 0x53, 0x74, 0x6f, 0x70, 0x52, 0x73, 0x70, 0x22, 0x15, 0x82, 0xd3, 0xe4, 0x93,
0x02, 0x0f, 0x3a, 0x01, 0x2a, 0x22, 0x0a, 0x2f, 0x67, 0x61, 0x6d, 0x65, 0x2f, 0x73, 0x74, 0x6f,
0x70, 0x12, 0x97, 0x01, 0x0a, 0x10, 0x47, 0x69, 0x76, 0x65, 0x41, 0x70, 0x70, 0x6c, 0x69, 0x63,
0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x2c, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65,
0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65,
0x2e, 0x47, 0x69, 0x76, 0x65, 0x41, 0x70, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e,
0x73, 0x52, 0x65, 0x71, 0x1a, 0x2c, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65,
0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x47,
0x69, 0x76, 0x65, 0x41, 0x70, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52,
0x73, 0x70, 0x22, 0x27, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x21, 0x3a, 0x01, 0x2a, 0x22, 0x1c, 0x2f,
0x74, 0x65, 0x61, 0x6d, 0x73, 0x2f, 0x7b, 0x74, 0x65, 0x61, 0x6d, 0x49, 0x64, 0x7d, 0x2f, 0x61,
0x70, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x9a, 0x01, 0x0a, 0x18,
0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x54, 0x65, 0x61, 0x6d, 0x73, 0x51, 0x72, 0x43,
0x6f, 0x64, 0x65, 0x73, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x34, 0x2e, 0x63, 0x72, 0x61, 0x62, 0x73,
0x2e, 0x65, 0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69,
0x76, 0x65, 0x2e, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x54, 0x65, 0x61, 0x6d, 0x73,
0x51, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x73, 0x46, 0x69, 0x6c, 0x65, 0x52, 0x65, 0x71, 0x1a, 0x34,
0x2e, 0x63, 0x72, 0x61, 0x62, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x69, 0x6e, 0x67, 0x5f, 0x64,
0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x47, 0x69, 0x76, 0x65, 0x41, 0x70, 0x70,
0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x73, 0x70, 0x22, 0x27, 0x82, 0xd3,
0xe4, 0x93, 0x02, 0x21, 0x3a, 0x01, 0x2a, 0x22, 0x1c, 0x2f, 0x74, 0x65, 0x61, 0x6d, 0x73, 0x2f,
0x7b, 0x74, 0x65, 0x61, 0x6d, 0x49, 0x64, 0x7d, 0x2f, 0x61, 0x70, 0x70, 0x6c, 0x69, 0x63, 0x61,
0x74, 0x69, 0x6f, 0x6e, 0x73, 0x42, 0x0b, 0x5a, 0x09, 0x70, 0x6b, 0x67, 0x2f, 0x70, 0x72, 0x6f,
0x74, 0x6f, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x76, 0x65, 0x2e, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61,
0x64, 0x54, 0x65, 0x61, 0x6d, 0x73, 0x51, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x73, 0x46, 0x69, 0x6c,
0x65, 0x52, 0x73, 0x70, 0x22, 0x12, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x0c, 0x12, 0x0a, 0x2f, 0x74,
0x65, 0x61, 0x6d, 0x73, 0x2f, 0x70, 0x64, 0x66, 0x42, 0x0b, 0x5a, 0x09, 0x70, 0x6b, 0x67, 0x2f,
0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
}
var (
@ -1411,7 +1511,7 @@ func file_main_proto_rawDescGZIP() []byte {
return file_main_proto_rawDescData
}
var file_main_proto_msgTypes = make([]protoimpl.MessageInfo, 25)
var file_main_proto_msgTypes = make([]protoimpl.MessageInfo, 27)
var file_main_proto_goTypes = []interface{}{
(*PingReq)(nil), // 0: crabs.evening_detective.PingReq
(*PingRsp)(nil), // 1: crabs.evening_detective.PingRsp
@ -1438,6 +1538,8 @@ var file_main_proto_goTypes = []interface{}{
(*GameStopRsp)(nil), // 22: crabs.evening_detective.GameStopRsp
(*GiveApplicationsReq)(nil), // 23: crabs.evening_detective.GiveApplicationsReq
(*GiveApplicationsRsp)(nil), // 24: crabs.evening_detective.GiveApplicationsRsp
(*DownloadTeamsQrCodesFileReq)(nil), // 25: crabs.evening_detective.DownloadTeamsQrCodesFileReq
(*DownloadTeamsQrCodesFileRsp)(nil), // 26: crabs.evening_detective.DownloadTeamsQrCodesFileRsp
}
var file_main_proto_depIdxs = []int32{
3, // 0: crabs.evening_detective.AddTeamsReq.teams:type_name -> crabs.evening_detective.Team
@ -1457,18 +1559,20 @@ var file_main_proto_depIdxs = []int32{
19, // 14: crabs.evening_detective.EveningDetective.GameStart:input_type -> crabs.evening_detective.GameStartReq
21, // 15: crabs.evening_detective.EveningDetective.GameStop:input_type -> crabs.evening_detective.GameStopReq
23, // 16: crabs.evening_detective.EveningDetective.GiveApplications:input_type -> crabs.evening_detective.GiveApplicationsReq
1, // 17: crabs.evening_detective.EveningDetective.Ping:output_type -> crabs.evening_detective.PingRsp
4, // 18: crabs.evening_detective.EveningDetective.AddTeams:output_type -> crabs.evening_detective.AddTeamsRsp
7, // 19: crabs.evening_detective.EveningDetective.GetTeams:output_type -> crabs.evening_detective.GetTeamsRsp
9, // 20: crabs.evening_detective.EveningDetective.GetTeamsCSV:output_type -> crabs.evening_detective.GetTeamsCSVRsp
13, // 21: crabs.evening_detective.EveningDetective.GetTeam:output_type -> crabs.evening_detective.GetTeamRsp
15, // 22: crabs.evening_detective.EveningDetective.AddAction:output_type -> crabs.evening_detective.AddActionRsp
18, // 23: crabs.evening_detective.EveningDetective.GetGame:output_type -> crabs.evening_detective.GetGameRsp
20, // 24: crabs.evening_detective.EveningDetective.GameStart:output_type -> crabs.evening_detective.GameStartRsp
22, // 25: crabs.evening_detective.EveningDetective.GameStop:output_type -> crabs.evening_detective.GameStopRsp
24, // 26: crabs.evening_detective.EveningDetective.GiveApplications:output_type -> crabs.evening_detective.GiveApplicationsRsp
17, // [17:27] is the sub-list for method output_type
7, // [7:17] is the sub-list for method input_type
25, // 17: crabs.evening_detective.EveningDetective.DownloadTeamsQrCodesFile:input_type -> crabs.evening_detective.DownloadTeamsQrCodesFileReq
1, // 18: crabs.evening_detective.EveningDetective.Ping:output_type -> crabs.evening_detective.PingRsp
4, // 19: crabs.evening_detective.EveningDetective.AddTeams:output_type -> crabs.evening_detective.AddTeamsRsp
7, // 20: crabs.evening_detective.EveningDetective.GetTeams:output_type -> crabs.evening_detective.GetTeamsRsp
9, // 21: crabs.evening_detective.EveningDetective.GetTeamsCSV:output_type -> crabs.evening_detective.GetTeamsCSVRsp
13, // 22: crabs.evening_detective.EveningDetective.GetTeam:output_type -> crabs.evening_detective.GetTeamRsp
15, // 23: crabs.evening_detective.EveningDetective.AddAction:output_type -> crabs.evening_detective.AddActionRsp
18, // 24: crabs.evening_detective.EveningDetective.GetGame:output_type -> crabs.evening_detective.GetGameRsp
20, // 25: crabs.evening_detective.EveningDetective.GameStart:output_type -> crabs.evening_detective.GameStartRsp
22, // 26: crabs.evening_detective.EveningDetective.GameStop:output_type -> crabs.evening_detective.GameStopRsp
24, // 27: crabs.evening_detective.EveningDetective.GiveApplications:output_type -> crabs.evening_detective.GiveApplicationsRsp
26, // 28: crabs.evening_detective.EveningDetective.DownloadTeamsQrCodesFile:output_type -> crabs.evening_detective.DownloadTeamsQrCodesFileRsp
18, // [18:29] is the sub-list for method output_type
7, // [7:18] 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
@ -1780,6 +1884,30 @@ func file_main_proto_init() {
return nil
}
}
file_main_proto_msgTypes[25].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*DownloadTeamsQrCodesFileReq); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_main_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*DownloadTeamsQrCodesFileRsp); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
}
type x struct{}
out := protoimpl.TypeBuilder{
@ -1787,7 +1915,7 @@ func file_main_proto_init() {
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: file_main_proto_rawDesc,
NumEnums: 0,
NumMessages: 25,
NumMessages: 27,
NumExtensions: 0,
NumServices: 1,
},

View File

@ -285,6 +285,24 @@ func local_request_EveningDetective_GiveApplications_0(ctx context.Context, mars
}
func request_EveningDetective_DownloadTeamsQrCodesFile_0(ctx context.Context, marshaler runtime.Marshaler, client EveningDetectiveClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
var protoReq DownloadTeamsQrCodesFileReq
var metadata runtime.ServerMetadata
msg, err := client.DownloadTeamsQrCodesFile(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))
return msg, metadata, err
}
func local_request_EveningDetective_DownloadTeamsQrCodesFile_0(ctx context.Context, marshaler runtime.Marshaler, server EveningDetectiveServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
var protoReq DownloadTeamsQrCodesFileReq
var metadata runtime.ServerMetadata
msg, err := server.DownloadTeamsQrCodesFile(ctx, &protoReq)
return msg, metadata, err
}
// RegisterEveningDetectiveHandlerServer registers the http handlers for service EveningDetective to "mux".
// UnaryRPC :call EveningDetectiveServer directly.
// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906.
@ -541,6 +559,31 @@ func RegisterEveningDetectiveHandlerServer(ctx context.Context, mux *runtime.Ser
})
mux.Handle("GET", pattern_EveningDetective_DownloadTeamsQrCodesFile_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(req.Context())
defer cancel()
var stream runtime.ServerTransportStream
ctx = grpc.NewContextWithServerTransportStream(ctx, &stream)
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
var err error
var annotatedContext context.Context
annotatedContext, err = runtime.AnnotateIncomingContext(ctx, mux, req, "/crabs.evening_detective.EveningDetective/DownloadTeamsQrCodesFile", runtime.WithHTTPPathPattern("/teams/pdf"))
if err != nil {
runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
return
}
resp, md, err := local_request_EveningDetective_DownloadTeamsQrCodesFile_0(annotatedContext, inboundMarshaler, server, req, pathParams)
md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer())
annotatedContext = runtime.NewServerMetadataContext(annotatedContext, md)
if err != nil {
runtime.HTTPError(annotatedContext, mux, outboundMarshaler, w, req, err)
return
}
forward_EveningDetective_DownloadTeamsQrCodesFile_0(annotatedContext, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
})
return nil
}
@ -802,6 +845,28 @@ func RegisterEveningDetectiveHandlerClient(ctx context.Context, mux *runtime.Ser
})
mux.Handle("GET", pattern_EveningDetective_DownloadTeamsQrCodesFile_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(req.Context())
defer cancel()
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
var err error
var annotatedContext context.Context
annotatedContext, err = runtime.AnnotateContext(ctx, mux, req, "/crabs.evening_detective.EveningDetective/DownloadTeamsQrCodesFile", runtime.WithHTTPPathPattern("/teams/pdf"))
if err != nil {
runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
return
}
resp, md, err := request_EveningDetective_DownloadTeamsQrCodesFile_0(annotatedContext, inboundMarshaler, client, req, pathParams)
annotatedContext = runtime.NewServerMetadataContext(annotatedContext, md)
if err != nil {
runtime.HTTPError(annotatedContext, mux, outboundMarshaler, w, req, err)
return
}
forward_EveningDetective_DownloadTeamsQrCodesFile_0(annotatedContext, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
})
return nil
}
@ -825,6 +890,8 @@ var (
pattern_EveningDetective_GameStop_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"game", "stop"}, ""))
pattern_EveningDetective_GiveApplications_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 1, 0, 4, 1, 5, 1, 2, 2}, []string{"teams", "teamId", "applications"}, ""))
pattern_EveningDetective_DownloadTeamsQrCodesFile_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1}, []string{"teams", "pdf"}, ""))
)
var (
@ -847,4 +914,6 @@ var (
forward_EveningDetective_GameStop_0 = runtime.ForwardResponseMessage
forward_EveningDetective_GiveApplications_0 = runtime.ForwardResponseMessage
forward_EveningDetective_DownloadTeamsQrCodesFile_0 = runtime.ForwardResponseMessage
)

View File

@ -247,6 +247,28 @@
]
}
},
"/teams/pdf": {
"get": {
"operationId": "EveningDetective_DownloadTeamsQrCodesFile",
"responses": {
"200": {
"description": "A successful response.",
"schema": {
"$ref": "#/definitions/evening_detectiveDownloadTeamsQrCodesFileRsp"
}
},
"default": {
"description": "An unexpected error response.",
"schema": {
"$ref": "#/definitions/runtimeError"
}
}
},
"tags": [
"EveningDetective"
]
}
},
"/teams/{teamId}/applications": {
"post": {
"operationId": "EveningDetective_GiveApplications",
@ -360,6 +382,15 @@
}
}
},
"evening_detectiveDownloadTeamsQrCodesFileRsp": {
"type": "object",
"properties": {
"result": {
"type": "string",
"format": "byte"
}
}
},
"evening_detectiveGameStartReq": {
"type": "object"
},

View File

@ -29,6 +29,7 @@ const (
EveningDetective_GameStart_FullMethodName = "/crabs.evening_detective.EveningDetective/GameStart"
EveningDetective_GameStop_FullMethodName = "/crabs.evening_detective.EveningDetective/GameStop"
EveningDetective_GiveApplications_FullMethodName = "/crabs.evening_detective.EveningDetective/GiveApplications"
EveningDetective_DownloadTeamsQrCodesFile_FullMethodName = "/crabs.evening_detective.EveningDetective/DownloadTeamsQrCodesFile"
)
// EveningDetectiveClient is the client API for EveningDetective service.
@ -45,6 +46,7 @@ type EveningDetectiveClient interface {
GameStart(ctx context.Context, in *GameStartReq, opts ...grpc.CallOption) (*GameStartRsp, error)
GameStop(ctx context.Context, in *GameStopReq, opts ...grpc.CallOption) (*GameStopRsp, error)
GiveApplications(ctx context.Context, in *GiveApplicationsReq, opts ...grpc.CallOption) (*GiveApplicationsRsp, error)
DownloadTeamsQrCodesFile(ctx context.Context, in *DownloadTeamsQrCodesFileReq, opts ...grpc.CallOption) (*DownloadTeamsQrCodesFileRsp, error)
}
type eveningDetectiveClient struct {
@ -145,6 +147,15 @@ func (c *eveningDetectiveClient) GiveApplications(ctx context.Context, in *GiveA
return out, nil
}
func (c *eveningDetectiveClient) DownloadTeamsQrCodesFile(ctx context.Context, in *DownloadTeamsQrCodesFileReq, opts ...grpc.CallOption) (*DownloadTeamsQrCodesFileRsp, error) {
out := new(DownloadTeamsQrCodesFileRsp)
err := c.cc.Invoke(ctx, EveningDetective_DownloadTeamsQrCodesFile_FullMethodName, in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
// EveningDetectiveServer is the server API for EveningDetective service.
// All implementations must embed UnimplementedEveningDetectiveServer
// for forward compatibility
@ -159,6 +170,7 @@ type EveningDetectiveServer interface {
GameStart(context.Context, *GameStartReq) (*GameStartRsp, error)
GameStop(context.Context, *GameStopReq) (*GameStopRsp, error)
GiveApplications(context.Context, *GiveApplicationsReq) (*GiveApplicationsRsp, error)
DownloadTeamsQrCodesFile(context.Context, *DownloadTeamsQrCodesFileReq) (*DownloadTeamsQrCodesFileRsp, error)
mustEmbedUnimplementedEveningDetectiveServer()
}
@ -196,6 +208,9 @@ func (UnimplementedEveningDetectiveServer) GameStop(context.Context, *GameStopRe
func (UnimplementedEveningDetectiveServer) GiveApplications(context.Context, *GiveApplicationsReq) (*GiveApplicationsRsp, error) {
return nil, status.Errorf(codes.Unimplemented, "method GiveApplications not implemented")
}
func (UnimplementedEveningDetectiveServer) DownloadTeamsQrCodesFile(context.Context, *DownloadTeamsQrCodesFileReq) (*DownloadTeamsQrCodesFileRsp, error) {
return nil, status.Errorf(codes.Unimplemented, "method DownloadTeamsQrCodesFile not implemented")
}
func (UnimplementedEveningDetectiveServer) mustEmbedUnimplementedEveningDetectiveServer() {}
// UnsafeEveningDetectiveServer may be embedded to opt out of forward compatibility for this service.
@ -389,6 +404,24 @@ func _EveningDetective_GiveApplications_Handler(srv interface{}, ctx context.Con
return interceptor(ctx, in, info, handler)
}
func _EveningDetective_DownloadTeamsQrCodesFile_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(DownloadTeamsQrCodesFileReq)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(EveningDetectiveServer).DownloadTeamsQrCodesFile(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: EveningDetective_DownloadTeamsQrCodesFile_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(EveningDetectiveServer).DownloadTeamsQrCodesFile(ctx, req.(*DownloadTeamsQrCodesFileReq))
}
return interceptor(ctx, in, info, handler)
}
// EveningDetective_ServiceDesc is the grpc.ServiceDesc for EveningDetective service.
// It's only intended for direct use with grpc.RegisterService,
// and not to be introspected or modified (even as a copy)
@ -436,6 +469,10 @@ var EveningDetective_ServiceDesc = grpc.ServiceDesc{
MethodName: "GiveApplications",
Handler: _EveningDetective_GiveApplications_Handler,
},
{
MethodName: "DownloadTeamsQrCodesFile",
Handler: _EveningDetective_DownloadTeamsQrCodesFile_Handler,
},
},
Streams: []grpc.StreamDesc{},
Metadata: "main.proto",

View File

@ -1 +1 @@
import{_ as o,c as s,a as t,o as a}from"./index-C49JGeDk.js";const n={},c={class:"about"};function r(_,e){return a(),s("div",c,e[0]||(e[0]=[t("h1",null,"This is an about page",-1)]))}const l=o(n,[["render",r]]);export{l as default};
import{_ as o,c as s,a as t,o as a}from"./index-BnuCLF3i.js";const n={},c={class:"about"};function r(_,e){return a(),s("div",c,e[0]||(e[0]=[t("h1",null,"This is an about page",-1)]))}const l=o(n,[["render",r]]);export{l as default};

View File

@ -0,0 +1 @@
:root{--vt-c-white: #ffffff;--vt-c-white-soft: #f8f8f8;--vt-c-white-mute: #f2f2f2;--vt-c-black: #181818;--vt-c-black-soft: #222222;--vt-c-black-mute: #282828;--vt-c-indigo: #2c3e50;--vt-c-divider-light-1: rgba(60, 60, 60, .29);--vt-c-divider-light-2: rgba(60, 60, 60, .12);--vt-c-divider-dark-1: rgba(84, 84, 84, .65);--vt-c-divider-dark-2: rgba(84, 84, 84, .48);--vt-c-text-light-1: var(--vt-c-indigo);--vt-c-text-light-2: rgba(60, 60, 60, .66);--vt-c-text-dark-1: var(--vt-c-white);--vt-c-text-dark-2: rgba(235, 235, 235, .64);--main-color: rgba(34, 50, 60, 1);--second-color: rgb(136, 105, 31);--main-back-color: rgba(240, 240, 240, 1);--main-back-item-color: rgba(254, 254, 254, 1)}:root{--color-background: var(--vt-c-white);--color-background-soft: var(--vt-c-white-soft);--color-background-mute: var(--vt-c-white-mute);--color-border: var(--vt-c-divider-light-2);--color-border-hover: var(--vt-c-divider-light-1);--color-heading: var(--vt-c-text-light-1);--color-text: var(--vt-c-text-light-1);--section-gap: 160px}*,*:before,*:after{box-sizing:border-box;margin:0;font-weight:400}body{min-height:100dvh;color:var(--color-text);background:var(--main-back-color);transition:color .5s,background-color .5s;line-height:1.6;font-family:Inter,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,sans-serif;font-size:15px;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.header-block{height:50px;background-color:var(--main-color);font-size:large;color:#fff;vertical-align:middle;padding:10px 0 10px 16px;font-weight:700}.input-custom{width:100%;box-sizing:border-box;margin-bottom:15px}.button-custom{margin-left:auto;background-color:var(--main-color);font-weight:600;color:#fff}.button-custom-inline{margin:10px;background-color:var(--main-color);font-weight:600;color:#fff;padding:6px 8px;border:1px solid #ddd;border-radius:15px;font-size:14px}.button-custom:hover,.button-custom-inline:hover{background-color:var(--second-color)}.input-custom,.button-custom{padding:12px 16px;border:1px solid #ddd;border-radius:15px;font-size:16px}.button-container{display:flex}.center-message{display:flex;justify-content:center;align-items:center;height:calc(100dvh - 100px);text-align:center}header[data-v-e5db0c22]{line-height:1.5;max-height:100vh}.logo[data-v-e5db0c22]{display:block;margin:0 auto 2rem}nav[data-v-e5db0c22]{width:100%;font-size:12px;text-align:center;margin-top:2rem}nav a.router-link-exact-active[data-v-e5db0c22]{color:var(--color-text)}nav a.router-link-exact-active[data-v-e5db0c22]:hover{background-color:transparent}nav a[data-v-e5db0c22]{display:inline-block;padding:0 1rem;border-left:1px solid var(--color-border)}nav a[data-v-e5db0c22]:first-of-type{border:0}@media (min-width: 1024px){header[data-v-e5db0c22]{display:flex;place-items:center;padding-right:calc(var(--section-gap) / 2)}.logo[data-v-e5db0c22]{margin:0 2rem 0 0}header .wrapper[data-v-e5db0c22]{display:flex;place-items:flex-start;flex-wrap:wrap}nav[data-v-e5db0c22]{text-align:left;margin-left:-1rem;font-size:1rem;padding:1rem 0;margin-top:1rem}}body[data-v-764d6ba3]{font-family:Arial,sans-serif;margin:20px}.buttons-block[data-v-764d6ba3]{padding-top:20px}.button-menu[data-v-764d6ba3]{margin:5px}table[data-v-764d6ba3]{width:700px;border-collapse:collapse;margin:30px auto;border:1px solid #444444}th[data-v-764d6ba3],td[data-v-764d6ba3]{padding:12px;text-align:left}th[data-v-764d6ba3]{background-color:var(--main-color);color:#fff;font-weight:700}tr[data-v-764d6ba3]:nth-child(odd){background-color:#efefef}tr[data-v-764d6ba3]:nth-child(2n){background-color:#fff}tr[data-v-764d6ba3]:hover{background-color:#cfcfcf}.time[data-v-764d6ba3]{white-space:nowrap}.team-name[data-v-764d6ba3]{font-weight:600}.link-button[data-v-764d6ba3]{display:inline;border:none;background:none;padding:0;margin:0;font:inherit;cursor:pointer;color:var(--main-color);text-decoration:underline;font-weight:600;-webkit-appearance:none;-moz-appearance:none;appearance:none;line-height:inherit;text-align:left}.link-button[data-v-764d6ba3]:hover{color:var(--second-color);text-decoration:none}.link-button[data-v-764d6ba3]:active{color:#036}.link-button[data-v-764d6ba3]:focus{outline:none;text-decoration:none;box-shadow:0 0 0 2px #0066cc4d}.form-block[data-v-764d6ba3]{width:700px;margin:0 auto}a[data-v-764d6ba3]{color:var(--second-color);text-decoration:none;transition:all .2s ease;cursor:pointer}a[data-v-764d6ba3]:hover{text-decoration:underline;text-decoration-thickness:2px;text-underline-offset:3px}a[data-v-764d6ba3]:focus-visible{outline:2px solid #3182ce;outline-offset:2px;border-radius:2px}a[disabled][data-v-764d6ba3]{color:#a0aec0;pointer-events:none;cursor:not-allowed}.qr[data-v-764d6ba3]{position:absolute;top:80px;right:30px;text-align:center;width:120px}.button-container[data-v-764d6ba3]{margin-bottom:30px}

File diff suppressed because one or more lines are too long

View File

@ -1 +0,0 @@
:root{--vt-c-white: #ffffff;--vt-c-white-soft: #f8f8f8;--vt-c-white-mute: #f2f2f2;--vt-c-black: #181818;--vt-c-black-soft: #222222;--vt-c-black-mute: #282828;--vt-c-indigo: #2c3e50;--vt-c-divider-light-1: rgba(60, 60, 60, .29);--vt-c-divider-light-2: rgba(60, 60, 60, .12);--vt-c-divider-dark-1: rgba(84, 84, 84, .65);--vt-c-divider-dark-2: rgba(84, 84, 84, .48);--vt-c-text-light-1: var(--vt-c-indigo);--vt-c-text-light-2: rgba(60, 60, 60, .66);--vt-c-text-dark-1: var(--vt-c-white);--vt-c-text-dark-2: rgba(235, 235, 235, .64);--main-color: rgba(34, 50, 60, 1);--second-color: rgb(136, 105, 31);--main-back-color: rgba(240, 240, 240, 1);--main-back-item-color: rgba(254, 254, 254, 1)}:root{--color-background: var(--vt-c-white);--color-background-soft: var(--vt-c-white-soft);--color-background-mute: var(--vt-c-white-mute);--color-border: var(--vt-c-divider-light-2);--color-border-hover: var(--vt-c-divider-light-1);--color-heading: var(--vt-c-text-light-1);--color-text: var(--vt-c-text-light-1);--section-gap: 160px}*,*:before,*:after{box-sizing:border-box;margin:0;font-weight:400}body{min-height:100dvh;color:var(--color-text);background:var(--main-back-color);transition:color .5s,background-color .5s;line-height:1.6;font-family:Inter,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,sans-serif;font-size:15px;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.header-block{height:50px;background-color:var(--main-color);font-size:large;color:#fff;vertical-align:middle;padding:10px 0 10px 16px;font-weight:700}.input-custom{width:100%;box-sizing:border-box;margin-bottom:15px}.button-custom{margin-left:auto;background-color:var(--main-color);font-weight:600;color:#fff}.button-custom:hover{background-color:var(--second-color)}.input-custom,.button-custom{padding:12px 16px;border:1px solid #ddd;border-radius:15px;font-size:16px}.button-container{display:flex}.center-message{display:flex;justify-content:center;align-items:center;height:calc(100dvh - 100px);text-align:center}header[data-v-e5db0c22]{line-height:1.5;max-height:100vh}.logo[data-v-e5db0c22]{display:block;margin:0 auto 2rem}nav[data-v-e5db0c22]{width:100%;font-size:12px;text-align:center;margin-top:2rem}nav a.router-link-exact-active[data-v-e5db0c22]{color:var(--color-text)}nav a.router-link-exact-active[data-v-e5db0c22]:hover{background-color:transparent}nav a[data-v-e5db0c22]{display:inline-block;padding:0 1rem;border-left:1px solid var(--color-border)}nav a[data-v-e5db0c22]:first-of-type{border:0}@media (min-width: 1024px){header[data-v-e5db0c22]{display:flex;place-items:center;padding-right:calc(var(--section-gap) / 2)}.logo[data-v-e5db0c22]{margin:0 2rem 0 0}header .wrapper[data-v-e5db0c22]{display:flex;place-items:flex-start;flex-wrap:wrap}nav[data-v-e5db0c22]{text-align:left;margin-left:-1rem;font-size:1rem;padding:1rem 0;margin-top:1rem}}body[data-v-4e1da5de]{font-family:Arial,sans-serif;margin:20px}.buttons-block[data-v-4e1da5de]{padding-top:20px}.button-menu[data-v-4e1da5de]{margin:5px}table[data-v-4e1da5de]{width:700px;border-collapse:collapse;margin:30px auto;border:1px solid #444444}th[data-v-4e1da5de],td[data-v-4e1da5de]{padding:12px;text-align:left}th[data-v-4e1da5de]{background-color:var(--main-color);color:#fff;font-weight:700}tr[data-v-4e1da5de]:nth-child(odd){background-color:#efefef}tr[data-v-4e1da5de]:nth-child(2n){background-color:#fff}tr[data-v-4e1da5de]:hover{background-color:#cfcfcf}.time[data-v-4e1da5de]{white-space:nowrap}.team-name[data-v-4e1da5de]{font-weight:600}.link-button[data-v-4e1da5de]{display:inline;border:none;background:none;padding:0;margin:0;font:inherit;cursor:pointer;color:var(--main-color);text-decoration:underline;font-weight:600;-webkit-appearance:none;-moz-appearance:none;appearance:none;line-height:inherit;text-align:left}.link-button[data-v-4e1da5de]:hover{color:var(--second-color);text-decoration:none}.link-button[data-v-4e1da5de]:active{color:#036}.link-button[data-v-4e1da5de]:focus{outline:none;text-decoration:none;box-shadow:0 0 0 2px #0066cc4d}.form-block[data-v-4e1da5de]{width:700px;margin:0 auto}a[data-v-4e1da5de]{color:var(--second-color);text-decoration:none;transition:all .2s ease;cursor:pointer}a[data-v-4e1da5de]:hover{text-decoration:underline;text-decoration-thickness:2px;text-underline-offset:3px}a[data-v-4e1da5de]:focus-visible{outline:2px solid #3182ce;outline-offset:2px;border-radius:2px}a[disabled][data-v-4e1da5de]{color:#a0aec0;pointer-events:none;cursor:not-allowed}.qr[data-v-4e1da5de]{position:absolute;top:80px;right:30px;text-align:center;width:120px}.button-container[data-v-4e1da5de]{margin-bottom:30px}

View File

@ -5,8 +5,8 @@
<link rel="icon" href="/favicon.ico">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>ВД Админка</title>
<script type="module" crossorigin src="/assets/index-C49JGeDk.js"></script>
<link rel="stylesheet" crossorigin href="/assets/index-D-LAc9ox.css">
<script type="module" crossorigin src="/assets/index-BnuCLF3i.js"></script>
<link rel="stylesheet" crossorigin href="/assets/index-0km8kjt9.css">
</head>
<body>
<div id="app"></div>