Files
base/api/pb/discount/discount.pb.go
2026-04-10 18:25:21 +03:30

380 lines
13 KiB
Go

// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.28.1
// protoc v3.11.2
// source: discount.proto
package discount
import (
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
reflect "reflect"
sync "sync"
)
const (
// Verify that this generated code is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
// Verify that runtime/protoimpl is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)
type GetVendorDiscountRequest struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
Discounts []*GetVendorDiscountRequest_DiscountEntry `protobuf:"bytes,1,rep,name=discounts,proto3" json:"discounts,omitempty"`
}
func (x *GetVendorDiscountRequest) Reset() {
*x = GetVendorDiscountRequest{}
if protoimpl.UnsafeEnabled {
mi := &file_discount_proto_msgTypes[0]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *GetVendorDiscountRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetVendorDiscountRequest) ProtoMessage() {}
func (x *GetVendorDiscountRequest) ProtoReflect() protoreflect.Message {
mi := &file_discount_proto_msgTypes[0]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetVendorDiscountRequest.ProtoReflect.Descriptor instead.
func (*GetVendorDiscountRequest) Descriptor() ([]byte, []int) {
return file_discount_proto_rawDescGZIP(), []int{0}
}
func (x *GetVendorDiscountRequest) GetDiscounts() []*GetVendorDiscountRequest_DiscountEntry {
if x != nil {
return x.Discounts
}
return nil
}
type GetVendorDiscountResponse struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
Discounts []*GetVendorDiscountResponse_DiscountEntry `protobuf:"bytes,1,rep,name=discounts,proto3" json:"discounts,omitempty"`
}
func (x *GetVendorDiscountResponse) Reset() {
*x = GetVendorDiscountResponse{}
if protoimpl.UnsafeEnabled {
mi := &file_discount_proto_msgTypes[1]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *GetVendorDiscountResponse) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetVendorDiscountResponse) ProtoMessage() {}
func (x *GetVendorDiscountResponse) ProtoReflect() protoreflect.Message {
mi := &file_discount_proto_msgTypes[1]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetVendorDiscountResponse.ProtoReflect.Descriptor instead.
func (*GetVendorDiscountResponse) Descriptor() ([]byte, []int) {
return file_discount_proto_rawDescGZIP(), []int{1}
}
func (x *GetVendorDiscountResponse) GetDiscounts() []*GetVendorDiscountResponse_DiscountEntry {
if x != nil {
return x.Discounts
}
return nil
}
type GetVendorDiscountRequest_DiscountEntry struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
ProductId int32 `protobuf:"varint,1,opt,name=product_id,json=productId,proto3" json:"product_id,omitempty"`
VendorId int32 `protobuf:"varint,2,opt,name=vendor_id,json=vendorId,proto3" json:"vendor_id,omitempty"`
}
func (x *GetVendorDiscountRequest_DiscountEntry) Reset() {
*x = GetVendorDiscountRequest_DiscountEntry{}
if protoimpl.UnsafeEnabled {
mi := &file_discount_proto_msgTypes[2]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *GetVendorDiscountRequest_DiscountEntry) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetVendorDiscountRequest_DiscountEntry) ProtoMessage() {}
func (x *GetVendorDiscountRequest_DiscountEntry) ProtoReflect() protoreflect.Message {
mi := &file_discount_proto_msgTypes[2]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetVendorDiscountRequest_DiscountEntry.ProtoReflect.Descriptor instead.
func (*GetVendorDiscountRequest_DiscountEntry) Descriptor() ([]byte, []int) {
return file_discount_proto_rawDescGZIP(), []int{0, 0}
}
func (x *GetVendorDiscountRequest_DiscountEntry) GetProductId() int32 {
if x != nil {
return x.ProductId
}
return 0
}
func (x *GetVendorDiscountRequest_DiscountEntry) GetVendorId() int32 {
if x != nil {
return x.VendorId
}
return 0
}
type GetVendorDiscountResponse_DiscountEntry struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
ProductId int32 `protobuf:"varint,1,opt,name=product_id,json=productId,proto3" json:"product_id,omitempty"`
VendorId int32 `protobuf:"varint,2,opt,name=vendor_id,json=vendorId,proto3" json:"vendor_id,omitempty"`
Percent float32 `protobuf:"fixed32,3,opt,name=percent,proto3" json:"percent,omitempty"`
}
func (x *GetVendorDiscountResponse_DiscountEntry) Reset() {
*x = GetVendorDiscountResponse_DiscountEntry{}
if protoimpl.UnsafeEnabled {
mi := &file_discount_proto_msgTypes[3]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *GetVendorDiscountResponse_DiscountEntry) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetVendorDiscountResponse_DiscountEntry) ProtoMessage() {}
func (x *GetVendorDiscountResponse_DiscountEntry) ProtoReflect() protoreflect.Message {
mi := &file_discount_proto_msgTypes[3]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetVendorDiscountResponse_DiscountEntry.ProtoReflect.Descriptor instead.
func (*GetVendorDiscountResponse_DiscountEntry) Descriptor() ([]byte, []int) {
return file_discount_proto_rawDescGZIP(), []int{1, 0}
}
func (x *GetVendorDiscountResponse_DiscountEntry) GetProductId() int32 {
if x != nil {
return x.ProductId
}
return 0
}
func (x *GetVendorDiscountResponse_DiscountEntry) GetVendorId() int32 {
if x != nil {
return x.VendorId
}
return 0
}
func (x *GetVendorDiscountResponse_DiscountEntry) GetPercent() float32 {
if x != nil {
return x.Percent
}
return 0
}
var File_discount_proto protoreflect.FileDescriptor
var file_discount_proto_rawDesc = []byte{
0x0a, 0x0e, 0x64, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f,
0x12, 0x08, 0x64, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0xb7, 0x01, 0x0a, 0x18, 0x47,
0x65, 0x74, 0x56, 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x44, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74,
0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x4e, 0x0a, 0x09, 0x64, 0x69, 0x73, 0x63, 0x6f,
0x75, 0x6e, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x30, 0x2e, 0x64, 0x69, 0x73,
0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x47, 0x65, 0x74, 0x56, 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x44,
0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x2e, 0x44,
0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x09, 0x64, 0x69,
0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x1a, 0x4b, 0x0a, 0x0d, 0x44, 0x69, 0x73, 0x63, 0x6f,
0x75, 0x6e, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x1d, 0x0a, 0x0a, 0x70, 0x72, 0x6f, 0x64,
0x75, 0x63, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x70, 0x72,
0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, 0x64, 0x12, 0x1b, 0x0a, 0x09, 0x76, 0x65, 0x6e, 0x64, 0x6f,
0x72, 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x76, 0x65, 0x6e, 0x64,
0x6f, 0x72, 0x49, 0x64, 0x22, 0xd3, 0x01, 0x0a, 0x19, 0x47, 0x65, 0x74, 0x56, 0x65, 0x6e, 0x64,
0x6f, 0x72, 0x44, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e,
0x73, 0x65, 0x12, 0x4f, 0x0a, 0x09, 0x64, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x18,
0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x31, 0x2e, 0x64, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74,
0x2e, 0x47, 0x65, 0x74, 0x56, 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x44, 0x69, 0x73, 0x63, 0x6f, 0x75,
0x6e, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x2e, 0x44, 0x69, 0x73, 0x63, 0x6f,
0x75, 0x6e, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x09, 0x64, 0x69, 0x73, 0x63, 0x6f, 0x75,
0x6e, 0x74, 0x73, 0x1a, 0x65, 0x0a, 0x0d, 0x44, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x45,
0x6e, 0x74, 0x72, 0x79, 0x12, 0x1d, 0x0a, 0x0a, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x5f,
0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63,
0x74, 0x49, 0x64, 0x12, 0x1b, 0x0a, 0x09, 0x76, 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x5f, 0x69, 0x64,
0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x76, 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x49, 0x64,
0x12, 0x18, 0x0a, 0x07, 0x70, 0x65, 0x72, 0x63, 0x65, 0x6e, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28,
0x02, 0x52, 0x07, 0x70, 0x65, 0x72, 0x63, 0x65, 0x6e, 0x74, 0x32, 0x6e, 0x0a, 0x08, 0x44, 0x69,
0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x62, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x56, 0x65, 0x6e,
0x64, 0x6f, 0x72, 0x44, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x12,
0x22, 0x2e, 0x64, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x47, 0x65, 0x74, 0x56, 0x65,
0x6e, 0x64, 0x6f, 0x72, 0x44, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75,
0x65, 0x73, 0x74, 0x1a, 0x23, 0x2e, 0x64, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x2e, 0x47,
0x65, 0x74, 0x56, 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x44, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74,
0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, 0x03, 0x5a, 0x01, 0x2e, 0x62,
0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
}
var (
file_discount_proto_rawDescOnce sync.Once
file_discount_proto_rawDescData = file_discount_proto_rawDesc
)
func file_discount_proto_rawDescGZIP() []byte {
file_discount_proto_rawDescOnce.Do(func() {
file_discount_proto_rawDescData = protoimpl.X.CompressGZIP(file_discount_proto_rawDescData)
})
return file_discount_proto_rawDescData
}
var file_discount_proto_msgTypes = make([]protoimpl.MessageInfo, 4)
var file_discount_proto_goTypes = []interface{}{
(*GetVendorDiscountRequest)(nil), // 0: discount.GetVendorDiscountRequest
(*GetVendorDiscountResponse)(nil), // 1: discount.GetVendorDiscountResponse
(*GetVendorDiscountRequest_DiscountEntry)(nil), // 2: discount.GetVendorDiscountRequest.DiscountEntry
(*GetVendorDiscountResponse_DiscountEntry)(nil), // 3: discount.GetVendorDiscountResponse.DiscountEntry
}
var file_discount_proto_depIdxs = []int32{
2, // 0: discount.GetVendorDiscountRequest.discounts:type_name -> discount.GetVendorDiscountRequest.DiscountEntry
3, // 1: discount.GetVendorDiscountResponse.discounts:type_name -> discount.GetVendorDiscountResponse.DiscountEntry
0, // 2: discount.Discount.GetVendorDiscountInfo:input_type -> discount.GetVendorDiscountRequest
1, // 3: discount.Discount.GetVendorDiscountInfo:output_type -> discount.GetVendorDiscountResponse
3, // [3:4] is the sub-list for method output_type
2, // [2:3] is the sub-list for method input_type
2, // [2:2] is the sub-list for extension type_name
2, // [2:2] is the sub-list for extension extendee
0, // [0:2] is the sub-list for field type_name
}
func init() { file_discount_proto_init() }
func file_discount_proto_init() {
if File_discount_proto != nil {
return
}
if !protoimpl.UnsafeEnabled {
file_discount_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*GetVendorDiscountRequest); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_discount_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*GetVendorDiscountResponse); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_discount_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*GetVendorDiscountRequest_DiscountEntry); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_discount_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*GetVendorDiscountResponse_DiscountEntry); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
}
type x struct{}
out := protoimpl.TypeBuilder{
File: protoimpl.DescBuilder{
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: file_discount_proto_rawDesc,
NumEnums: 0,
NumMessages: 4,
NumExtensions: 0,
NumServices: 1,
},
GoTypes: file_discount_proto_goTypes,
DependencyIndexes: file_discount_proto_depIdxs,
MessageInfos: file_discount_proto_msgTypes,
}.Build()
File_discount_proto = out.File
file_discount_proto_rawDesc = nil
file_discount_proto_goTypes = nil
file_discount_proto_depIdxs = nil
}