Create & Init Project...
This commit is contained in:
69
app/service/openplatform/ticket-item/api/grpc/v1/BUILD
Normal file
69
app/service/openplatform/ticket-item/api/grpc/v1/BUILD
Normal file
@ -0,0 +1,69 @@
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
load(
|
||||
"@io_bazel_rules_go//go:def.bzl",
|
||||
"go_library",
|
||||
)
|
||||
load(
|
||||
"@io_bazel_rules_go//proto:def.bzl",
|
||||
"go_proto_library",
|
||||
)
|
||||
|
||||
proto_library(
|
||||
name = "v1_proto",
|
||||
srcs = [
|
||||
"area.proto",
|
||||
"bulletin.proto",
|
||||
"guest.proto",
|
||||
"item.proto",
|
||||
"place.proto",
|
||||
"screen.proto",
|
||||
"seat.proto",
|
||||
"ticket.proto",
|
||||
"time.proto",
|
||||
"venue.proto",
|
||||
],
|
||||
tags = ["automanaged"],
|
||||
deps = ["@gogo_special_proto//github.com/gogo/protobuf/gogoproto"],
|
||||
)
|
||||
|
||||
go_proto_library(
|
||||
name = "v1_go_proto",
|
||||
compilers = ["@io_bazel_rules_go//proto:gogofast_grpc"],
|
||||
importpath = "go-common/app/service/openplatform/ticket-item/api/grpc/v1",
|
||||
proto = ":v1_proto",
|
||||
tags = ["automanaged"],
|
||||
deps = ["@com_github_gogo_protobuf//gogoproto:go_default_library"],
|
||||
)
|
||||
|
||||
go_library(
|
||||
name = "go_default_library",
|
||||
srcs = ["client.go"],
|
||||
embed = [":v1_go_proto"],
|
||||
importpath = "go-common/app/service/openplatform/ticket-item/api/grpc/v1",
|
||||
tags = ["automanaged"],
|
||||
visibility = ["//visibility:public"],
|
||||
deps = [
|
||||
"//library/log:go_default_library",
|
||||
"//library/net/rpc/warden:go_default_library",
|
||||
"//library/net/rpc/warden/balancer/wrr:go_default_library",
|
||||
"@com_github_gogo_protobuf//gogoproto:go_default_library",
|
||||
"@com_github_gogo_protobuf//proto:go_default_library",
|
||||
"@org_golang_google_grpc//:go_default_library",
|
||||
"@org_golang_x_net//context:go_default_library",
|
||||
],
|
||||
)
|
||||
|
||||
filegroup(
|
||||
name = "package-srcs",
|
||||
srcs = glob(["**"]),
|
||||
tags = ["automanaged"],
|
||||
visibility = ["//visibility:private"],
|
||||
)
|
||||
|
||||
filegroup(
|
||||
name = "all-srcs",
|
||||
srcs = [":package-srcs"],
|
||||
tags = ["automanaged"],
|
||||
visibility = ["//visibility:public"],
|
||||
)
|
1545
app/service/openplatform/ticket-item/api/grpc/v1/area.pb.go
Normal file
1545
app/service/openplatform/ticket-item/api/grpc/v1/area.pb.go
Normal file
File diff suppressed because it is too large
Load Diff
69
app/service/openplatform/ticket-item/api/grpc/v1/area.proto
Normal file
69
app/service/openplatform/ticket-item/api/grpc/v1/area.proto
Normal file
@ -0,0 +1,69 @@
|
||||
syntax = "proto3";
|
||||
package ticket.service.item.v1;
|
||||
|
||||
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
|
||||
|
||||
option (gogoproto.goproto_enum_prefix_all) = false;
|
||||
option (gogoproto.goproto_getters_all) = false;
|
||||
option (gogoproto.unmarshaler_all) = true;
|
||||
option (gogoproto.marshaler_all) = true;
|
||||
option (gogoproto.sizer_all) = true;
|
||||
option go_package = "v1";
|
||||
|
||||
// The area service definition.
|
||||
service Area {
|
||||
rpc AreaInfo (AreaInfoRequest) returns (AreaInfoReply) {}
|
||||
rpc DeleteArea (DeleteAreaRequest) returns (DeleteAreaReply) {}
|
||||
}
|
||||
|
||||
// The response message containing the area info
|
||||
message AreaInfo {
|
||||
int64 id = 1 [(gogoproto.jsontag) = "id", (gogoproto.customname)= "ID"];
|
||||
string a_id = 2 [(gogoproto.jsontag) = "a_id", (gogoproto.customname)= "AID"];
|
||||
string name = 3 [(gogoproto.jsontag) = "name"];
|
||||
int32 seat_num = 4 [(gogoproto.jsontag) = "seat_num"];
|
||||
int32 width = 5 [(gogoproto.jsontag) = "width"];
|
||||
int32 height = 6 [(gogoproto.jsontag) = "height"];
|
||||
int64 place = 7 [(gogoproto.jsontag) = "place"];
|
||||
int32 col_start = 8 [(gogoproto.jsontag) = "col_start"];
|
||||
int32 col_type = 9 [(gogoproto.jsontag) = "col_type"];
|
||||
int32 col_direction = 10 [(gogoproto.jsontag) = "col_direction"];
|
||||
string row_list = 11 [(gogoproto.jsontag) = "row_list"];
|
||||
string seat_start = 12 [(gogoproto.jsontag) = "seat_start"];
|
||||
}
|
||||
|
||||
// areaInfo接口请求
|
||||
message AreaInfoRequest {
|
||||
// 待修改区域的ID(为0表示创建)
|
||||
int64 ID = 1 [(gogoproto.jsontag) = "id", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
// 区域自定义编号
|
||||
string AID = 2 [(gogoproto.jsontag) = "a_id", (gogoproto.moretags) = "validate:\"min=1,max=16\""];
|
||||
// 区域名
|
||||
string Name = 3 [(gogoproto.jsontag) = "name", (gogoproto.moretags) = "validate:\"min=1,max=16\""];
|
||||
// 所属场地ID
|
||||
int64 Place = 4 [(gogoproto.jsontag) = "place", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
// 区域坐标
|
||||
string Coordinate = 5 [(gogoproto.jsontag) = "coordinate", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
}
|
||||
|
||||
// areaInfo接口返回
|
||||
message AreaInfoReply {
|
||||
// 操作结果
|
||||
bool Success = 1 [(gogoproto.jsontag) = "success"];
|
||||
// 操作区域ID
|
||||
int64 ID = 2 [(gogoproto.jsontag) = "id"];
|
||||
// 场地坐标
|
||||
string Coordinate = 3 [(gogoproto.jsontag) = "coordinate"];
|
||||
}
|
||||
|
||||
// deleteArea接口请求
|
||||
message DeleteAreaRequest {
|
||||
// 待删除区域的ID
|
||||
int64 ID = 1 [(gogoproto.jsontag) = "id", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
}
|
||||
|
||||
// deleteArea接口返回
|
||||
message DeleteAreaReply {
|
||||
// 操作结果
|
||||
bool Success = 1 [(gogoproto.jsontag) = "success"];
|
||||
}
|
1620
app/service/openplatform/ticket-item/api/grpc/v1/bulletin.pb.go
Normal file
1620
app/service/openplatform/ticket-item/api/grpc/v1/bulletin.pb.go
Normal file
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,54 @@
|
||||
syntax = "proto3";
|
||||
package ticket.service.item.v1;
|
||||
|
||||
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
|
||||
|
||||
option go_package = "v1";
|
||||
|
||||
// The bulletin service definition.
|
||||
service Bulletin {
|
||||
rpc BulletinInfo (BulletinInfoRequest) returns (BulletinReply) {}
|
||||
rpc BulletinCheck (BulletinCheckRequest) returns (BulletinReply) {}
|
||||
rpc BulletinState (BulletinStateRequest) returns (BulletinReply) {}
|
||||
}
|
||||
|
||||
// The response message containing the bulletin info
|
||||
message BulletinInfo {
|
||||
int64 id = 1 [(gogoproto.jsontag) = "id", (gogoproto.moretags) = "validate:\"min=1\"", (gogoproto.customname)= "ID"];
|
||||
string title = 2 [(gogoproto.jsontag) = "title"];
|
||||
string content = 3 [(gogoproto.jsontag) = "content"];
|
||||
string detail = 4 [(gogoproto.jsontag) = "detail"];
|
||||
string ctime = 5 [(gogoproto.jsontag) = "ctime", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
string mtime = 6 [(gogoproto.jsontag) = "mtime", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
uint64 ver_id = 7 [(gogoproto.jsontag) = "ver_id", (gogoproto.moretags) = "validate:\"min=0\"", (gogoproto.customname)= "VerID"];
|
||||
}
|
||||
|
||||
// The request message containing the bulletin info to update
|
||||
message BulletinInfoRequest {
|
||||
uint64 ver_id = 1 [(gogoproto.jsontag) = "ver_id", (gogoproto.customname)= "VerID"];
|
||||
string title = 2 [(gogoproto.jsontag) = "title", (gogoproto.moretags) = "validate:\"required,max=32\""];
|
||||
string content = 3 [(gogoproto.jsontag) = "content", (gogoproto.moretags) = "validate:\"max=128\""];
|
||||
string detail = 4 [(gogoproto.jsontag) = "detail"];
|
||||
int64 target_item = 5 [(gogoproto.jsontag) = "target_item"];
|
||||
int64 parent_id = 6 [(gogoproto.jsontag) = "parent_id", (gogoproto.moretags) = "validate:\"required,min=1\"", (gogoproto.customname)= "ParentID"];
|
||||
}
|
||||
|
||||
// The request message containing the required version info to review the bulletin
|
||||
message BulletinCheckRequest {
|
||||
uint64 ver_id = 1 [(gogoproto.jsontag) = "ver_id", (gogoproto.moretags) = "validate:\"required,min=1\"", (gogoproto.customname)= "VerID"];
|
||||
int32 op_type = 2 [(gogoproto.jsontag) = "op_type", (gogoproto.moretags) = "validate:\"min=0,max=1\""];
|
||||
string comment = 3 [(gogoproto.jsontag) = "comment"];
|
||||
string reviewer = 4 [(gogoproto.jsontag) = "reviewer", (gogoproto.moretags) = "validate:\"required\""];
|
||||
}
|
||||
|
||||
// The request message containing the required version info to change the bulletin's status
|
||||
message BulletinStateRequest {
|
||||
uint64 ver_id = 1 [(gogoproto.jsontag) = "ver_id", (gogoproto.moretags) = "validate:\"required,min=1\"", (gogoproto.customname)= "VerID"];
|
||||
int32 op_type = 2 [(gogoproto.jsontag) = "op_type", (gogoproto.moretags) = "validate:\"min=0,max=1\""];
|
||||
int32 source = 3 [(gogoproto.jsontag) = "source", (gogoproto.moretags) = "validate:\"min=1,max=2\""];
|
||||
}
|
||||
|
||||
// The general response message containing the result after updating/inserting the bulletin info
|
||||
message BulletinReply {
|
||||
bool success = 1 [(gogoproto.jsontag) = "success"];
|
||||
}
|
44
app/service/openplatform/ticket-item/api/grpc/v1/client.go
Normal file
44
app/service/openplatform/ticket-item/api/grpc/v1/client.go
Normal file
@ -0,0 +1,44 @@
|
||||
package v1
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"go-common/library/log"
|
||||
"go-common/library/net/rpc/warden"
|
||||
"go-common/library/net/rpc/warden/balancer/wrr"
|
||||
|
||||
"google.golang.org/grpc"
|
||||
)
|
||||
|
||||
// AppID unique app id for service diSCovery
|
||||
const AppID = "ticket.service.item"
|
||||
|
||||
//Client 客户端枚举
|
||||
type Client struct {
|
||||
IC ItemClient
|
||||
GC GuestClient
|
||||
BC BulletinClient
|
||||
VC VenueClient
|
||||
PC PlaceClient
|
||||
AC AreaClient
|
||||
SC SeatClient
|
||||
}
|
||||
|
||||
// New 新建客户端实例
|
||||
func New(c *warden.ClientConfig) (*Client, error) {
|
||||
client := warden.NewClient(c, grpc.WithBalancerName(wrr.Name))
|
||||
conn, err := client.Dial(context.Background(), "discovery://default/"+AppID)
|
||||
if err != nil {
|
||||
log.Error("client can not connect server: %v", err)
|
||||
return nil, err
|
||||
}
|
||||
return &Client{
|
||||
IC: NewItemClient(conn),
|
||||
GC: NewGuestClient(conn),
|
||||
BC: NewBulletinClient(conn),
|
||||
VC: NewVenueClient(conn),
|
||||
PC: NewPlaceClient(conn),
|
||||
AC: NewAreaClient(conn),
|
||||
SC: NewSeatClient(conn),
|
||||
}, nil
|
||||
}
|
811
app/service/openplatform/ticket-item/api/grpc/v1/guest.pb.go
Normal file
811
app/service/openplatform/ticket-item/api/grpc/v1/guest.pb.go
Normal file
@ -0,0 +1,811 @@
|
||||
// Code generated by protoc-gen-gogo. DO NOT EDIT.
|
||||
// source: app/service/openplatform/ticket-item/api/grpc/v1/guest.proto
|
||||
|
||||
package v1
|
||||
|
||||
import proto "github.com/gogo/protobuf/proto"
|
||||
import fmt "fmt"
|
||||
import math "math"
|
||||
import _ "github.com/gogo/protobuf/gogoproto"
|
||||
|
||||
import context "golang.org/x/net/context"
|
||||
import grpc "google.golang.org/grpc"
|
||||
|
||||
import io "io"
|
||||
|
||||
// Reference imports to suppress errors if they are not otherwise used.
|
||||
var _ = proto.Marshal
|
||||
var _ = fmt.Errorf
|
||||
var _ = math.Inf
|
||||
|
||||
// The request message containing the guest info to update/insert
|
||||
type GuestInfoRequest struct {
|
||||
ID uint32 `protobuf:"varint,1,opt,name=id,proto3" json:"id" validate:"min=0"`
|
||||
Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name" validate:"max=32"`
|
||||
GuestImg string `protobuf:"bytes,3,opt,name=guest_img,json=guestImg,proto3" json:"guest_img" validate:"min=0"`
|
||||
Description string `protobuf:"bytes,4,opt,name=description,proto3" json:"description" validate:"max=128"`
|
||||
GuestID int64 `protobuf:"varint,5,opt,name=guest_id,json=guestId,proto3" json:"guest_id"`
|
||||
}
|
||||
|
||||
func (m *GuestInfoRequest) Reset() { *m = GuestInfoRequest{} }
|
||||
func (m *GuestInfoRequest) String() string { return proto.CompactTextString(m) }
|
||||
func (*GuestInfoRequest) ProtoMessage() {}
|
||||
func (*GuestInfoRequest) Descriptor() ([]byte, []int) { return fileDescriptorGuest, []int{0} }
|
||||
|
||||
// The request message containing the required info to change guest's status
|
||||
type GuestStatusRequest struct {
|
||||
ID int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id" validate:"required,min=1"`
|
||||
Status int32 `protobuf:"varint,2,opt,name=status,proto3" json:"status" validate:"max=1"`
|
||||
}
|
||||
|
||||
func (m *GuestStatusRequest) Reset() { *m = GuestStatusRequest{} }
|
||||
func (m *GuestStatusRequest) String() string { return proto.CompactTextString(m) }
|
||||
func (*GuestStatusRequest) ProtoMessage() {}
|
||||
func (*GuestStatusRequest) Descriptor() ([]byte, []int) { return fileDescriptorGuest, []int{1} }
|
||||
|
||||
// The general response message contaning the result after updating/inserting the guest info
|
||||
type GuestInfoReply struct {
|
||||
Success bool `protobuf:"varint,1,opt,name=success,proto3" json:"success"`
|
||||
}
|
||||
|
||||
func (m *GuestInfoReply) Reset() { *m = GuestInfoReply{} }
|
||||
func (m *GuestInfoReply) String() string { return proto.CompactTextString(m) }
|
||||
func (*GuestInfoReply) ProtoMessage() {}
|
||||
func (*GuestInfoReply) Descriptor() ([]byte, []int) { return fileDescriptorGuest, []int{2} }
|
||||
|
||||
func init() {
|
||||
proto.RegisterType((*GuestInfoRequest)(nil), "ticket.service.item.v1.GuestInfoRequest")
|
||||
proto.RegisterType((*GuestStatusRequest)(nil), "ticket.service.item.v1.GuestStatusRequest")
|
||||
proto.RegisterType((*GuestInfoReply)(nil), "ticket.service.item.v1.GuestInfoReply")
|
||||
}
|
||||
|
||||
// Reference imports to suppress errors if they are not otherwise used.
|
||||
var _ context.Context
|
||||
var _ grpc.ClientConn
|
||||
|
||||
// This is a compile-time assertion to ensure that this generated file
|
||||
// is compatible with the grpc package it is being compiled against.
|
||||
const _ = grpc.SupportPackageIsVersion4
|
||||
|
||||
// Client API for Guest service
|
||||
|
||||
type GuestClient interface {
|
||||
GuestInfo(ctx context.Context, in *GuestInfoRequest, opts ...grpc.CallOption) (*GuestInfoReply, error)
|
||||
GuestStatus(ctx context.Context, in *GuestStatusRequest, opts ...grpc.CallOption) (*GuestInfoReply, error)
|
||||
}
|
||||
|
||||
type guestClient struct {
|
||||
cc *grpc.ClientConn
|
||||
}
|
||||
|
||||
func NewGuestClient(cc *grpc.ClientConn) GuestClient {
|
||||
return &guestClient{cc}
|
||||
}
|
||||
|
||||
func (c *guestClient) GuestInfo(ctx context.Context, in *GuestInfoRequest, opts ...grpc.CallOption) (*GuestInfoReply, error) {
|
||||
out := new(GuestInfoReply)
|
||||
err := grpc.Invoke(ctx, "/ticket.service.item.v1.Guest/GuestInfo", in, out, c.cc, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
}
|
||||
|
||||
func (c *guestClient) GuestStatus(ctx context.Context, in *GuestStatusRequest, opts ...grpc.CallOption) (*GuestInfoReply, error) {
|
||||
out := new(GuestInfoReply)
|
||||
err := grpc.Invoke(ctx, "/ticket.service.item.v1.Guest/GuestStatus", in, out, c.cc, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
}
|
||||
|
||||
// Server API for Guest service
|
||||
|
||||
type GuestServer interface {
|
||||
GuestInfo(context.Context, *GuestInfoRequest) (*GuestInfoReply, error)
|
||||
GuestStatus(context.Context, *GuestStatusRequest) (*GuestInfoReply, error)
|
||||
}
|
||||
|
||||
func RegisterGuestServer(s *grpc.Server, srv GuestServer) {
|
||||
s.RegisterService(&_Guest_serviceDesc, srv)
|
||||
}
|
||||
|
||||
func _Guest_GuestInfo_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(GuestInfoRequest)
|
||||
if err := dec(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if interceptor == nil {
|
||||
return srv.(GuestServer).GuestInfo(ctx, in)
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: "/ticket.service.item.v1.Guest/GuestInfo",
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(GuestServer).GuestInfo(ctx, req.(*GuestInfoRequest))
|
||||
}
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _Guest_GuestStatus_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(GuestStatusRequest)
|
||||
if err := dec(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if interceptor == nil {
|
||||
return srv.(GuestServer).GuestStatus(ctx, in)
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: "/ticket.service.item.v1.Guest/GuestStatus",
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(GuestServer).GuestStatus(ctx, req.(*GuestStatusRequest))
|
||||
}
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
var _Guest_serviceDesc = grpc.ServiceDesc{
|
||||
ServiceName: "ticket.service.item.v1.Guest",
|
||||
HandlerType: (*GuestServer)(nil),
|
||||
Methods: []grpc.MethodDesc{
|
||||
{
|
||||
MethodName: "GuestInfo",
|
||||
Handler: _Guest_GuestInfo_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "GuestStatus",
|
||||
Handler: _Guest_GuestStatus_Handler,
|
||||
},
|
||||
},
|
||||
Streams: []grpc.StreamDesc{},
|
||||
Metadata: "app/service/openplatform/ticket-item/api/grpc/v1/guest.proto",
|
||||
}
|
||||
|
||||
func (m *GuestInfoRequest) Marshal() (dAtA []byte, err error) {
|
||||
size := m.Size()
|
||||
dAtA = make([]byte, size)
|
||||
n, err := m.MarshalTo(dAtA)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return dAtA[:n], nil
|
||||
}
|
||||
|
||||
func (m *GuestInfoRequest) MarshalTo(dAtA []byte) (int, error) {
|
||||
var i int
|
||||
_ = i
|
||||
var l int
|
||||
_ = l
|
||||
if m.ID != 0 {
|
||||
dAtA[i] = 0x8
|
||||
i++
|
||||
i = encodeVarintGuest(dAtA, i, uint64(m.ID))
|
||||
}
|
||||
if len(m.Name) > 0 {
|
||||
dAtA[i] = 0x12
|
||||
i++
|
||||
i = encodeVarintGuest(dAtA, i, uint64(len(m.Name)))
|
||||
i += copy(dAtA[i:], m.Name)
|
||||
}
|
||||
if len(m.GuestImg) > 0 {
|
||||
dAtA[i] = 0x1a
|
||||
i++
|
||||
i = encodeVarintGuest(dAtA, i, uint64(len(m.GuestImg)))
|
||||
i += copy(dAtA[i:], m.GuestImg)
|
||||
}
|
||||
if len(m.Description) > 0 {
|
||||
dAtA[i] = 0x22
|
||||
i++
|
||||
i = encodeVarintGuest(dAtA, i, uint64(len(m.Description)))
|
||||
i += copy(dAtA[i:], m.Description)
|
||||
}
|
||||
if m.GuestID != 0 {
|
||||
dAtA[i] = 0x28
|
||||
i++
|
||||
i = encodeVarintGuest(dAtA, i, uint64(m.GuestID))
|
||||
}
|
||||
return i, nil
|
||||
}
|
||||
|
||||
func (m *GuestStatusRequest) Marshal() (dAtA []byte, err error) {
|
||||
size := m.Size()
|
||||
dAtA = make([]byte, size)
|
||||
n, err := m.MarshalTo(dAtA)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return dAtA[:n], nil
|
||||
}
|
||||
|
||||
func (m *GuestStatusRequest) MarshalTo(dAtA []byte) (int, error) {
|
||||
var i int
|
||||
_ = i
|
||||
var l int
|
||||
_ = l
|
||||
if m.ID != 0 {
|
||||
dAtA[i] = 0x8
|
||||
i++
|
||||
i = encodeVarintGuest(dAtA, i, uint64(m.ID))
|
||||
}
|
||||
if m.Status != 0 {
|
||||
dAtA[i] = 0x10
|
||||
i++
|
||||
i = encodeVarintGuest(dAtA, i, uint64(m.Status))
|
||||
}
|
||||
return i, nil
|
||||
}
|
||||
|
||||
func (m *GuestInfoReply) Marshal() (dAtA []byte, err error) {
|
||||
size := m.Size()
|
||||
dAtA = make([]byte, size)
|
||||
n, err := m.MarshalTo(dAtA)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return dAtA[:n], nil
|
||||
}
|
||||
|
||||
func (m *GuestInfoReply) MarshalTo(dAtA []byte) (int, error) {
|
||||
var i int
|
||||
_ = i
|
||||
var l int
|
||||
_ = l
|
||||
if m.Success {
|
||||
dAtA[i] = 0x8
|
||||
i++
|
||||
if m.Success {
|
||||
dAtA[i] = 1
|
||||
} else {
|
||||
dAtA[i] = 0
|
||||
}
|
||||
i++
|
||||
}
|
||||
return i, nil
|
||||
}
|
||||
|
||||
func encodeVarintGuest(dAtA []byte, offset int, v uint64) int {
|
||||
for v >= 1<<7 {
|
||||
dAtA[offset] = uint8(v&0x7f | 0x80)
|
||||
v >>= 7
|
||||
offset++
|
||||
}
|
||||
dAtA[offset] = uint8(v)
|
||||
return offset + 1
|
||||
}
|
||||
func (m *GuestInfoRequest) Size() (n int) {
|
||||
var l int
|
||||
_ = l
|
||||
if m.ID != 0 {
|
||||
n += 1 + sovGuest(uint64(m.ID))
|
||||
}
|
||||
l = len(m.Name)
|
||||
if l > 0 {
|
||||
n += 1 + l + sovGuest(uint64(l))
|
||||
}
|
||||
l = len(m.GuestImg)
|
||||
if l > 0 {
|
||||
n += 1 + l + sovGuest(uint64(l))
|
||||
}
|
||||
l = len(m.Description)
|
||||
if l > 0 {
|
||||
n += 1 + l + sovGuest(uint64(l))
|
||||
}
|
||||
if m.GuestID != 0 {
|
||||
n += 1 + sovGuest(uint64(m.GuestID))
|
||||
}
|
||||
return n
|
||||
}
|
||||
|
||||
func (m *GuestStatusRequest) Size() (n int) {
|
||||
var l int
|
||||
_ = l
|
||||
if m.ID != 0 {
|
||||
n += 1 + sovGuest(uint64(m.ID))
|
||||
}
|
||||
if m.Status != 0 {
|
||||
n += 1 + sovGuest(uint64(m.Status))
|
||||
}
|
||||
return n
|
||||
}
|
||||
|
||||
func (m *GuestInfoReply) Size() (n int) {
|
||||
var l int
|
||||
_ = l
|
||||
if m.Success {
|
||||
n += 2
|
||||
}
|
||||
return n
|
||||
}
|
||||
|
||||
func sovGuest(x uint64) (n int) {
|
||||
for {
|
||||
n++
|
||||
x >>= 7
|
||||
if x == 0 {
|
||||
break
|
||||
}
|
||||
}
|
||||
return n
|
||||
}
|
||||
func sozGuest(x uint64) (n int) {
|
||||
return sovGuest(uint64((x << 1) ^ uint64((int64(x) >> 63))))
|
||||
}
|
||||
func (m *GuestInfoRequest) Unmarshal(dAtA []byte) error {
|
||||
l := len(dAtA)
|
||||
iNdEx := 0
|
||||
for iNdEx < l {
|
||||
preIndex := iNdEx
|
||||
var wire uint64
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGuest
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
wire |= (uint64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
fieldNum := int32(wire >> 3)
|
||||
wireType := int(wire & 0x7)
|
||||
if wireType == 4 {
|
||||
return fmt.Errorf("proto: GuestInfoRequest: wiretype end group for non-group")
|
||||
}
|
||||
if fieldNum <= 0 {
|
||||
return fmt.Errorf("proto: GuestInfoRequest: illegal tag %d (wire type %d)", fieldNum, wire)
|
||||
}
|
||||
switch fieldNum {
|
||||
case 1:
|
||||
if wireType != 0 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field ID", wireType)
|
||||
}
|
||||
m.ID = 0
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGuest
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
m.ID |= (uint32(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
case 2:
|
||||
if wireType != 2 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
|
||||
}
|
||||
var stringLen uint64
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGuest
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
stringLen |= (uint64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
intStringLen := int(stringLen)
|
||||
if intStringLen < 0 {
|
||||
return ErrInvalidLengthGuest
|
||||
}
|
||||
postIndex := iNdEx + intStringLen
|
||||
if postIndex > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
m.Name = string(dAtA[iNdEx:postIndex])
|
||||
iNdEx = postIndex
|
||||
case 3:
|
||||
if wireType != 2 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field GuestImg", wireType)
|
||||
}
|
||||
var stringLen uint64
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGuest
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
stringLen |= (uint64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
intStringLen := int(stringLen)
|
||||
if intStringLen < 0 {
|
||||
return ErrInvalidLengthGuest
|
||||
}
|
||||
postIndex := iNdEx + intStringLen
|
||||
if postIndex > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
m.GuestImg = string(dAtA[iNdEx:postIndex])
|
||||
iNdEx = postIndex
|
||||
case 4:
|
||||
if wireType != 2 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field Description", wireType)
|
||||
}
|
||||
var stringLen uint64
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGuest
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
stringLen |= (uint64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
intStringLen := int(stringLen)
|
||||
if intStringLen < 0 {
|
||||
return ErrInvalidLengthGuest
|
||||
}
|
||||
postIndex := iNdEx + intStringLen
|
||||
if postIndex > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
m.Description = string(dAtA[iNdEx:postIndex])
|
||||
iNdEx = postIndex
|
||||
case 5:
|
||||
if wireType != 0 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field GuestID", wireType)
|
||||
}
|
||||
m.GuestID = 0
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGuest
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
m.GuestID |= (int64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
default:
|
||||
iNdEx = preIndex
|
||||
skippy, err := skipGuest(dAtA[iNdEx:])
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if skippy < 0 {
|
||||
return ErrInvalidLengthGuest
|
||||
}
|
||||
if (iNdEx + skippy) > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
iNdEx += skippy
|
||||
}
|
||||
}
|
||||
|
||||
if iNdEx > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
return nil
|
||||
}
|
||||
func (m *GuestStatusRequest) Unmarshal(dAtA []byte) error {
|
||||
l := len(dAtA)
|
||||
iNdEx := 0
|
||||
for iNdEx < l {
|
||||
preIndex := iNdEx
|
||||
var wire uint64
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGuest
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
wire |= (uint64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
fieldNum := int32(wire >> 3)
|
||||
wireType := int(wire & 0x7)
|
||||
if wireType == 4 {
|
||||
return fmt.Errorf("proto: GuestStatusRequest: wiretype end group for non-group")
|
||||
}
|
||||
if fieldNum <= 0 {
|
||||
return fmt.Errorf("proto: GuestStatusRequest: illegal tag %d (wire type %d)", fieldNum, wire)
|
||||
}
|
||||
switch fieldNum {
|
||||
case 1:
|
||||
if wireType != 0 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field ID", wireType)
|
||||
}
|
||||
m.ID = 0
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGuest
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
m.ID |= (int64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
case 2:
|
||||
if wireType != 0 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
|
||||
}
|
||||
m.Status = 0
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGuest
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
m.Status |= (int32(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
default:
|
||||
iNdEx = preIndex
|
||||
skippy, err := skipGuest(dAtA[iNdEx:])
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if skippy < 0 {
|
||||
return ErrInvalidLengthGuest
|
||||
}
|
||||
if (iNdEx + skippy) > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
iNdEx += skippy
|
||||
}
|
||||
}
|
||||
|
||||
if iNdEx > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
return nil
|
||||
}
|
||||
func (m *GuestInfoReply) Unmarshal(dAtA []byte) error {
|
||||
l := len(dAtA)
|
||||
iNdEx := 0
|
||||
for iNdEx < l {
|
||||
preIndex := iNdEx
|
||||
var wire uint64
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGuest
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
wire |= (uint64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
fieldNum := int32(wire >> 3)
|
||||
wireType := int(wire & 0x7)
|
||||
if wireType == 4 {
|
||||
return fmt.Errorf("proto: GuestInfoReply: wiretype end group for non-group")
|
||||
}
|
||||
if fieldNum <= 0 {
|
||||
return fmt.Errorf("proto: GuestInfoReply: illegal tag %d (wire type %d)", fieldNum, wire)
|
||||
}
|
||||
switch fieldNum {
|
||||
case 1:
|
||||
if wireType != 0 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field Success", wireType)
|
||||
}
|
||||
var v int
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGuest
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
v |= (int(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
m.Success = bool(v != 0)
|
||||
default:
|
||||
iNdEx = preIndex
|
||||
skippy, err := skipGuest(dAtA[iNdEx:])
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if skippy < 0 {
|
||||
return ErrInvalidLengthGuest
|
||||
}
|
||||
if (iNdEx + skippy) > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
iNdEx += skippy
|
||||
}
|
||||
}
|
||||
|
||||
if iNdEx > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
return nil
|
||||
}
|
||||
func skipGuest(dAtA []byte) (n int, err error) {
|
||||
l := len(dAtA)
|
||||
iNdEx := 0
|
||||
for iNdEx < l {
|
||||
var wire uint64
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return 0, ErrIntOverflowGuest
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return 0, io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
wire |= (uint64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
wireType := int(wire & 0x7)
|
||||
switch wireType {
|
||||
case 0:
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return 0, ErrIntOverflowGuest
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return 0, io.ErrUnexpectedEOF
|
||||
}
|
||||
iNdEx++
|
||||
if dAtA[iNdEx-1] < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
return iNdEx, nil
|
||||
case 1:
|
||||
iNdEx += 8
|
||||
return iNdEx, nil
|
||||
case 2:
|
||||
var length int
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return 0, ErrIntOverflowGuest
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return 0, io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
length |= (int(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
iNdEx += length
|
||||
if length < 0 {
|
||||
return 0, ErrInvalidLengthGuest
|
||||
}
|
||||
return iNdEx, nil
|
||||
case 3:
|
||||
for {
|
||||
var innerWire uint64
|
||||
var start int = iNdEx
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return 0, ErrIntOverflowGuest
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return 0, io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
innerWire |= (uint64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
innerWireType := int(innerWire & 0x7)
|
||||
if innerWireType == 4 {
|
||||
break
|
||||
}
|
||||
next, err := skipGuest(dAtA[start:])
|
||||
if err != nil {
|
||||
return 0, err
|
||||
}
|
||||
iNdEx = start + next
|
||||
}
|
||||
return iNdEx, nil
|
||||
case 4:
|
||||
return iNdEx, nil
|
||||
case 5:
|
||||
iNdEx += 4
|
||||
return iNdEx, nil
|
||||
default:
|
||||
return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
|
||||
}
|
||||
}
|
||||
panic("unreachable")
|
||||
}
|
||||
|
||||
var (
|
||||
ErrInvalidLengthGuest = fmt.Errorf("proto: negative length found during unmarshaling")
|
||||
ErrIntOverflowGuest = fmt.Errorf("proto: integer overflow")
|
||||
)
|
||||
|
||||
func init() {
|
||||
proto.RegisterFile("app/service/openplatform/ticket-item/api/grpc/v1/guest.proto", fileDescriptorGuest)
|
||||
}
|
||||
|
||||
var fileDescriptorGuest = []byte{
|
||||
// 491 bytes of a gzipped FileDescriptorProto
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x52, 0xcd, 0x6e, 0xd3, 0x40,
|
||||
0x10, 0x8e, 0x9d, 0xa6, 0x49, 0x36, 0x02, 0x95, 0x3d, 0x80, 0xa9, 0x84, 0x37, 0x58, 0x2a, 0x0a,
|
||||
0x88, 0x7a, 0xeb, 0x54, 0xe2, 0x4f, 0x94, 0x83, 0x85, 0x54, 0xe5, 0x6a, 0x6e, 0x5c, 0x2a, 0xc7,
|
||||
0xde, 0x98, 0x15, 0x71, 0x76, 0x6b, 0xaf, 0x2d, 0xfa, 0x04, 0xbc, 0x10, 0x0f, 0xd1, 0x0b, 0x52,
|
||||
0x9f, 0x60, 0x45, 0x7d, 0xf4, 0x31, 0x4f, 0x80, 0xbc, 0x4e, 0x52, 0x37, 0xaa, 0xaa, 0xde, 0x76,
|
||||
0x66, 0xbe, 0xf9, 0x66, 0xbe, 0x6f, 0x07, 0x7c, 0xf6, 0x39, 0xc7, 0x29, 0x49, 0x72, 0x1a, 0x10,
|
||||
0xcc, 0x38, 0x59, 0xf0, 0xb9, 0x2f, 0x66, 0x2c, 0x89, 0xb1, 0xa0, 0xc1, 0x4f, 0x22, 0x0e, 0xa9,
|
||||
0x20, 0x31, 0xf6, 0x39, 0xc5, 0x51, 0xc2, 0x03, 0x9c, 0x3b, 0x38, 0xca, 0x48, 0x2a, 0x6c, 0x9e,
|
||||
0x30, 0xc1, 0xe0, 0xd3, 0x1a, 0x64, 0xaf, 0x08, 0xec, 0x0a, 0x6c, 0xe7, 0xce, 0xfe, 0x61, 0x44,
|
||||
0xc5, 0x8f, 0x6c, 0x6a, 0x07, 0x2c, 0xc6, 0x11, 0x8b, 0x18, 0x56, 0xf0, 0x69, 0x36, 0x53, 0x91,
|
||||
0x0a, 0xd4, 0xab, 0xa6, 0xb1, 0xfe, 0xe8, 0x60, 0xef, 0xb4, 0xa2, 0x9d, 0x2c, 0x66, 0xcc, 0x23,
|
||||
0xe7, 0xd5, 0x13, 0x1e, 0x01, 0x9d, 0x86, 0x86, 0x36, 0xd4, 0x46, 0x8f, 0xdc, 0x61, 0x21, 0x91,
|
||||
0x3e, 0xf9, 0x5a, 0x4a, 0xa4, 0xd3, 0x70, 0x29, 0xd1, 0x5e, 0xee, 0xcf, 0x69, 0xe8, 0x0b, 0xf2,
|
||||
0xc9, 0x8a, 0xe9, 0xe2, 0xe4, 0xc8, 0xf2, 0x74, 0x1a, 0x42, 0x07, 0xec, 0x2c, 0xfc, 0x98, 0x18,
|
||||
0xfa, 0x50, 0x1b, 0xf5, 0xdd, 0x17, 0xa5, 0x44, 0x2a, 0x5e, 0x4a, 0xf4, 0xa4, 0x81, 0xf7, 0x7f,
|
||||
0x9d, 0x1c, 0x8f, 0x2d, 0x4f, 0x95, 0xe0, 0x17, 0xd0, 0x57, 0x7a, 0xce, 0x68, 0x1c, 0x19, 0x6d,
|
||||
0xd5, 0xf7, 0xb2, 0x94, 0xe8, 0x26, 0x79, 0xe7, 0xb0, 0x9e, 0x2a, 0x4f, 0xe2, 0x08, 0x9e, 0x82,
|
||||
0x41, 0x48, 0xd2, 0x20, 0xa1, 0x5c, 0x50, 0xb6, 0x30, 0x76, 0x14, 0xc3, 0x41, 0x29, 0x51, 0x33,
|
||||
0xbd, 0x94, 0x08, 0xde, 0x5e, 0xc0, 0x19, 0x7f, 0xb0, 0xbc, 0x26, 0x04, 0x8e, 0x41, 0x6f, 0x35,
|
||||
0x33, 0x34, 0x3a, 0x43, 0x6d, 0xd4, 0x76, 0x9f, 0x15, 0x12, 0x75, 0x6b, 0x57, 0x2a, 0xe1, 0x9b,
|
||||
0xb2, 0xd7, 0xad, 0xa7, 0x87, 0xd6, 0x6f, 0x0d, 0x40, 0x05, 0xf8, 0x26, 0x7c, 0x91, 0xa5, 0x6b,
|
||||
0xe3, 0x3e, 0x6e, 0x8c, 0x6b, 0xbb, 0xaf, 0xb7, 0x8c, 0x7b, 0x7e, 0xb3, 0x47, 0x42, 0xce, 0x33,
|
||||
0x9a, 0x90, 0xf0, 0x6d, 0x25, 0xca, 0xa9, 0x1d, 0x7c, 0x07, 0x76, 0x53, 0xc5, 0xa5, 0x3c, 0xec,
|
||||
0xb8, 0x66, 0x29, 0xd1, 0x2a, 0xb3, 0x65, 0x44, 0x25, 0xc2, 0xf2, 0x56, 0x35, 0xeb, 0x3d, 0x78,
|
||||
0xdc, 0xf8, 0x3f, 0x3e, 0xbf, 0x80, 0x07, 0xa0, 0x9b, 0x66, 0x41, 0x40, 0xd2, 0x54, 0x6d, 0xd2,
|
||||
0x73, 0x07, 0xa5, 0x44, 0xeb, 0x94, 0xb7, 0x7e, 0x8c, 0xff, 0x6a, 0xa0, 0xa3, 0x3a, 0xe1, 0x19,
|
||||
0xe8, 0x6f, 0x28, 0xe0, 0xc8, 0xbe, 0xfb, 0xb0, 0xec, 0xed, 0x2b, 0xd9, 0x7f, 0xf5, 0x00, 0x24,
|
||||
0x9f, 0x5f, 0x58, 0x2d, 0x18, 0x80, 0x41, 0xc3, 0x2c, 0xf8, 0xe6, 0xde, 0xc6, 0x5b, 0x8e, 0x3e,
|
||||
0x7c, 0x88, 0x6b, 0x5c, 0x5e, 0x9b, 0xad, 0xab, 0x6b, 0xb3, 0x75, 0x59, 0x98, 0xda, 0x55, 0x61,
|
||||
0x6a, 0xff, 0x0a, 0x53, 0xfb, 0xae, 0xe7, 0xce, 0x74, 0x57, 0x9d, 0xfa, 0xf1, 0xff, 0x00, 0x00,
|
||||
0x00, 0xff, 0xff, 0x44, 0x78, 0x81, 0x56, 0x71, 0x03, 0x00, 0x00,
|
||||
}
|
37
app/service/openplatform/ticket-item/api/grpc/v1/guest.proto
Normal file
37
app/service/openplatform/ticket-item/api/grpc/v1/guest.proto
Normal file
@ -0,0 +1,37 @@
|
||||
syntax = "proto3";
|
||||
package ticket.service.item.v1;
|
||||
|
||||
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
|
||||
|
||||
option (gogoproto.goproto_enum_prefix_all) = false;
|
||||
option (gogoproto.goproto_getters_all) = false;
|
||||
option (gogoproto.unmarshaler_all) = true;
|
||||
option (gogoproto.marshaler_all) = true;
|
||||
option (gogoproto.sizer_all) = true;
|
||||
option go_package = "v1";
|
||||
|
||||
// The guest service definition.
|
||||
service Guest {
|
||||
rpc GuestInfo (GuestInfoRequest) returns (GuestInfoReply) {}
|
||||
rpc GuestStatus (GuestStatusRequest) returns (GuestInfoReply) {}
|
||||
}
|
||||
|
||||
// The request message containing the guest info to update/insert
|
||||
message GuestInfoRequest {
|
||||
uint32 id = 1 [(gogoproto.jsontag) = "id", (gogoproto.moretags) = "validate:\"min=0\"", (gogoproto.customname)= "ID"];
|
||||
string name = 2 [(gogoproto.jsontag) = "name", (gogoproto.moretags) = "validate:\"max=32\""];
|
||||
string guest_img = 3 [(gogoproto.jsontag) = "guest_img", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
string description = 4 [(gogoproto.jsontag) = "description", (gogoproto.moretags) = "validate:\"max=128\""];
|
||||
int64 guest_id = 5 [(gogoproto.jsontag) = "guest_id", (gogoproto.customname)= "GuestID"];
|
||||
}
|
||||
|
||||
// The request message containing the required info to change guest's status
|
||||
message GuestStatusRequest {
|
||||
int64 id = 1 [(gogoproto.jsontag) = "id", (gogoproto.moretags) = "validate:\"required,min=1\"", (gogoproto.customname)= "ID"];
|
||||
int32 status = 2 [(gogoproto.jsontag) = "status", (gogoproto.moretags) = "validate:\"max=1\""];
|
||||
}
|
||||
|
||||
// The general response message contaning the result after updating/inserting the guest info
|
||||
message GuestInfoReply {
|
||||
bool success = 1 [(gogoproto.jsontag) = "success"];
|
||||
}
|
7232
app/service/openplatform/ticket-item/api/grpc/v1/item.pb.go
Normal file
7232
app/service/openplatform/ticket-item/api/grpc/v1/item.pb.go
Normal file
File diff suppressed because it is too large
Load Diff
247
app/service/openplatform/ticket-item/api/grpc/v1/item.proto
Normal file
247
app/service/openplatform/ticket-item/api/grpc/v1/item.proto
Normal file
@ -0,0 +1,247 @@
|
||||
syntax = "proto3";
|
||||
package ticket.service.item.v1;
|
||||
|
||||
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
|
||||
import "app/service/openplatform/ticket-item/api/grpc/v1/screen.proto";
|
||||
import "app/service/openplatform/ticket-item/api/grpc/v1/bulletin.proto";
|
||||
import "app/service/openplatform/ticket-item/api/grpc/v1/guest.proto";
|
||||
import "app/service/openplatform/ticket-item/api/grpc/v1/time.proto";
|
||||
import "app/service/openplatform/ticket-item/api/grpc/v1/venue.proto";
|
||||
option (gogoproto.goproto_enum_prefix_all) = false;
|
||||
option (gogoproto.goproto_getters_all) = false;
|
||||
option (gogoproto.unmarshaler_all) = true;
|
||||
option (gogoproto.marshaler_all) = true;
|
||||
option (gogoproto.sizer_all) = true;
|
||||
option go_package = "v1";
|
||||
|
||||
// The get service definition.
|
||||
service Item {
|
||||
// Info Servcie
|
||||
rpc Info (InfoRequest) returns (InfoReply) {}
|
||||
// cards Servcie
|
||||
rpc Cards (CardsRequest) returns (CardsReply) {}
|
||||
// BillInfo Servcie
|
||||
rpc BillInfo (BillRequest) returns (BillReply) {}
|
||||
// Wish Service
|
||||
rpc Wish (WishRequest) returns (WishReply) {}
|
||||
// Version Service
|
||||
rpc Version (VersionRequest) returns (VersionReply) {}
|
||||
// VersionReview Service
|
||||
rpc VersionReview (VersionReviewRequest) returns (VersionReviewReply) {}
|
||||
// VersionStatus Service
|
||||
rpc VersionStatus (VersionStatusRequest) returns (VersionStatusReply) {}
|
||||
// BannerEdit Service
|
||||
rpc BannerEdit (BannerEditRequest) returns (BannerEditReply) {}
|
||||
}
|
||||
|
||||
// The request message containing the itemID.
|
||||
message InfoRequest {
|
||||
int64 id = 1 [(gogoproto.jsontag) = "id", (gogoproto.moretags) = "validate:\"required\"", (gogoproto.customname)= "ID"];
|
||||
}
|
||||
|
||||
// The request message containing the itemIDs.
|
||||
message CardsRequest {
|
||||
repeated int64 ids = 1 [(gogoproto.jsontag) = "ids", (gogoproto.moretags) = "validate:\"required\"", (gogoproto.customname)= "IDs"];
|
||||
}
|
||||
|
||||
// The request message containing the itemIDs ScIDs TicketIDs.
|
||||
message BillRequest {
|
||||
repeated int64 ids = 1 [(gogoproto.jsontag) = "ids", (gogoproto.moretags) = "validate:\"required\"",(gogoproto.customname)= "IDs"];
|
||||
repeated int64 tk_ids = 2 [(gogoproto.jsontag) = "sc_ids", (gogoproto.moretags) = "validate:\"required\"", (gogoproto.customname)= "ScIDs"];
|
||||
repeated int64 sc_ids = 3 [(gogoproto.jsontag) = "tk_ids", (gogoproto.moretags) = "validate:\"required\"", (gogoproto.customname)= "TkIDs"];
|
||||
}
|
||||
|
||||
// The response message containing the itembaseinfo and related screeninfo,ticketinfo
|
||||
message InfoReply {
|
||||
int64 id = 1 [(gogoproto.jsontag) = "id", (gogoproto.moretags) = "validate:\"min=1\"", (gogoproto.customname)= "ID"];
|
||||
string name = 2 [(gogoproto.jsontag) = "name"];
|
||||
int32 status = 3 [(gogoproto.jsontag) = "status", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
int32 type = 4 [(gogoproto.jsontag) = "type", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
int32 rec = 5 [(gogoproto.jsontag) = "rec", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
int32 is_sale = 6 [(gogoproto.jsontag) = "is_sale", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
string ticket_desc = 7 [(gogoproto.jsontag) = "desc"];
|
||||
int32 sale_flag = 8 [(gogoproto.jsontag) = "sale_flag", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
string prom_tag = 9 [(gogoproto.jsontag) = "promo_tags"];
|
||||
ImgList img = 10 [(gogoproto.jsontag) = "img"];
|
||||
ItemTime time = 11 [(gogoproto.jsontag) = "time"];
|
||||
map<int64,ScreenInfo> screen = 12 [(gogoproto.jsontag) = "screen"];
|
||||
ItemExt ext = 13 [(gogoproto.jsontag) = "ext"];
|
||||
BillOpt bill_opt = 14 [(gogoproto.jsontag) = "bill_opt"];
|
||||
}
|
||||
|
||||
// The response message containing the map type cardinfo
|
||||
message CardsReply{
|
||||
map<int64,CardReply> cards = 1 [(gogoproto.jsontag) = "list"];
|
||||
}
|
||||
|
||||
// The response message containing the itembaseInfo
|
||||
message CardReply {
|
||||
int64 id = 1 [(gogoproto.jsontag) = "id", (gogoproto.moretags) = "validate:\"min=1\"", (gogoproto.customname)= "ID"];
|
||||
string name = 2 [(gogoproto.jsontag) = "name"];
|
||||
int32 status = 3 [(gogoproto.jsontag) = "status", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
int32 type = 4 [(gogoproto.jsontag) = "type", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
int32 rec = 5 [(gogoproto.jsontag) = "rec", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
int32 is_sale = 6 [(gogoproto.jsontag) = "is_sale", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
string ticket_desc = 7 [(gogoproto.jsontag) = "desc"];
|
||||
int32 sale_flag = 8 [(gogoproto.jsontag) = "sale_flag", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
string prom_tag = 9 [(gogoproto.jsontag) = "promo_tags"];
|
||||
ImgList img = 10 [(gogoproto.jsontag) = "img"];
|
||||
ItemTime time = 11 [(gogoproto.jsontag) = "time"];
|
||||
VenueInfo venue = 12 [(gogoproto.jsontag) = "venue"];
|
||||
}
|
||||
|
||||
|
||||
// The response message containing billinfo
|
||||
message BillReply {
|
||||
map<int64,ItemBase> base_info= 1 [(gogoproto.jsontag) = "base_info"];
|
||||
map<int64,BillOpt> bill_opt= 2 [(gogoproto.jsontag) = "bill_opt"];
|
||||
}
|
||||
|
||||
|
||||
// The response message containing the itembaseinfo and map type screeninfo
|
||||
message ItemBase {
|
||||
int64 id = 1 [(gogoproto.jsontag) = "id", (gogoproto.moretags) = "validate:\"min=1\"", (gogoproto.customname)= "ID"];
|
||||
int32 status = 2 [(gogoproto.jsontag) = "status", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
string name = 3 [(gogoproto.jsontag) = "name"];
|
||||
int32 type = 4 [(gogoproto.jsontag) = "type", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
int32 is_sale = 5 [(gogoproto.jsontag) = "is_sale", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
string prom_tag = 6 [(gogoproto.jsontag) = "promo_tags"];
|
||||
uint64 ver_id = 7 [(gogoproto.jsontag) = "ver_id", (gogoproto.moretags) = "validate:\"min=0\"", (gogoproto.customname)= "VerID"];
|
||||
ItemTime time = 8 [(gogoproto.jsontag) = "time"];
|
||||
ImgList img = 9 [(gogoproto.jsontag) = "img"];
|
||||
map<int64,ScreenInfo> screen = 10 [(gogoproto.jsontag) = "screen"];
|
||||
}
|
||||
|
||||
// The response message containing the ItemExtinfo
|
||||
message ItemExt {
|
||||
string label = 1 [(gogoproto.jsontag) = "label"];
|
||||
int32 sp_type = 2 [(gogoproto.jsontag) = "sponsor_type", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
uint64 ver_id = 3 [(gogoproto.jsontag) = "ver_id", (gogoproto.moretags) = "validate:\"min=0\"", (gogoproto.customname)= "VerID"];
|
||||
string detail = 4 [(gogoproto.jsontag) = "detail"];
|
||||
VenueInfo venue = 5 [(gogoproto.jsontag) = "venue"];
|
||||
repeated BulletinInfo bulletin = 6 [(gogoproto.jsontag) = "bulletin"];
|
||||
repeated GuestInfoRequest guest = 7 [(gogoproto.jsontag) = "guest"];
|
||||
}
|
||||
|
||||
// The response message containing the ImgList
|
||||
message ImgList {
|
||||
string first = 1 [(gogoproto.jsontag) = "first"];
|
||||
string banner = 2 [(gogoproto.jsontag) = "banner"];
|
||||
}
|
||||
|
||||
// The response message containing the ItemBillOption
|
||||
message BillOpt {
|
||||
string buyerInfo = 1 [(gogoproto.jsontag) = "buyer_info"];
|
||||
int32 exp_tip = 2 [(gogoproto.jsontag) = "exptip"];
|
||||
int32 exp_free = 3 [(gogoproto.jsontag) = "expfree"];
|
||||
int32 vip_exp_free = 4 [(gogoproto.jsontag) = "vip_exp_free"];
|
||||
BuyNumLimit buy_limit = 5 [(gogoproto.jsontag) = "buy_num_limit"];
|
||||
}
|
||||
|
||||
// 项目限购结构
|
||||
message BuyNumLimit {
|
||||
repeated BnlLevel level = 1 [(gogoproto.jsontag) = "level"];
|
||||
int32 per = 2 [(gogoproto.jsontag) = "per"];
|
||||
map<int32, BnlLevel> vip = 3 [(gogoproto.jsontag) = "vip", (gogoproto.customname) = "VIP"];
|
||||
}
|
||||
|
||||
message BnlLevel {
|
||||
int32 apply_to_vip = 1 [(gogoproto.jsontag) = "apply_to_vip"];
|
||||
int32 max = 2 [(gogoproto.jsontag) = "max"];
|
||||
int32 min = 3 [(gogoproto.jsontag) = "min"];
|
||||
}
|
||||
|
||||
// The request message containing ItemID MID Face.
|
||||
message WishRequest {
|
||||
int64 item_id = 1 [(gogoproto.jsontag) = "item_id", (gogoproto.moretags) = "validate:\"required\"", (gogoproto.customname)= "ItemID"];
|
||||
int64 mid = 2 [(gogoproto.jsontag) = "mid", (gogoproto.moretags) = "validate:\"required\"", (gogoproto.customname)= "MID"];
|
||||
string face = 3 [(gogoproto.jsontag) = "face"];
|
||||
}
|
||||
|
||||
// The response message containing the ITEMID MID
|
||||
message WishReply {
|
||||
int64 item_id = 1 [(gogoproto.jsontag) = "item_id", (gogoproto.moretags) = "validate:\"required\"", (gogoproto.customname)= "ItemID"];
|
||||
int64 mid = 2 [(gogoproto.jsontag) = "mid", (gogoproto.moretags) = "validate:\"required\"", (gogoproto.customname)= "MID"];
|
||||
}
|
||||
|
||||
|
||||
// FavRequest 收藏
|
||||
message FavRequest {
|
||||
int64 item_id = 1 [(gogoproto.jsontag) = "item_id", (gogoproto.moretags) = "validate:\"required\"", (gogoproto.customname)= "ItemID"];
|
||||
int64 mid = 2 [(gogoproto.jsontag) = "mid", (gogoproto.moretags) = "validate:\"required\"", (gogoproto.customname)= "MID"];
|
||||
int32 type = 3 [(gogoproto.jsontag) = "type", (gogoproto.moretags) = "validate:\"required,min=1,max=3\"", (gogoproto.customname)= "Type"];
|
||||
int32 Status = 4 [(gogoproto.jsontag) = "status", (gogoproto.moretags) = "validate:\"required,min=0,max=1\"", (gogoproto.customname)= "Status"];
|
||||
}
|
||||
|
||||
// FavReply 收藏
|
||||
message FavReply {
|
||||
int64 item_id = 1 [(gogoproto.jsontag) = "item_id", (gogoproto.moretags) = "validate:\"required\"", (gogoproto.customname)= "ItemID"];
|
||||
int64 mid = 2 [(gogoproto.jsontag) = "mid", (gogoproto.moretags) = "validate:\"required\"", (gogoproto.customname)= "MID"];
|
||||
int32 type = 3 [(gogoproto.jsontag) = "type", (gogoproto.moretags) = "validate:\"required,min=0,max=1\"", (gogoproto.customname)= "Type"];
|
||||
int32 Status = 4 [(gogoproto.jsontag) = "status", (gogoproto.moretags) = "validate:\"required,min=0,max=1\"", (gogoproto.customname)= "Status"];
|
||||
}
|
||||
|
||||
|
||||
// The request message containing the version info to update/insert project
|
||||
message VersionRequest {
|
||||
uint64 ver_id = 1 [(gogoproto.jsontag) = "ver_id", (gogoproto.moretags) = "validate:\"required,min=0\""];
|
||||
uint32 op_type = 2 [(gogoproto.jsontag) = "op_type", (gogoproto.moretags) = "validate:\"max=1\""];
|
||||
}
|
||||
|
||||
|
||||
// The general response message containing the result after updating/inserting the project info
|
||||
message VersionReply {
|
||||
int64 project_id = 1 [(gogoproto.jsontag) = "project_id"];
|
||||
}
|
||||
|
||||
|
||||
// The request message containing the info to add/edit a banner
|
||||
message BannerEditRequest {
|
||||
uint64 ver_id = 1 [(gogoproto.jsontag) = "ver_id"];
|
||||
int32 op_type = 2 [(gogoproto.jsontag) = "op_type"];
|
||||
string name = 3 [(gogoproto.jsontag) = "name"];
|
||||
int32 position = 4 [(gogoproto.jsontag) = "position"];
|
||||
int32 sub_position = 5 [(gogoproto.jsontag) = "sub_position"];
|
||||
int32 order = 6 [(gogoproto.jsontag) = "order"];
|
||||
int64 pub_start = 7 [(gogoproto.jsontag) = "pub_start"];
|
||||
int64 pub_end = 8 [(gogoproto.jsontag) = "pub_end"];
|
||||
string pic = 9 [(gogoproto.jsontag) = "pic"];
|
||||
string url = 10 [(gogoproto.jsontag) = "url"];
|
||||
string from = 11 [(gogoproto.jsontag) = "from"];
|
||||
string location = 12 [(gogoproto.jsontag) = "location"];
|
||||
string uname = 13 [(gogoproto.jsontag) = "uname"];
|
||||
int32 target_user = 14 [(gogoproto.jsontag) = "target_user"];
|
||||
}
|
||||
|
||||
|
||||
// The response message containing the result after adding/editing a banner
|
||||
message BannerEditReply {
|
||||
int64 banner_id = 1 [(gogoproto.jsontag) = "banner_id"];
|
||||
}
|
||||
|
||||
// The request message containing the info to pass/reject a version
|
||||
message VersionReviewRequest {
|
||||
uint64 ver_id = 1 [(gogoproto.jsontag) = "ver_id"];
|
||||
int32 op_type = 2 [(gogoproto.jsontag) = "op_type"];
|
||||
int32 ver_type = 3 [(gogoproto.jsontag) = "ver_type"];
|
||||
string msg = 4 [(gogoproto.jsontag) = "msg"];
|
||||
string uname = 5 [(gogoproto.jsontag) = "uname"];
|
||||
}
|
||||
|
||||
// The response message containing the result after passing/rejecting a version
|
||||
message VersionReviewReply {
|
||||
uint64 ver_id = 1 [(gogoproto.jsontag) = "ver_id"];
|
||||
}
|
||||
|
||||
// The request message containing the info to change a version's status
|
||||
message VersionStatusRequest {
|
||||
uint64 ver_id = 1 [(gogoproto.jsontag) = "ver_id"];
|
||||
int32 op_type = 2 [(gogoproto.jsontag) = "op_type"];
|
||||
int32 ver_type = 3 [(gogoproto.jsontag) = "ver_type"];
|
||||
string uname = 4 [(gogoproto.jsontag) = "uname"];
|
||||
}
|
||||
|
||||
// The response message containing the result after changing a version's status
|
||||
message VersionStatusReply {
|
||||
uint64 ver_id = 1 [(gogoproto.jsontag) = "ver_id"];
|
||||
}
|
4
app/service/openplatform/ticket-item/api/grpc/v1/p2g.sh
Normal file
4
app/service/openplatform/ticket-item/api/grpc/v1/p2g.sh
Normal file
@ -0,0 +1,4 @@
|
||||
#! /bin/sh
|
||||
# 在环境变量中设置好$GOPATH即可食用
|
||||
cd $GOPATH/src/go-common/app/service/openplatform/ticket-item/api/grpc/v1
|
||||
$GOPATH/src/go-common/app/tool/warden/protoc.sh
|
1005
app/service/openplatform/ticket-item/api/grpc/v1/place.pb.go
Normal file
1005
app/service/openplatform/ticket-item/api/grpc/v1/place.pb.go
Normal file
File diff suppressed because it is too large
Load Diff
58
app/service/openplatform/ticket-item/api/grpc/v1/place.proto
Normal file
58
app/service/openplatform/ticket-item/api/grpc/v1/place.proto
Normal file
@ -0,0 +1,58 @@
|
||||
syntax = "proto3";
|
||||
package ticket.service.item.v1;
|
||||
|
||||
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
|
||||
|
||||
option (gogoproto.goproto_enum_prefix_all) = false;
|
||||
option (gogoproto.goproto_getters_all) = false;
|
||||
option (gogoproto.unmarshaler_all) = true;
|
||||
option (gogoproto.marshaler_all) = true;
|
||||
option (gogoproto.sizer_all) = true;
|
||||
option go_package = "v1";
|
||||
|
||||
// The place service definition.
|
||||
service Place {
|
||||
rpc PlaceInfo (PlaceInfoRequest) returns (PlaceInfoReply) {}
|
||||
}
|
||||
|
||||
// The response message containing the Place info
|
||||
message PlaceInfo {
|
||||
// 状态
|
||||
int64 id = 1 [(gogoproto.jsontag) = "id",(gogoproto.customname)= "ID"];
|
||||
// 场地名
|
||||
int32 status = 2 [(gogoproto.jsontag) = "status"];
|
||||
// 场地底图
|
||||
string name = 3 [(gogoproto.jsontag) = "name"];
|
||||
// 场馆ID
|
||||
string base_pic = 4 [(gogoproto.jsontag) = "base_pic"];
|
||||
// mis画框宽度
|
||||
int32 d_width = 5 [(gogoproto.jsontag) = "d_width"];
|
||||
// mis画框高度
|
||||
int32 d_height = 6 [(gogoproto.jsontag) = "d_height"];
|
||||
}
|
||||
|
||||
// placeInfo接口请求
|
||||
message PlaceInfoRequest {
|
||||
// 待修改场地的ID(为0表示创建)
|
||||
int64 ID = 1 [(gogoproto.jsontag) = "id", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
// 状态
|
||||
int32 Status = 2 [(gogoproto.jsontag) = "status", (gogoproto.moretags) = "validate:\"min=0,max=1\""];
|
||||
// 场地名
|
||||
string Name = 3 [(gogoproto.jsontag) = "name", (gogoproto.moretags) = "validate:\"max=16\""];
|
||||
// 场地底图
|
||||
string BasePic = 4 [(gogoproto.jsontag) = "base_pic", (gogoproto.moretags) = "validate:\"max=128\""];
|
||||
// 场馆ID
|
||||
int64 Venue = 5 [(gogoproto.jsontag) = "venue", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
// mis画框宽度
|
||||
int32 DWidth = 6 [(gogoproto.jsontag) = "d_width", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
// mis画框高度
|
||||
int32 DHeight = 7 [(gogoproto.jsontag) = "d_height", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
}
|
||||
|
||||
// placeInfo接口返回
|
||||
message PlaceInfoReply {
|
||||
// 操作结果
|
||||
bool Success = 1 [(gogoproto.jsontag) = "success"];
|
||||
// 操作场地ID
|
||||
int64 ID = 2 [(gogoproto.jsontag) = "id"];
|
||||
}
|
818
app/service/openplatform/ticket-item/api/grpc/v1/screen.pb.go
Normal file
818
app/service/openplatform/ticket-item/api/grpc/v1/screen.pb.go
Normal file
@ -0,0 +1,818 @@
|
||||
// Code generated by protoc-gen-gogo. DO NOT EDIT.
|
||||
// source: app/service/openplatform/ticket-item/api/grpc/v1/screen.proto
|
||||
|
||||
package v1
|
||||
|
||||
import proto "github.com/gogo/protobuf/proto"
|
||||
import fmt "fmt"
|
||||
import math "math"
|
||||
import _ "github.com/gogo/protobuf/gogoproto"
|
||||
|
||||
import io "io"
|
||||
|
||||
// Reference imports to suppress errors if they are not otherwise used.
|
||||
var _ = proto.Marshal
|
||||
var _ = fmt.Errorf
|
||||
var _ = math.Inf
|
||||
|
||||
// The response message containing the ScreenInfo
|
||||
type ScreenInfo struct {
|
||||
ID int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id" validate:"min=0"`
|
||||
Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name"`
|
||||
Status int32 `protobuf:"varint,3,opt,name=status,proto3" json:"status" validate:"min=0"`
|
||||
// 类型: 1-坐, 2-站
|
||||
Type int32 `protobuf:"varint,4,opt,name=type,proto3" json:"type" validate:"min=0"`
|
||||
// 出票方式: 1-纸质票, 2-电子票, 3-外部票
|
||||
TicketType int32 `protobuf:"varint,5,opt,name=ticket_type,json=ticketType,proto3" json:"ticket_type" validate:"min=0"`
|
||||
// 票区分的场次类型: 1-普通场次, 2-通票场次 3-联票场次
|
||||
ScreenType int32 `protobuf:"varint,6,opt,name=screen_type,json=screenType,proto3" json:"screen_type" validate:"min=0"`
|
||||
// 配送方式: 1-不配送, 2-自取, 3-快递
|
||||
DeliveryType int32 `protobuf:"varint,7,opt,name=delivery_type,json=deliveryType,proto3" json:"delivery_type" validate:"min=0"`
|
||||
// 是否选座 是-1,否-0
|
||||
PickSeat int32 `protobuf:"varint,8,opt,name=pick_seat,json=pickSeat,proto3" json:"pick_seat" validate:"min=0"`
|
||||
// 售卖状态
|
||||
SaleFlag int32 `protobuf:"varint,9,opt,name=sale_flag,json=saleFlag,proto3" json:"sale_flag" validate:"min=0"`
|
||||
ScTime *ScreenTime `protobuf:"bytes,10,opt,name=sc_time,json=scTime" json:"time"`
|
||||
Ticket map[int64]*TicketInfo `protobuf:"bytes,11,rep,name=Ticket" json:"ticket" protobuf_key:"varint,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value"`
|
||||
}
|
||||
|
||||
func (m *ScreenInfo) Reset() { *m = ScreenInfo{} }
|
||||
func (m *ScreenInfo) String() string { return proto.CompactTextString(m) }
|
||||
func (*ScreenInfo) ProtoMessage() {}
|
||||
func (*ScreenInfo) Descriptor() ([]byte, []int) { return fileDescriptorScreen, []int{0} }
|
||||
|
||||
func (m *ScreenInfo) GetID() int64 {
|
||||
if m != nil {
|
||||
return m.ID
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (m *ScreenInfo) GetName() string {
|
||||
if m != nil {
|
||||
return m.Name
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (m *ScreenInfo) GetStatus() int32 {
|
||||
if m != nil {
|
||||
return m.Status
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (m *ScreenInfo) GetType() int32 {
|
||||
if m != nil {
|
||||
return m.Type
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (m *ScreenInfo) GetTicketType() int32 {
|
||||
if m != nil {
|
||||
return m.TicketType
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (m *ScreenInfo) GetScreenType() int32 {
|
||||
if m != nil {
|
||||
return m.ScreenType
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (m *ScreenInfo) GetDeliveryType() int32 {
|
||||
if m != nil {
|
||||
return m.DeliveryType
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (m *ScreenInfo) GetPickSeat() int32 {
|
||||
if m != nil {
|
||||
return m.PickSeat
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (m *ScreenInfo) GetSaleFlag() int32 {
|
||||
if m != nil {
|
||||
return m.SaleFlag
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (m *ScreenInfo) GetScTime() *ScreenTime {
|
||||
if m != nil {
|
||||
return m.ScTime
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (m *ScreenInfo) GetTicket() map[int64]*TicketInfo {
|
||||
if m != nil {
|
||||
return m.Ticket
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func init() {
|
||||
proto.RegisterType((*ScreenInfo)(nil), "ticket.service.item.v1.ScreenInfo")
|
||||
}
|
||||
func (m *ScreenInfo) Marshal() (dAtA []byte, err error) {
|
||||
size := m.Size()
|
||||
dAtA = make([]byte, size)
|
||||
n, err := m.MarshalTo(dAtA)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return dAtA[:n], nil
|
||||
}
|
||||
|
||||
func (m *ScreenInfo) MarshalTo(dAtA []byte) (int, error) {
|
||||
var i int
|
||||
_ = i
|
||||
var l int
|
||||
_ = l
|
||||
if m.ID != 0 {
|
||||
dAtA[i] = 0x8
|
||||
i++
|
||||
i = encodeVarintScreen(dAtA, i, uint64(m.ID))
|
||||
}
|
||||
if len(m.Name) > 0 {
|
||||
dAtA[i] = 0x12
|
||||
i++
|
||||
i = encodeVarintScreen(dAtA, i, uint64(len(m.Name)))
|
||||
i += copy(dAtA[i:], m.Name)
|
||||
}
|
||||
if m.Status != 0 {
|
||||
dAtA[i] = 0x18
|
||||
i++
|
||||
i = encodeVarintScreen(dAtA, i, uint64(m.Status))
|
||||
}
|
||||
if m.Type != 0 {
|
||||
dAtA[i] = 0x20
|
||||
i++
|
||||
i = encodeVarintScreen(dAtA, i, uint64(m.Type))
|
||||
}
|
||||
if m.TicketType != 0 {
|
||||
dAtA[i] = 0x28
|
||||
i++
|
||||
i = encodeVarintScreen(dAtA, i, uint64(m.TicketType))
|
||||
}
|
||||
if m.ScreenType != 0 {
|
||||
dAtA[i] = 0x30
|
||||
i++
|
||||
i = encodeVarintScreen(dAtA, i, uint64(m.ScreenType))
|
||||
}
|
||||
if m.DeliveryType != 0 {
|
||||
dAtA[i] = 0x38
|
||||
i++
|
||||
i = encodeVarintScreen(dAtA, i, uint64(m.DeliveryType))
|
||||
}
|
||||
if m.PickSeat != 0 {
|
||||
dAtA[i] = 0x40
|
||||
i++
|
||||
i = encodeVarintScreen(dAtA, i, uint64(m.PickSeat))
|
||||
}
|
||||
if m.SaleFlag != 0 {
|
||||
dAtA[i] = 0x48
|
||||
i++
|
||||
i = encodeVarintScreen(dAtA, i, uint64(m.SaleFlag))
|
||||
}
|
||||
if m.ScTime != nil {
|
||||
dAtA[i] = 0x52
|
||||
i++
|
||||
i = encodeVarintScreen(dAtA, i, uint64(m.ScTime.Size()))
|
||||
n1, err := m.ScTime.MarshalTo(dAtA[i:])
|
||||
if err != nil {
|
||||
return 0, err
|
||||
}
|
||||
i += n1
|
||||
}
|
||||
if len(m.Ticket) > 0 {
|
||||
for k, _ := range m.Ticket {
|
||||
dAtA[i] = 0x5a
|
||||
i++
|
||||
v := m.Ticket[k]
|
||||
msgSize := 0
|
||||
if v != nil {
|
||||
msgSize = v.Size()
|
||||
msgSize += 1 + sovScreen(uint64(msgSize))
|
||||
}
|
||||
mapSize := 1 + sovScreen(uint64(k)) + msgSize
|
||||
i = encodeVarintScreen(dAtA, i, uint64(mapSize))
|
||||
dAtA[i] = 0x8
|
||||
i++
|
||||
i = encodeVarintScreen(dAtA, i, uint64(k))
|
||||
if v != nil {
|
||||
dAtA[i] = 0x12
|
||||
i++
|
||||
i = encodeVarintScreen(dAtA, i, uint64(v.Size()))
|
||||
n2, err := v.MarshalTo(dAtA[i:])
|
||||
if err != nil {
|
||||
return 0, err
|
||||
}
|
||||
i += n2
|
||||
}
|
||||
}
|
||||
}
|
||||
return i, nil
|
||||
}
|
||||
|
||||
func encodeVarintScreen(dAtA []byte, offset int, v uint64) int {
|
||||
for v >= 1<<7 {
|
||||
dAtA[offset] = uint8(v&0x7f | 0x80)
|
||||
v >>= 7
|
||||
offset++
|
||||
}
|
||||
dAtA[offset] = uint8(v)
|
||||
return offset + 1
|
||||
}
|
||||
func (m *ScreenInfo) Size() (n int) {
|
||||
var l int
|
||||
_ = l
|
||||
if m.ID != 0 {
|
||||
n += 1 + sovScreen(uint64(m.ID))
|
||||
}
|
||||
l = len(m.Name)
|
||||
if l > 0 {
|
||||
n += 1 + l + sovScreen(uint64(l))
|
||||
}
|
||||
if m.Status != 0 {
|
||||
n += 1 + sovScreen(uint64(m.Status))
|
||||
}
|
||||
if m.Type != 0 {
|
||||
n += 1 + sovScreen(uint64(m.Type))
|
||||
}
|
||||
if m.TicketType != 0 {
|
||||
n += 1 + sovScreen(uint64(m.TicketType))
|
||||
}
|
||||
if m.ScreenType != 0 {
|
||||
n += 1 + sovScreen(uint64(m.ScreenType))
|
||||
}
|
||||
if m.DeliveryType != 0 {
|
||||
n += 1 + sovScreen(uint64(m.DeliveryType))
|
||||
}
|
||||
if m.PickSeat != 0 {
|
||||
n += 1 + sovScreen(uint64(m.PickSeat))
|
||||
}
|
||||
if m.SaleFlag != 0 {
|
||||
n += 1 + sovScreen(uint64(m.SaleFlag))
|
||||
}
|
||||
if m.ScTime != nil {
|
||||
l = m.ScTime.Size()
|
||||
n += 1 + l + sovScreen(uint64(l))
|
||||
}
|
||||
if len(m.Ticket) > 0 {
|
||||
for k, v := range m.Ticket {
|
||||
_ = k
|
||||
_ = v
|
||||
l = 0
|
||||
if v != nil {
|
||||
l = v.Size()
|
||||
l += 1 + sovScreen(uint64(l))
|
||||
}
|
||||
mapEntrySize := 1 + sovScreen(uint64(k)) + l
|
||||
n += mapEntrySize + 1 + sovScreen(uint64(mapEntrySize))
|
||||
}
|
||||
}
|
||||
return n
|
||||
}
|
||||
|
||||
func sovScreen(x uint64) (n int) {
|
||||
for {
|
||||
n++
|
||||
x >>= 7
|
||||
if x == 0 {
|
||||
break
|
||||
}
|
||||
}
|
||||
return n
|
||||
}
|
||||
func sozScreen(x uint64) (n int) {
|
||||
return sovScreen(uint64((x << 1) ^ uint64((int64(x) >> 63))))
|
||||
}
|
||||
func (m *ScreenInfo) Unmarshal(dAtA []byte) error {
|
||||
l := len(dAtA)
|
||||
iNdEx := 0
|
||||
for iNdEx < l {
|
||||
preIndex := iNdEx
|
||||
var wire uint64
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowScreen
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
wire |= (uint64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
fieldNum := int32(wire >> 3)
|
||||
wireType := int(wire & 0x7)
|
||||
if wireType == 4 {
|
||||
return fmt.Errorf("proto: ScreenInfo: wiretype end group for non-group")
|
||||
}
|
||||
if fieldNum <= 0 {
|
||||
return fmt.Errorf("proto: ScreenInfo: illegal tag %d (wire type %d)", fieldNum, wire)
|
||||
}
|
||||
switch fieldNum {
|
||||
case 1:
|
||||
if wireType != 0 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field ID", wireType)
|
||||
}
|
||||
m.ID = 0
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowScreen
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
m.ID |= (int64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
case 2:
|
||||
if wireType != 2 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
|
||||
}
|
||||
var stringLen uint64
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowScreen
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
stringLen |= (uint64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
intStringLen := int(stringLen)
|
||||
if intStringLen < 0 {
|
||||
return ErrInvalidLengthScreen
|
||||
}
|
||||
postIndex := iNdEx + intStringLen
|
||||
if postIndex > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
m.Name = string(dAtA[iNdEx:postIndex])
|
||||
iNdEx = postIndex
|
||||
case 3:
|
||||
if wireType != 0 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
|
||||
}
|
||||
m.Status = 0
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowScreen
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
m.Status |= (int32(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
case 4:
|
||||
if wireType != 0 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType)
|
||||
}
|
||||
m.Type = 0
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowScreen
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
m.Type |= (int32(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
case 5:
|
||||
if wireType != 0 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field TicketType", wireType)
|
||||
}
|
||||
m.TicketType = 0
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowScreen
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
m.TicketType |= (int32(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
case 6:
|
||||
if wireType != 0 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field ScreenType", wireType)
|
||||
}
|
||||
m.ScreenType = 0
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowScreen
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
m.ScreenType |= (int32(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
case 7:
|
||||
if wireType != 0 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field DeliveryType", wireType)
|
||||
}
|
||||
m.DeliveryType = 0
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowScreen
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
m.DeliveryType |= (int32(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
case 8:
|
||||
if wireType != 0 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field PickSeat", wireType)
|
||||
}
|
||||
m.PickSeat = 0
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowScreen
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
m.PickSeat |= (int32(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
case 9:
|
||||
if wireType != 0 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field SaleFlag", wireType)
|
||||
}
|
||||
m.SaleFlag = 0
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowScreen
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
m.SaleFlag |= (int32(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
case 10:
|
||||
if wireType != 2 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field ScTime", wireType)
|
||||
}
|
||||
var msglen int
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowScreen
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
msglen |= (int(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
if msglen < 0 {
|
||||
return ErrInvalidLengthScreen
|
||||
}
|
||||
postIndex := iNdEx + msglen
|
||||
if postIndex > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
if m.ScTime == nil {
|
||||
m.ScTime = &ScreenTime{}
|
||||
}
|
||||
if err := m.ScTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
|
||||
return err
|
||||
}
|
||||
iNdEx = postIndex
|
||||
case 11:
|
||||
if wireType != 2 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field Ticket", wireType)
|
||||
}
|
||||
var msglen int
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowScreen
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
msglen |= (int(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
if msglen < 0 {
|
||||
return ErrInvalidLengthScreen
|
||||
}
|
||||
postIndex := iNdEx + msglen
|
||||
if postIndex > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
if m.Ticket == nil {
|
||||
m.Ticket = make(map[int64]*TicketInfo)
|
||||
}
|
||||
var mapkey int64
|
||||
var mapvalue *TicketInfo
|
||||
for iNdEx < postIndex {
|
||||
entryPreIndex := iNdEx
|
||||
var wire uint64
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowScreen
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
wire |= (uint64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
fieldNum := int32(wire >> 3)
|
||||
if fieldNum == 1 {
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowScreen
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
mapkey |= (int64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
} else if fieldNum == 2 {
|
||||
var mapmsglen int
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowScreen
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
mapmsglen |= (int(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
if mapmsglen < 0 {
|
||||
return ErrInvalidLengthScreen
|
||||
}
|
||||
postmsgIndex := iNdEx + mapmsglen
|
||||
if mapmsglen < 0 {
|
||||
return ErrInvalidLengthScreen
|
||||
}
|
||||
if postmsgIndex > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
mapvalue = &TicketInfo{}
|
||||
if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil {
|
||||
return err
|
||||
}
|
||||
iNdEx = postmsgIndex
|
||||
} else {
|
||||
iNdEx = entryPreIndex
|
||||
skippy, err := skipScreen(dAtA[iNdEx:])
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if skippy < 0 {
|
||||
return ErrInvalidLengthScreen
|
||||
}
|
||||
if (iNdEx + skippy) > postIndex {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
iNdEx += skippy
|
||||
}
|
||||
}
|
||||
m.Ticket[mapkey] = mapvalue
|
||||
iNdEx = postIndex
|
||||
default:
|
||||
iNdEx = preIndex
|
||||
skippy, err := skipScreen(dAtA[iNdEx:])
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if skippy < 0 {
|
||||
return ErrInvalidLengthScreen
|
||||
}
|
||||
if (iNdEx + skippy) > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
iNdEx += skippy
|
||||
}
|
||||
}
|
||||
|
||||
if iNdEx > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
return nil
|
||||
}
|
||||
func skipScreen(dAtA []byte) (n int, err error) {
|
||||
l := len(dAtA)
|
||||
iNdEx := 0
|
||||
for iNdEx < l {
|
||||
var wire uint64
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return 0, ErrIntOverflowScreen
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return 0, io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
wire |= (uint64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
wireType := int(wire & 0x7)
|
||||
switch wireType {
|
||||
case 0:
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return 0, ErrIntOverflowScreen
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return 0, io.ErrUnexpectedEOF
|
||||
}
|
||||
iNdEx++
|
||||
if dAtA[iNdEx-1] < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
return iNdEx, nil
|
||||
case 1:
|
||||
iNdEx += 8
|
||||
return iNdEx, nil
|
||||
case 2:
|
||||
var length int
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return 0, ErrIntOverflowScreen
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return 0, io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
length |= (int(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
iNdEx += length
|
||||
if length < 0 {
|
||||
return 0, ErrInvalidLengthScreen
|
||||
}
|
||||
return iNdEx, nil
|
||||
case 3:
|
||||
for {
|
||||
var innerWire uint64
|
||||
var start int = iNdEx
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return 0, ErrIntOverflowScreen
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return 0, io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
innerWire |= (uint64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
innerWireType := int(innerWire & 0x7)
|
||||
if innerWireType == 4 {
|
||||
break
|
||||
}
|
||||
next, err := skipScreen(dAtA[start:])
|
||||
if err != nil {
|
||||
return 0, err
|
||||
}
|
||||
iNdEx = start + next
|
||||
}
|
||||
return iNdEx, nil
|
||||
case 4:
|
||||
return iNdEx, nil
|
||||
case 5:
|
||||
iNdEx += 4
|
||||
return iNdEx, nil
|
||||
default:
|
||||
return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
|
||||
}
|
||||
}
|
||||
panic("unreachable")
|
||||
}
|
||||
|
||||
var (
|
||||
ErrInvalidLengthScreen = fmt.Errorf("proto: negative length found during unmarshaling")
|
||||
ErrIntOverflowScreen = fmt.Errorf("proto: integer overflow")
|
||||
)
|
||||
|
||||
func init() {
|
||||
proto.RegisterFile("app/service/openplatform/ticket-item/api/grpc/v1/screen.proto", fileDescriptorScreen)
|
||||
}
|
||||
|
||||
var fileDescriptorScreen = []byte{
|
||||
// 514 bytes of a gzipped FileDescriptorProto
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x93, 0xcf, 0x8a, 0xd3, 0x40,
|
||||
0x1c, 0xc7, 0x49, 0xda, 0x66, 0xdb, 0x89, 0x42, 0x99, 0x83, 0x84, 0xb2, 0x34, 0xb1, 0x22, 0xe4,
|
||||
0xb2, 0x49, 0xbb, 0x82, 0x2c, 0x2b, 0xf5, 0x10, 0x76, 0x85, 0xf5, 0x98, 0xed, 0x49, 0x90, 0x32,
|
||||
0x4d, 0xa6, 0x71, 0x68, 0xfe, 0x91, 0x4c, 0x03, 0x7d, 0x13, 0x1f, 0xc9, 0xa3, 0x4f, 0x10, 0xa4,
|
||||
0xc7, 0x1c, 0x7d, 0x02, 0x99, 0xdf, 0x44, 0x5b, 0x21, 0x2c, 0xe8, 0xa5, 0xcc, 0xef, 0xcf, 0xe7,
|
||||
0xd3, 0x19, 0xfa, 0x2d, 0x5a, 0x92, 0x3c, 0x77, 0x4b, 0x5a, 0x54, 0x2c, 0xa0, 0x6e, 0x96, 0xd3,
|
||||
0x34, 0x8f, 0x09, 0xdf, 0x66, 0x45, 0xe2, 0x72, 0x16, 0xec, 0x28, 0xbf, 0x62, 0x9c, 0x26, 0x2e,
|
||||
0xc9, 0x99, 0x1b, 0x15, 0x79, 0xe0, 0x56, 0x0b, 0xb7, 0x0c, 0x0a, 0x4a, 0x53, 0x27, 0x2f, 0x32,
|
||||
0x9e, 0xe1, 0x17, 0x72, 0xcb, 0x69, 0x0d, 0x8e, 0xd8, 0x76, 0xaa, 0xc5, 0xe4, 0x2a, 0x62, 0xfc,
|
||||
0xcb, 0x7e, 0xe3, 0x04, 0x59, 0xe2, 0x46, 0x59, 0x94, 0xb9, 0xb0, 0xbe, 0xd9, 0x6f, 0xa1, 0x82,
|
||||
0x02, 0x4e, 0x52, 0x33, 0x79, 0xf7, 0xcf, 0xb7, 0xe0, 0x2c, 0xa1, 0x2d, 0xbc, 0xfc, 0x0f, 0x18,
|
||||
0x2e, 0x0d, 0xf8, 0xec, 0xab, 0x86, 0xd0, 0x23, 0xbc, 0xe9, 0x21, 0xdd, 0x66, 0x78, 0x8e, 0x54,
|
||||
0x16, 0x1a, 0x8a, 0xa5, 0xd8, 0x3d, 0xcf, 0x3a, 0xd6, 0xa6, 0xfa, 0x70, 0xd7, 0xd4, 0xa6, 0xca,
|
||||
0xc2, 0x9f, 0xb5, 0x39, 0xae, 0x48, 0xcc, 0x42, 0xc2, 0xe9, 0xed, 0x2c, 0x61, 0xe9, 0x72, 0x3e,
|
||||
0xf3, 0x55, 0x16, 0xe2, 0x4b, 0xd4, 0x4f, 0x49, 0x42, 0x0d, 0xd5, 0x52, 0xec, 0x91, 0x37, 0x6c,
|
||||
0x6a, 0x13, 0x6a, 0x1f, 0x3e, 0xf1, 0x5b, 0xa4, 0x95, 0x9c, 0xf0, 0x7d, 0x69, 0xf4, 0x2c, 0xc5,
|
||||
0x1e, 0x78, 0xd3, 0xa6, 0x36, 0xdb, 0x4e, 0xa7, 0xb1, 0x9d, 0xe1, 0x39, 0xea, 0xf3, 0x43, 0x4e,
|
||||
0x8d, 0x3e, 0x50, 0x97, 0xc2, 0x2a, 0xea, 0x4e, 0x06, 0x26, 0xf8, 0x0e, 0xe9, 0xf2, 0x61, 0x6b,
|
||||
0x00, 0x07, 0x00, 0xbe, 0x6a, 0x6a, 0xf3, 0xbc, 0xdd, 0xc9, 0x23, 0xb9, 0xb0, 0x6a, 0x2d, 0xf2,
|
||||
0x17, 0x96, 0x16, 0xed, 0x64, 0x39, 0x6b, 0x77, 0x5b, 0xe4, 0x02, 0x58, 0x3e, 0xa2, 0xe7, 0x21,
|
||||
0x8d, 0x59, 0x45, 0x8b, 0x83, 0xf4, 0x5c, 0x80, 0xe7, 0x75, 0x53, 0x9b, 0x7f, 0x0f, 0x3a, 0x4d,
|
||||
0xcf, 0x7e, 0xaf, 0x80, 0xeb, 0x3d, 0x1a, 0xe5, 0x2c, 0xd8, 0xad, 0x4b, 0x4a, 0xb8, 0x31, 0x04,
|
||||
0xcf, 0xcb, 0xa6, 0x36, 0x4f, 0xcd, 0x4e, 0xc7, 0x50, 0x8c, 0x1f, 0x29, 0xe1, 0x82, 0x2f, 0x49,
|
||||
0x4c, 0xd7, 0xdb, 0x98, 0x44, 0xc6, 0xe8, 0xc4, 0xff, 0x69, 0x76, 0xf3, 0x62, 0xfc, 0x21, 0x26,
|
||||
0x11, 0xbe, 0x47, 0x17, 0x65, 0xb0, 0x16, 0x81, 0x33, 0x90, 0xa5, 0xd8, 0xfa, 0xf5, 0xcc, 0xe9,
|
||||
0x4e, 0xbd, 0x23, 0x63, 0xb4, 0x62, 0x09, 0x95, 0x31, 0x10, 0x8c, 0xaf, 0x95, 0x81, 0xe8, 0x60,
|
||||
0x1f, 0x69, 0x2b, 0xc0, 0x0c, 0xdd, 0xea, 0xd9, 0xfa, 0xb5, 0xf3, 0xb4, 0x45, 0x84, 0xd1, 0x91,
|
||||
0xc0, 0x7d, 0xca, 0x8b, 0x83, 0x87, 0x44, 0x70, 0x24, 0xe2, 0xb7, 0xa6, 0xc9, 0x67, 0xa4, 0x9f,
|
||||
0xad, 0xe0, 0x31, 0xea, 0xed, 0xe8, 0x41, 0x86, 0xd7, 0x17, 0x47, 0x7c, 0x83, 0x06, 0x15, 0x89,
|
||||
0xf7, 0x32, 0x9c, 0x4f, 0xdc, 0x5c, 0x5a, 0xc4, 0x77, 0xfa, 0x12, 0xb8, 0x55, 0x6f, 0x14, 0x6f,
|
||||
0xfc, 0xed, 0x38, 0x55, 0xbe, 0x1f, 0xa7, 0xca, 0x8f, 0xe3, 0x54, 0xf9, 0xa4, 0x56, 0x8b, 0x8d,
|
||||
0x06, 0xff, 0x99, 0x37, 0xbf, 0x02, 0x00, 0x00, 0xff, 0xff, 0x7c, 0x79, 0x0d, 0x96, 0x37, 0x04,
|
||||
0x00, 0x00,
|
||||
}
|
@ -0,0 +1,29 @@
|
||||
syntax = "proto3";
|
||||
package ticket.service.item.v1;
|
||||
|
||||
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
|
||||
import "app/service/openplatform/ticket-item/api/grpc/v1/time.proto";
|
||||
import "app/service/openplatform/ticket-item/api/grpc/v1/ticket.proto";
|
||||
|
||||
option go_package = "v1";
|
||||
|
||||
// The response message containing the ScreenInfo
|
||||
message ScreenInfo {
|
||||
int64 id = 1 [(gogoproto.jsontag) = "id", (gogoproto.moretags) = "validate:\"min=0\"", (gogoproto.customname)= "ID"];
|
||||
string name = 2 [(gogoproto.jsontag) = "name"];
|
||||
int32 status = 3 [(gogoproto.jsontag) = "status", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
// 类型: 1-坐, 2-站
|
||||
int32 type = 4 [(gogoproto.jsontag) = "type", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
// 出票方式: 1-纸质票, 2-电子票, 3-外部票
|
||||
int32 ticket_type = 5 [(gogoproto.jsontag) = "ticket_type", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
// 票区分的场次类型: 1-普通场次, 2-通票场次 3-联票场次
|
||||
int32 screen_type = 6 [(gogoproto.jsontag) = "screen_type", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
// 配送方式: 1-不配送, 2-自取, 3-快递
|
||||
int32 delivery_type = 7 [(gogoproto.jsontag) = "delivery_type", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
// 是否选座 是-1,否-0
|
||||
int32 pick_seat = 8 [(gogoproto.jsontag) = "pick_seat", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
// 售卖状态
|
||||
int32 sale_flag = 9 [(gogoproto.jsontag) = "sale_flag", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
ScreenTime sc_time = 10 [(gogoproto.jsontag) = "time"];
|
||||
map<int64,TicketInfo> Ticket = 11 [(gogoproto.jsontag) = "ticket"];
|
||||
}
|
1856
app/service/openplatform/ticket-item/api/grpc/v1/seat.pb.go
Normal file
1856
app/service/openplatform/ticket-item/api/grpc/v1/seat.pb.go
Normal file
File diff suppressed because it is too large
Load Diff
96
app/service/openplatform/ticket-item/api/grpc/v1/seat.proto
Normal file
96
app/service/openplatform/ticket-item/api/grpc/v1/seat.proto
Normal file
@ -0,0 +1,96 @@
|
||||
syntax = "proto3";
|
||||
package ticket.service.item.v1;
|
||||
|
||||
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
|
||||
|
||||
option (gogoproto.goproto_enum_prefix_all) = false;
|
||||
option (gogoproto.goproto_getters_all) = false;
|
||||
option (gogoproto.unmarshaler_all) = true;
|
||||
option (gogoproto.marshaler_all) = true;
|
||||
option (gogoproto.sizer_all) = true;
|
||||
option go_package = "v1";
|
||||
|
||||
// The seat service definition.
|
||||
service Seat {
|
||||
rpc SeatInfo (SeatInfoRequest) returns (SeatInfoReply) {}
|
||||
rpc SeatStock (SeatStockRequest) returns (SeatStockReply) {}
|
||||
rpc RemoveSeatOrders (RemoveSeatOrdersRequest) returns (RemoveSeatOrdersReply) {}
|
||||
}
|
||||
|
||||
// 单个座位信息
|
||||
message AreaSeatInfo {
|
||||
// 座位图x
|
||||
int32 X = 1 [(gogoproto.jsontag) = "x", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
// 座位图y
|
||||
int32 Y = 2 [(gogoproto.jsontag) = "y", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
// 座位号
|
||||
string Label = 3 [(gogoproto.jsontag) = "label", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
// 背景色
|
||||
string Bgcolor = 4 [(gogoproto.jsontag) = "bgcolor", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
// 区域ID
|
||||
int64 Area = 5 [(gogoproto.jsontag) = "area", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
}
|
||||
|
||||
// seatInfo接口请求
|
||||
message SeatInfoRequest {
|
||||
// 区域ID
|
||||
int64 Area = 1 [(gogoproto.jsontag) = "area", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
// 座位数
|
||||
int32 SeatsNum = 2 [(gogoproto.jsontag) = "seats_num", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
// 座位图
|
||||
string SeatMap = 3 [(gogoproto.jsontag) = "seat_map", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
// 座位数组
|
||||
repeated AreaSeatInfo Seats = 4 [(gogoproto.jsontag) = "seats", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
// 坐区宽度
|
||||
int32 Width = 5 [(gogoproto.jsontag) = "width", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
// 坐区高度
|
||||
int32 Height = 6 [(gogoproto.jsontag) = "height", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
// 行号序列
|
||||
string RowList = 7 [(gogoproto.jsontag) = "row_list", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
// 座位起始坐标
|
||||
string SeatStart = 8 [(gogoproto.jsontag) = "seat_start", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
}
|
||||
|
||||
// seatInfo接口返回
|
||||
message SeatInfoReply {
|
||||
// 操作结果
|
||||
bool Success = 1 [(gogoproto.jsontag) = "success"];
|
||||
}
|
||||
|
||||
// 座位票种
|
||||
message SeatPrice {
|
||||
// 座位图x
|
||||
int32 X = 1 [(gogoproto.jsontag) = "x", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
// 座位图y
|
||||
int32 Y = 2 [(gogoproto.jsontag) = "y", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
// 票种ID
|
||||
int64 Price = 3 [(gogoproto.jsontag) = "price", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
}
|
||||
|
||||
// seatStock接口请求
|
||||
message SeatStockRequest {
|
||||
// 场次ID
|
||||
int64 Screen = 1 [(gogoproto.jsontag) = "screen", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
// 区域ID
|
||||
int64 Area = 2 [(gogoproto.jsontag) = "area", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
// 座位票种定义数组
|
||||
repeated SeatPrice SeatInfo = 3 [(gogoproto.jsontag) = "seatInfo", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
}
|
||||
|
||||
// seatStock接口返回
|
||||
message SeatStockReply {
|
||||
// 操作结果
|
||||
bool Success = 1 [(gogoproto.jsontag) = "success"];
|
||||
}
|
||||
|
||||
// removeSeatOrders接口请求
|
||||
message RemoveSeatOrdersRequest {
|
||||
// 票价ID
|
||||
int64 Price = 1 [(gogoproto.jsontag) = "price", (gogoproto.moretags) = "validate:\"min=1\""];
|
||||
}
|
||||
|
||||
// removeSeatOrders接口返回
|
||||
message RemoveSeatOrdersReply {
|
||||
// 影响的区域
|
||||
repeated int64 Areas = 1 [(gogoproto.jsontag) = "areas"];
|
||||
}
|
1812
app/service/openplatform/ticket-item/api/grpc/v1/ticket.pb.go
Normal file
1812
app/service/openplatform/ticket-item/api/grpc/v1/ticket.pb.go
Normal file
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,48 @@
|
||||
syntax = "proto3";
|
||||
package ticket.service.item.v1;
|
||||
|
||||
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
|
||||
import "app/service/openplatform/ticket-item/api/grpc/v1/time.proto";
|
||||
|
||||
option go_package = "v1";
|
||||
|
||||
// The response message containing the TicketInfo
|
||||
message TicketInfo {
|
||||
int64 id = 1 [(gogoproto.jsontag) = "id", (gogoproto.moretags) = "validate:\"min=1\"", (gogoproto.customname)= "ID"];
|
||||
string desc = 2 [(gogoproto.jsontag) = "name"];
|
||||
// 票类型:1-单场票 2-通票 3-联票
|
||||
int32 type = 3 [(gogoproto.jsontag) = "type", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
// 售卖类型 1-预售票 2-现场票
|
||||
int32 sale_type = 4 [(gogoproto.jsontag) = "stype", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
string link_sc = 5 [(gogoproto.jsontag) = "lk_screen"];
|
||||
string link_ticket_id = 6 [(gogoproto.jsontag) = "lk_ticket", (gogoproto.customname)= "LinkTicketID"];
|
||||
string symbol = 7 [(gogoproto.jsontag) = "symbol"];
|
||||
string color = 8 [(gogoproto.jsontag) = "color"];
|
||||
int32 buy_limit = 9 [(gogoproto.jsontag) = "buy_limit", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
string desc_detail = 10 [(gogoproto.jsontag) = "desc"];
|
||||
int32 sale_flag = 11 [(gogoproto.jsontag) = "sale_flag", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
TicketPriceList price_list = 12[(gogoproto.jsontag) = "price"];
|
||||
TicketStatus status_list = 13 [(gogoproto.jsontag) = "status"];
|
||||
TicketTime time = 14 [(gogoproto.jsontag) = "time"];
|
||||
TicketBuyNumLimit buy_num_limit = 15 [(gogoproto.jsontag) = "buy_num_limit"];
|
||||
}
|
||||
|
||||
message TicketBuyNumLimit {
|
||||
map<int32,int64> normal = 1 [(gogoproto.jsontag) = "normal"];
|
||||
map<int32,int64> vip = 2 [(gogoproto.jsontag) = "vip"];
|
||||
map<int32,int64> annual_vip = 3 [(gogoproto.jsontag) = "annual_vip"];
|
||||
}
|
||||
|
||||
// The response message containing the IsSale IsVisible IsRefund
|
||||
message TicketStatus {
|
||||
int32 is_sale = 1 [(gogoproto.jsontag) = "is_sale", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
int32 is_visible = 2[(gogoproto.jsontag) = "is_visible", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
int32 is_refund =3 [(gogoproto.jsontag) = "is_refund", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
}
|
||||
|
||||
// The response message containing the Price OriginPrice MarketPrice
|
||||
message TicketPriceList {
|
||||
int32 price = 1 [(gogoproto.jsontag) = "price", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
int32 ori_price = 2 [(gogoproto.jsontag) = "oprice", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
int32 mkt_price = 3 [(gogoproto.jsontag) = "mprice", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
}
|
705
app/service/openplatform/ticket-item/api/grpc/v1/time.pb.go
Normal file
705
app/service/openplatform/ticket-item/api/grpc/v1/time.pb.go
Normal file
@ -0,0 +1,705 @@
|
||||
// Code generated by protoc-gen-gogo. DO NOT EDIT.
|
||||
// source: app/service/openplatform/ticket-item/api/grpc/v1/time.proto
|
||||
|
||||
package v1
|
||||
|
||||
import proto "github.com/gogo/protobuf/proto"
|
||||
import fmt "fmt"
|
||||
import math "math"
|
||||
import _ "github.com/gogo/protobuf/gogoproto"
|
||||
|
||||
import io "io"
|
||||
|
||||
// Reference imports to suppress errors if they are not otherwise used.
|
||||
var _ = proto.Marshal
|
||||
var _ = fmt.Errorf
|
||||
var _ = math.Inf
|
||||
|
||||
// The response message containing the Item related time
|
||||
type ItemTime struct {
|
||||
Stime int32 `protobuf:"varint,1,opt,name=stime,proto3" json:"stime"`
|
||||
Etime int32 `protobuf:"varint,2,opt,name=etime,proto3" json:"etime"`
|
||||
}
|
||||
|
||||
func (m *ItemTime) Reset() { *m = ItemTime{} }
|
||||
func (m *ItemTime) String() string { return proto.CompactTextString(m) }
|
||||
func (*ItemTime) ProtoMessage() {}
|
||||
func (*ItemTime) Descriptor() ([]byte, []int) { return fileDescriptorTime, []int{0} }
|
||||
|
||||
func (m *ItemTime) GetStime() int32 {
|
||||
if m != nil {
|
||||
return m.Stime
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (m *ItemTime) GetEtime() int32 {
|
||||
if m != nil {
|
||||
return m.Etime
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
// The response message containing the Screen related time
|
||||
type ScreenTime struct {
|
||||
Stime int32 `protobuf:"varint,1,opt,name=stime,proto3" json:"stime" validate:"min=0"`
|
||||
Etime int32 `protobuf:"varint,2,opt,name=etime,proto3" json:"etime" validate:"min=0"`
|
||||
SaleStime int32 `protobuf:"varint,3,opt,name=sale_stime,json=saleStime,proto3" json:"sales" validate:"min=0"`
|
||||
SaleEtime int32 `protobuf:"varint,4,opt,name=sale_etime,json=saleEtime,proto3" json:"salee" validate:"min=0"`
|
||||
}
|
||||
|
||||
func (m *ScreenTime) Reset() { *m = ScreenTime{} }
|
||||
func (m *ScreenTime) String() string { return proto.CompactTextString(m) }
|
||||
func (*ScreenTime) ProtoMessage() {}
|
||||
func (*ScreenTime) Descriptor() ([]byte, []int) { return fileDescriptorTime, []int{1} }
|
||||
|
||||
func (m *ScreenTime) GetStime() int32 {
|
||||
if m != nil {
|
||||
return m.Stime
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (m *ScreenTime) GetEtime() int32 {
|
||||
if m != nil {
|
||||
return m.Etime
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (m *ScreenTime) GetSaleStime() int32 {
|
||||
if m != nil {
|
||||
return m.SaleStime
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (m *ScreenTime) GetSaleEtime() int32 {
|
||||
if m != nil {
|
||||
return m.SaleEtime
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
// The response message containing the Ticket related time
|
||||
type TicketTime struct {
|
||||
SaleStime int64 `protobuf:"varint,1,opt,name=sale_stime,json=saleStime,proto3" json:"sales" validate:"min=0"`
|
||||
SaleEtime int64 `protobuf:"varint,2,opt,name=sale_etime,json=saleEtime,proto3" json:"salee" validate:"min=0"`
|
||||
}
|
||||
|
||||
func (m *TicketTime) Reset() { *m = TicketTime{} }
|
||||
func (m *TicketTime) String() string { return proto.CompactTextString(m) }
|
||||
func (*TicketTime) ProtoMessage() {}
|
||||
func (*TicketTime) Descriptor() ([]byte, []int) { return fileDescriptorTime, []int{2} }
|
||||
|
||||
func (m *TicketTime) GetSaleStime() int64 {
|
||||
if m != nil {
|
||||
return m.SaleStime
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (m *TicketTime) GetSaleEtime() int64 {
|
||||
if m != nil {
|
||||
return m.SaleEtime
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func init() {
|
||||
proto.RegisterType((*ItemTime)(nil), "ticket.service.item.v1.ItemTime")
|
||||
proto.RegisterType((*ScreenTime)(nil), "ticket.service.item.v1.ScreenTime")
|
||||
proto.RegisterType((*TicketTime)(nil), "ticket.service.item.v1.TicketTime")
|
||||
}
|
||||
func (m *ItemTime) Marshal() (dAtA []byte, err error) {
|
||||
size := m.Size()
|
||||
dAtA = make([]byte, size)
|
||||
n, err := m.MarshalTo(dAtA)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return dAtA[:n], nil
|
||||
}
|
||||
|
||||
func (m *ItemTime) MarshalTo(dAtA []byte) (int, error) {
|
||||
var i int
|
||||
_ = i
|
||||
var l int
|
||||
_ = l
|
||||
if m.Stime != 0 {
|
||||
dAtA[i] = 0x8
|
||||
i++
|
||||
i = encodeVarintTime(dAtA, i, uint64(m.Stime))
|
||||
}
|
||||
if m.Etime != 0 {
|
||||
dAtA[i] = 0x10
|
||||
i++
|
||||
i = encodeVarintTime(dAtA, i, uint64(m.Etime))
|
||||
}
|
||||
return i, nil
|
||||
}
|
||||
|
||||
func (m *ScreenTime) Marshal() (dAtA []byte, err error) {
|
||||
size := m.Size()
|
||||
dAtA = make([]byte, size)
|
||||
n, err := m.MarshalTo(dAtA)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return dAtA[:n], nil
|
||||
}
|
||||
|
||||
func (m *ScreenTime) MarshalTo(dAtA []byte) (int, error) {
|
||||
var i int
|
||||
_ = i
|
||||
var l int
|
||||
_ = l
|
||||
if m.Stime != 0 {
|
||||
dAtA[i] = 0x8
|
||||
i++
|
||||
i = encodeVarintTime(dAtA, i, uint64(m.Stime))
|
||||
}
|
||||
if m.Etime != 0 {
|
||||
dAtA[i] = 0x10
|
||||
i++
|
||||
i = encodeVarintTime(dAtA, i, uint64(m.Etime))
|
||||
}
|
||||
if m.SaleStime != 0 {
|
||||
dAtA[i] = 0x18
|
||||
i++
|
||||
i = encodeVarintTime(dAtA, i, uint64(m.SaleStime))
|
||||
}
|
||||
if m.SaleEtime != 0 {
|
||||
dAtA[i] = 0x20
|
||||
i++
|
||||
i = encodeVarintTime(dAtA, i, uint64(m.SaleEtime))
|
||||
}
|
||||
return i, nil
|
||||
}
|
||||
|
||||
func (m *TicketTime) Marshal() (dAtA []byte, err error) {
|
||||
size := m.Size()
|
||||
dAtA = make([]byte, size)
|
||||
n, err := m.MarshalTo(dAtA)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return dAtA[:n], nil
|
||||
}
|
||||
|
||||
func (m *TicketTime) MarshalTo(dAtA []byte) (int, error) {
|
||||
var i int
|
||||
_ = i
|
||||
var l int
|
||||
_ = l
|
||||
if m.SaleStime != 0 {
|
||||
dAtA[i] = 0x8
|
||||
i++
|
||||
i = encodeVarintTime(dAtA, i, uint64(m.SaleStime))
|
||||
}
|
||||
if m.SaleEtime != 0 {
|
||||
dAtA[i] = 0x10
|
||||
i++
|
||||
i = encodeVarintTime(dAtA, i, uint64(m.SaleEtime))
|
||||
}
|
||||
return i, nil
|
||||
}
|
||||
|
||||
func encodeVarintTime(dAtA []byte, offset int, v uint64) int {
|
||||
for v >= 1<<7 {
|
||||
dAtA[offset] = uint8(v&0x7f | 0x80)
|
||||
v >>= 7
|
||||
offset++
|
||||
}
|
||||
dAtA[offset] = uint8(v)
|
||||
return offset + 1
|
||||
}
|
||||
func (m *ItemTime) Size() (n int) {
|
||||
var l int
|
||||
_ = l
|
||||
if m.Stime != 0 {
|
||||
n += 1 + sovTime(uint64(m.Stime))
|
||||
}
|
||||
if m.Etime != 0 {
|
||||
n += 1 + sovTime(uint64(m.Etime))
|
||||
}
|
||||
return n
|
||||
}
|
||||
|
||||
func (m *ScreenTime) Size() (n int) {
|
||||
var l int
|
||||
_ = l
|
||||
if m.Stime != 0 {
|
||||
n += 1 + sovTime(uint64(m.Stime))
|
||||
}
|
||||
if m.Etime != 0 {
|
||||
n += 1 + sovTime(uint64(m.Etime))
|
||||
}
|
||||
if m.SaleStime != 0 {
|
||||
n += 1 + sovTime(uint64(m.SaleStime))
|
||||
}
|
||||
if m.SaleEtime != 0 {
|
||||
n += 1 + sovTime(uint64(m.SaleEtime))
|
||||
}
|
||||
return n
|
||||
}
|
||||
|
||||
func (m *TicketTime) Size() (n int) {
|
||||
var l int
|
||||
_ = l
|
||||
if m.SaleStime != 0 {
|
||||
n += 1 + sovTime(uint64(m.SaleStime))
|
||||
}
|
||||
if m.SaleEtime != 0 {
|
||||
n += 1 + sovTime(uint64(m.SaleEtime))
|
||||
}
|
||||
return n
|
||||
}
|
||||
|
||||
func sovTime(x uint64) (n int) {
|
||||
for {
|
||||
n++
|
||||
x >>= 7
|
||||
if x == 0 {
|
||||
break
|
||||
}
|
||||
}
|
||||
return n
|
||||
}
|
||||
func sozTime(x uint64) (n int) {
|
||||
return sovTime(uint64((x << 1) ^ uint64((int64(x) >> 63))))
|
||||
}
|
||||
func (m *ItemTime) Unmarshal(dAtA []byte) error {
|
||||
l := len(dAtA)
|
||||
iNdEx := 0
|
||||
for iNdEx < l {
|
||||
preIndex := iNdEx
|
||||
var wire uint64
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowTime
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
wire |= (uint64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
fieldNum := int32(wire >> 3)
|
||||
wireType := int(wire & 0x7)
|
||||
if wireType == 4 {
|
||||
return fmt.Errorf("proto: ItemTime: wiretype end group for non-group")
|
||||
}
|
||||
if fieldNum <= 0 {
|
||||
return fmt.Errorf("proto: ItemTime: illegal tag %d (wire type %d)", fieldNum, wire)
|
||||
}
|
||||
switch fieldNum {
|
||||
case 1:
|
||||
if wireType != 0 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field Stime", wireType)
|
||||
}
|
||||
m.Stime = 0
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowTime
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
m.Stime |= (int32(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
case 2:
|
||||
if wireType != 0 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field Etime", wireType)
|
||||
}
|
||||
m.Etime = 0
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowTime
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
m.Etime |= (int32(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
default:
|
||||
iNdEx = preIndex
|
||||
skippy, err := skipTime(dAtA[iNdEx:])
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if skippy < 0 {
|
||||
return ErrInvalidLengthTime
|
||||
}
|
||||
if (iNdEx + skippy) > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
iNdEx += skippy
|
||||
}
|
||||
}
|
||||
|
||||
if iNdEx > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
return nil
|
||||
}
|
||||
func (m *ScreenTime) Unmarshal(dAtA []byte) error {
|
||||
l := len(dAtA)
|
||||
iNdEx := 0
|
||||
for iNdEx < l {
|
||||
preIndex := iNdEx
|
||||
var wire uint64
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowTime
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
wire |= (uint64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
fieldNum := int32(wire >> 3)
|
||||
wireType := int(wire & 0x7)
|
||||
if wireType == 4 {
|
||||
return fmt.Errorf("proto: ScreenTime: wiretype end group for non-group")
|
||||
}
|
||||
if fieldNum <= 0 {
|
||||
return fmt.Errorf("proto: ScreenTime: illegal tag %d (wire type %d)", fieldNum, wire)
|
||||
}
|
||||
switch fieldNum {
|
||||
case 1:
|
||||
if wireType != 0 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field Stime", wireType)
|
||||
}
|
||||
m.Stime = 0
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowTime
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
m.Stime |= (int32(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
case 2:
|
||||
if wireType != 0 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field Etime", wireType)
|
||||
}
|
||||
m.Etime = 0
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowTime
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
m.Etime |= (int32(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
case 3:
|
||||
if wireType != 0 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field SaleStime", wireType)
|
||||
}
|
||||
m.SaleStime = 0
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowTime
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
m.SaleStime |= (int32(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
case 4:
|
||||
if wireType != 0 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field SaleEtime", wireType)
|
||||
}
|
||||
m.SaleEtime = 0
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowTime
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
m.SaleEtime |= (int32(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
default:
|
||||
iNdEx = preIndex
|
||||
skippy, err := skipTime(dAtA[iNdEx:])
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if skippy < 0 {
|
||||
return ErrInvalidLengthTime
|
||||
}
|
||||
if (iNdEx + skippy) > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
iNdEx += skippy
|
||||
}
|
||||
}
|
||||
|
||||
if iNdEx > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
return nil
|
||||
}
|
||||
func (m *TicketTime) Unmarshal(dAtA []byte) error {
|
||||
l := len(dAtA)
|
||||
iNdEx := 0
|
||||
for iNdEx < l {
|
||||
preIndex := iNdEx
|
||||
var wire uint64
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowTime
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
wire |= (uint64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
fieldNum := int32(wire >> 3)
|
||||
wireType := int(wire & 0x7)
|
||||
if wireType == 4 {
|
||||
return fmt.Errorf("proto: TicketTime: wiretype end group for non-group")
|
||||
}
|
||||
if fieldNum <= 0 {
|
||||
return fmt.Errorf("proto: TicketTime: illegal tag %d (wire type %d)", fieldNum, wire)
|
||||
}
|
||||
switch fieldNum {
|
||||
case 1:
|
||||
if wireType != 0 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field SaleStime", wireType)
|
||||
}
|
||||
m.SaleStime = 0
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowTime
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
m.SaleStime |= (int64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
case 2:
|
||||
if wireType != 0 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field SaleEtime", wireType)
|
||||
}
|
||||
m.SaleEtime = 0
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowTime
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
m.SaleEtime |= (int64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
default:
|
||||
iNdEx = preIndex
|
||||
skippy, err := skipTime(dAtA[iNdEx:])
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if skippy < 0 {
|
||||
return ErrInvalidLengthTime
|
||||
}
|
||||
if (iNdEx + skippy) > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
iNdEx += skippy
|
||||
}
|
||||
}
|
||||
|
||||
if iNdEx > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
return nil
|
||||
}
|
||||
func skipTime(dAtA []byte) (n int, err error) {
|
||||
l := len(dAtA)
|
||||
iNdEx := 0
|
||||
for iNdEx < l {
|
||||
var wire uint64
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return 0, ErrIntOverflowTime
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return 0, io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
wire |= (uint64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
wireType := int(wire & 0x7)
|
||||
switch wireType {
|
||||
case 0:
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return 0, ErrIntOverflowTime
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return 0, io.ErrUnexpectedEOF
|
||||
}
|
||||
iNdEx++
|
||||
if dAtA[iNdEx-1] < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
return iNdEx, nil
|
||||
case 1:
|
||||
iNdEx += 8
|
||||
return iNdEx, nil
|
||||
case 2:
|
||||
var length int
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return 0, ErrIntOverflowTime
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return 0, io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
length |= (int(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
iNdEx += length
|
||||
if length < 0 {
|
||||
return 0, ErrInvalidLengthTime
|
||||
}
|
||||
return iNdEx, nil
|
||||
case 3:
|
||||
for {
|
||||
var innerWire uint64
|
||||
var start int = iNdEx
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return 0, ErrIntOverflowTime
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return 0, io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
innerWire |= (uint64(b) & 0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
innerWireType := int(innerWire & 0x7)
|
||||
if innerWireType == 4 {
|
||||
break
|
||||
}
|
||||
next, err := skipTime(dAtA[start:])
|
||||
if err != nil {
|
||||
return 0, err
|
||||
}
|
||||
iNdEx = start + next
|
||||
}
|
||||
return iNdEx, nil
|
||||
case 4:
|
||||
return iNdEx, nil
|
||||
case 5:
|
||||
iNdEx += 4
|
||||
return iNdEx, nil
|
||||
default:
|
||||
return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
|
||||
}
|
||||
}
|
||||
panic("unreachable")
|
||||
}
|
||||
|
||||
var (
|
||||
ErrInvalidLengthTime = fmt.Errorf("proto: negative length found during unmarshaling")
|
||||
ErrIntOverflowTime = fmt.Errorf("proto: integer overflow")
|
||||
)
|
||||
|
||||
func init() {
|
||||
proto.RegisterFile("app/service/openplatform/ticket-item/api/grpc/v1/time.proto", fileDescriptorTime)
|
||||
}
|
||||
|
||||
var fileDescriptorTime = []byte{
|
||||
// 310 bytes of a gzipped FileDescriptorProto
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x91, 0xbf, 0x4e, 0xc3, 0x30,
|
||||
0x10, 0xc6, 0xe5, 0x94, 0x22, 0xea, 0xa9, 0xca, 0x80, 0x10, 0x52, 0x13, 0x94, 0x89, 0xa5, 0x31,
|
||||
0x51, 0x36, 0xfe, 0x2c, 0x95, 0x18, 0x90, 0x98, 0x68, 0x26, 0x16, 0xe4, 0x84, 0x6b, 0xb0, 0x88,
|
||||
0x63, 0x2b, 0x71, 0xf3, 0x0c, 0x3c, 0x1a, 0x23, 0x4f, 0x50, 0xa1, 0x8c, 0x8c, 0x7d, 0x02, 0x94,
|
||||
0x33, 0x14, 0x22, 0x8a, 0x90, 0x98, 0x9c, 0xcb, 0x7d, 0xdf, 0xf7, 0xbb, 0xd3, 0xd1, 0x33, 0xae,
|
||||
0x35, 0xab, 0xa1, 0x6a, 0x44, 0x06, 0x4c, 0x69, 0x28, 0x75, 0xc1, 0xcd, 0x42, 0x55, 0x92, 0x19,
|
||||
0x91, 0x3d, 0x82, 0x99, 0x0a, 0x03, 0x92, 0x71, 0x2d, 0x58, 0x5e, 0xe9, 0x8c, 0x35, 0x11, 0x33,
|
||||
0x42, 0x42, 0xa8, 0x2b, 0x65, 0x94, 0xbb, 0x6f, 0x35, 0xe1, 0x87, 0x3f, 0xec, 0xb4, 0x61, 0x13,
|
||||
0x1d, 0x4e, 0x73, 0x61, 0x1e, 0x96, 0x69, 0x98, 0x29, 0xc9, 0x72, 0x95, 0x2b, 0x86, 0xf2, 0x74,
|
||||
0xb9, 0xc0, 0x0a, 0x0b, 0xfc, 0xb2, 0x31, 0xc1, 0x35, 0xdd, 0xbb, 0x32, 0x20, 0x13, 0x21, 0xc1,
|
||||
0xf5, 0xe9, 0xb0, 0xee, 0x08, 0x07, 0xe4, 0x88, 0x1c, 0x0f, 0x67, 0xa3, 0xb7, 0x95, 0x6f, 0x7f,
|
||||
0xdc, 0xd8, 0xa7, 0x13, 0x00, 0x0a, 0x9c, 0x2f, 0x01, 0x58, 0x01, 0x3e, 0xc1, 0x9a, 0x50, 0x3a,
|
||||
0xcf, 0x2a, 0x80, 0x12, 0x03, 0xe3, 0x7e, 0xe0, 0x64, 0x13, 0xb8, 0x5e, 0xf9, 0xe3, 0x86, 0x17,
|
||||
0xe2, 0x9e, 0x1b, 0x38, 0x0d, 0xa4, 0x28, 0x2f, 0x4e, 0x82, 0x4f, 0x48, 0xdc, 0x87, 0x4c, 0x36,
|
||||
0x90, 0xed, 0x26, 0x6c, 0xb9, 0xe7, 0x94, 0xd6, 0xbc, 0x80, 0x3b, 0x8b, 0x1b, 0x7c, 0xc3, 0xf1,
|
||||
0x02, 0xea, 0xad, 0xce, 0x51, 0xd7, 0x9a, 0xf7, 0xdc, 0x96, 0xbb, 0xd3, 0x77, 0xc3, 0xef, 0xee,
|
||||
0x4b, 0x5c, 0xfa, 0x89, 0x50, 0x9a, 0xe0, 0x31, 0x92, 0x9f, 0xa3, 0x74, 0x9b, 0x0f, 0xfe, 0x3d,
|
||||
0x8a, 0xd3, 0x77, 0xff, 0x35, 0xca, 0x6c, 0xfc, 0xdc, 0x7a, 0xe4, 0xa5, 0xf5, 0xc8, 0x6b, 0xeb,
|
||||
0x91, 0x5b, 0xa7, 0x89, 0xd2, 0x5d, 0x3c, 0x73, 0xfc, 0x1e, 0x00, 0x00, 0xff, 0xff, 0x47, 0x84,
|
||||
0xeb, 0xce, 0x6c, 0x02, 0x00, 0x00,
|
||||
}
|
26
app/service/openplatform/ticket-item/api/grpc/v1/time.proto
Normal file
26
app/service/openplatform/ticket-item/api/grpc/v1/time.proto
Normal file
@ -0,0 +1,26 @@
|
||||
syntax = "proto3";
|
||||
package ticket.service.item.v1;
|
||||
|
||||
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
|
||||
|
||||
option go_package = "v1";
|
||||
|
||||
// The response message containing the Item related time
|
||||
message ItemTime {
|
||||
int32 stime = 1 [(gogoproto.jsontag) = "stime"];
|
||||
int32 etime = 2 [(gogoproto.jsontag) = "etime"];
|
||||
}
|
||||
|
||||
// The response message containing the Screen related time
|
||||
message ScreenTime {
|
||||
int32 stime = 1 [(gogoproto.jsontag) = "stime", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
int32 etime = 2 [(gogoproto.jsontag) = "etime", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
int32 sale_stime = 3 [(gogoproto.jsontag) = "sales", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
int32 sale_etime = 4 [(gogoproto.jsontag) = "salee", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
}
|
||||
|
||||
// The response message containing the Ticket related time
|
||||
message TicketTime {
|
||||
int64 sale_stime = 1 [(gogoproto.jsontag) = "sales", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
int64 sale_etime = 2 [(gogoproto.jsontag) = "salee", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
}
|
1379
app/service/openplatform/ticket-item/api/grpc/v1/venue.pb.go
Normal file
1379
app/service/openplatform/ticket-item/api/grpc/v1/venue.pb.go
Normal file
File diff suppressed because it is too large
Load Diff
65
app/service/openplatform/ticket-item/api/grpc/v1/venue.proto
Normal file
65
app/service/openplatform/ticket-item/api/grpc/v1/venue.proto
Normal file
@ -0,0 +1,65 @@
|
||||
syntax = "proto3";
|
||||
package ticket.service.item.v1;
|
||||
|
||||
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
|
||||
import "app/service/openplatform/ticket-item/api/grpc/v1/place.proto";
|
||||
|
||||
option (gogoproto.goproto_enum_prefix_all) = false;
|
||||
option (gogoproto.goproto_getters_all) = false;
|
||||
option (gogoproto.unmarshaler_all) = true;
|
||||
option (gogoproto.marshaler_all) = true;
|
||||
option (gogoproto.sizer_all) = true;
|
||||
option go_package = "v1";
|
||||
|
||||
// The venue service definition.
|
||||
service Venue {
|
||||
rpc VenueInfo (VenueInfoRequest) returns (VenueInfoReply) {}
|
||||
}
|
||||
|
||||
// The response message containing the VenueInfo
|
||||
message VenueInfo {
|
||||
int64 id = 1 [(gogoproto.jsontag) = "id",(gogoproto.customname)= "ID"];
|
||||
string name = 2 [(gogoproto.jsontag) = "name"];
|
||||
int32 status= 3 [(gogoproto.jsontag) = "status"];
|
||||
VenueAddrInfo addrInfo = 4 [(gogoproto.jsontag) = "addr"];
|
||||
PlaceInfo place_info = 5 [(gogoproto.jsontag) = "place"];
|
||||
}
|
||||
|
||||
// The response message containing the Venue location info
|
||||
message VenueAddrInfo {
|
||||
int64 province = 1 [(gogoproto.jsontag) = "provid"];
|
||||
int64 city = 2 [(gogoproto.jsontag) = "cityid"];
|
||||
int64 district = 3 [(gogoproto.jsontag) = "distid"];
|
||||
string addressDetail = 4 [(gogoproto.jsontag) = "addr"];
|
||||
string traffic = 5 [(gogoproto.jsontag) = "traff"];
|
||||
string lon_lat_type = 6 [(gogoproto.jsontag) = "lonlat_type"];
|
||||
string lonLat = 7 [(gogoproto.jsontag) = "lonlat"];
|
||||
}
|
||||
|
||||
// venueInfo接口请求
|
||||
message VenueInfoRequest {
|
||||
// 待修改场馆的ID(为0表示创建)
|
||||
int64 ID = 1 [(gogoproto.jsontag) = "id", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
// 场馆名
|
||||
string Name = 2 [(gogoproto.jsontag) = "name", (gogoproto.moretags) = "validate:\"max=25\""];
|
||||
// 状态 1-启用 0-停用
|
||||
int32 Status = 3 [(gogoproto.jsontag) = "status", (gogoproto.moretags) = "validate:\"min=0,max=1\""];
|
||||
// 省份ID
|
||||
int64 Province = 4 [(gogoproto.jsontag) = "provid", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
// 城市ID
|
||||
int64 City = 5 [(gogoproto.jsontag) = "cityid", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
// 区县ID
|
||||
int64 District = 6 [(gogoproto.jsontag) = "distid", (gogoproto.moretags) = "validate:\"min=0\""];
|
||||
// 详细地址
|
||||
string AddressDetail = 7 [(gogoproto.jsontag) = "addr", (gogoproto.moretags) = "validate:\"min=0,max=60\""];
|
||||
// 交通信息
|
||||
string Traffic = 8 [(gogoproto.jsontag) = "traff", (gogoproto.moretags) = "validate:\"min=0,max=100\""];
|
||||
}
|
||||
|
||||
// venue接口返回
|
||||
message VenueInfoReply {
|
||||
// 操作结果
|
||||
bool Success = 1 [(gogoproto.jsontag) = "success"];
|
||||
// 操作场馆ID
|
||||
int64 ID = 2 [(gogoproto.jsontag) = "id"];
|
||||
}
|
Reference in New Issue
Block a user