From eb69096c83beada41c0478974c868caa38b4bbb8 Mon Sep 17 00:00:00 2001 From: jarrysix Date: Mon, 13 Mar 2023 17:38:35 +0800 Subject: [PATCH 01/33] feat: item safeguard_flag --- core/domain/interface/item/item.go | 2 + .../domain/interface/item/snapshot_service.go | 2 + core/domain/item/item.go | 1 + core/domain/item/snapshot_service.go | 1 + core/service/idl/message/item_dto.proto | 9 +- core/service/parser/item_dto.go | 45 +- core/service/parser/parser.go | 7 +- core/service/parser/snapshot.go | 39 +- core/service/proto/item_dto.pb.go | 778 +++++++++--------- upgrade/sql/2023-03.sql | 14 +- 10 files changed, 480 insertions(+), 418 deletions(-) diff --git a/core/domain/interface/item/item.go b/core/domain/interface/item/item.go index 5059dd257..dd4aa7f40 100755 --- a/core/domain/interface/item/item.go +++ b/core/domain/interface/item/item.go @@ -410,6 +410,8 @@ type ( Weight int32 `db:"weight"` // 体积:毫升(ml) Bulk int32 `db:"bulk"` + // 商品购物保障 + SafeguardFlag int `db:"safeguard_flag"` // 是否上架 ShelveState int32 `db:"shelve_state"` // 审核状态 diff --git a/core/domain/interface/item/snapshot_service.go b/core/domain/interface/item/snapshot_service.go index fcdf7a660..1866deff3 100755 --- a/core/domain/interface/item/snapshot_service.go +++ b/core/domain/interface/item/snapshot_service.go @@ -71,6 +71,8 @@ type ( Weight int32 `db:"weight"` // 体积(ml) Bulk int32 `db:"bulk"` + // 商品购物保障 + SafeguardFlag int `db:"safeguard_flag"` // 会员价 LevelSales int32 `db:"level_sales"` // 上架状态 diff --git a/core/domain/item/item.go b/core/domain/item/item.go index e54fc723b..f5eeabf89 100755 --- a/core/domain/item/item.go +++ b/core/domain/item/item.go @@ -274,6 +274,7 @@ func (i *itemImpl) SetValue(v *item.GoodsItem) error { i.value.ExpressTid = v.ExpressTid i.value.Title = v.Title i.value.ItemFlag = v.ItemFlag + i.value.SafeguardFlag = v.SafeguardFlag i.value.ShortTitle = v.ShortTitle i.value.Code = v.Code i.value.StockNum = v.StockNum diff --git a/core/domain/item/snapshot_service.go b/core/domain/item/snapshot_service.go index 4b71227b6..1c8005e98 100755 --- a/core/domain/item/snapshot_service.go +++ b/core/domain/item/snapshot_service.go @@ -104,6 +104,7 @@ func (s *snapshotServiceImpl) updateSnapshot(ls *item.Snapshot, Price: it.Price, OriginPrice: it.OriginPrice, Weight: it.Weight, + SafeguardFlag: it.SafeguardFlag, Bulk: it.Bulk, LevelSales: int32(levelSales), ShelveState: it.ShelveState, diff --git a/core/service/idl/message/item_dto.proto b/core/service/idl/message/item_dto.proto index 37ad70fdd..155a159f5 100644 --- a/core/service/idl/message/item_dto.proto +++ b/core/service/idl/message/item_dto.proto @@ -152,6 +152,9 @@ message SaveItemRequest { int64 expressTid = 23; repeated SSku skuArray = 24; repeated SLevelPrice levelPrices = 25; + + // 商品购物保障 + int32 safeguardFlag = 26; } // 商品数据响应 @@ -218,6 +221,8 @@ message SItemDataResponse { SItemFlagData flagData = 29; // 会员价 repeated SLevelPrice levelPrices = 30; + // 商品购物保障 + int32 safeguardFlag = 31; } // 商品标志枚举 @@ -425,8 +430,10 @@ message ItemSnapshotResponse { repeated SLevelPrice levelPrices = 28; // 视频介绍 string introVideo = 29; + // 商品购物保障 + int32 safeguardFlag = 30; // 返回Sku-HTML - string skuHtml = 30; + string skuHtml = 31; } /** 产品属性值(用于展示详情) */ diff --git a/core/service/parser/item_dto.go b/core/service/parser/item_dto.go index 04f8df112..6028c5580 100644 --- a/core/service/parser/item_dto.go +++ b/core/service/parser/item_dto.go @@ -127,28 +127,29 @@ func ParseGoodsItem(src *proto.SaveItemRequest) *item.GoodsItem { image = src.Images[0] } dst := &item.GoodsItem{ - Id: src.ItemId, - ProductId: src.ProductId, - CategoryId: int32(src.CategoryId), - VendorId: src.VendorId, - BrandId: int32(src.BrandId), - ShopId: src.ShopId, - ShopCatId: 0, //todo:?? - ExpressTid: int32(src.ExpressTid), //src., - Title: src.Title, - IntroVideo: src.IntroVideo, - ShortTitle: "", //src.Sho, - Code: src.Code, - Image: image, - Images: src.Images, - PriceRange: src.PriceRange, - StockNum: src.StockNum, - SaleNum: 0, - SkuId: src.SkuId, - OriginPrice: src.OriginPrice, - Cost: src.Cost, - Price: src.Price, - SkuArray: make([]*item.Sku, len(src.SkuArray)), + Id: src.ItemId, + ProductId: src.ProductId, + CategoryId: int32(src.CategoryId), + VendorId: src.VendorId, + BrandId: int32(src.BrandId), + ShopId: src.ShopId, + ShopCatId: 0, //todo:?? + ExpressTid: int32(src.ExpressTid), //src., + Title: src.Title, + IntroVideo: src.IntroVideo, + ShortTitle: "", //src.Sho, + Code: src.Code, + Image: image, + Images: src.Images, + PriceRange: src.PriceRange, + StockNum: src.StockNum, + SaleNum: 0, + SkuId: src.SkuId, + OriginPrice: src.OriginPrice, + Cost: src.Cost, + Price: src.Price, + SafeguardFlag: int(src.SafeguardFlag), + SkuArray: make([]*item.Sku, len(src.SkuArray)), } for i, v := range src.SkuArray { dst.SkuArray[i] = Sku(v) diff --git a/core/service/parser/parser.go b/core/service/parser/parser.go index 652b636f9..6f7ce1592 100755 --- a/core/service/parser/parser.go +++ b/core/service/parser/parser.go @@ -87,9 +87,10 @@ func ItemDataDto(src item.GoodsItem) *proto.SItemDataResponse { OriginPrice: src.OriginPrice, //Weight: src.Weight, //Bulk: src.Bulk, - ShelveState: src.ShelveState, - ReviewState: src.ReviewState, - ReviewRemark: src.ReviewRemark, + ShelveState: src.ShelveState, + ReviewState: src.ReviewState, + ReviewRemark: src.ReviewRemark, + SafeguardFlag: int32(src.SafeguardFlag), //CreateTime: src.CreateTime, } if src.SkuArray != nil { diff --git a/core/service/parser/snapshot.go b/core/service/parser/snapshot.go index 954688595..60ae00966 100644 --- a/core/service/parser/snapshot.go +++ b/core/service/parser/snapshot.go @@ -17,25 +17,26 @@ import ( func ParseItemSnapshotDto(src *item.Snapshot) *proto.ItemSnapshotResponse { return &proto.ItemSnapshotResponse{ - ItemId: src.ItemId, - ProductId: src.ProductId, - CategoryId: int64(src.CatId), - VendorId: src.VendorId, - BrandId: int64(src.BrandId), - ShopId: src.ShopId, - ShopCatId: int64(src.ShopCatId), - ExpressTid: int64(src.ExpressTid), - Title: src.Title, - ShortTitle: src.ShortTitle, - ProductCode: src.Code, - Images: []string{src.Image}, - PriceRange: src.PriceRange, - SkuId: src.SkuId, - StockNum: 0, - SaleNum: 0, - Price: src.Price, - OriginPrice: src.OriginPrice, - SkuArray: nil, + ItemId: src.ItemId, + ProductId: src.ProductId, + CategoryId: int64(src.CatId), + VendorId: src.VendorId, + BrandId: int64(src.BrandId), + ShopId: src.ShopId, + ShopCatId: int64(src.ShopCatId), + ExpressTid: int64(src.ExpressTid), + Title: src.Title, + ShortTitle: src.ShortTitle, + ProductCode: src.Code, + Images: []string{src.Image}, + PriceRange: src.PriceRange, + SkuId: src.SkuId, + StockNum: 0, + SaleNum: 0, + Price: src.Price, + OriginPrice: src.OriginPrice, + SafeguardFlag: int32(src.SafeguardFlag), + SkuArray: nil, } } diff --git a/core/service/proto/item_dto.pb.go b/core/service/proto/item_dto.pb.go index a410bf82b..766c99903 100644 --- a/core/service/proto/item_dto.pb.go +++ b/core/service/proto/item_dto.pb.go @@ -949,6 +949,8 @@ type SaveItemRequest struct { ExpressTid int64 `protobuf:"varint,23,opt,name=expressTid,proto3" json:"expressTid"` SkuArray []*SSku `protobuf:"bytes,24,rep,name=skuArray,proto3" json:"skuArray"` LevelPrices []*SLevelPrice `protobuf:"bytes,25,rep,name=levelPrices,proto3" json:"levelPrices"` + // 商品购物保障 + SafeguardFlag int32 `protobuf:"varint,26,opt,name=safeguardFlag,proto3" json:"safeguardFlag"` } func (x *SaveItemRequest) Reset() { @@ -1158,6 +1160,13 @@ func (x *SaveItemRequest) GetLevelPrices() []*SLevelPrice { return nil } +func (x *SaveItemRequest) GetSafeguardFlag() int32 { + if x != nil { + return x.SafeguardFlag + } + return 0 +} + // 商品数据响应 type SItemDataResponse struct { state protoimpl.MessageState @@ -1225,6 +1234,8 @@ type SItemDataResponse struct { FlagData *SItemFlagData `protobuf:"bytes,29,opt,name=flagData,proto3" json:"flagData"` // 会员价 LevelPrices []*SLevelPrice `protobuf:"bytes,30,rep,name=levelPrices,proto3" json:"levelPrices"` + // 商品购物保障 + SafeguardFlag int32 `protobuf:"varint,31,opt,name=safeguardFlag,proto3" json:"safeguardFlag"` } func (x *SItemDataResponse) Reset() { @@ -1469,6 +1480,13 @@ func (x *SItemDataResponse) GetLevelPrices() []*SLevelPrice { return nil } +func (x *SItemDataResponse) GetSafeguardFlag() int32 { + if x != nil { + return x.SafeguardFlag + } + return 0 +} + // 商品标志 type SItemFlagData struct { state protoimpl.MessageState @@ -2310,8 +2328,10 @@ type ItemSnapshotResponse struct { LevelPrices []*SLevelPrice `protobuf:"bytes,28,rep,name=levelPrices,proto3" json:"levelPrices"` // 视频介绍 IntroVideo string `protobuf:"bytes,29,opt,name=introVideo,proto3" json:"introVideo"` + // 商品购物保障 + SafeguardFlag int32 `protobuf:"varint,30,opt,name=safeguardFlag,proto3" json:"safeguardFlag"` // 返回Sku-HTML - SkuHtml string `protobuf:"bytes,30,opt,name=skuHtml,proto3" json:"skuHtml"` + SkuHtml string `protobuf:"bytes,31,opt,name=skuHtml,proto3" json:"skuHtml"` } func (x *ItemSnapshotResponse) Reset() { @@ -2535,6 +2555,13 @@ func (x *ItemSnapshotResponse) GetIntroVideo() string { return "" } +func (x *ItemSnapshotResponse) GetSafeguardFlag() int32 { + if x != nil { + return x.SafeguardFlag + } + return 0 +} + func (x *ItemSnapshotResponse) GetSkuHtml() string { if x != nil { return x.SkuHtml @@ -3861,7 +3888,7 @@ var file_message_item_dto_proto_rawDesc = []byte{ 0x52, 0x04, 0x62, 0x75, 0x6c, 0x6b, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x74, 0x6f, 0x63, 0x6b, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x73, 0x74, 0x6f, 0x63, 0x6b, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x61, 0x6c, 0x65, 0x4e, 0x75, 0x6d, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x73, - 0x61, 0x6c, 0x65, 0x4e, 0x75, 0x6d, 0x22, 0xe0, 0x05, 0x0a, 0x0f, 0x53, 0x61, 0x76, 0x65, 0x49, + 0x61, 0x6c, 0x65, 0x4e, 0x75, 0x6d, 0x22, 0x86, 0x06, 0x0a, 0x0f, 0x53, 0x61, 0x76, 0x65, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, 0x64, 0x18, @@ -3907,381 +3934,388 @@ var file_message_item_dto_proto_rawDesc = []byte{ 0x08, 0x73, 0x6b, 0x75, 0x41, 0x72, 0x72, 0x61, 0x79, 0x12, 0x2e, 0x0a, 0x0b, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x50, 0x72, 0x69, 0x63, 0x65, 0x73, 0x18, 0x19, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x53, 0x4c, 0x65, 0x76, 0x65, 0x6c, 0x50, 0x72, 0x69, 0x63, 0x65, 0x52, 0x0b, 0x6c, 0x65, - 0x76, 0x65, 0x6c, 0x50, 0x72, 0x69, 0x63, 0x65, 0x73, 0x22, 0xa2, 0x07, 0x0a, 0x11, 0x53, 0x49, - 0x74, 0x65, 0x6d, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, - 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x70, 0x72, 0x6f, 0x64, 0x75, - 0x63, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x70, 0x72, 0x6f, 0x64, - 0x75, 0x63, 0x74, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x76, 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x49, - 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x76, 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x49, - 0x64, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x68, 0x6f, 0x70, 0x49, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x06, 0x73, 0x68, 0x6f, 0x70, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x61, 0x74, - 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x63, - 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x69, 0x74, - 0x6c, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x12, - 0x1e, 0x0a, 0x0a, 0x73, 0x68, 0x6f, 0x72, 0x74, 0x54, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x07, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0a, 0x73, 0x68, 0x6f, 0x72, 0x74, 0x54, 0x69, 0x74, 0x6c, 0x65, 0x12, - 0x1e, 0x0a, 0x0a, 0x69, 0x6e, 0x74, 0x72, 0x6f, 0x56, 0x69, 0x64, 0x65, 0x6f, 0x18, 0x08, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0a, 0x69, 0x6e, 0x74, 0x72, 0x6f, 0x56, 0x69, 0x64, 0x65, 0x6f, 0x12, - 0x18, 0x0a, 0x07, 0x67, 0x6f, 0x6f, 0x64, 0x73, 0x4e, 0x6f, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x07, 0x67, 0x6f, 0x6f, 0x64, 0x73, 0x4e, 0x6f, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x68, 0x75, - 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x74, 0x68, - 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x6d, 0x61, 0x67, 0x65, - 0x73, 0x18, 0x0b, 0x20, 0x03, 0x28, 0x09, 0x52, 0x06, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x73, 0x12, - 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x73, 0x74, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x63, - 0x6f, 0x73, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x50, 0x72, 0x69, - 0x63, 0x65, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, - 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x70, 0x72, 0x69, 0x63, 0x65, 0x18, 0x0e, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x70, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x70, - 0x72, 0x69, 0x63, 0x65, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0a, 0x70, 0x72, 0x69, 0x63, 0x65, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x73, - 0x6b, 0x75, 0x49, 0x64, 0x18, 0x10, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x73, 0x6b, 0x75, 0x49, - 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x69, 0x74, 0x65, 0x6d, 0x46, 0x6c, 0x61, 0x67, 0x18, 0x11, 0x20, - 0x01, 0x28, 0x05, 0x52, 0x08, 0x69, 0x74, 0x65, 0x6d, 0x46, 0x6c, 0x61, 0x67, 0x12, 0x1a, 0x0a, - 0x08, 0x73, 0x74, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x12, 0x20, 0x01, 0x28, 0x05, 0x52, - 0x08, 0x73, 0x74, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x61, 0x6c, - 0x65, 0x4e, 0x75, 0x6d, 0x18, 0x13, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x73, 0x61, 0x6c, 0x65, - 0x4e, 0x75, 0x6d, 0x12, 0x20, 0x0a, 0x0b, 0x73, 0x68, 0x65, 0x6c, 0x76, 0x65, 0x53, 0x74, 0x61, - 0x74, 0x65, 0x18, 0x14, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0b, 0x73, 0x68, 0x65, 0x6c, 0x76, 0x65, - 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x20, 0x0a, 0x0b, 0x72, 0x65, 0x76, 0x69, 0x65, 0x77, 0x53, - 0x74, 0x61, 0x74, 0x65, 0x18, 0x15, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0b, 0x72, 0x65, 0x76, 0x69, - 0x65, 0x77, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x22, 0x0a, 0x0c, 0x72, 0x65, 0x76, 0x69, 0x65, - 0x77, 0x52, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x18, 0x16, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x72, - 0x65, 0x76, 0x69, 0x65, 0x77, 0x52, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x12, 0x18, 0x0a, 0x07, 0x62, - 0x72, 0x61, 0x6e, 0x64, 0x49, 0x64, 0x18, 0x17, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x62, 0x72, - 0x61, 0x6e, 0x64, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x18, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x65, 0x78, 0x70, - 0x72, 0x65, 0x73, 0x73, 0x54, 0x69, 0x64, 0x18, 0x19, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x65, - 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x69, 0x64, 0x12, 0x24, 0x0a, 0x09, 0x61, 0x74, 0x74, - 0x72, 0x41, 0x72, 0x72, 0x61, 0x79, 0x18, 0x1a, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x06, 0x2e, 0x53, - 0x41, 0x74, 0x74, 0x72, 0x52, 0x09, 0x61, 0x74, 0x74, 0x72, 0x41, 0x72, 0x72, 0x61, 0x79, 0x12, - 0x21, 0x0a, 0x08, 0x73, 0x6b, 0x75, 0x41, 0x72, 0x72, 0x61, 0x79, 0x18, 0x1b, 0x20, 0x03, 0x28, - 0x0b, 0x32, 0x05, 0x2e, 0x53, 0x53, 0x6b, 0x75, 0x52, 0x08, 0x73, 0x6b, 0x75, 0x41, 0x72, 0x72, - 0x61, 0x79, 0x12, 0x2e, 0x0a, 0x0b, 0x73, 0x70, 0x65, 0x63, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, - 0x73, 0x18, 0x1c, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x53, 0x53, 0x70, 0x65, 0x63, 0x4f, - 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0b, 0x73, 0x70, 0x65, 0x63, 0x4f, 0x70, 0x74, 0x69, 0x6f, - 0x6e, 0x73, 0x12, 0x2a, 0x0a, 0x08, 0x66, 0x6c, 0x61, 0x67, 0x44, 0x61, 0x74, 0x61, 0x18, 0x1d, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x53, 0x49, 0x74, 0x65, 0x6d, 0x46, 0x6c, 0x61, 0x67, - 0x44, 0x61, 0x74, 0x61, 0x52, 0x08, 0x66, 0x6c, 0x61, 0x67, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2e, - 0x0a, 0x0b, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x50, 0x72, 0x69, 0x63, 0x65, 0x73, 0x18, 0x1e, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x53, 0x4c, 0x65, 0x76, 0x65, 0x6c, 0x50, 0x72, 0x69, 0x63, - 0x65, 0x52, 0x0b, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x50, 0x72, 0x69, 0x63, 0x65, 0x73, 0x22, 0xc3, - 0x02, 0x0a, 0x0d, 0x53, 0x49, 0x74, 0x65, 0x6d, 0x46, 0x6c, 0x61, 0x67, 0x44, 0x61, 0x74, 0x61, - 0x12, 0x24, 0x0a, 0x0d, 0x69, 0x73, 0x4e, 0x65, 0x77, 0x4f, 0x6e, 0x53, 0x68, 0x65, 0x6c, 0x76, - 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0d, 0x69, 0x73, 0x4e, 0x65, 0x77, 0x4f, 0x6e, - 0x53, 0x68, 0x65, 0x6c, 0x76, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x69, 0x73, 0x48, 0x6f, 0x74, 0x53, - 0x61, 0x6c, 0x65, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0a, 0x69, 0x73, 0x48, 0x6f, - 0x74, 0x53, 0x61, 0x6c, 0x65, 0x73, 0x12, 0x20, 0x0a, 0x0b, 0x69, 0x73, 0x52, 0x65, 0x63, 0x6f, - 0x6d, 0x6d, 0x65, 0x6e, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0b, 0x69, 0x73, 0x52, - 0x65, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x69, 0x73, 0x45, 0x78, - 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0a, 0x69, 0x73, - 0x45, 0x78, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x73, 0x47, 0x69, - 0x66, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x69, 0x73, 0x47, 0x69, 0x66, 0x74, - 0x12, 0x20, 0x0a, 0x0b, 0x69, 0x73, 0x41, 0x66, 0x66, 0x69, 0x6c, 0x69, 0x61, 0x74, 0x65, 0x18, - 0x06, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0b, 0x69, 0x73, 0x41, 0x66, 0x66, 0x69, 0x6c, 0x69, 0x61, - 0x74, 0x65, 0x12, 0x20, 0x0a, 0x0b, 0x69, 0x73, 0x53, 0x65, 0x6c, 0x66, 0x53, 0x61, 0x6c, 0x65, - 0x73, 0x18, 0x07, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0b, 0x69, 0x73, 0x53, 0x65, 0x6c, 0x66, 0x53, - 0x61, 0x6c, 0x65, 0x73, 0x12, 0x26, 0x0a, 0x0e, 0x69, 0x73, 0x46, 0x72, 0x65, 0x65, 0x44, 0x65, - 0x6c, 0x69, 0x76, 0x65, 0x72, 0x79, 0x18, 0x08, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0e, 0x69, 0x73, - 0x46, 0x72, 0x65, 0x65, 0x44, 0x65, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x79, 0x12, 0x26, 0x0a, 0x0e, - 0x69, 0x73, 0x53, 0x65, 0x6c, 0x66, 0x44, 0x65, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x79, 0x18, 0x09, - 0x20, 0x01, 0x28, 0x08, 0x52, 0x0e, 0x69, 0x73, 0x53, 0x65, 0x6c, 0x66, 0x44, 0x65, 0x6c, 0x69, - 0x76, 0x65, 0x72, 0x79, 0x22, 0xd9, 0x07, 0x0a, 0x10, 0x53, 0x55, 0x6e, 0x69, 0x66, 0x69, 0x65, - 0x64, 0x56, 0x69, 0x65, 0x77, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, - 0x6d, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, - 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, 0x64, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, 0x64, 0x12, - 0x1a, 0x0a, 0x08, 0x76, 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x08, 0x76, 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x73, - 0x68, 0x6f, 0x70, 0x49, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x73, 0x68, 0x6f, - 0x70, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, - 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, - 0x79, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x06, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x73, 0x68, 0x6f, - 0x72, 0x74, 0x54, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x73, - 0x68, 0x6f, 0x72, 0x74, 0x54, 0x69, 0x74, 0x6c, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x67, 0x6f, 0x6f, - 0x64, 0x73, 0x4e, 0x6f, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x67, 0x6f, 0x6f, 0x64, - 0x73, 0x4e, 0x6f, 0x12, 0x14, 0x0a, 0x05, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x18, 0x09, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x05, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x6d, 0x61, - 0x67, 0x65, 0x73, 0x18, 0x0a, 0x20, 0x03, 0x28, 0x09, 0x52, 0x06, 0x69, 0x6d, 0x61, 0x67, 0x65, - 0x73, 0x12, 0x20, 0x0a, 0x0b, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x50, 0x72, 0x69, 0x63, 0x65, - 0x18, 0x0b, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x50, 0x72, - 0x69, 0x63, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x70, 0x72, 0x69, 0x63, 0x65, 0x18, 0x0c, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x05, 0x70, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x70, 0x72, 0x6f, - 0x6d, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x70, 0x72, - 0x6f, 0x6d, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x70, 0x72, 0x69, 0x63, 0x65, - 0x52, 0x61, 0x6e, 0x67, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x70, 0x72, 0x69, - 0x63, 0x65, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x67, 0x6f, 0x6f, 0x64, 0x73, - 0x49, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x67, 0x6f, 0x6f, 0x64, 0x73, 0x49, - 0x64, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x6b, 0x75, 0x49, 0x64, 0x18, 0x10, 0x20, 0x01, 0x28, 0x03, + 0x76, 0x65, 0x6c, 0x50, 0x72, 0x69, 0x63, 0x65, 0x73, 0x12, 0x24, 0x0a, 0x0d, 0x73, 0x61, 0x66, + 0x65, 0x67, 0x75, 0x61, 0x72, 0x64, 0x46, 0x6c, 0x61, 0x67, 0x18, 0x1a, 0x20, 0x01, 0x28, 0x05, + 0x52, 0x0d, 0x73, 0x61, 0x66, 0x65, 0x67, 0x75, 0x61, 0x72, 0x64, 0x46, 0x6c, 0x61, 0x67, 0x22, + 0xc8, 0x07, 0x0a, 0x11, 0x53, 0x49, 0x74, 0x65, 0x6d, 0x44, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x1c, 0x0a, + 0x09, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x09, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x76, + 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x76, + 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x68, 0x6f, 0x70, 0x49, + 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x73, 0x68, 0x6f, 0x70, 0x49, 0x64, 0x12, + 0x1e, 0x0a, 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x18, 0x05, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x12, + 0x14, 0x0a, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, + 0x74, 0x69, 0x74, 0x6c, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x73, 0x68, 0x6f, 0x72, 0x74, 0x54, 0x69, + 0x74, 0x6c, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x73, 0x68, 0x6f, 0x72, 0x74, + 0x54, 0x69, 0x74, 0x6c, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x69, 0x6e, 0x74, 0x72, 0x6f, 0x56, 0x69, + 0x64, 0x65, 0x6f, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x69, 0x6e, 0x74, 0x72, 0x6f, + 0x56, 0x69, 0x64, 0x65, 0x6f, 0x12, 0x18, 0x0a, 0x07, 0x67, 0x6f, 0x6f, 0x64, 0x73, 0x4e, 0x6f, + 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x67, 0x6f, 0x6f, 0x64, 0x73, 0x4e, 0x6f, 0x12, + 0x1c, 0x0a, 0x09, 0x74, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x18, 0x0a, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x09, 0x74, 0x68, 0x75, 0x6d, 0x62, 0x6e, 0x61, 0x69, 0x6c, 0x12, 0x16, 0x0a, + 0x06, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x73, 0x18, 0x0b, 0x20, 0x03, 0x28, 0x09, 0x52, 0x06, 0x69, + 0x6d, 0x61, 0x67, 0x65, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x73, 0x74, 0x18, 0x0c, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x04, 0x63, 0x6f, 0x73, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x6f, 0x72, 0x69, + 0x67, 0x69, 0x6e, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, + 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x70, + 0x72, 0x69, 0x63, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x70, 0x72, 0x69, 0x63, + 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x70, 0x72, 0x69, 0x63, 0x65, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x18, + 0x0f, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x70, 0x72, 0x69, 0x63, 0x65, 0x52, 0x61, 0x6e, 0x67, + 0x65, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x6b, 0x75, 0x49, 0x64, 0x18, 0x10, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x73, 0x6b, 0x75, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x69, 0x74, 0x65, 0x6d, 0x46, - 0x6c, 0x61, 0x67, 0x18, 0x12, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x69, 0x74, 0x65, 0x6d, 0x46, + 0x6c, 0x61, 0x67, 0x18, 0x11, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x69, 0x74, 0x65, 0x6d, 0x46, 0x6c, 0x61, 0x67, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x74, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, - 0x13, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x73, 0x74, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x12, - 0x18, 0x0a, 0x07, 0x73, 0x61, 0x6c, 0x65, 0x4e, 0x75, 0x6d, 0x18, 0x14, 0x20, 0x01, 0x28, 0x05, - 0x52, 0x07, 0x73, 0x61, 0x6c, 0x65, 0x4e, 0x75, 0x6d, 0x12, 0x2a, 0x0a, 0x08, 0x66, 0x6c, 0x61, - 0x67, 0x44, 0x61, 0x74, 0x61, 0x18, 0x15, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x53, 0x49, - 0x74, 0x65, 0x6d, 0x46, 0x6c, 0x61, 0x67, 0x44, 0x61, 0x74, 0x61, 0x52, 0x08, 0x66, 0x6c, 0x61, - 0x67, 0x44, 0x61, 0x74, 0x61, 0x12, 0x18, 0x0a, 0x07, 0x62, 0x72, 0x61, 0x6e, 0x64, 0x49, 0x64, - 0x18, 0x16, 0x20, 0x01, 0x28, 0x12, 0x52, 0x07, 0x62, 0x72, 0x61, 0x6e, 0x64, 0x49, 0x64, 0x12, - 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x17, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, - 0x6f, 0x64, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x65, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x69, - 0x64, 0x18, 0x18, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x65, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, - 0x54, 0x69, 0x64, 0x12, 0x20, 0x0a, 0x0b, 0x73, 0x68, 0x65, 0x6c, 0x76, 0x65, 0x53, 0x74, 0x61, - 0x74, 0x65, 0x18, 0x19, 0x20, 0x01, 0x28, 0x11, 0x52, 0x0b, 0x73, 0x68, 0x65, 0x6c, 0x76, 0x65, - 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x20, 0x0a, 0x0b, 0x72, 0x65, 0x76, 0x69, 0x65, 0x77, 0x53, - 0x74, 0x61, 0x74, 0x65, 0x18, 0x1a, 0x20, 0x01, 0x28, 0x11, 0x52, 0x0b, 0x72, 0x65, 0x76, 0x69, - 0x65, 0x77, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, - 0x65, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x1b, 0x20, 0x01, 0x28, 0x12, 0x52, 0x0a, 0x75, 0x70, 0x64, - 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x21, 0x0a, 0x08, 0x73, 0x6b, 0x75, 0x41, 0x72, - 0x72, 0x61, 0x79, 0x18, 0x1c, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x05, 0x2e, 0x53, 0x53, 0x6b, 0x75, - 0x52, 0x08, 0x73, 0x6b, 0x75, 0x41, 0x72, 0x72, 0x61, 0x79, 0x12, 0x2e, 0x0a, 0x0b, 0x6c, 0x65, - 0x76, 0x65, 0x6c, 0x50, 0x72, 0x69, 0x63, 0x65, 0x73, 0x18, 0x1d, 0x20, 0x03, 0x28, 0x0b, 0x32, - 0x0c, 0x2e, 0x53, 0x4c, 0x65, 0x76, 0x65, 0x6c, 0x50, 0x72, 0x69, 0x63, 0x65, 0x52, 0x0b, 0x6c, - 0x65, 0x76, 0x65, 0x6c, 0x50, 0x72, 0x69, 0x63, 0x65, 0x73, 0x12, 0x2a, 0x0a, 0x08, 0x76, 0x69, - 0x65, 0x77, 0x44, 0x61, 0x74, 0x61, 0x18, 0x1e, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x53, - 0x49, 0x74, 0x65, 0x6d, 0x56, 0x69, 0x65, 0x77, 0x44, 0x61, 0x74, 0x61, 0x52, 0x08, 0x76, 0x69, - 0x65, 0x77, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2f, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x1f, - 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x53, 0x55, 0x6e, 0x69, 0x66, 0x69, 0x65, 0x64, 0x56, - 0x69, 0x65, 0x77, 0x49, 0x74, 0x65, 0x6d, 0x2e, 0x44, 0x61, 0x74, 0x61, 0x45, 0x6e, 0x74, 0x72, - 0x79, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x1a, 0x37, 0x0a, 0x09, 0x44, 0x61, 0x74, 0x61, 0x45, - 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, - 0x22, 0x8d, 0x01, 0x0a, 0x0d, 0x53, 0x49, 0x74, 0x65, 0x6d, 0x56, 0x69, 0x65, 0x77, 0x44, 0x61, - 0x74, 0x61, 0x12, 0x18, 0x0a, 0x07, 0x64, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x73, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x07, 0x64, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x73, 0x12, 0x16, 0x0a, 0x06, - 0x74, 0x68, 0x75, 0x6d, 0x62, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x06, 0x74, 0x68, - 0x75, 0x6d, 0x62, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x73, 0x18, 0x03, - 0x20, 0x03, 0x28, 0x09, 0x52, 0x06, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, - 0x73, 0x6b, 0x75, 0x48, 0x74, 0x6d, 0x6c, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x73, - 0x6b, 0x75, 0x48, 0x74, 0x6d, 0x6c, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x6b, 0x75, 0x4a, 0x73, 0x6f, - 0x6e, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x73, 0x6b, 0x75, 0x4a, 0x73, 0x6f, 0x6e, - 0x22, 0x78, 0x0a, 0x10, 0x53, 0x61, 0x76, 0x65, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x65, 0x72, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x11, 0x52, 0x07, 0x65, 0x72, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x16, - 0x0a, 0x06, 0x65, 0x72, 0x72, 0x4d, 0x73, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, - 0x65, 0x72, 0x72, 0x4d, 0x73, 0x67, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x1a, - 0x0a, 0x08, 0x69, 0x74, 0x65, 0x6d, 0x46, 0x6c, 0x61, 0x67, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, - 0x52, 0x08, 0x69, 0x74, 0x65, 0x6d, 0x46, 0x6c, 0x61, 0x67, 0x22, 0x3a, 0x0a, 0x15, 0x49, 0x74, - 0x65, 0x6d, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x12, 0x21, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x03, - 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x53, 0x49, 0x74, 0x65, 0x6d, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x52, - 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x84, 0x01, 0x0a, 0x0a, 0x53, 0x49, 0x74, 0x65, 0x6d, - 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x05, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x74, 0x61, 0x67, - 0x43, 0x6f, 0x64, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x74, 0x61, 0x67, 0x43, - 0x6f, 0x64, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x49, 0x6d, 0x61, 0x67, - 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x49, 0x6d, - 0x61, 0x67, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x22, 0x9b, 0x01, - 0x0a, 0x19, 0x47, 0x65, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x41, 0x6e, 0x64, 0x53, 0x6e, 0x61, 0x70, - 0x73, 0x68, 0x6f, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x69, - 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, - 0x6d, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x08, 0x73, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x12, - 0x24, 0x0a, 0x0d, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x53, 0x6b, 0x75, 0x48, 0x74, 0x6d, 0x6c, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0d, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x53, 0x6b, - 0x75, 0x48, 0x74, 0x6d, 0x6c, 0x12, 0x24, 0x0a, 0x0d, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x53, - 0x6b, 0x75, 0x4a, 0x73, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0d, 0x72, 0x65, - 0x74, 0x75, 0x72, 0x6e, 0x53, 0x6b, 0x75, 0x4a, 0x73, 0x6f, 0x6e, 0x22, 0xf0, 0x06, 0x0a, 0x14, - 0x49, 0x74, 0x65, 0x6d, 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, - 0x63, 0x6f, 0x64, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, - 0x12, 0x1c, 0x0a, 0x09, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, 0x64, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x09, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, 0x64, 0x12, 0x1e, - 0x0a, 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x18, 0x04, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x12, 0x1a, - 0x0a, 0x08, 0x76, 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x49, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x08, 0x76, 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x68, - 0x6f, 0x70, 0x49, 0x64, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x73, 0x68, 0x6f, 0x70, - 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x62, 0x72, 0x61, 0x6e, 0x64, 0x49, 0x64, 0x18, 0x06, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x07, 0x62, 0x72, 0x61, 0x6e, 0x64, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, - 0x73, 0x68, 0x6f, 0x70, 0x43, 0x61, 0x74, 0x49, 0x64, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x09, 0x73, 0x68, 0x6f, 0x70, 0x43, 0x61, 0x74, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x65, 0x78, - 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x69, 0x64, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, - 0x65, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x69, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x69, - 0x74, 0x6c, 0x65, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, - 0x12, 0x1e, 0x0a, 0x0a, 0x73, 0x68, 0x6f, 0x72, 0x74, 0x54, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x0c, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x73, 0x68, 0x6f, 0x72, 0x74, 0x54, 0x69, 0x74, 0x6c, 0x65, - 0x12, 0x20, 0x0a, 0x0b, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x18, - 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x43, 0x6f, - 0x64, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x73, 0x18, 0x0e, 0x20, 0x03, - 0x28, 0x09, 0x52, 0x06, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x73, 0x12, 0x1e, 0x0a, 0x0a, 0x70, 0x72, - 0x69, 0x63, 0x65, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, - 0x70, 0x72, 0x69, 0x63, 0x65, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x6b, - 0x75, 0x49, 0x64, 0x18, 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x73, 0x6b, 0x75, 0x49, 0x64, - 0x12, 0x14, 0x0a, 0x05, 0x70, 0x72, 0x69, 0x63, 0x65, 0x18, 0x12, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x05, 0x70, 0x72, 0x69, 0x63, 0x65, 0x12, 0x20, 0x0a, 0x0b, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, - 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x13, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x6f, 0x72, 0x69, - 0x67, 0x69, 0x6e, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x74, 0x6f, 0x63, - 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x14, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x73, 0x74, 0x6f, 0x63, - 0x6b, 0x4e, 0x75, 0x6d, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x61, 0x6c, 0x65, 0x4e, 0x75, 0x6d, 0x18, - 0x15, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x73, 0x61, 0x6c, 0x65, 0x4e, 0x75, 0x6d, 0x12, 0x20, - 0x0a, 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x16, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, - 0x12, 0x29, 0x0a, 0x09, 0x61, 0x74, 0x74, 0x72, 0x41, 0x72, 0x72, 0x61, 0x79, 0x18, 0x17, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x53, 0x41, 0x74, 0x74, 0x72, 0x56, 0x61, 0x6c, 0x75, 0x65, - 0x52, 0x09, 0x61, 0x74, 0x74, 0x72, 0x41, 0x72, 0x72, 0x61, 0x79, 0x12, 0x21, 0x0a, 0x08, 0x73, - 0x6b, 0x75, 0x41, 0x72, 0x72, 0x61, 0x79, 0x18, 0x18, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x05, 0x2e, - 0x53, 0x53, 0x6b, 0x75, 0x52, 0x08, 0x73, 0x6b, 0x75, 0x41, 0x72, 0x72, 0x61, 0x79, 0x12, 0x2e, - 0x0a, 0x0b, 0x73, 0x70, 0x65, 0x63, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x19, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x53, 0x53, 0x70, 0x65, 0x63, 0x4f, 0x70, 0x74, 0x69, 0x6f, - 0x6e, 0x52, 0x0b, 0x73, 0x70, 0x65, 0x63, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x18, - 0x0a, 0x07, 0x73, 0x6b, 0x75, 0x4a, 0x73, 0x6f, 0x6e, 0x18, 0x1a, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x07, 0x73, 0x6b, 0x75, 0x4a, 0x73, 0x6f, 0x6e, 0x12, 0x2a, 0x0a, 0x08, 0x66, 0x6c, 0x61, 0x67, - 0x44, 0x61, 0x74, 0x61, 0x18, 0x1b, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x53, 0x49, 0x74, + 0x12, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x73, 0x74, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x12, + 0x18, 0x0a, 0x07, 0x73, 0x61, 0x6c, 0x65, 0x4e, 0x75, 0x6d, 0x18, 0x13, 0x20, 0x01, 0x28, 0x05, + 0x52, 0x07, 0x73, 0x61, 0x6c, 0x65, 0x4e, 0x75, 0x6d, 0x12, 0x20, 0x0a, 0x0b, 0x73, 0x68, 0x65, + 0x6c, 0x76, 0x65, 0x53, 0x74, 0x61, 0x74, 0x65, 0x18, 0x14, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0b, + 0x73, 0x68, 0x65, 0x6c, 0x76, 0x65, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x20, 0x0a, 0x0b, 0x72, + 0x65, 0x76, 0x69, 0x65, 0x77, 0x53, 0x74, 0x61, 0x74, 0x65, 0x18, 0x15, 0x20, 0x01, 0x28, 0x05, + 0x52, 0x0b, 0x72, 0x65, 0x76, 0x69, 0x65, 0x77, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x22, 0x0a, + 0x0c, 0x72, 0x65, 0x76, 0x69, 0x65, 0x77, 0x52, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x18, 0x16, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0c, 0x72, 0x65, 0x76, 0x69, 0x65, 0x77, 0x52, 0x65, 0x6d, 0x61, 0x72, + 0x6b, 0x12, 0x18, 0x0a, 0x07, 0x62, 0x72, 0x61, 0x6e, 0x64, 0x49, 0x64, 0x18, 0x17, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x07, 0x62, 0x72, 0x61, 0x6e, 0x64, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x63, + 0x6f, 0x64, 0x65, 0x18, 0x18, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, + 0x1e, 0x0a, 0x0a, 0x65, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x69, 0x64, 0x18, 0x19, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x0a, 0x65, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x69, 0x64, 0x12, + 0x24, 0x0a, 0x09, 0x61, 0x74, 0x74, 0x72, 0x41, 0x72, 0x72, 0x61, 0x79, 0x18, 0x1a, 0x20, 0x03, + 0x28, 0x0b, 0x32, 0x06, 0x2e, 0x53, 0x41, 0x74, 0x74, 0x72, 0x52, 0x09, 0x61, 0x74, 0x74, 0x72, + 0x41, 0x72, 0x72, 0x61, 0x79, 0x12, 0x21, 0x0a, 0x08, 0x73, 0x6b, 0x75, 0x41, 0x72, 0x72, 0x61, + 0x79, 0x18, 0x1b, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x05, 0x2e, 0x53, 0x53, 0x6b, 0x75, 0x52, 0x08, + 0x73, 0x6b, 0x75, 0x41, 0x72, 0x72, 0x61, 0x79, 0x12, 0x2e, 0x0a, 0x0b, 0x73, 0x70, 0x65, 0x63, + 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x1c, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0c, 0x2e, + 0x53, 0x53, 0x70, 0x65, 0x63, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0b, 0x73, 0x70, 0x65, + 0x63, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x2a, 0x0a, 0x08, 0x66, 0x6c, 0x61, 0x67, + 0x44, 0x61, 0x74, 0x61, 0x18, 0x1d, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x53, 0x49, 0x74, 0x65, 0x6d, 0x46, 0x6c, 0x61, 0x67, 0x44, 0x61, 0x74, 0x61, 0x52, 0x08, 0x66, 0x6c, 0x61, 0x67, 0x44, 0x61, 0x74, 0x61, 0x12, 0x2e, 0x0a, 0x0b, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x50, 0x72, 0x69, - 0x63, 0x65, 0x73, 0x18, 0x1c, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x53, 0x4c, 0x65, 0x76, + 0x63, 0x65, 0x73, 0x18, 0x1e, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x53, 0x4c, 0x65, 0x76, 0x65, 0x6c, 0x50, 0x72, 0x69, 0x63, 0x65, 0x52, 0x0b, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x50, 0x72, - 0x69, 0x63, 0x65, 0x73, 0x12, 0x1e, 0x0a, 0x0a, 0x69, 0x6e, 0x74, 0x72, 0x6f, 0x56, 0x69, 0x64, - 0x65, 0x6f, 0x18, 0x1d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x69, 0x6e, 0x74, 0x72, 0x6f, 0x56, - 0x69, 0x64, 0x65, 0x6f, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x6b, 0x75, 0x48, 0x74, 0x6d, 0x6c, 0x18, - 0x1e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x73, 0x6b, 0x75, 0x48, 0x74, 0x6d, 0x6c, 0x22, 0x5e, - 0x0a, 0x0a, 0x53, 0x41, 0x74, 0x74, 0x72, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x16, 0x0a, 0x06, - 0x61, 0x74, 0x74, 0x72, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x61, 0x74, - 0x74, 0x72, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x61, 0x74, 0x74, 0x72, 0x4e, 0x61, 0x6d, 0x65, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x61, 0x74, 0x74, 0x72, 0x4e, 0x61, 0x6d, 0x65, - 0x12, 0x1c, 0x0a, 0x09, 0x61, 0x74, 0x74, 0x72, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x04, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x74, 0x74, 0x72, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x49, - 0x0a, 0x0b, 0x53, 0x53, 0x70, 0x65, 0x63, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, - 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, - 0x65, 0x12, 0x26, 0x0a, 0x05, 0x69, 0x74, 0x65, 0x6d, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, - 0x32, 0x10, 0x2e, 0x53, 0x53, 0x70, 0x65, 0x63, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x74, - 0x65, 0x6d, 0x52, 0x05, 0x69, 0x74, 0x65, 0x6d, 0x73, 0x22, 0x53, 0x0a, 0x0f, 0x53, 0x53, 0x70, - 0x65, 0x63, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x14, 0x0a, 0x05, - 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x6c, 0x61, 0x62, - 0x65, 0x6c, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x63, 0x6f, 0x6c, 0x6f, - 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x63, 0x6f, 0x6c, 0x6f, 0x72, 0x22, 0xc2, - 0x02, 0x0a, 0x0e, 0x53, 0x54, 0x72, 0x61, 0x64, 0x65, 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, - 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, - 0x64, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x6b, 0x75, - 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x73, 0x6b, 0x75, 0x49, 0x64, 0x12, - 0x20, 0x0a, 0x0b, 0x73, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x4b, 0x65, 0x79, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x73, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x4b, 0x65, - 0x79, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x65, 0x6c, 0x6c, 0x65, 0x72, 0x49, 0x64, 0x18, 0x05, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x08, 0x73, 0x65, 0x6c, 0x6c, 0x65, 0x72, 0x49, 0x64, 0x12, 0x1e, 0x0a, - 0x0a, 0x73, 0x65, 0x6c, 0x6c, 0x65, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0a, 0x73, 0x65, 0x6c, 0x6c, 0x65, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x14, 0x0a, - 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x69, - 0x74, 0x6c, 0x65, 0x12, 0x20, 0x0a, 0x0b, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x43, 0x6f, - 0x64, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, - 0x74, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x73, 0x6b, 0x75, 0x18, 0x09, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x03, 0x73, 0x6b, 0x75, 0x12, 0x14, 0x0a, 0x05, 0x69, 0x6d, 0x61, 0x67, 0x65, - 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x12, 0x14, 0x0a, - 0x05, 0x70, 0x72, 0x69, 0x63, 0x65, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x70, 0x72, - 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, - 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, - 0x69, 0x6d, 0x65, 0x22, 0x81, 0x01, 0x0a, 0x0b, 0x53, 0x4c, 0x65, 0x76, 0x65, 0x6c, 0x50, 0x72, - 0x69, 0x63, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x02, 0x69, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x05, 0x52, 0x05, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x12, 0x14, 0x0a, 0x05, 0x70, 0x72, 0x69, - 0x63, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x70, 0x72, 0x69, 0x63, 0x65, 0x12, - 0x1c, 0x0a, 0x09, 0x6d, 0x61, 0x78, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x04, 0x20, 0x01, - 0x28, 0x05, 0x52, 0x09, 0x6d, 0x61, 0x78, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x18, 0x0a, - 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, - 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x22, 0x5c, 0x0a, 0x10, 0x49, 0x74, 0x65, 0x6d, 0x42, - 0x79, 0x53, 0x6b, 0x75, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x70, - 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, - 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x6b, 0x75, - 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x73, 0x6b, 0x75, 0x49, 0x64, 0x12, - 0x14, 0x0a, 0x05, 0x65, 0x78, 0x74, 0x72, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, 0x05, - 0x65, 0x78, 0x74, 0x72, 0x61, 0x22, 0x44, 0x0a, 0x12, 0x49, 0x74, 0x65, 0x6d, 0x49, 0x6c, 0x6c, - 0x65, 0x67, 0x61, 0x6c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x69, - 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, - 0x6d, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x06, 0x72, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x22, 0x64, 0x0a, 0x12, 0x52, - 0x65, 0x63, 0x79, 0x63, 0x6c, 0x65, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x12, 0x16, 0x0a, 0x06, 0x49, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x06, 0x49, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x52, 0x65, 0x63, - 0x79, 0x63, 0x6c, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x52, 0x65, 0x63, 0x79, - 0x63, 0x6c, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x49, 0x73, 0x44, 0x65, 0x73, 0x74, 0x6f, 0x72, 0x79, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x49, 0x73, 0x44, 0x65, 0x73, 0x74, 0x6f, 0x72, - 0x79, 0x22, 0x57, 0x0a, 0x11, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x65, 0x76, 0x69, 0x65, 0x77, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x12, - 0x0a, 0x04, 0x70, 0x61, 0x73, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x04, 0x70, 0x61, - 0x73, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x06, 0x72, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x22, 0x53, 0x0a, 0x15, 0x53, 0x61, - 0x76, 0x65, 0x4c, 0x65, 0x76, 0x65, 0x6c, 0x50, 0x72, 0x69, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x22, 0x0a, 0x05, 0x76, - 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x53, 0x4c, 0x65, - 0x76, 0x65, 0x6c, 0x50, 0x72, 0x69, 0x63, 0x65, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, - 0x8d, 0x01, 0x0a, 0x12, 0x53, 0x68, 0x65, 0x6c, 0x76, 0x65, 0x53, 0x74, 0x61, 0x74, 0x65, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x2b, 0x0a, 0x08, 0x69, 0x74, 0x65, 0x6d, 0x54, 0x79, - 0x70, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x0f, 0x2e, 0x45, 0x49, 0x74, 0x65, 0x6d, - 0x53, 0x61, 0x6c, 0x65, 0x73, 0x54, 0x79, 0x70, 0x65, 0x52, 0x08, 0x69, 0x74, 0x65, 0x6d, 0x54, - 0x79, 0x70, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x73, - 0x68, 0x65, 0x6c, 0x76, 0x65, 0x4f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, 0x08, 0x73, - 0x68, 0x65, 0x6c, 0x76, 0x65, 0x4f, 0x6e, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x65, 0x6d, 0x61, 0x72, - 0x6b, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x72, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x22, - 0x3d, 0x0a, 0x17, 0x53, 0x57, 0x73, 0x53, 0x6b, 0x75, 0x50, 0x72, 0x69, 0x63, 0x65, 0x4c, 0x69, - 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x22, 0x0a, 0x05, 0x76, 0x61, - 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x53, 0x57, 0x73, 0x53, - 0x6b, 0x75, 0x50, 0x72, 0x69, 0x63, 0x65, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x68, - 0x0a, 0x14, 0x53, 0x61, 0x76, 0x65, 0x53, 0x6b, 0x75, 0x50, 0x72, 0x69, 0x63, 0x65, 0x73, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x14, - 0x0a, 0x05, 0x73, 0x6b, 0x75, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x73, - 0x6b, 0x75, 0x49, 0x64, 0x12, 0x22, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x03, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x53, 0x57, 0x73, 0x53, 0x6b, 0x75, 0x50, 0x72, 0x69, 0x63, - 0x65, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x65, 0x0a, 0x0b, 0x53, 0x57, 0x73, 0x53, - 0x6b, 0x75, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x72, 0x65, 0x71, 0x75, 0x69, - 0x72, 0x65, 0x4e, 0x75, 0x6d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x72, 0x65, 0x71, - 0x75, 0x69, 0x72, 0x65, 0x4e, 0x75, 0x6d, 0x12, 0x26, 0x0a, 0x0e, 0x77, 0x68, 0x6f, 0x6c, 0x65, - 0x73, 0x61, 0x6c, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x0e, 0x77, 0x68, 0x6f, 0x6c, 0x65, 0x73, 0x61, 0x6c, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x22, - 0x45, 0x0a, 0x1b, 0x53, 0x57, 0x73, 0x49, 0x74, 0x65, 0x6d, 0x44, 0x69, 0x73, 0x63, 0x6f, 0x75, - 0x6e, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x26, - 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x10, 0x2e, - 0x53, 0x57, 0x73, 0x49, 0x74, 0x65, 0x6d, 0x44, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, - 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x48, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x57, 0x73, 0x44, - 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, - 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, - 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, - 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, - 0x22, 0x73, 0x0a, 0x17, 0x53, 0x61, 0x76, 0x65, 0x49, 0x74, 0x65, 0x6d, 0x44, 0x69, 0x73, 0x63, - 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x69, - 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, - 0x6d, 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x12, 0x26, 0x0a, - 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x10, 0x2e, 0x53, - 0x57, 0x73, 0x49, 0x74, 0x65, 0x6d, 0x44, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x05, - 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x8f, 0x01, 0x0a, 0x0f, 0x53, 0x57, 0x73, 0x49, 0x74, 0x65, - 0x6d, 0x44, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x22, 0x0a, 0x0c, 0x62, 0x75, 0x79, - 0x65, 0x72, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x0c, 0x62, 0x75, 0x79, 0x65, 0x72, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x12, 0x24, 0x0a, - 0x0d, 0x72, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x72, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x41, 0x6d, 0x6f, - 0x75, 0x6e, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x64, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, - 0x61, 0x74, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x64, 0x69, 0x73, 0x63, 0x6f, - 0x75, 0x6e, 0x74, 0x52, 0x61, 0x74, 0x65, 0x2a, 0x31, 0x0a, 0x0e, 0x45, 0x49, 0x74, 0x65, 0x6d, - 0x53, 0x61, 0x6c, 0x65, 0x73, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0d, 0x0a, 0x09, 0x49, 0x54, 0x5f, - 0x4e, 0x4f, 0x52, 0x4d, 0x41, 0x4c, 0x10, 0x00, 0x12, 0x10, 0x0a, 0x0c, 0x49, 0x54, 0x5f, 0x57, - 0x48, 0x4f, 0x4c, 0x45, 0x53, 0x41, 0x4c, 0x45, 0x10, 0x01, 0x2a, 0xa5, 0x01, 0x0a, 0x09, 0x45, - 0x49, 0x74, 0x65, 0x6d, 0x46, 0x6c, 0x61, 0x67, 0x12, 0x0e, 0x0a, 0x0a, 0x5f, 0x45, 0x49, 0x74, - 0x65, 0x6d, 0x46, 0x6c, 0x61, 0x67, 0x10, 0x00, 0x12, 0x0d, 0x0a, 0x09, 0x53, 0x65, 0x6c, 0x66, - 0x53, 0x61, 0x6c, 0x65, 0x73, 0x10, 0x01, 0x12, 0x10, 0x0a, 0x0c, 0x46, 0x72, 0x65, 0x65, 0x44, - 0x65, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x79, 0x10, 0x02, 0x12, 0x0d, 0x0a, 0x09, 0x52, 0x65, 0x63, - 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x64, 0x10, 0x04, 0x12, 0x0c, 0x0a, 0x08, 0x45, 0x78, 0x63, 0x68, - 0x61, 0x6e, 0x67, 0x65, 0x10, 0x08, 0x12, 0x08, 0x0a, 0x04, 0x47, 0x69, 0x66, 0x74, 0x10, 0x10, - 0x12, 0x0d, 0x0a, 0x09, 0x41, 0x66, 0x66, 0x69, 0x6c, 0x69, 0x61, 0x74, 0x65, 0x10, 0x20, 0x12, - 0x0f, 0x0a, 0x0b, 0x4e, 0x65, 0x77, 0x4f, 0x6e, 0x53, 0x68, 0x65, 0x6c, 0x76, 0x65, 0x10, 0x40, - 0x12, 0x0d, 0x0a, 0x08, 0x48, 0x6f, 0x74, 0x53, 0x61, 0x6c, 0x65, 0x73, 0x10, 0x80, 0x01, 0x12, - 0x11, 0x0a, 0x0c, 0x53, 0x65, 0x6c, 0x66, 0x44, 0x65, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x79, 0x10, - 0x80, 0x02, 0x42, 0x1f, 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, - 0x2e, 0x67, 0x6f, 0x32, 0x6f, 0x2e, 0x72, 0x70, 0x63, 0x5a, 0x08, 0x2e, 0x2f, 0x3b, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x69, 0x63, 0x65, 0x73, 0x12, 0x24, 0x0a, 0x0d, 0x73, 0x61, 0x66, 0x65, 0x67, 0x75, 0x61, 0x72, + 0x64, 0x46, 0x6c, 0x61, 0x67, 0x18, 0x1f, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0d, 0x73, 0x61, 0x66, + 0x65, 0x67, 0x75, 0x61, 0x72, 0x64, 0x46, 0x6c, 0x61, 0x67, 0x22, 0xc3, 0x02, 0x0a, 0x0d, 0x53, + 0x49, 0x74, 0x65, 0x6d, 0x46, 0x6c, 0x61, 0x67, 0x44, 0x61, 0x74, 0x61, 0x12, 0x24, 0x0a, 0x0d, + 0x69, 0x73, 0x4e, 0x65, 0x77, 0x4f, 0x6e, 0x53, 0x68, 0x65, 0x6c, 0x76, 0x65, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x08, 0x52, 0x0d, 0x69, 0x73, 0x4e, 0x65, 0x77, 0x4f, 0x6e, 0x53, 0x68, 0x65, 0x6c, + 0x76, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x69, 0x73, 0x48, 0x6f, 0x74, 0x53, 0x61, 0x6c, 0x65, 0x73, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0a, 0x69, 0x73, 0x48, 0x6f, 0x74, 0x53, 0x61, 0x6c, + 0x65, 0x73, 0x12, 0x20, 0x0a, 0x0b, 0x69, 0x73, 0x52, 0x65, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, + 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0b, 0x69, 0x73, 0x52, 0x65, 0x63, 0x6f, 0x6d, + 0x6d, 0x65, 0x6e, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x69, 0x73, 0x45, 0x78, 0x63, 0x68, 0x61, 0x6e, + 0x67, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0a, 0x69, 0x73, 0x45, 0x78, 0x63, 0x68, + 0x61, 0x6e, 0x67, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x73, 0x47, 0x69, 0x66, 0x74, 0x18, 0x05, + 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x69, 0x73, 0x47, 0x69, 0x66, 0x74, 0x12, 0x20, 0x0a, 0x0b, + 0x69, 0x73, 0x41, 0x66, 0x66, 0x69, 0x6c, 0x69, 0x61, 0x74, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, + 0x08, 0x52, 0x0b, 0x69, 0x73, 0x41, 0x66, 0x66, 0x69, 0x6c, 0x69, 0x61, 0x74, 0x65, 0x12, 0x20, + 0x0a, 0x0b, 0x69, 0x73, 0x53, 0x65, 0x6c, 0x66, 0x53, 0x61, 0x6c, 0x65, 0x73, 0x18, 0x07, 0x20, + 0x01, 0x28, 0x08, 0x52, 0x0b, 0x69, 0x73, 0x53, 0x65, 0x6c, 0x66, 0x53, 0x61, 0x6c, 0x65, 0x73, + 0x12, 0x26, 0x0a, 0x0e, 0x69, 0x73, 0x46, 0x72, 0x65, 0x65, 0x44, 0x65, 0x6c, 0x69, 0x76, 0x65, + 0x72, 0x79, 0x18, 0x08, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0e, 0x69, 0x73, 0x46, 0x72, 0x65, 0x65, + 0x44, 0x65, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x79, 0x12, 0x26, 0x0a, 0x0e, 0x69, 0x73, 0x53, 0x65, + 0x6c, 0x66, 0x44, 0x65, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x79, 0x18, 0x09, 0x20, 0x01, 0x28, 0x08, + 0x52, 0x0e, 0x69, 0x73, 0x53, 0x65, 0x6c, 0x66, 0x44, 0x65, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x79, + 0x22, 0xd9, 0x07, 0x0a, 0x10, 0x53, 0x55, 0x6e, 0x69, 0x66, 0x69, 0x65, 0x64, 0x56, 0x69, 0x65, + 0x77, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x1c, 0x0a, + 0x09, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x09, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x76, + 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x76, + 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x68, 0x6f, 0x70, 0x49, + 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x73, 0x68, 0x6f, 0x70, 0x49, 0x64, 0x12, + 0x1e, 0x0a, 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x18, 0x05, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x12, + 0x14, 0x0a, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, + 0x74, 0x69, 0x74, 0x6c, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x73, 0x68, 0x6f, 0x72, 0x74, 0x54, 0x69, + 0x74, 0x6c, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x73, 0x68, 0x6f, 0x72, 0x74, + 0x54, 0x69, 0x74, 0x6c, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x67, 0x6f, 0x6f, 0x64, 0x73, 0x4e, 0x6f, + 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x67, 0x6f, 0x6f, 0x64, 0x73, 0x4e, 0x6f, 0x12, + 0x14, 0x0a, 0x05, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, + 0x69, 0x6d, 0x61, 0x67, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x73, 0x18, + 0x0a, 0x20, 0x03, 0x28, 0x09, 0x52, 0x06, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x73, 0x12, 0x20, 0x0a, + 0x0b, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x0b, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x0b, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, + 0x14, 0x0a, 0x05, 0x70, 0x72, 0x69, 0x63, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, + 0x70, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x70, 0x72, 0x6f, 0x6d, 0x50, 0x72, 0x69, + 0x63, 0x65, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x70, 0x72, 0x6f, 0x6d, 0x50, 0x72, + 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x70, 0x72, 0x69, 0x63, 0x65, 0x52, 0x61, 0x6e, 0x67, + 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x70, 0x72, 0x69, 0x63, 0x65, 0x52, 0x61, + 0x6e, 0x67, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x67, 0x6f, 0x6f, 0x64, 0x73, 0x49, 0x64, 0x18, 0x0f, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x67, 0x6f, 0x6f, 0x64, 0x73, 0x49, 0x64, 0x12, 0x14, 0x0a, + 0x05, 0x73, 0x6b, 0x75, 0x49, 0x64, 0x18, 0x10, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x73, 0x6b, + 0x75, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x69, 0x74, 0x65, 0x6d, 0x46, 0x6c, 0x61, 0x67, 0x18, + 0x12, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x69, 0x74, 0x65, 0x6d, 0x46, 0x6c, 0x61, 0x67, 0x12, + 0x1a, 0x0a, 0x08, 0x73, 0x74, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x13, 0x20, 0x01, 0x28, + 0x05, 0x52, 0x08, 0x73, 0x74, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x12, 0x18, 0x0a, 0x07, 0x73, + 0x61, 0x6c, 0x65, 0x4e, 0x75, 0x6d, 0x18, 0x14, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x73, 0x61, + 0x6c, 0x65, 0x4e, 0x75, 0x6d, 0x12, 0x2a, 0x0a, 0x08, 0x66, 0x6c, 0x61, 0x67, 0x44, 0x61, 0x74, + 0x61, 0x18, 0x15, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x53, 0x49, 0x74, 0x65, 0x6d, 0x46, + 0x6c, 0x61, 0x67, 0x44, 0x61, 0x74, 0x61, 0x52, 0x08, 0x66, 0x6c, 0x61, 0x67, 0x44, 0x61, 0x74, + 0x61, 0x12, 0x18, 0x0a, 0x07, 0x62, 0x72, 0x61, 0x6e, 0x64, 0x49, 0x64, 0x18, 0x16, 0x20, 0x01, + 0x28, 0x12, 0x52, 0x07, 0x62, 0x72, 0x61, 0x6e, 0x64, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x63, + 0x6f, 0x64, 0x65, 0x18, 0x17, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, + 0x1e, 0x0a, 0x0a, 0x65, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x69, 0x64, 0x18, 0x18, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x0a, 0x65, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x69, 0x64, 0x12, + 0x20, 0x0a, 0x0b, 0x73, 0x68, 0x65, 0x6c, 0x76, 0x65, 0x53, 0x74, 0x61, 0x74, 0x65, 0x18, 0x19, + 0x20, 0x01, 0x28, 0x11, 0x52, 0x0b, 0x73, 0x68, 0x65, 0x6c, 0x76, 0x65, 0x53, 0x74, 0x61, 0x74, + 0x65, 0x12, 0x20, 0x0a, 0x0b, 0x72, 0x65, 0x76, 0x69, 0x65, 0x77, 0x53, 0x74, 0x61, 0x74, 0x65, + 0x18, 0x1a, 0x20, 0x01, 0x28, 0x11, 0x52, 0x0b, 0x72, 0x65, 0x76, 0x69, 0x65, 0x77, 0x53, 0x74, + 0x61, 0x74, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, + 0x65, 0x18, 0x1b, 0x20, 0x01, 0x28, 0x12, 0x52, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, + 0x69, 0x6d, 0x65, 0x12, 0x21, 0x0a, 0x08, 0x73, 0x6b, 0x75, 0x41, 0x72, 0x72, 0x61, 0x79, 0x18, + 0x1c, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x05, 0x2e, 0x53, 0x53, 0x6b, 0x75, 0x52, 0x08, 0x73, 0x6b, + 0x75, 0x41, 0x72, 0x72, 0x61, 0x79, 0x12, 0x2e, 0x0a, 0x0b, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x50, + 0x72, 0x69, 0x63, 0x65, 0x73, 0x18, 0x1d, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x53, 0x4c, + 0x65, 0x76, 0x65, 0x6c, 0x50, 0x72, 0x69, 0x63, 0x65, 0x52, 0x0b, 0x6c, 0x65, 0x76, 0x65, 0x6c, + 0x50, 0x72, 0x69, 0x63, 0x65, 0x73, 0x12, 0x2a, 0x0a, 0x08, 0x76, 0x69, 0x65, 0x77, 0x44, 0x61, + 0x74, 0x61, 0x18, 0x1e, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x53, 0x49, 0x74, 0x65, 0x6d, + 0x56, 0x69, 0x65, 0x77, 0x44, 0x61, 0x74, 0x61, 0x52, 0x08, 0x76, 0x69, 0x65, 0x77, 0x44, 0x61, + 0x74, 0x61, 0x12, 0x2f, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x1f, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x1b, 0x2e, 0x53, 0x55, 0x6e, 0x69, 0x66, 0x69, 0x65, 0x64, 0x56, 0x69, 0x65, 0x77, 0x49, + 0x74, 0x65, 0x6d, 0x2e, 0x44, 0x61, 0x74, 0x61, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x04, 0x64, + 0x61, 0x74, 0x61, 0x1a, 0x37, 0x0a, 0x09, 0x44, 0x61, 0x74, 0x61, 0x45, 0x6e, 0x74, 0x72, 0x79, + 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, + 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x8d, 0x01, 0x0a, + 0x0d, 0x53, 0x49, 0x74, 0x65, 0x6d, 0x56, 0x69, 0x65, 0x77, 0x44, 0x61, 0x74, 0x61, 0x12, 0x18, + 0x0a, 0x07, 0x64, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x07, 0x64, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x68, 0x75, 0x6d, + 0x62, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x06, 0x74, 0x68, 0x75, 0x6d, 0x62, 0x73, + 0x12, 0x16, 0x0a, 0x06, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x09, + 0x52, 0x06, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x6b, 0x75, 0x48, + 0x74, 0x6d, 0x6c, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x73, 0x6b, 0x75, 0x48, 0x74, + 0x6d, 0x6c, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x6b, 0x75, 0x4a, 0x73, 0x6f, 0x6e, 0x18, 0x05, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x07, 0x73, 0x6b, 0x75, 0x4a, 0x73, 0x6f, 0x6e, 0x22, 0x78, 0x0a, 0x10, + 0x53, 0x61, 0x76, 0x65, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x18, 0x0a, 0x07, 0x65, 0x72, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x11, 0x52, 0x07, 0x65, 0x72, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x65, 0x72, + 0x72, 0x4d, 0x73, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x65, 0x72, 0x72, 0x4d, + 0x73, 0x67, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x69, 0x74, + 0x65, 0x6d, 0x46, 0x6c, 0x61, 0x67, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x69, 0x74, + 0x65, 0x6d, 0x46, 0x6c, 0x61, 0x67, 0x22, 0x3a, 0x0a, 0x15, 0x49, 0x74, 0x65, 0x6d, 0x4c, 0x61, + 0x62, 0x65, 0x6c, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, + 0x21, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0b, + 0x2e, 0x53, 0x49, 0x74, 0x65, 0x6d, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x52, 0x05, 0x76, 0x61, 0x6c, + 0x75, 0x65, 0x22, 0x84, 0x01, 0x0a, 0x0a, 0x53, 0x49, 0x74, 0x65, 0x6d, 0x4c, 0x61, 0x62, 0x65, + 0x6c, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x02, 0x69, + 0x64, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x74, 0x61, 0x67, 0x43, 0x6f, 0x64, 0x65, + 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x74, 0x61, 0x67, 0x43, 0x6f, 0x64, 0x65, 0x12, + 0x1e, 0x0a, 0x0a, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x49, 0x6d, 0x61, 0x67, 0x65, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x49, 0x6d, 0x61, 0x67, 0x65, 0x12, + 0x18, 0x0a, 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, + 0x52, 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x22, 0x9b, 0x01, 0x0a, 0x19, 0x47, 0x65, + 0x74, 0x49, 0x74, 0x65, 0x6d, 0x41, 0x6e, 0x64, 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, + 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, + 0x1a, 0x0a, 0x08, 0x73, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x08, 0x52, 0x08, 0x73, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x12, 0x24, 0x0a, 0x0d, 0x72, + 0x65, 0x74, 0x75, 0x72, 0x6e, 0x53, 0x6b, 0x75, 0x48, 0x74, 0x6d, 0x6c, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x08, 0x52, 0x0d, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x53, 0x6b, 0x75, 0x48, 0x74, 0x6d, + 0x6c, 0x12, 0x24, 0x0a, 0x0d, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x53, 0x6b, 0x75, 0x4a, 0x73, + 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0d, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, + 0x53, 0x6b, 0x75, 0x4a, 0x73, 0x6f, 0x6e, 0x22, 0x96, 0x07, 0x0a, 0x14, 0x49, 0x74, 0x65, 0x6d, + 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x1c, 0x0a, 0x09, + 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x09, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x61, + 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, + 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x76, 0x65, + 0x6e, 0x64, 0x6f, 0x72, 0x49, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x76, 0x65, + 0x6e, 0x64, 0x6f, 0x72, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x68, 0x6f, 0x70, 0x49, 0x64, + 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x73, 0x68, 0x6f, 0x70, 0x49, 0x64, 0x12, 0x18, + 0x0a, 0x07, 0x62, 0x72, 0x61, 0x6e, 0x64, 0x49, 0x64, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x07, 0x62, 0x72, 0x61, 0x6e, 0x64, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x73, 0x68, 0x6f, 0x70, + 0x43, 0x61, 0x74, 0x49, 0x64, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x73, 0x68, 0x6f, + 0x70, 0x43, 0x61, 0x74, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x65, 0x78, 0x70, 0x72, 0x65, 0x73, + 0x73, 0x54, 0x69, 0x64, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x65, 0x78, 0x70, 0x72, + 0x65, 0x73, 0x73, 0x54, 0x69, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, + 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x12, 0x1e, 0x0a, 0x0a, + 0x73, 0x68, 0x6f, 0x72, 0x74, 0x54, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0a, 0x73, 0x68, 0x6f, 0x72, 0x74, 0x54, 0x69, 0x74, 0x6c, 0x65, 0x12, 0x20, 0x0a, 0x0b, + 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x0d, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0b, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x16, + 0x0a, 0x06, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x73, 0x18, 0x0e, 0x20, 0x03, 0x28, 0x09, 0x52, 0x06, + 0x69, 0x6d, 0x61, 0x67, 0x65, 0x73, 0x12, 0x1e, 0x0a, 0x0a, 0x70, 0x72, 0x69, 0x63, 0x65, 0x52, + 0x61, 0x6e, 0x67, 0x65, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x70, 0x72, 0x69, 0x63, + 0x65, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x6b, 0x75, 0x49, 0x64, 0x18, + 0x11, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x73, 0x6b, 0x75, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, + 0x70, 0x72, 0x69, 0x63, 0x65, 0x18, 0x12, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x70, 0x72, 0x69, + 0x63, 0x65, 0x12, 0x20, 0x0a, 0x0b, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x50, 0x72, 0x69, 0x63, + 0x65, 0x18, 0x13, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x50, + 0x72, 0x69, 0x63, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x74, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, + 0x18, 0x14, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x73, 0x74, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, + 0x12, 0x18, 0x0a, 0x07, 0x73, 0x61, 0x6c, 0x65, 0x4e, 0x75, 0x6d, 0x18, 0x15, 0x20, 0x01, 0x28, + 0x05, 0x52, 0x07, 0x73, 0x61, 0x6c, 0x65, 0x4e, 0x75, 0x6d, 0x12, 0x20, 0x0a, 0x0b, 0x64, 0x65, + 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x16, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x29, 0x0a, 0x09, + 0x61, 0x74, 0x74, 0x72, 0x41, 0x72, 0x72, 0x61, 0x79, 0x18, 0x17, 0x20, 0x03, 0x28, 0x0b, 0x32, + 0x0b, 0x2e, 0x53, 0x41, 0x74, 0x74, 0x72, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x52, 0x09, 0x61, 0x74, + 0x74, 0x72, 0x41, 0x72, 0x72, 0x61, 0x79, 0x12, 0x21, 0x0a, 0x08, 0x73, 0x6b, 0x75, 0x41, 0x72, + 0x72, 0x61, 0x79, 0x18, 0x18, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x05, 0x2e, 0x53, 0x53, 0x6b, 0x75, + 0x52, 0x08, 0x73, 0x6b, 0x75, 0x41, 0x72, 0x72, 0x61, 0x79, 0x12, 0x2e, 0x0a, 0x0b, 0x73, 0x70, + 0x65, 0x63, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x19, 0x20, 0x03, 0x28, 0x0b, 0x32, + 0x0c, 0x2e, 0x53, 0x53, 0x70, 0x65, 0x63, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0b, 0x73, + 0x70, 0x65, 0x63, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x6b, + 0x75, 0x4a, 0x73, 0x6f, 0x6e, 0x18, 0x1a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x73, 0x6b, 0x75, + 0x4a, 0x73, 0x6f, 0x6e, 0x12, 0x2a, 0x0a, 0x08, 0x66, 0x6c, 0x61, 0x67, 0x44, 0x61, 0x74, 0x61, + 0x18, 0x1b, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x53, 0x49, 0x74, 0x65, 0x6d, 0x46, 0x6c, + 0x61, 0x67, 0x44, 0x61, 0x74, 0x61, 0x52, 0x08, 0x66, 0x6c, 0x61, 0x67, 0x44, 0x61, 0x74, 0x61, + 0x12, 0x2e, 0x0a, 0x0b, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x50, 0x72, 0x69, 0x63, 0x65, 0x73, 0x18, + 0x1c, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x53, 0x4c, 0x65, 0x76, 0x65, 0x6c, 0x50, 0x72, + 0x69, 0x63, 0x65, 0x52, 0x0b, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x50, 0x72, 0x69, 0x63, 0x65, 0x73, + 0x12, 0x1e, 0x0a, 0x0a, 0x69, 0x6e, 0x74, 0x72, 0x6f, 0x56, 0x69, 0x64, 0x65, 0x6f, 0x18, 0x1d, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x69, 0x6e, 0x74, 0x72, 0x6f, 0x56, 0x69, 0x64, 0x65, 0x6f, + 0x12, 0x24, 0x0a, 0x0d, 0x73, 0x61, 0x66, 0x65, 0x67, 0x75, 0x61, 0x72, 0x64, 0x46, 0x6c, 0x61, + 0x67, 0x18, 0x1e, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0d, 0x73, 0x61, 0x66, 0x65, 0x67, 0x75, 0x61, + 0x72, 0x64, 0x46, 0x6c, 0x61, 0x67, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x6b, 0x75, 0x48, 0x74, 0x6d, + 0x6c, 0x18, 0x1f, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x73, 0x6b, 0x75, 0x48, 0x74, 0x6d, 0x6c, + 0x22, 0x5e, 0x0a, 0x0a, 0x53, 0x41, 0x74, 0x74, 0x72, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x16, + 0x0a, 0x06, 0x61, 0x74, 0x74, 0x72, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, + 0x61, 0x74, 0x74, 0x72, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x61, 0x74, 0x74, 0x72, 0x4e, 0x61, + 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x61, 0x74, 0x74, 0x72, 0x4e, 0x61, + 0x6d, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x61, 0x74, 0x74, 0x72, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x18, + 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x74, 0x74, 0x72, 0x56, 0x61, 0x6c, 0x75, 0x65, + 0x22, 0x49, 0x0a, 0x0b, 0x53, 0x53, 0x70, 0x65, 0x63, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x12, + 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, + 0x61, 0x6d, 0x65, 0x12, 0x26, 0x0a, 0x05, 0x69, 0x74, 0x65, 0x6d, 0x73, 0x18, 0x02, 0x20, 0x03, + 0x28, 0x0b, 0x32, 0x10, 0x2e, 0x53, 0x53, 0x70, 0x65, 0x63, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, + 0x49, 0x74, 0x65, 0x6d, 0x52, 0x05, 0x69, 0x74, 0x65, 0x6d, 0x73, 0x22, 0x53, 0x0a, 0x0f, 0x53, + 0x53, 0x70, 0x65, 0x63, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x14, + 0x0a, 0x05, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x6c, + 0x61, 0x62, 0x65, 0x6c, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x63, 0x6f, + 0x6c, 0x6f, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x63, 0x6f, 0x6c, 0x6f, 0x72, + 0x22, 0xc2, 0x02, 0x0a, 0x0e, 0x53, 0x54, 0x72, 0x61, 0x64, 0x65, 0x53, 0x6e, 0x61, 0x70, 0x73, + 0x68, 0x6f, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x02, 0x69, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x73, + 0x6b, 0x75, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x73, 0x6b, 0x75, 0x49, + 0x64, 0x12, 0x20, 0x0a, 0x0b, 0x73, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x4b, 0x65, 0x79, + 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x73, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, + 0x4b, 0x65, 0x79, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x65, 0x6c, 0x6c, 0x65, 0x72, 0x49, 0x64, 0x18, + 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x73, 0x65, 0x6c, 0x6c, 0x65, 0x72, 0x49, 0x64, 0x12, + 0x1e, 0x0a, 0x0a, 0x73, 0x65, 0x6c, 0x6c, 0x65, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x06, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0a, 0x73, 0x65, 0x6c, 0x6c, 0x65, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x12, + 0x14, 0x0a, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, + 0x74, 0x69, 0x74, 0x6c, 0x65, 0x12, 0x20, 0x0a, 0x0b, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, + 0x43, 0x6f, 0x64, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x70, 0x72, 0x6f, 0x64, + 0x75, 0x63, 0x74, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x73, 0x6b, 0x75, 0x18, 0x09, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x73, 0x6b, 0x75, 0x12, 0x14, 0x0a, 0x05, 0x69, 0x6d, 0x61, + 0x67, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x12, + 0x14, 0x0a, 0x05, 0x70, 0x72, 0x69, 0x63, 0x65, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, + 0x70, 0x72, 0x69, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, + 0x69, 0x6d, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, + 0x65, 0x54, 0x69, 0x6d, 0x65, 0x22, 0x81, 0x01, 0x0a, 0x0b, 0x53, 0x4c, 0x65, 0x76, 0x65, 0x6c, + 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x12, 0x14, 0x0a, 0x05, 0x70, + 0x72, 0x69, 0x63, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x70, 0x72, 0x69, 0x63, + 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x6d, 0x61, 0x78, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x04, + 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x6d, 0x61, 0x78, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, + 0x18, 0x0a, 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, + 0x52, 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x22, 0x5c, 0x0a, 0x10, 0x49, 0x74, 0x65, + 0x6d, 0x42, 0x79, 0x53, 0x6b, 0x75, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1c, 0x0a, + 0x09, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x09, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x73, + 0x6b, 0x75, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x73, 0x6b, 0x75, 0x49, + 0x64, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x78, 0x74, 0x72, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, + 0x52, 0x05, 0x65, 0x78, 0x74, 0x72, 0x61, 0x22, 0x44, 0x0a, 0x12, 0x49, 0x74, 0x65, 0x6d, 0x49, + 0x6c, 0x6c, 0x65, 0x67, 0x61, 0x6c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, + 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x69, + 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x72, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x22, 0x64, 0x0a, + 0x12, 0x52, 0x65, 0x63, 0x79, 0x63, 0x6c, 0x65, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x49, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x06, 0x49, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x52, + 0x65, 0x63, 0x79, 0x63, 0x6c, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x52, 0x65, + 0x63, 0x79, 0x63, 0x6c, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x49, 0x73, 0x44, 0x65, 0x73, 0x74, 0x6f, + 0x72, 0x79, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x49, 0x73, 0x44, 0x65, 0x73, 0x74, + 0x6f, 0x72, 0x79, 0x22, 0x57, 0x0a, 0x11, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x65, 0x76, 0x69, 0x65, + 0x77, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, + 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, + 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x73, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x04, + 0x70, 0x61, 0x73, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x72, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x22, 0x53, 0x0a, 0x15, + 0x53, 0x61, 0x76, 0x65, 0x4c, 0x65, 0x76, 0x65, 0x6c, 0x50, 0x72, 0x69, 0x63, 0x65, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x22, 0x0a, + 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x53, + 0x4c, 0x65, 0x76, 0x65, 0x6c, 0x50, 0x72, 0x69, 0x63, 0x65, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, + 0x65, 0x22, 0x8d, 0x01, 0x0a, 0x12, 0x53, 0x68, 0x65, 0x6c, 0x76, 0x65, 0x53, 0x74, 0x61, 0x74, + 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x2b, 0x0a, 0x08, 0x69, 0x74, 0x65, 0x6d, + 0x54, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x0f, 0x2e, 0x45, 0x49, 0x74, + 0x65, 0x6d, 0x53, 0x61, 0x6c, 0x65, 0x73, 0x54, 0x79, 0x70, 0x65, 0x52, 0x08, 0x69, 0x74, 0x65, + 0x6d, 0x54, 0x79, 0x70, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x1a, 0x0a, + 0x08, 0x73, 0x68, 0x65, 0x6c, 0x76, 0x65, 0x4f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, + 0x08, 0x73, 0x68, 0x65, 0x6c, 0x76, 0x65, 0x4f, 0x6e, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x65, 0x6d, + 0x61, 0x72, 0x6b, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x72, 0x65, 0x6d, 0x61, 0x72, + 0x6b, 0x22, 0x3d, 0x0a, 0x17, 0x53, 0x57, 0x73, 0x53, 0x6b, 0x75, 0x50, 0x72, 0x69, 0x63, 0x65, + 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x22, 0x0a, 0x05, + 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x53, 0x57, + 0x73, 0x53, 0x6b, 0x75, 0x50, 0x72, 0x69, 0x63, 0x65, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, + 0x22, 0x68, 0x0a, 0x14, 0x53, 0x61, 0x76, 0x65, 0x53, 0x6b, 0x75, 0x50, 0x72, 0x69, 0x63, 0x65, + 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, + 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, + 0x12, 0x14, 0x0a, 0x05, 0x73, 0x6b, 0x75, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x05, 0x73, 0x6b, 0x75, 0x49, 0x64, 0x12, 0x22, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, + 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0c, 0x2e, 0x53, 0x57, 0x73, 0x53, 0x6b, 0x75, 0x50, 0x72, + 0x69, 0x63, 0x65, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x65, 0x0a, 0x0b, 0x53, 0x57, + 0x73, 0x53, 0x6b, 0x75, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x72, 0x65, 0x71, + 0x75, 0x69, 0x72, 0x65, 0x4e, 0x75, 0x6d, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x72, + 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x4e, 0x75, 0x6d, 0x12, 0x26, 0x0a, 0x0e, 0x77, 0x68, 0x6f, + 0x6c, 0x65, 0x73, 0x61, 0x6c, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x0e, 0x77, 0x68, 0x6f, 0x6c, 0x65, 0x73, 0x61, 0x6c, 0x65, 0x50, 0x72, 0x69, 0x63, + 0x65, 0x22, 0x45, 0x0a, 0x1b, 0x53, 0x57, 0x73, 0x49, 0x74, 0x65, 0x6d, 0x44, 0x69, 0x73, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x26, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, + 0x10, 0x2e, 0x53, 0x57, 0x73, 0x49, 0x74, 0x65, 0x6d, 0x44, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x48, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x57, + 0x73, 0x44, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x67, 0x72, 0x6f, 0x75, + 0x70, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, + 0x49, 0x64, 0x22, 0x73, 0x0a, 0x17, 0x53, 0x61, 0x76, 0x65, 0x49, 0x74, 0x65, 0x6d, 0x44, 0x69, + 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, + 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x69, + 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x12, + 0x26, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x10, + 0x2e, 0x53, 0x57, 0x73, 0x49, 0x74, 0x65, 0x6d, 0x44, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, + 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x8f, 0x01, 0x0a, 0x0f, 0x53, 0x57, 0x73, 0x49, + 0x74, 0x65, 0x6d, 0x44, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, + 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x22, 0x0a, 0x0c, 0x62, + 0x75, 0x79, 0x65, 0x72, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x0c, 0x62, 0x75, 0x79, 0x65, 0x72, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x12, + 0x24, 0x0a, 0x0d, 0x72, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x41, 0x6d, 0x6f, 0x75, 0x6e, 0x74, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0d, 0x72, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x41, + 0x6d, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x22, 0x0a, 0x0c, 0x64, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x52, 0x61, 0x74, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0c, 0x64, 0x69, 0x73, + 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x61, 0x74, 0x65, 0x2a, 0x31, 0x0a, 0x0e, 0x45, 0x49, 0x74, + 0x65, 0x6d, 0x53, 0x61, 0x6c, 0x65, 0x73, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0d, 0x0a, 0x09, 0x49, + 0x54, 0x5f, 0x4e, 0x4f, 0x52, 0x4d, 0x41, 0x4c, 0x10, 0x00, 0x12, 0x10, 0x0a, 0x0c, 0x49, 0x54, + 0x5f, 0x57, 0x48, 0x4f, 0x4c, 0x45, 0x53, 0x41, 0x4c, 0x45, 0x10, 0x01, 0x2a, 0xa5, 0x01, 0x0a, + 0x09, 0x45, 0x49, 0x74, 0x65, 0x6d, 0x46, 0x6c, 0x61, 0x67, 0x12, 0x0e, 0x0a, 0x0a, 0x5f, 0x45, + 0x49, 0x74, 0x65, 0x6d, 0x46, 0x6c, 0x61, 0x67, 0x10, 0x00, 0x12, 0x0d, 0x0a, 0x09, 0x53, 0x65, + 0x6c, 0x66, 0x53, 0x61, 0x6c, 0x65, 0x73, 0x10, 0x01, 0x12, 0x10, 0x0a, 0x0c, 0x46, 0x72, 0x65, + 0x65, 0x44, 0x65, 0x6c, 0x69, 0x76, 0x65, 0x72, 0x79, 0x10, 0x02, 0x12, 0x0d, 0x0a, 0x09, 0x52, + 0x65, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x64, 0x10, 0x04, 0x12, 0x0c, 0x0a, 0x08, 0x45, 0x78, + 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x10, 0x08, 0x12, 0x08, 0x0a, 0x04, 0x47, 0x69, 0x66, 0x74, + 0x10, 0x10, 0x12, 0x0d, 0x0a, 0x09, 0x41, 0x66, 0x66, 0x69, 0x6c, 0x69, 0x61, 0x74, 0x65, 0x10, + 0x20, 0x12, 0x0f, 0x0a, 0x0b, 0x4e, 0x65, 0x77, 0x4f, 0x6e, 0x53, 0x68, 0x65, 0x6c, 0x76, 0x65, + 0x10, 0x40, 0x12, 0x0d, 0x0a, 0x08, 0x48, 0x6f, 0x74, 0x53, 0x61, 0x6c, 0x65, 0x73, 0x10, 0x80, + 0x01, 0x12, 0x11, 0x0a, 0x0c, 0x53, 0x65, 0x6c, 0x66, 0x44, 0x65, 0x6c, 0x69, 0x76, 0x65, 0x72, + 0x79, 0x10, 0x80, 0x02, 0x42, 0x1f, 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, 0x67, 0x69, 0x74, 0x68, + 0x75, 0x62, 0x2e, 0x67, 0x6f, 0x32, 0x6f, 0x2e, 0x72, 0x70, 0x63, 0x5a, 0x08, 0x2e, 0x2f, 0x3b, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/upgrade/sql/2023-03.sql b/upgrade/sql/2023-03.sql index e1f607bfc..928a82a2c 100644 --- a/upgrade/sql/2023-03.sql +++ b/upgrade/sql/2023-03.sql @@ -182,4 +182,16 @@ ALTER TABLE IF EXISTS public.item_sku RENAME retail_price TO origin_price; ALTER TABLE IF EXISTS public.item_snapshot - RENAME retail_price TO origin_price; \ No newline at end of file + RENAME retail_price TO origin_price; + +/* 2023-03-13 */ + +ALTER TABLE IF EXISTS public.item_info + ADD COLUMN safeguard_flag integer NOT NULL DEFAULT 0; +COMMENT ON COLUMN public.item_info.safeguard_flag + IS '购物保障'; + +ALTER TABLE IF EXISTS public.item_snapshot + ADD COLUMN safeguard_flag integer NOT NULL DEFAULT 0; +COMMENT ON COLUMN public.item_snapshot.safeguard_flag + IS '购物保障'; \ No newline at end of file From d843b58c3460a415bf2566dcba047973c788a720 Mon Sep 17 00:00:00 2001 From: jarrysix Date: Mon, 13 Mar 2023 18:03:19 +0800 Subject: [PATCH 02/33] feat: item safeguard --- upgrade/sql/2023-03.sql | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/upgrade/sql/2023-03.sql b/upgrade/sql/2023-03.sql index 928a82a2c..849a449d1 100644 --- a/upgrade/sql/2023-03.sql +++ b/upgrade/sql/2023-03.sql @@ -82,6 +82,7 @@ CREATE TABLE public.sys_safeguard ( id bigserial NOT NULL, bind_type integer NOT NULL, + flag integer NOT NULL DEFAULT 0, name character varying(20) NOT NULL, content character varying(120) NOT NULL, class_name character varying(20) NOT NULL, @@ -93,6 +94,7 @@ CREATE TABLE public.sys_safeguard PRIMARY KEY (id) ); + ALTER TABLE IF EXISTS public.sys_safeguard OWNER to postgres; @@ -105,6 +107,9 @@ COMMENT ON COLUMN public.sys_safeguard.id COMMENT ON COLUMN public.sys_safeguard.bind_type IS '绑定类型:1:店铺 2:商品'; +COMMENT ON COLUMN public.sys_safeguard.flag + IS '保障标志'; + COMMENT ON COLUMN public.sys_safeguard.name IS '保障名称'; From ea8ff69184c88064989df4bf339d1bf90506fba9 Mon Sep 17 00:00:00 2001 From: jarrysix Date: Tue, 14 Mar 2023 15:51:04 +0800 Subject: [PATCH 03/33] fix: item shelve down and remote ite snapshot --- core/domain/interface/item/snapshot_service.go | 3 +++ core/domain/item/item.go | 16 ++++++++++++++++ tests/service/member_service_test.go | 12 ++++++++++++ 3 files changed, 31 insertions(+) diff --git a/core/domain/interface/item/snapshot_service.go b/core/domain/interface/item/snapshot_service.go index 1866deff3..28bcdb4fa 100755 --- a/core/domain/interface/item/snapshot_service.go +++ b/core/domain/interface/item/snapshot_service.go @@ -17,6 +17,9 @@ type ( // 获取最新的快照 GetLatestSnapshot(itemId int64) *Snapshot + // RemoveSnapshot 移除快照 + RemoveSnapshot(itemId int64) error + // 获取最新的商品销售快照,如果商品有更新,则更新销售快照 GetLatestSalesSnapshot(itemId, skuId int64) *TradeSnapshot diff --git a/core/domain/item/item.go b/core/domain/item/item.go index f5eeabf89..6e5949438 100755 --- a/core/domain/item/item.go +++ b/core/domain/item/item.go @@ -620,6 +620,7 @@ func (i *itemImpl) SetShelve(state int32, remark string) error { i.value.ShelveState = state if i.value.ReviewState != enum.ReviewPass { i.value.ReviewState = enum.ReviewAwaiting + i.removeSnapshot() } i.value.ReviewRemark = remark _, err := i.Save() @@ -737,16 +738,31 @@ func (i *itemImpl) ReleaseStock(skuId int64, quantity int32) error { func (i *itemImpl) Recycle() error { if i.value.IsRecycle == 0 { i.value.IsRecycle = 1 + i.value.ShelveState = item.ShelvesDown _, err := i.Save() + // 删除快照 + if err == nil { + err = i.removeSnapshot() + } return err } return nil } +// 删除快照 +func (i *itemImpl) removeSnapshot() error { + if sn := i.Snapshot(); sn != nil { + i.snapshot = nil + return i.repo.SnapshotService().RemoveSnapshot(sn.ItemId) + } + return nil +} + // 从回收站中撤回 func (i *itemImpl) RecycleRevert() error { if i.value.IsRecycle == 1 { i.value.IsRecycle = 0 + i.value.ShelveState = item.ShelvesOn _, err := i.Save() return err } diff --git a/tests/service/member_service_test.go b/tests/service/member_service_test.go index b42b58505..d82b45df0 100755 --- a/tests/service/member_service_test.go +++ b/tests/service/member_service_test.go @@ -150,3 +150,15 @@ func Test_memberService_InviterArray(t *testing.T) { }) t.Log(ret) } + +// 测试绑定邀请人 +func TestSetInviter(t *testing.T) { + ret, _ := impl.MemberService.SetInviter(context.TODO(), + &proto.SetInviterRequest{ + MemberId: 771, + InviterCode: "f2PWIo", + AllowChange: false, + }) + t.Log(ret) + +} From 6a4403587acb21097dfb0490209fe95eefb5ec0d Mon Sep 17 00:00:00 2001 From: jarrysix Date: Tue, 14 Mar 2023 15:58:02 +0800 Subject: [PATCH 04/33] fix: item shelve down and remote ite snapshot --- core/domain/interface/item/item.go | 5 +-- core/domain/item/snapshot_service.go | 53 +++++++++++++++------------- core/repos/item_repo.go | 6 ++++ 3 files changed, 38 insertions(+), 26 deletions(-) diff --git a/core/domain/interface/item/item.go b/core/domain/interface/item/item.go index dd4aa7f40..3e7cfcdb2 100755 --- a/core/domain/interface/item/item.go +++ b/core/domain/interface/item/item.go @@ -327,9 +327,10 @@ type ( // RemoveGoodSMemberLevelPrice 移除会员价 RemoveGoodSMemberLevelPrice(id int) error - // SaveSnapshot 保存快照 + // SaveSnapshot 保存 SaveSnapshot(*Snapshot) (int64, error) - + // DeleteSnapshot 删除商品快照 + DeleteSnapshot(itemId int64) error // GetSnapshots 根据指定商品快照 GetSnapshots(skuIdArr []int64) []Snapshot diff --git a/core/domain/item/snapshot_service.go b/core/domain/item/snapshot_service.go index 1c8005e98..575a8c49b 100755 --- a/core/domain/item/snapshot_service.go +++ b/core/domain/item/snapshot_service.go @@ -84,31 +84,31 @@ func (s *snapshotServiceImpl) updateSnapshot(ls *item.Snapshot, } unix := time.Now().Unix() var snap = &item.Snapshot{ - ItemId: it.Id, - Key: fmt.Sprintf("%d-g%d-%d", it.VendorId, it.Id, unix), - CatId: it.CategoryId, - ItemFlag: it.ItemFlag, - VendorId: it.VendorId, - BrandId: it.BrandId, - ProductId: it.ProductId, - ShopId: it.ShopId, - ShopCatId: it.ShopCatId, - ExpressTid: it.ExpressTid, - SkuId: it.SkuId, - Title: it.Title, - ShortTitle: it.ShortTitle, - Code: it.Code, - Image: it.Image, - PriceRange: it.PriceRange, - Cost: it.Cost, - Price: it.Price, - OriginPrice: it.OriginPrice, - Weight: it.Weight, + ItemId: it.Id, + Key: fmt.Sprintf("%d-g%d-%d", it.VendorId, it.Id, unix), + CatId: it.CategoryId, + ItemFlag: it.ItemFlag, + VendorId: it.VendorId, + BrandId: it.BrandId, + ProductId: it.ProductId, + ShopId: it.ShopId, + ShopCatId: it.ShopCatId, + ExpressTid: it.ExpressTid, + SkuId: it.SkuId, + Title: it.Title, + ShortTitle: it.ShortTitle, + Code: it.Code, + Image: it.Image, + PriceRange: it.PriceRange, + Cost: it.Cost, + Price: it.Price, + OriginPrice: it.OriginPrice, + Weight: it.Weight, SafeguardFlag: it.SafeguardFlag, - Bulk: it.Bulk, - LevelSales: int32(levelSales), - ShelveState: it.ShelveState, - UpdateTime: it.UpdateTime, + Bulk: it.Bulk, + LevelSales: int32(levelSales), + ShelveState: it.ShelveState, + UpdateTime: it.UpdateTime, } // 比较快照,如果为最新则更新快照 if s.CompareSnapshot(snap, ls) { @@ -117,6 +117,11 @@ func (s *snapshotServiceImpl) updateSnapshot(ls *item.Snapshot, return snap.ItemId, nil } +// RemoveSnapshot 移出商品快照 +func (s *snapshotServiceImpl) RemoveSnapshot(itemId int64) error { + return s.itemRepo.DeleteSnapshot(itemId) +} + // GetSaleSnapshotByKey 根据KEY获取已销售商品的快照 func (s *snapshotServiceImpl) GetSaleSnapshotByKey(key string) *item.TradeSnapshot { return s.itemRepo.GetSaleSnapshotByKey(key) diff --git a/core/repos/item_repo.go b/core/repos/item_repo.go index 3ff50737f..350061efb 100755 --- a/core/repos/item_repo.go +++ b/core/repos/item_repo.go @@ -220,6 +220,12 @@ func (i *itemRepoImpl) SaveSnapshot(v *item.Snapshot) (int64, error) { return v.ItemId, err } +// DeleteSnapshot 删除商品快照 +func (i *itemRepoImpl) DeleteSnapshot(itemId int64) error { + return i.o.DeleteByPk(&item.Snapshot{}, itemId) + +} + // GetLatestSnapshot 获取最新的商品快照 func (i *itemRepoImpl) GetLatestSnapshot(itemId int64) *item.Snapshot { e := &item.Snapshot{} From 2e34551189a5a839fe9944d8705cff161e4c37fd Mon Sep 17 00:00:00 2001 From: jarrysix Date: Tue, 14 Mar 2023 16:06:51 +0800 Subject: [PATCH 05/33] fix: item shelve down and remote ite snapshot --- core/domain/item/item.go | 7 ++++++- tests/domain/item_test.go | 11 +++++++++++ 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/core/domain/item/item.go b/core/domain/item/item.go index 6e5949438..2a2b9506d 100755 --- a/core/domain/item/item.go +++ b/core/domain/item/item.go @@ -620,10 +620,15 @@ func (i *itemImpl) SetShelve(state int32, remark string) error { i.value.ShelveState = state if i.value.ReviewState != enum.ReviewPass { i.value.ReviewState = enum.ReviewAwaiting - i.removeSnapshot() } i.value.ReviewRemark = remark _, err := i.Save() + // 下架删除快照 + if err == nil { + if i.value.ShelveState == 0 { + i.removeSnapshot() + } + } return err } diff --git a/tests/domain/item_test.go b/tests/domain/item_test.go index 38db06590..f96533df4 100755 --- a/tests/domain/item_test.go +++ b/tests/domain/item_test.go @@ -231,3 +231,14 @@ func TestAuditItem(t *testing.T) { it := repo.GetItem(itemId) it.Review(true, "") } + +func TestItemShelveDown(t *testing.T) { + var itemId int64 = 3252 + repo := ti.Factory.GetItemRepo() + it := repo.GetItem(itemId) + err := it.SetShelve(0, "测试下架") + if err != nil { + t.Error(err) + t.FailNow() + } +} From 63cc86dd656896ea36f4832c442c97a6ae311386 Mon Sep 17 00:00:00 2001 From: jarrysix Date: Tue, 14 Mar 2023 16:09:17 +0800 Subject: [PATCH 06/33] fix: item shelve down and remote ite snapshot --- tests/domain/item_test.go | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/tests/domain/item_test.go b/tests/domain/item_test.go index f96533df4..4cabbc06e 100755 --- a/tests/domain/item_test.go +++ b/tests/domain/item_test.go @@ -232,6 +232,7 @@ func TestAuditItem(t *testing.T) { it.Review(true, "") } +// 测试商品下架 func TestItemShelveDown(t *testing.T) { var itemId int64 = 3252 repo := ti.Factory.GetItemRepo() @@ -242,3 +243,15 @@ func TestItemShelveDown(t *testing.T) { t.FailNow() } } + +// 测试商品回收 +func TestItemRecycle(t *testing.T) { + var itemId int64 = 3162 + repo := ti.Factory.GetItemRepo() + it := repo.GetItem(itemId) + err := it.Recycle() + if err != nil { + t.Error(err) + t.FailNow() + } +} From dec98673d43679a10a5b7f7cb106334128dde800 Mon Sep 17 00:00:00 2001 From: jarrysix Date: Tue, 14 Mar 2023 16:16:26 +0800 Subject: [PATCH 07/33] fix: item recycle --- core/service/impl/2.item_service.go | 4 ++-- tests/domain/item_test.go | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/core/service/impl/2.item_service.go b/core/service/impl/2.item_service.go index 54e65a454..d3ea097ab 100755 --- a/core/service/impl/2.item_service.go +++ b/core/service/impl/2.item_service.go @@ -188,9 +188,9 @@ func (i *itemService) RecycleItem(_ context.Context, req *proto.RecycleItemReque err = it.Destroy() } else { if req.Recycle { - err = it.RecycleRevert() - } else { err = it.Recycle() + } else { + err = it.RecycleRevert() } } } diff --git a/tests/domain/item_test.go b/tests/domain/item_test.go index 4cabbc06e..855e3545c 100755 --- a/tests/domain/item_test.go +++ b/tests/domain/item_test.go @@ -246,7 +246,7 @@ func TestItemShelveDown(t *testing.T) { // 测试商品回收 func TestItemRecycle(t *testing.T) { - var itemId int64 = 3162 + var itemId int64 = 1998 repo := ti.Factory.GetItemRepo() it := repo.GetItem(itemId) err := it.Recycle() From 84041b9cd299ccf7e0db17ab23ffeb2f9945c09e Mon Sep 17 00:00:00 2001 From: jarrysix Date: Tue, 14 Mar 2023 17:41:24 +0800 Subject: [PATCH 08/33] fix: generate snapshot on save --- core/domain/item/item.go | 3 +++ core/domain/item/snapshot_service.go | 25 +++++++++++++++++-------- 2 files changed, 20 insertions(+), 8 deletions(-) diff --git a/core/domain/item/item.go b/core/domain/item/item.go index 2a2b9506d..325b80250 100755 --- a/core/domain/item/item.go +++ b/core/domain/item/item.go @@ -517,6 +517,9 @@ func (i *itemImpl) Save() (_ int64, err error) { } } } + if err == nil && i.value.ReviewState == enum.ReviewPass { + _, err = i.repo.SnapshotService().GenerateSnapshot(i.value) + } return i.value.Id, err } diff --git a/core/domain/item/snapshot_service.go b/core/domain/item/snapshot_service.go index 575a8c49b..c05f82502 100755 --- a/core/domain/item/snapshot_service.go +++ b/core/domain/item/snapshot_service.go @@ -12,7 +12,6 @@ import ( "fmt" "time" - "github.com/ixre/go2o/core/domain/interface/domain/enum" "github.com/ixre/go2o/core/domain/interface/item" ) @@ -37,12 +36,22 @@ func (s *snapshotServiceImpl) GetLatestSnapshot(itemId int64) *item.Snapshot { func (s *snapshotServiceImpl) CompareSnapshot(snap *item.Snapshot, latest *item.Snapshot) bool { if latest != nil { - return latest.Title != snap.Title || latest.CatId != snap.CatId || latest.Image != snap.Image || - latest.Cost != snap.Cost || latest.OriginPrice != snap.OriginPrice || latest.Price != snap.Price || - latest.ExpressTid != snap.ExpressTid || latest.Weight != snap.Weight || latest.Bulk != snap.Bulk || - latest.PriceRange != snap.PriceRange || latest.ShopCatId != snap.ShopCatId || - latest.ShortTitle != snap.ShortTitle || latest.ShopId != snap.ShopId || - latest.ProductId != snap.ProductId + return latest.Title != snap.Title || + latest.CatId != snap.CatId || + latest.Image != snap.Image || + latest.Cost != snap.Cost || + latest.OriginPrice != snap.OriginPrice || + latest.Price != snap.Price || + latest.ExpressTid != snap.ExpressTid || + latest.Weight != snap.Weight || + latest.Bulk != snap.Bulk || + latest.PriceRange != snap.PriceRange || + latest.ShopCatId != snap.ShopCatId || + latest.ShortTitle != snap.ShortTitle || + latest.ShopId != snap.ShopId || + latest.ProductId != snap.ProductId || + latest.ItemFlag != snap.ItemFlag || + latest.SafeguardFlag != snap.SafeguardFlag } return true } @@ -68,7 +77,7 @@ func (s *snapshotServiceImpl) GenerateSnapshot(it *item.GoodsItem) (int64, error // 检查快照 err := s.checkSnapshot(ls, it) // 审核通过后更新快照 - if err == nil && it.ReviewState == enum.ReviewPass { + if err == nil { return s.updateSnapshot(ls, it) } return 0, err From af48f51c8fddcd16587b7409f7deee28653dd5da Mon Sep 17 00:00:00 2001 From: jarrysix Date: Tue, 14 Mar 2023 17:50:04 +0800 Subject: [PATCH 09/33] feat:add key ItemGenerateSnapshotReviewEnabled --- core/domain/interface/registry/keys.go | 5 +++++ core/domain/interface/registry/merge.go | 3 +++ core/domain/item/item.go | 5 ++++- 3 files changed, 12 insertions(+), 1 deletion(-) diff --git a/core/domain/interface/registry/keys.go b/core/domain/interface/registry/keys.go index 7e2db7bd8..758be607d 100755 --- a/core/domain/interface/registry/keys.go +++ b/core/domain/interface/registry/keys.go @@ -205,6 +205,11 @@ var ( // 抵扣1元所需要的积分个数 IntegralDiscountQuantity = KeyFormat("IntegralDiscountQuantity") + /** 商品 */ + + // 修改商品是否需要审核 + ItemGenerateSnapshotReviewEnabled = KeyFormat("ItemGenerateSnapshotReviewEnabled") + /** 订单 */ // 是否启用订单返利 OrderEnableAffiliateRebate = KeyFormat("OrderEnableAffiliateRebate") diff --git a/core/domain/interface/registry/merge.go b/core/domain/interface/registry/merge.go index 593b126a4..3e94950b6 100755 --- a/core/domain/interface/registry/merge.go +++ b/core/domain/interface/registry/merge.go @@ -135,6 +135,9 @@ func MergeRegistries() []*Registry { mergeAdd("兑换1元所需要的积分(0不兑换)", IntegralExchangeQuantity, "1000", "") mergeAdd("抵扣1元所需要的积分(0不抵扣)", IntegralDiscountQuantity, "1000", "") + // 商品 + mergeAdd("修改商品是否需要审核", ItemGenerateSnapshotReviewEnabled, "1", "0:关闭,1:启用") + // 订单 mergeAdd("是否启用订单返利", OrderEnableAffiliateRebate, "0", "") mergeAdd("全局订单返利比例", OrderGlobalAffiliateRebateRate, "0", "") diff --git a/core/domain/item/item.go b/core/domain/item/item.go index 325b80250..36c0380d4 100755 --- a/core/domain/item/item.go +++ b/core/domain/item/item.go @@ -435,7 +435,10 @@ func (i *itemImpl) copyFromProduct(v *item.GoodsItem) error { // 重置审核状态 func (i *itemImpl) resetReview() { - i.value.ReviewState = enum.ReviewAwaiting + ir := i.registryRepo.Get(registry.ItemGenerateSnapshotReviewEnabled) + if ir != nil && ir.BoolValue() { + i.value.ReviewState = enum.ReviewAwaiting + } } // 检查商品数据是否正确 From a381969098fcb7bb8cd16fecbec727b661ee7d20 Mon Sep 17 00:00:00 2001 From: jarrysix Date: Tue, 14 Mar 2023 18:03:43 +0800 Subject: [PATCH 10/33] fix: ad hyper link --- core/domain/interface/ad/ad_types.go | 4 ++-- .../interface/delivery/coverage_value.go | 2 +- upgrade/sql/2023-03.sql | 22 ++++++++++++++++++- 3 files changed, 24 insertions(+), 4 deletions(-) diff --git a/core/domain/interface/ad/ad_types.go b/core/domain/interface/ad/ad_types.go index 033de5961..e724c1e55 100755 --- a/core/domain/interface/ad/ad_types.go +++ b/core/domain/interface/ad/ad_types.go @@ -18,7 +18,7 @@ type ( // 超链接 HyperLink struct { - Id int64 `db:"id"` + Id int64 `db:"id" auto:"yes" pk:"yes"` AdId int64 `db:"ad_id"` Title string `db:"title"` LinkUrl string `db:"link_url"` @@ -32,7 +32,7 @@ type ( // 广告图片 Image struct { // 图片编号 - Id int64 `db:"id" auto:"yes" pk:"true"` + Id int64 `db:"id" auto:"yes" pk:"yes"` // 广告编号 AdId int64 `db:"ad_id"` diff --git a/core/domain/interface/delivery/coverage_value.go b/core/domain/interface/delivery/coverage_value.go index 5fd99a2d5..3ed364440 100755 --- a/core/domain/interface/delivery/coverage_value.go +++ b/core/domain/interface/delivery/coverage_value.go @@ -10,7 +10,7 @@ package delivery // 覆盖区域 type CoverageValue struct { - Id int32 `db:"id" auto:"yes" pk:"true"` + Id int32 `db:"id" auto:"yes" pk:"yes"` Name string `db:"name"` Lng float64 `db:"lng"` Lat float64 `db:"lat"` diff --git a/upgrade/sql/2023-03.sql b/upgrade/sql/2023-03.sql index 849a449d1..11a5584cd 100644 --- a/upgrade/sql/2023-03.sql +++ b/upgrade/sql/2023-03.sql @@ -199,4 +199,24 @@ COMMENT ON COLUMN public.item_info.safeguard_flag ALTER TABLE IF EXISTS public.item_snapshot ADD COLUMN safeguard_flag integer NOT NULL DEFAULT 0; COMMENT ON COLUMN public.item_snapshot.safeguard_flag - IS '购物保障'; \ No newline at end of file + IS '购物保障'; + + +/* 2023-03-13 文本广告 */ +DROP TABLE IF EXISTS public.ad_hyperlink; +CREATE TABLE IF NOT EXISTS public.ad_hyperlink +( + id bigserial NOT NULL, + ad_id integer NOT NULL, + title character varying(50) COLLATE pg_catalog."default" NOT NULL, + link_url character varying(120) COLLATE pg_catalog."default" NOT NULL, + CONSTRAINT ad_hyperlink_pkey PRIMARY KEY (id) +) + +TABLESPACE pg_default; +ALTER TABLE IF EXISTS public.ad_hyperlink OWNER to postgres; +COMMENT ON TABLE public.ad_hyperlink IS '文本广告'; +COMMENT ON COLUMN public.ad_hyperlink.id IS '编号'; +COMMENT ON COLUMN public.ad_hyperlink.ad_id IS '广告编号'; +COMMENT ON COLUMN public.ad_hyperlink.title IS '标题'; +COMMENT ON COLUMN public.ad_hyperlink.link_url IS '链接地址'; \ No newline at end of file From 4f4bd048dd5e1f7cd489e579455af3056d5c43f7 Mon Sep 17 00:00:00 2001 From: jarrysix Date: Tue, 14 Mar 2023 18:22:43 +0800 Subject: [PATCH 11/33] fix: advertisement_test.go --- core/domain/ad/hyper_link.go | 7 ------- tests/domain/advertisement_test.go | 9 +++++++++ 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/core/domain/ad/hyper_link.go b/core/domain/ad/hyper_link.go index c77581823..2a004beff 100755 --- a/core/domain/ad/hyper_link.go +++ b/core/domain/ad/hyper_link.go @@ -23,13 +23,6 @@ type HyperLinkAdImpl struct { func (h *HyperLinkAdImpl) getData() *ad.HyperLink { if h.extValue == nil { h.extValue = h._rep.GetTextAdData(h.GetDomainId()) - - //如果不存在,则创建一个新的对象 - if h.extValue == nil { - h.extValue = &ad.HyperLink{ - AdId: h.GetDomainId(), - } - } } return h.extValue } diff --git a/tests/domain/advertisement_test.go b/tests/domain/advertisement_test.go index 30a7ec885..fab1ba1e4 100644 --- a/tests/domain/advertisement_test.go +++ b/tests/domain/advertisement_test.go @@ -5,6 +5,7 @@ import ( "testing" "github.com/ixre/go2o/tests/ti" + "github.com/ixre/gof/types/typeconv" ) func TestGetGroups(t *testing.T) { @@ -33,3 +34,11 @@ func TestQueryAdvertisementData(t *testing.T) { t.Fail() } } + +func TestQueryHyperLinkAdvertisementData(t *testing.T) { + manager := ti.Factory.GetAdRepo().GetAdManager() + iu := manager.GetUserAd(0) + ad := iu.GetById(8) + v := ad.Dto() + t.Log("广告数据:", typeconv.MustJson(v)) +} From 4a4fabd5690863f6497899205bec5595212a79e0 Mon Sep 17 00:00:00 2001 From: jarrysix Date: Tue, 14 Mar 2023 18:29:15 +0800 Subject: [PATCH 12/33] fix: advertisement_test.go --- core/service/impl/2.advertisement_service.go | 8 +++++++- tests/service/advertisement_test.go | 20 ++++++++++++++++++++ 2 files changed, 27 insertions(+), 1 deletion(-) create mode 100644 tests/service/advertisement_test.go diff --git a/core/service/impl/2.advertisement_service.go b/core/service/impl/2.advertisement_service.go index 6c0a68015..481e5a055 100755 --- a/core/service/impl/2.advertisement_service.go +++ b/core/service/impl/2.advertisement_service.go @@ -44,7 +44,7 @@ func (a *advertisementService) GetPosition(_ context.Context, id *proto.AdPositi if ip != nil { return a.parseAdPositionDto(ip), nil } - return nil,ad.ErrNoSuchAdPosition + return nil, ad.ErrNoSuchAdPosition } func (a *advertisementService) SaveAdPosition(_ context.Context, r *proto.SAdPosition) (*proto.Result, error) { @@ -325,6 +325,9 @@ func (a *advertisementService) parseAdImage(v *proto.SImageAdData) *ad.Image { func (a *advertisementService) parseTextDto(dto *ad.AdDto) *proto.STextAdData { v := dto.Data.(*ad.HyperLink) + if v == nil { + return &proto.STextAdData{} + } return &proto.STextAdData{ Id: v.Id, Title: v.Title, @@ -334,6 +337,9 @@ func (a *advertisementService) parseTextDto(dto *ad.AdDto) *proto.STextAdData { func (a *advertisementService) parseImageDto(dto *ad.AdDto) *proto.SImageAdData { v := dto.Data.(*ad.Image) + if v == nil { + return &proto.SImageAdData{} + } return a.parseSingleImageDto(v) } diff --git a/tests/service/advertisement_test.go b/tests/service/advertisement_test.go new file mode 100644 index 000000000..874b0aa90 --- /dev/null +++ b/tests/service/advertisement_test.go @@ -0,0 +1,20 @@ +package service + +import ( + "context" + "testing" + + "github.com/ixre/go2o/core/service/impl" + "github.com/ixre/go2o/core/service/proto" + "github.com/ixre/gof/types/typeconv" +) + +func TestQueryHyperLinkAdvertisementData(t *testing.T) { + ret, _ := impl.AdService.GetAdvertisement(context.TODO(), &proto.AdIdRequest{ + AdUserId: 0, + AdId: 8, + AdKey: "", + ReturnData: true, + }) + t.Log("广告数据:", typeconv.MustJson(ret)) +} From e3ca3adb800b7b896baae6494ba9d1e13898f035 Mon Sep 17 00:00:00 2001 From: jarrysix Date: Wed, 15 Mar 2023 17:26:47 +0800 Subject: [PATCH 13/33] fix: advertisement_test.go --- core/domain/ad/hyper_link.go | 3 +++ core/domain/ad/image_ad.go | 14 +++++--------- 2 files changed, 8 insertions(+), 9 deletions(-) diff --git a/core/domain/ad/hyper_link.go b/core/domain/ad/hyper_link.go index 2a004beff..cd94153a8 100755 --- a/core/domain/ad/hyper_link.go +++ b/core/domain/ad/hyper_link.go @@ -40,6 +40,9 @@ func (h *HyperLinkAdImpl) Save() (int64, error) { id, err := h.adImpl.Save() if err == nil { v := h.getData() + if v == nil { + v = &ad.HyperLink{} + } v.AdId = id _, err = h._rep.SaveTextAdData(v) } diff --git a/core/domain/ad/image_ad.go b/core/domain/ad/image_ad.go index 84eaa6f92..3e66f0fe9 100755 --- a/core/domain/ad/image_ad.go +++ b/core/domain/ad/image_ad.go @@ -27,15 +27,6 @@ func (i *ImageAdImpl) getData() *ad.Image { if gallery.Len() > 0 { i.extValue = gallery[0] } - - //如果不存在,则创建一个新的对象 - if i.extValue == nil { - i.extValue = &ad.Image{ - AdId: i.GetDomainId(), - ImageUrl: format.GetNoPicPath(), - Enabled: 1, - } - } } return i.extValue } @@ -54,6 +45,11 @@ func (i *ImageAdImpl) Save() (int64, error) { id, err := i.adImpl.Save() if err == nil { v := i.getData() + if v == nil { + v = &ad.Image{ + ImageUrl: format.GetNoPicPath(), + } + } v.AdId = id _, err = i._rep.SaveImageAdData(v) } From b3ceaa83aaf4846d96dc9797dc1cab76bcfb406d Mon Sep 17 00:00:00 2001 From: jarrysix Date: Wed, 15 Mar 2023 17:33:05 +0800 Subject: [PATCH 14/33] fix: advertisement_test.go --- core/service/idl/message/advertisement_dto.proto | 2 +- core/service/impl/2.advertisement_service.go | 4 ++-- core/service/proto/advertisement_dto.pb.go | 10 +++++----- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/core/service/idl/message/advertisement_dto.proto b/core/service/idl/message/advertisement_dto.proto index e8d66a58b..f389cf714 100644 --- a/core/service/idl/message/advertisement_dto.proto +++ b/core/service/idl/message/advertisement_dto.proto @@ -95,7 +95,7 @@ message SAdvertisementDto { message STextAdData { int64 id = 1; string title = 2; - string linkURL = 3; + string linkUrl = 3; } // 图片广告数据 diff --git a/core/service/impl/2.advertisement_service.go b/core/service/impl/2.advertisement_service.go index 481e5a055..141552117 100755 --- a/core/service/impl/2.advertisement_service.go +++ b/core/service/impl/2.advertisement_service.go @@ -297,7 +297,7 @@ func (a *advertisementService) parseHyperLinkAd(v *proto.STextAdData) *ad.HyperL return &ad.HyperLink{ Id: v.Id, Title: v.Title, - LinkUrl: v.LinkURL, + LinkUrl: v.LinkUrl, } } @@ -331,7 +331,7 @@ func (a *advertisementService) parseTextDto(dto *ad.AdDto) *proto.STextAdData { return &proto.STextAdData{ Id: v.Id, Title: v.Title, - LinkURL: v.LinkUrl, + LinkUrl: v.LinkUrl, } } diff --git a/core/service/proto/advertisement_dto.pb.go b/core/service/proto/advertisement_dto.pb.go index 84884eda6..cace3e0f2 100644 --- a/core/service/proto/advertisement_dto.pb.go +++ b/core/service/proto/advertisement_dto.pb.go @@ -620,7 +620,7 @@ type STextAdData struct { Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id"` Title string `protobuf:"bytes,2,opt,name=title,proto3" json:"title"` - LinkURL string `protobuf:"bytes,3,opt,name=linkURL,proto3" json:"linkURL"` + LinkUrl string `protobuf:"bytes,3,opt,name=linkUrl,proto3" json:"linkUrl"` } func (x *STextAdData) Reset() { @@ -669,9 +669,9 @@ func (x *STextAdData) GetTitle() string { return "" } -func (x *STextAdData) GetLinkURL() string { +func (x *STextAdData) GetLinkUrl() string { if x != nil { - return x.LinkURL + return x.LinkUrl } return "" } @@ -1382,8 +1382,8 @@ var file_message_advertisement_dto_proto_rawDesc = []byte{ 0x22, 0x4d, 0x0a, 0x0b, 0x53, 0x54, 0x65, 0x78, 0x74, 0x41, 0x64, 0x44, 0x61, 0x74, 0x61, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, - 0x74, 0x69, 0x74, 0x6c, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x6c, 0x69, 0x6e, 0x6b, 0x55, 0x52, 0x4c, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6c, 0x69, 0x6e, 0x6b, 0x55, 0x52, 0x4c, 0x22, + 0x74, 0x69, 0x74, 0x6c, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x6c, 0x69, 0x6e, 0x6b, 0x55, 0x72, 0x6c, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6c, 0x69, 0x6e, 0x6b, 0x55, 0x72, 0x6c, 0x22, 0x9e, 0x01, 0x0a, 0x0c, 0x53, 0x49, 0x6d, 0x61, 0x67, 0x65, 0x41, 0x64, 0x44, 0x61, 0x74, 0x61, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, From 430a824c1062e050ee934a4cbec473b40ead4fb7 Mon Sep 17 00:00:00 2001 From: jarrysix Date: Wed, 15 Mar 2023 17:51:56 +0800 Subject: [PATCH 15/33] fix: orders quantity --- core/query/member_query.go | 5 +++-- tests/service/query_service_test.go | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/core/query/member_query.go b/core/query/member_query.go index ae8e7e6b3..c718ec7ab 100755 --- a/core/query/member_query.go +++ b/core/query/member_query.go @@ -396,8 +396,9 @@ func (m *MemberQuery) OrdersQuantity(memberId int64) map[int]int { mp := make(map[int]int, 0) m.Connector.Query(` SELECT o.status,COUNT(0) as n FROM sale_sub_order o - GROUP BY o.status,o.buyer_id,is_forbidden - having is_forbidden = 0 AND o.buyer_id = $1`, func(rows *sql.Rows) { + GROUP BY o.status,o.buyer_id,is_forbidden,break_status + having is_forbidden = 0 AND break_status <> 0 + AND o.buyer_id = $1`, func(rows *sql.Rows) { s, n := 0, 0 for rows.Next() { rows.Scan(&s, &n) diff --git a/tests/service/query_service_test.go b/tests/service/query_service_test.go index 518bc5871..a11979071 100644 --- a/tests/service/query_service_test.go +++ b/tests/service/query_service_test.go @@ -96,7 +96,7 @@ func TestPagingShopGoodsRequest(t *testing.T) { } func TestMemberStatifics(t *testing.T) { - var memberId int64 = 723 + var memberId int64 = 729 mp, _ := impl.QueryService.MemberStatistics(context.TODO(), &proto.MemberStatisticsRequest{ MemberId: memberId, }) From 9b572ceb85abd6c3f0e8a22da4202b541668749f Mon Sep 17 00:00:00 2001 From: jarrysix Date: Wed, 15 Mar 2023 18:40:30 +0800 Subject: [PATCH 16/33] fix: update product model --- core/query/member_query.go | 2 +- core/service/idl/product_service.proto | 22 +- core/service/impl/2.product_service.go | 10 +- core/service/proto/product_service.pb.go | 1009 ++++++++++------- core/service/proto/product_service_grpc.pb.go | 12 +- 5 files changed, 604 insertions(+), 451 deletions(-) diff --git a/core/query/member_query.go b/core/query/member_query.go index c718ec7ab..601eb4b30 100755 --- a/core/query/member_query.go +++ b/core/query/member_query.go @@ -397,7 +397,7 @@ func (m *MemberQuery) OrdersQuantity(memberId int64) map[int]int { m.Connector.Query(` SELECT o.status,COUNT(0) as n FROM sale_sub_order o GROUP BY o.status,o.buyer_id,is_forbidden,break_status - having is_forbidden = 0 AND break_status <> 0 + having is_forbidden = 0 AND break_status <> 0cd AND o.buyer_id = $1`, func(rows *sql.Rows) { s, n := 0, 0 for rows.Next() { diff --git a/core/service/idl/product_service.proto b/core/service/idl/product_service.proto index 5020e55a2..45d87c9dd 100644 --- a/core/service/idl/product_service.proto +++ b/core/service/idl/product_service.proto @@ -21,7 +21,7 @@ service ProductService { } // 保存产品模型 - rpc SaveProductModel (SProductModel) returns (Result) { + rpc SaveProductModel (SaveProductModelRequest) returns (Result) { } // 删除产品模型 rpc DeleteModel_ (ProductModelId) returns (Result) { @@ -126,6 +126,26 @@ message SProductModel { int32 enabled = 8; } + +// 保存产品模型请求 +message SaveProductModelRequest { + // 编号 + int64 id = 1; + // 名称 + string name = 2; + // 关联品牌 + repeated int64 brands = 3; + // 属性 + repeated SProductAttr attrs = 4; + // 规格 + repeated SProductSpec specs = 5; + // 是否更新规格和属性,为true时不更新品牌 + bool updateAttrSpec = 7; + // 是否启用 + int32 enabled = 8; +} + + // 产品模型属性 message SProductAttr { // 编号 diff --git a/core/service/impl/2.product_service.go b/core/service/impl/2.product_service.go index df4666b42..268eac501 100755 --- a/core/service/impl/2.product_service.go +++ b/core/service/impl/2.product_service.go @@ -249,7 +249,7 @@ func (p *productService) SaveProductInfo(_ context.Context, r *proto.ProductInfo } // SaveModel 保存产品模型 -func (p *productService) SaveProductModel(_ context.Context, r *proto.SProductModel) (*proto.Result, error) { +func (p *productService) SaveProductModel(_ context.Context, r *proto.SaveProductModelRequest) (*proto.Result, error) { var pm promodel.IProductModel v := p.parseProductModel(r) if v.Id > 0 { @@ -263,15 +263,15 @@ func (p *productService) SaveProductModel(_ context.Context, r *proto.SProductMo err := pm.SetValue(v) if err == nil { // 保存属性 - if err == nil && len(v.Attrs) > 0 { + if err == nil && r.UpdateAttrSpec { err = pm.SetAttrs(v.Attrs) } // 保存规格 - if err == nil && len(v.Specs) > 0 { + if err == nil && r.UpdateAttrSpec { err = pm.SetSpecs(v.Specs) } // 保存品牌 - if err == nil{ + if err == nil && !r.UpdateAttrSpec { err = pm.SetBrands(v.BrandArray) } } @@ -660,7 +660,7 @@ func (p *productService) parseProduct(v *proto.SaveProductRequest) *product.Prod return ret } -func (p *productService) parseProductModel(v *proto.SProductModel) *promodel.ProductModel { +func (p *productService) parseProductModel(v *proto.SaveProductModelRequest) *promodel.ProductModel { ret := &promodel.ProductModel{ Id: int(v.Id), Name: v.Name, diff --git a/core/service/proto/product_service.pb.go b/core/service/proto/product_service.pb.go index 525be7919..64146241d 100644 --- a/core/service/proto/product_service.pb.go +++ b/core/service/proto/product_service.pb.go @@ -469,6 +469,109 @@ func (x *SProductModel) GetEnabled() int32 { return 0 } +// 保存产品模型请求 +type SaveProductModelRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // 编号 + Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id"` + // 名称 + Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name"` + // 关联品牌 + Brands []int64 `protobuf:"varint,3,rep,packed,name=brands,proto3" json:"brands"` + // 属性 + Attrs []*SProductAttr `protobuf:"bytes,4,rep,name=attrs,proto3" json:"attrs"` + // 规格 + Specs []*SProductSpec `protobuf:"bytes,5,rep,name=specs,proto3" json:"specs"` + // 是否更新规格和属性,为true时不更新品牌 + UpdateAttrSpec bool `protobuf:"varint,7,opt,name=updateAttrSpec,proto3" json:"updateAttrSpec"` + // 是否启用 + Enabled int32 `protobuf:"varint,8,opt,name=enabled,proto3" json:"enabled"` +} + +func (x *SaveProductModelRequest) Reset() { + *x = SaveProductModelRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_product_service_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *SaveProductModelRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*SaveProductModelRequest) ProtoMessage() {} + +func (x *SaveProductModelRequest) ProtoReflect() protoreflect.Message { + mi := &file_product_service_proto_msgTypes[8] + 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 SaveProductModelRequest.ProtoReflect.Descriptor instead. +func (*SaveProductModelRequest) Descriptor() ([]byte, []int) { + return file_product_service_proto_rawDescGZIP(), []int{8} +} + +func (x *SaveProductModelRequest) GetId() int64 { + if x != nil { + return x.Id + } + return 0 +} + +func (x *SaveProductModelRequest) GetName() string { + if x != nil { + return x.Name + } + return "" +} + +func (x *SaveProductModelRequest) GetBrands() []int64 { + if x != nil { + return x.Brands + } + return nil +} + +func (x *SaveProductModelRequest) GetAttrs() []*SProductAttr { + if x != nil { + return x.Attrs + } + return nil +} + +func (x *SaveProductModelRequest) GetSpecs() []*SProductSpec { + if x != nil { + return x.Specs + } + return nil +} + +func (x *SaveProductModelRequest) GetUpdateAttrSpec() bool { + if x != nil { + return x.UpdateAttrSpec + } + return false +} + +func (x *SaveProductModelRequest) GetEnabled() int32 { + if x != nil { + return x.Enabled + } + return 0 +} + // 产品模型属性 type SProductAttr struct { state protoimpl.MessageState @@ -494,7 +597,7 @@ type SProductAttr struct { func (x *SProductAttr) Reset() { *x = SProductAttr{} if protoimpl.UnsafeEnabled { - mi := &file_product_service_proto_msgTypes[8] + mi := &file_product_service_proto_msgTypes[9] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -507,7 +610,7 @@ func (x *SProductAttr) String() string { func (*SProductAttr) ProtoMessage() {} func (x *SProductAttr) ProtoReflect() protoreflect.Message { - mi := &file_product_service_proto_msgTypes[8] + mi := &file_product_service_proto_msgTypes[9] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -520,7 +623,7 @@ func (x *SProductAttr) ProtoReflect() protoreflect.Message { // Deprecated: Use SProductAttr.ProtoReflect.Descriptor instead. func (*SProductAttr) Descriptor() ([]byte, []int) { - return file_product_service_proto_rawDescGZIP(), []int{8} + return file_product_service_proto_rawDescGZIP(), []int{9} } func (x *SProductAttr) GetId() int64 { @@ -589,7 +692,7 @@ type SProductAttrItem struct { func (x *SProductAttrItem) Reset() { *x = SProductAttrItem{} if protoimpl.UnsafeEnabled { - mi := &file_product_service_proto_msgTypes[9] + mi := &file_product_service_proto_msgTypes[10] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -602,7 +705,7 @@ func (x *SProductAttrItem) String() string { func (*SProductAttrItem) ProtoMessage() {} func (x *SProductAttrItem) ProtoReflect() protoreflect.Message { - mi := &file_product_service_proto_msgTypes[9] + mi := &file_product_service_proto_msgTypes[10] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -615,7 +718,7 @@ func (x *SProductAttrItem) ProtoReflect() protoreflect.Message { // Deprecated: Use SProductAttrItem.ProtoReflect.Descriptor instead. func (*SProductAttrItem) Descriptor() ([]byte, []int) { - return file_product_service_proto_rawDescGZIP(), []int{9} + return file_product_service_proto_rawDescGZIP(), []int{10} } func (x *SProductAttrItem) GetId() int64 { @@ -660,7 +763,7 @@ type SProductAttrValue struct { func (x *SProductAttrValue) Reset() { *x = SProductAttrValue{} if protoimpl.UnsafeEnabled { - mi := &file_product_service_proto_msgTypes[10] + mi := &file_product_service_proto_msgTypes[11] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -673,7 +776,7 @@ func (x *SProductAttrValue) String() string { func (*SProductAttrValue) ProtoMessage() {} func (x *SProductAttrValue) ProtoReflect() protoreflect.Message { - mi := &file_product_service_proto_msgTypes[10] + mi := &file_product_service_proto_msgTypes[11] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -686,7 +789,7 @@ func (x *SProductAttrValue) ProtoReflect() protoreflect.Message { // Deprecated: Use SProductAttrValue.ProtoReflect.Descriptor instead. func (*SProductAttrValue) Descriptor() ([]byte, []int) { - return file_product_service_proto_rawDescGZIP(), []int{10} + return file_product_service_proto_rawDescGZIP(), []int{11} } func (x *SProductAttrValue) GetId() int64 { @@ -745,7 +848,7 @@ type SProductSpec struct { func (x *SProductSpec) Reset() { *x = SProductSpec{} if protoimpl.UnsafeEnabled { - mi := &file_product_service_proto_msgTypes[11] + mi := &file_product_service_proto_msgTypes[12] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -758,7 +861,7 @@ func (x *SProductSpec) String() string { func (*SProductSpec) ProtoMessage() {} func (x *SProductSpec) ProtoReflect() protoreflect.Message { - mi := &file_product_service_proto_msgTypes[11] + mi := &file_product_service_proto_msgTypes[12] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -771,7 +874,7 @@ func (x *SProductSpec) ProtoReflect() protoreflect.Message { // Deprecated: Use SProductSpec.ProtoReflect.Descriptor instead. func (*SProductSpec) Descriptor() ([]byte, []int) { - return file_product_service_proto_rawDescGZIP(), []int{11} + return file_product_service_proto_rawDescGZIP(), []int{12} } func (x *SProductSpec) GetId() int64 { @@ -828,7 +931,7 @@ type SProductSpecItem struct { func (x *SProductSpecItem) Reset() { *x = SProductSpecItem{} if protoimpl.UnsafeEnabled { - mi := &file_product_service_proto_msgTypes[12] + mi := &file_product_service_proto_msgTypes[13] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -841,7 +944,7 @@ func (x *SProductSpecItem) String() string { func (*SProductSpecItem) ProtoMessage() {} func (x *SProductSpecItem) ProtoReflect() protoreflect.Message { - mi := &file_product_service_proto_msgTypes[12] + mi := &file_product_service_proto_msgTypes[13] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -854,7 +957,7 @@ func (x *SProductSpecItem) ProtoReflect() protoreflect.Message { // Deprecated: Use SProductSpecItem.ProtoReflect.Descriptor instead. func (*SProductSpecItem) Descriptor() ([]byte, []int) { - return file_product_service_proto_rawDescGZIP(), []int{12} + return file_product_service_proto_rawDescGZIP(), []int{13} } func (x *SProductSpecItem) GetId() int64 { @@ -896,7 +999,7 @@ type ProductBrandListResponse struct { func (x *ProductBrandListResponse) Reset() { *x = ProductBrandListResponse{} if protoimpl.UnsafeEnabled { - mi := &file_product_service_proto_msgTypes[13] + mi := &file_product_service_proto_msgTypes[14] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -909,7 +1012,7 @@ func (x *ProductBrandListResponse) String() string { func (*ProductBrandListResponse) ProtoMessage() {} func (x *ProductBrandListResponse) ProtoReflect() protoreflect.Message { - mi := &file_product_service_proto_msgTypes[13] + mi := &file_product_service_proto_msgTypes[14] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -922,7 +1025,7 @@ func (x *ProductBrandListResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ProductBrandListResponse.ProtoReflect.Descriptor instead. func (*ProductBrandListResponse) Descriptor() ([]byte, []int) { - return file_product_service_proto_rawDescGZIP(), []int{13} + return file_product_service_proto_rawDescGZIP(), []int{14} } func (x *ProductBrandListResponse) GetValue() []*SProductBrand { @@ -961,7 +1064,7 @@ type SProductBrand struct { func (x *SProductBrand) Reset() { *x = SProductBrand{} if protoimpl.UnsafeEnabled { - mi := &file_product_service_proto_msgTypes[14] + mi := &file_product_service_proto_msgTypes[15] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -974,7 +1077,7 @@ func (x *SProductBrand) String() string { func (*SProductBrand) ProtoMessage() {} func (x *SProductBrand) ProtoReflect() protoreflect.Message { - mi := &file_product_service_proto_msgTypes[14] + mi := &file_product_service_proto_msgTypes[15] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -987,7 +1090,7 @@ func (x *SProductBrand) ProtoReflect() protoreflect.Message { // Deprecated: Use SProductBrand.ProtoReflect.Descriptor instead. func (*SProductBrand) Descriptor() ([]byte, []int) { - return file_product_service_proto_rawDescGZIP(), []int{14} + return file_product_service_proto_rawDescGZIP(), []int{15} } func (x *SProductBrand) GetId() int64 { @@ -1102,7 +1205,7 @@ type SProductCategory struct { func (x *SProductCategory) Reset() { *x = SProductCategory{} if protoimpl.UnsafeEnabled { - mi := &file_product_service_proto_msgTypes[15] + mi := &file_product_service_proto_msgTypes[16] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1115,7 +1218,7 @@ func (x *SProductCategory) String() string { func (*SProductCategory) ProtoMessage() {} func (x *SProductCategory) ProtoReflect() protoreflect.Message { - mi := &file_product_service_proto_msgTypes[15] + mi := &file_product_service_proto_msgTypes[16] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1128,7 +1231,7 @@ func (x *SProductCategory) ProtoReflect() protoreflect.Message { // Deprecated: Use SProductCategory.ProtoReflect.Descriptor instead. func (*SProductCategory) Descriptor() ([]byte, []int) { - return file_product_service_proto_rawDescGZIP(), []int{15} + return file_product_service_proto_rawDescGZIP(), []int{16} } func (x *SProductCategory) GetId() int64 { @@ -1301,7 +1404,7 @@ type SaveProductCategoryRequest struct { func (x *SaveProductCategoryRequest) Reset() { *x = SaveProductCategoryRequest{} if protoimpl.UnsafeEnabled { - mi := &file_product_service_proto_msgTypes[16] + mi := &file_product_service_proto_msgTypes[17] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1314,7 +1417,7 @@ func (x *SaveProductCategoryRequest) String() string { func (*SaveProductCategoryRequest) ProtoMessage() {} func (x *SaveProductCategoryRequest) ProtoReflect() protoreflect.Message { - mi := &file_product_service_proto_msgTypes[16] + mi := &file_product_service_proto_msgTypes[17] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1327,7 +1430,7 @@ func (x *SaveProductCategoryRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use SaveProductCategoryRequest.ProtoReflect.Descriptor instead. func (*SaveProductCategoryRequest) Descriptor() ([]byte, []int) { - return file_product_service_proto_rawDescGZIP(), []int{16} + return file_product_service_proto_rawDescGZIP(), []int{17} } func (x *SaveProductCategoryRequest) GetId() int64 { @@ -1434,7 +1537,7 @@ type SaveProductCategoryResponse struct { func (x *SaveProductCategoryResponse) Reset() { *x = SaveProductCategoryResponse{} if protoimpl.UnsafeEnabled { - mi := &file_product_service_proto_msgTypes[17] + mi := &file_product_service_proto_msgTypes[18] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1447,7 +1550,7 @@ func (x *SaveProductCategoryResponse) String() string { func (*SaveProductCategoryResponse) ProtoMessage() {} func (x *SaveProductCategoryResponse) ProtoReflect() protoreflect.Message { - mi := &file_product_service_proto_msgTypes[17] + mi := &file_product_service_proto_msgTypes[18] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1460,7 +1563,7 @@ func (x *SaveProductCategoryResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use SaveProductCategoryResponse.ProtoReflect.Descriptor instead. func (*SaveProductCategoryResponse) Descriptor() ([]byte, []int) { - return file_product_service_proto_rawDescGZIP(), []int{17} + return file_product_service_proto_rawDescGZIP(), []int{18} } func (x *SaveProductCategoryResponse) GetError() string { @@ -1502,7 +1605,7 @@ type SCategoryTree struct { func (x *SCategoryTree) Reset() { *x = SCategoryTree{} if protoimpl.UnsafeEnabled { - mi := &file_product_service_proto_msgTypes[18] + mi := &file_product_service_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1515,7 +1618,7 @@ func (x *SCategoryTree) String() string { func (*SCategoryTree) ProtoMessage() {} func (x *SCategoryTree) ProtoReflect() protoreflect.Message { - mi := &file_product_service_proto_msgTypes[18] + mi := &file_product_service_proto_msgTypes[19] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1528,7 +1631,7 @@ func (x *SCategoryTree) ProtoReflect() protoreflect.Message { // Deprecated: Use SCategoryTree.ProtoReflect.Descriptor instead. func (*SCategoryTree) Descriptor() ([]byte, []int) { - return file_product_service_proto_rawDescGZIP(), []int{18} + return file_product_service_proto_rawDescGZIP(), []int{19} } func (x *SCategoryTree) GetId() int64 { @@ -1597,7 +1700,7 @@ type GetCategoryRequest struct { func (x *GetCategoryRequest) Reset() { *x = GetCategoryRequest{} if protoimpl.UnsafeEnabled { - mi := &file_product_service_proto_msgTypes[19] + mi := &file_product_service_proto_msgTypes[20] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1610,7 +1713,7 @@ func (x *GetCategoryRequest) String() string { func (*GetCategoryRequest) ProtoMessage() {} func (x *GetCategoryRequest) ProtoReflect() protoreflect.Message { - mi := &file_product_service_proto_msgTypes[19] + mi := &file_product_service_proto_msgTypes[20] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1623,7 +1726,7 @@ func (x *GetCategoryRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetCategoryRequest.ProtoReflect.Descriptor instead. func (*GetCategoryRequest) Descriptor() ([]byte, []int) { - return file_product_service_proto_rawDescGZIP(), []int{19} + return file_product_service_proto_rawDescGZIP(), []int{20} } func (x *GetCategoryRequest) GetCategoryId() int64 { @@ -1666,7 +1769,7 @@ type CategoryTreeRequest struct { func (x *CategoryTreeRequest) Reset() { *x = CategoryTreeRequest{} if protoimpl.UnsafeEnabled { - mi := &file_product_service_proto_msgTypes[20] + mi := &file_product_service_proto_msgTypes[21] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1679,7 +1782,7 @@ func (x *CategoryTreeRequest) String() string { func (*CategoryTreeRequest) ProtoMessage() {} func (x *CategoryTreeRequest) ProtoReflect() protoreflect.Message { - mi := &file_product_service_proto_msgTypes[20] + mi := &file_product_service_proto_msgTypes[21] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1692,7 +1795,7 @@ func (x *CategoryTreeRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use CategoryTreeRequest.ProtoReflect.Descriptor instead. func (*CategoryTreeRequest) Descriptor() ([]byte, []int) { - return file_product_service_proto_rawDescGZIP(), []int{20} + return file_product_service_proto_rawDescGZIP(), []int{21} } func (x *CategoryTreeRequest) GetParentId() int64 { @@ -1735,7 +1838,7 @@ type CategoryTreeResponse struct { func (x *CategoryTreeResponse) Reset() { *x = CategoryTreeResponse{} if protoimpl.UnsafeEnabled { - mi := &file_product_service_proto_msgTypes[21] + mi := &file_product_service_proto_msgTypes[22] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1748,7 +1851,7 @@ func (x *CategoryTreeResponse) String() string { func (*CategoryTreeResponse) ProtoMessage() {} func (x *CategoryTreeResponse) ProtoReflect() protoreflect.Message { - mi := &file_product_service_proto_msgTypes[21] + mi := &file_product_service_proto_msgTypes[22] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1761,7 +1864,7 @@ func (x *CategoryTreeResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use CategoryTreeResponse.ProtoReflect.Descriptor instead. func (*CategoryTreeResponse) Descriptor() ([]byte, []int) { - return file_product_service_proto_rawDescGZIP(), []int{21} + return file_product_service_proto_rawDescGZIP(), []int{22} } func (x *CategoryTreeResponse) GetValue() []*SCategoryTree { @@ -1783,7 +1886,7 @@ type CategoriesResponse struct { func (x *CategoriesResponse) Reset() { *x = CategoriesResponse{} if protoimpl.UnsafeEnabled { - mi := &file_product_service_proto_msgTypes[22] + mi := &file_product_service_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1796,7 +1899,7 @@ func (x *CategoriesResponse) String() string { func (*CategoriesResponse) ProtoMessage() {} func (x *CategoriesResponse) ProtoReflect() protoreflect.Message { - mi := &file_product_service_proto_msgTypes[22] + mi := &file_product_service_proto_msgTypes[23] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1809,7 +1912,7 @@ func (x *CategoriesResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use CategoriesResponse.ProtoReflect.Descriptor instead. func (*CategoriesResponse) Descriptor() ([]byte, []int) { - return file_product_service_proto_rawDescGZIP(), []int{22} + return file_product_service_proto_rawDescGZIP(), []int{23} } func (x *CategoriesResponse) GetList() []*SProductCategory { @@ -1858,7 +1961,7 @@ type SProduct struct { func (x *SProduct) Reset() { *x = SProduct{} if protoimpl.UnsafeEnabled { - mi := &file_product_service_proto_msgTypes[23] + mi := &file_product_service_proto_msgTypes[24] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1871,7 +1974,7 @@ func (x *SProduct) String() string { func (*SProduct) ProtoMessage() {} func (x *SProduct) ProtoReflect() protoreflect.Message { - mi := &file_product_service_proto_msgTypes[23] + mi := &file_product_service_proto_msgTypes[24] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1884,7 +1987,7 @@ func (x *SProduct) ProtoReflect() protoreflect.Message { // Deprecated: Use SProduct.ProtoReflect.Descriptor instead. func (*SProduct) Descriptor() ([]byte, []int) { - return file_product_service_proto_rawDescGZIP(), []int{23} + return file_product_service_proto_rawDescGZIP(), []int{24} } func (x *SProduct) GetId() int64 { @@ -2026,7 +2129,7 @@ type SaveProductRequest struct { func (x *SaveProductRequest) Reset() { *x = SaveProductRequest{} if protoimpl.UnsafeEnabled { - mi := &file_product_service_proto_msgTypes[24] + mi := &file_product_service_proto_msgTypes[25] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2039,7 +2142,7 @@ func (x *SaveProductRequest) String() string { func (*SaveProductRequest) ProtoMessage() {} func (x *SaveProductRequest) ProtoReflect() protoreflect.Message { - mi := &file_product_service_proto_msgTypes[24] + mi := &file_product_service_proto_msgTypes[25] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2052,7 +2155,7 @@ func (x *SaveProductRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use SaveProductRequest.ProtoReflect.Descriptor instead. func (*SaveProductRequest) Descriptor() ([]byte, []int) { - return file_product_service_proto_rawDescGZIP(), []int{24} + return file_product_service_proto_rawDescGZIP(), []int{25} } func (x *SaveProductRequest) GetId() int64 { @@ -2172,7 +2275,7 @@ type ProductInfoRequest struct { func (x *ProductInfoRequest) Reset() { *x = ProductInfoRequest{} if protoimpl.UnsafeEnabled { - mi := &file_product_service_proto_msgTypes[25] + mi := &file_product_service_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2185,7 +2288,7 @@ func (x *ProductInfoRequest) String() string { func (*ProductInfoRequest) ProtoMessage() {} func (x *ProductInfoRequest) ProtoReflect() protoreflect.Message { - mi := &file_product_service_proto_msgTypes[25] + mi := &file_product_service_proto_msgTypes[26] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2198,7 +2301,7 @@ func (x *ProductInfoRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use ProductInfoRequest.ProtoReflect.Descriptor instead. func (*ProductInfoRequest) Descriptor() ([]byte, []int) { - return file_product_service_proto_rawDescGZIP(), []int{25} + return file_product_service_proto_rawDescGZIP(), []int{26} } func (x *ProductInfoRequest) GetProductId() int64 { @@ -2228,7 +2331,7 @@ type SaveProductResponse struct { func (x *SaveProductResponse) Reset() { *x = SaveProductResponse{} if protoimpl.UnsafeEnabled { - mi := &file_product_service_proto_msgTypes[26] + mi := &file_product_service_proto_msgTypes[27] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2241,7 +2344,7 @@ func (x *SaveProductResponse) String() string { func (*SaveProductResponse) ProtoMessage() {} func (x *SaveProductResponse) ProtoReflect() protoreflect.Message { - mi := &file_product_service_proto_msgTypes[26] + mi := &file_product_service_proto_msgTypes[27] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2254,7 +2357,7 @@ func (x *SaveProductResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use SaveProductResponse.ProtoReflect.Descriptor instead. func (*SaveProductResponse) Descriptor() ([]byte, []int) { - return file_product_service_proto_rawDescGZIP(), []int{26} + return file_product_service_proto_rawDescGZIP(), []int{27} } func (x *SaveProductResponse) GetErrCode() int32 { @@ -2320,114 +2423,86 @@ var file_product_service_proto_rawDesc = []byte{ 0x16, 0x0a, 0x06, 0x62, 0x72, 0x61, 0x6e, 0x64, 0x73, 0x18, 0x07, 0x20, 0x03, 0x28, 0x03, 0x52, 0x06, 0x62, 0x72, 0x61, 0x6e, 0x64, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x18, 0x08, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, - 0x64, 0x22, 0xd1, 0x01, 0x0a, 0x0c, 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x41, 0x74, - 0x74, 0x72, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, - 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x69, 0x73, 0x46, 0x69, 0x6c, 0x74, - 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x69, 0x73, 0x46, 0x69, 0x6c, 0x74, - 0x65, 0x72, 0x12, 0x1e, 0x0a, 0x0a, 0x6d, 0x75, 0x6c, 0x74, 0x69, 0x43, 0x68, 0x65, 0x63, 0x6b, - 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x6d, 0x75, 0x6c, 0x74, 0x69, 0x43, 0x68, 0x65, - 0x63, 0x6b, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, 0x18, 0x05, 0x20, - 0x01, 0x28, 0x05, 0x52, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, 0x12, 0x1e, 0x0a, 0x0a, - 0x69, 0x74, 0x65, 0x6d, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0a, 0x69, 0x74, 0x65, 0x6d, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x12, 0x27, 0x0a, 0x05, - 0x69, 0x74, 0x65, 0x6d, 0x73, 0x18, 0x07, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x53, 0x50, - 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x05, - 0x69, 0x74, 0x65, 0x6d, 0x73, 0x22, 0x52, 0x0a, 0x10, 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, - 0x74, 0x41, 0x74, 0x74, 0x72, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, - 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12, - 0x18, 0x0a, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, - 0x52, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, 0x22, 0x8f, 0x01, 0x0a, 0x11, 0x53, 0x50, - 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, - 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, - 0x16, 0x0a, 0x06, 0x61, 0x74, 0x74, 0x72, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x06, 0x61, 0x74, 0x74, 0x72, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x61, 0x74, 0x74, 0x72, 0x4e, - 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x61, 0x74, 0x74, 0x72, 0x4e, - 0x61, 0x6d, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x61, 0x74, 0x74, 0x72, 0x44, 0x61, 0x74, 0x61, 0x18, - 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x61, 0x74, 0x74, 0x72, 0x44, 0x61, 0x74, 0x61, 0x12, - 0x1a, 0x0a, 0x08, 0x61, 0x74, 0x74, 0x72, 0x57, 0x6f, 0x72, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x08, 0x61, 0x74, 0x74, 0x72, 0x57, 0x6f, 0x72, 0x64, 0x22, 0x95, 0x01, 0x0a, 0x0c, - 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x53, 0x70, 0x65, 0x63, 0x12, 0x0e, 0x0a, 0x02, - 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, - 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, - 0x12, 0x18, 0x0a, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x05, 0x52, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, 0x12, 0x1e, 0x0a, 0x0a, 0x69, 0x74, - 0x65, 0x6d, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, - 0x69, 0x74, 0x65, 0x6d, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x12, 0x27, 0x0a, 0x05, 0x69, 0x74, - 0x65, 0x6d, 0x73, 0x18, 0x05, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x53, 0x50, 0x72, 0x6f, - 0x64, 0x75, 0x63, 0x74, 0x53, 0x70, 0x65, 0x63, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x05, 0x69, 0x74, - 0x65, 0x6d, 0x73, 0x22, 0x68, 0x0a, 0x10, 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x53, - 0x70, 0x65, 0x63, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x14, 0x0a, - 0x05, 0x63, 0x6f, 0x6c, 0x6f, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x63, 0x6f, - 0x6c, 0x6f, 0x72, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, 0x22, 0x40, 0x0a, - 0x18, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x42, 0x72, 0x61, 0x6e, 0x64, 0x4c, 0x69, 0x73, - 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x24, 0x0a, 0x05, 0x76, 0x61, 0x6c, - 0x75, 0x65, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x53, 0x50, 0x72, 0x6f, 0x64, - 0x75, 0x63, 0x74, 0x42, 0x72, 0x61, 0x6e, 0x64, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, - 0x81, 0x02, 0x0a, 0x0d, 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x42, 0x72, 0x61, 0x6e, - 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, - 0x64, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x73, - 0x69, 0x74, 0x65, 0x55, 0x72, 0x6c, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x73, 0x69, - 0x74, 0x65, 0x55, 0x72, 0x6c, 0x12, 0x1c, 0x0a, 0x09, 0x69, 0x6e, 0x74, 0x72, 0x6f, 0x64, 0x75, - 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x69, 0x6e, 0x74, 0x72, 0x6f, 0x64, - 0x75, 0x63, 0x65, 0x12, 0x20, 0x0a, 0x0b, 0x72, 0x65, 0x76, 0x69, 0x65, 0x77, 0x53, 0x74, 0x61, - 0x74, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0b, 0x72, 0x65, 0x76, 0x69, 0x65, 0x77, - 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x22, 0x0a, 0x0c, 0x72, 0x65, 0x76, 0x69, 0x65, 0x77, 0x52, - 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x72, 0x65, 0x76, - 0x69, 0x65, 0x77, 0x52, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x12, 0x18, 0x0a, 0x07, 0x65, 0x6e, 0x61, - 0x62, 0x6c, 0x65, 0x64, 0x18, 0x08, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x65, 0x6e, 0x61, 0x62, - 0x6c, 0x65, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, - 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, - 0x69, 0x6d, 0x65, 0x22, 0x97, 0x05, 0x0a, 0x10, 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, - 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x70, 0x61, 0x72, 0x65, - 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x70, 0x61, 0x72, 0x65, - 0x6e, 0x74, 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x6d, 0x6f, 0x64, 0x65, 0x6c, 0x49, 0x64, 0x18, - 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x6d, 0x6f, 0x64, 0x65, 0x6c, 0x49, 0x64, 0x12, 0x1a, - 0x0a, 0x08, 0x70, 0x72, 0x69, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, - 0x52, 0x08, 0x70, 0x72, 0x69, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, - 0x6d, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x1c, - 0x0a, 0x09, 0x69, 0x73, 0x56, 0x69, 0x72, 0x74, 0x75, 0x61, 0x6c, 0x18, 0x06, 0x20, 0x01, 0x28, - 0x08, 0x52, 0x09, 0x69, 0x73, 0x56, 0x69, 0x72, 0x74, 0x75, 0x61, 0x6c, 0x12, 0x20, 0x0a, 0x0b, - 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x55, 0x72, 0x6c, 0x18, 0x07, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x0b, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x55, 0x72, 0x6c, 0x12, 0x20, - 0x0a, 0x0b, 0x72, 0x65, 0x64, 0x69, 0x72, 0x65, 0x63, 0x74, 0x55, 0x72, 0x6c, 0x18, 0x12, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0b, 0x72, 0x65, 0x64, 0x69, 0x72, 0x65, 0x63, 0x74, 0x55, 0x72, 0x6c, - 0x12, 0x12, 0x0a, 0x04, 0x69, 0x63, 0x6f, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, - 0x69, 0x63, 0x6f, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x69, 0x63, 0x6f, 0x6e, 0x50, 0x6f, 0x69, 0x6e, - 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x69, 0x63, 0x6f, 0x6e, 0x50, 0x6f, 0x69, - 0x6e, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x18, 0x0a, 0x20, 0x01, 0x28, - 0x05, 0x52, 0x05, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x6f, 0x72, 0x74, - 0x4e, 0x75, 0x6d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, - 0x75, 0x6d, 0x12, 0x1c, 0x0a, 0x09, 0x66, 0x6c, 0x6f, 0x6f, 0x72, 0x53, 0x68, 0x6f, 0x77, 0x18, - 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x66, 0x6c, 0x6f, 0x6f, 0x72, 0x53, 0x68, 0x6f, 0x77, - 0x12, 0x18, 0x0a, 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x18, 0x0d, 0x20, 0x01, 0x28, - 0x08, 0x52, 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x72, - 0x65, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, - 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x2d, 0x0a, 0x08, 0x63, 0x68, - 0x69, 0x6c, 0x64, 0x72, 0x65, 0x6e, 0x18, 0x0f, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x53, - 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x52, - 0x08, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x72, 0x65, 0x6e, 0x12, 0x26, 0x0a, 0x06, 0x62, 0x72, 0x61, - 0x6e, 0x64, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x53, 0x50, 0x72, 0x6f, - 0x64, 0x75, 0x63, 0x74, 0x42, 0x72, 0x61, 0x6e, 0x64, 0x52, 0x06, 0x62, 0x72, 0x61, 0x6e, 0x64, - 0x73, 0x12, 0x24, 0x0a, 0x05, 0x6d, 0x6f, 0x64, 0x65, 0x6c, 0x18, 0x11, 0x20, 0x01, 0x28, 0x0b, - 0x32, 0x0e, 0x2e, 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x4d, 0x6f, 0x64, 0x65, 0x6c, - 0x52, 0x05, 0x6d, 0x6f, 0x64, 0x65, 0x6c, 0x12, 0x38, 0x0a, 0x07, 0x6f, 0x70, 0x74, 0x69, 0x6f, - 0x6e, 0x73, 0x18, 0x13, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x53, 0x50, 0x72, 0x6f, 0x64, - 0x75, 0x63, 0x74, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x2e, 0x4f, 0x70, 0x74, 0x69, - 0x6f, 0x6e, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x07, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, - 0x73, 0x1a, 0x3a, 0x0a, 0x0c, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x45, 0x6e, 0x74, 0x72, - 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, - 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0xf8, 0x02, - 0x0a, 0x1a, 0x53, 0x61, 0x76, 0x65, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x43, 0x61, 0x74, - 0x65, 0x67, 0x6f, 0x72, 0x79, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, + 0x64, 0x22, 0xe1, 0x01, 0x0a, 0x17, 0x53, 0x61, 0x76, 0x65, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, + 0x74, 0x4d, 0x6f, 0x64, 0x65, 0x6c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, + 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, + 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, + 0x65, 0x12, 0x16, 0x0a, 0x06, 0x62, 0x72, 0x61, 0x6e, 0x64, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, + 0x03, 0x52, 0x06, 0x62, 0x72, 0x61, 0x6e, 0x64, 0x73, 0x12, 0x23, 0x0a, 0x05, 0x61, 0x74, 0x74, + 0x72, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0d, 0x2e, 0x53, 0x50, 0x72, 0x6f, 0x64, + 0x75, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x52, 0x05, 0x61, 0x74, 0x74, 0x72, 0x73, 0x12, 0x23, + 0x0a, 0x05, 0x73, 0x70, 0x65, 0x63, 0x73, 0x18, 0x05, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0d, 0x2e, + 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x53, 0x70, 0x65, 0x63, 0x52, 0x05, 0x73, 0x70, + 0x65, 0x63, 0x73, 0x12, 0x26, 0x0a, 0x0e, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x41, 0x74, 0x74, + 0x72, 0x53, 0x70, 0x65, 0x63, 0x18, 0x07, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0e, 0x75, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x41, 0x74, 0x74, 0x72, 0x53, 0x70, 0x65, 0x63, 0x12, 0x18, 0x0a, 0x07, 0x65, + 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x18, 0x08, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x65, 0x6e, + 0x61, 0x62, 0x6c, 0x65, 0x64, 0x22, 0xd1, 0x01, 0x0a, 0x0c, 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, + 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x69, 0x73, + 0x46, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x69, 0x73, + 0x46, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x12, 0x1e, 0x0a, 0x0a, 0x6d, 0x75, 0x6c, 0x74, 0x69, 0x43, + 0x68, 0x65, 0x63, 0x6b, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x6d, 0x75, 0x6c, 0x74, + 0x69, 0x43, 0x68, 0x65, 0x63, 0x6b, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, + 0x6d, 0x18, 0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, + 0x12, 0x1e, 0x0a, 0x0a, 0x69, 0x74, 0x65, 0x6d, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x18, 0x06, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x69, 0x74, 0x65, 0x6d, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x73, + 0x12, 0x27, 0x0a, 0x05, 0x69, 0x74, 0x65, 0x6d, 0x73, 0x18, 0x07, 0x20, 0x03, 0x28, 0x0b, 0x32, + 0x11, 0x2e, 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x49, 0x74, + 0x65, 0x6d, 0x52, 0x05, 0x69, 0x74, 0x65, 0x6d, 0x73, 0x22, 0x52, 0x0a, 0x10, 0x53, 0x50, 0x72, + 0x6f, 0x64, 0x75, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x0e, 0x0a, + 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x14, 0x0a, + 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, + 0x6c, 0x75, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, 0x22, 0x8f, 0x01, + 0x0a, 0x11, 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x56, 0x61, + 0x6c, 0x75, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x02, 0x69, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x61, 0x74, 0x74, 0x72, 0x49, 0x64, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x06, 0x61, 0x74, 0x74, 0x72, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x61, + 0x74, 0x74, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x61, + 0x74, 0x74, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x61, 0x74, 0x74, 0x72, 0x44, + 0x61, 0x74, 0x61, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x61, 0x74, 0x74, 0x72, 0x44, + 0x61, 0x74, 0x61, 0x12, 0x1a, 0x0a, 0x08, 0x61, 0x74, 0x74, 0x72, 0x57, 0x6f, 0x72, 0x64, 0x18, + 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x61, 0x74, 0x74, 0x72, 0x57, 0x6f, 0x72, 0x64, 0x22, + 0x95, 0x01, 0x0a, 0x0c, 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x53, 0x70, 0x65, 0x63, + 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, + 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, + 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, 0x12, 0x1e, + 0x0a, 0x0a, 0x69, 0x74, 0x65, 0x6d, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x18, 0x04, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0a, 0x69, 0x74, 0x65, 0x6d, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x12, 0x27, + 0x0a, 0x05, 0x69, 0x74, 0x65, 0x6d, 0x73, 0x18, 0x05, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x11, 0x2e, + 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x53, 0x70, 0x65, 0x63, 0x49, 0x74, 0x65, 0x6d, + 0x52, 0x05, 0x69, 0x74, 0x65, 0x6d, 0x73, 0x22, 0x68, 0x0a, 0x10, 0x53, 0x50, 0x72, 0x6f, 0x64, + 0x75, 0x63, 0x74, 0x53, 0x70, 0x65, 0x63, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x69, + 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x76, + 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, + 0x65, 0x12, 0x14, 0x0a, 0x05, 0x63, 0x6f, 0x6c, 0x6f, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x05, 0x63, 0x6f, 0x6c, 0x6f, 0x72, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, + 0x75, 0x6d, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, + 0x6d, 0x22, 0x40, 0x0a, 0x18, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x42, 0x72, 0x61, 0x6e, + 0x64, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x24, 0x0a, + 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x53, + 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x42, 0x72, 0x61, 0x6e, 0x64, 0x52, 0x05, 0x76, 0x61, + 0x6c, 0x75, 0x65, 0x22, 0x81, 0x02, 0x0a, 0x0d, 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, + 0x42, 0x72, 0x61, 0x6e, 0x64, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x69, 0x6d, 0x61, + 0x67, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x12, + 0x18, 0x0a, 0x07, 0x73, 0x69, 0x74, 0x65, 0x55, 0x72, 0x6c, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x07, 0x73, 0x69, 0x74, 0x65, 0x55, 0x72, 0x6c, 0x12, 0x1c, 0x0a, 0x09, 0x69, 0x6e, 0x74, + 0x72, 0x6f, 0x64, 0x75, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x69, 0x6e, + 0x74, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x65, 0x12, 0x20, 0x0a, 0x0b, 0x72, 0x65, 0x76, 0x69, 0x65, + 0x77, 0x53, 0x74, 0x61, 0x74, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0b, 0x72, 0x65, + 0x76, 0x69, 0x65, 0x77, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x22, 0x0a, 0x0c, 0x72, 0x65, 0x76, + 0x69, 0x65, 0x77, 0x52, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0c, 0x72, 0x65, 0x76, 0x69, 0x65, 0x77, 0x52, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x12, 0x18, 0x0a, + 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x18, 0x08, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, + 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, + 0x65, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x63, 0x72, 0x65, + 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x22, 0x97, 0x05, 0x0a, 0x10, 0x53, 0x50, 0x72, 0x6f, + 0x64, 0x75, 0x63, 0x74, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x70, 0x61, 0x72, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x70, 0x61, 0x72, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x6d, 0x6f, 0x64, 0x65, @@ -2444,180 +2519,223 @@ var file_product_service_proto_rawDesc = []byte{ 0x74, 0x55, 0x72, 0x6c, 0x12, 0x12, 0x0a, 0x04, 0x69, 0x63, 0x6f, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x69, 0x63, 0x6f, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x69, 0x63, 0x6f, 0x6e, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x69, 0x63, 0x6f, - 0x6e, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, - 0x6d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, - 0x12, 0x1c, 0x0a, 0x09, 0x66, 0x6c, 0x6f, 0x6f, 0x72, 0x53, 0x68, 0x6f, 0x77, 0x18, 0x0c, 0x20, - 0x01, 0x28, 0x08, 0x52, 0x09, 0x66, 0x6c, 0x6f, 0x6f, 0x72, 0x53, 0x68, 0x6f, 0x77, 0x12, 0x18, - 0x0a, 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x08, 0x52, - 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x22, 0x53, 0x0a, 0x1b, 0x53, 0x61, 0x76, 0x65, - 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x12, 0x1e, 0x0a, - 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x22, 0xc1, 0x01, - 0x0a, 0x0d, 0x53, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x54, 0x72, 0x65, 0x65, 0x12, + 0x6e, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x18, + 0x0a, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x12, 0x18, 0x0a, 0x07, + 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x73, + 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, 0x12, 0x1c, 0x0a, 0x09, 0x66, 0x6c, 0x6f, 0x6f, 0x72, 0x53, + 0x68, 0x6f, 0x77, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x66, 0x6c, 0x6f, 0x6f, 0x72, + 0x53, 0x68, 0x6f, 0x77, 0x12, 0x18, 0x0a, 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x18, + 0x0d, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x12, 0x1e, + 0x0a, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x0e, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x2d, + 0x0a, 0x08, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x72, 0x65, 0x6e, 0x18, 0x0f, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x11, 0x2e, 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x43, 0x61, 0x74, 0x65, 0x67, + 0x6f, 0x72, 0x79, 0x52, 0x08, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x72, 0x65, 0x6e, 0x12, 0x26, 0x0a, + 0x06, 0x62, 0x72, 0x61, 0x6e, 0x64, 0x73, 0x18, 0x10, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0e, 0x2e, + 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x42, 0x72, 0x61, 0x6e, 0x64, 0x52, 0x06, 0x62, + 0x72, 0x61, 0x6e, 0x64, 0x73, 0x12, 0x24, 0x0a, 0x05, 0x6d, 0x6f, 0x64, 0x65, 0x6c, 0x18, 0x11, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x4d, + 0x6f, 0x64, 0x65, 0x6c, 0x52, 0x05, 0x6d, 0x6f, 0x64, 0x65, 0x6c, 0x12, 0x38, 0x0a, 0x07, 0x6f, + 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x13, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x53, + 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x2e, + 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x07, 0x6f, 0x70, + 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x1a, 0x3a, 0x0a, 0x0c, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, + 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, + 0x01, 0x22, 0xf8, 0x02, 0x0a, 0x1a, 0x53, 0x61, 0x76, 0x65, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, + 0x74, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, + 0x12, 0x1a, 0x0a, 0x08, 0x70, 0x61, 0x72, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x08, 0x70, 0x61, 0x72, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, + 0x6d, 0x6f, 0x64, 0x65, 0x6c, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x6d, + 0x6f, 0x64, 0x65, 0x6c, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x70, 0x72, 0x69, 0x6f, 0x72, 0x69, + 0x74, 0x79, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x70, 0x72, 0x69, 0x6f, 0x72, 0x69, + 0x74, 0x79, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x69, 0x73, 0x56, 0x69, 0x72, 0x74, + 0x75, 0x61, 0x6c, 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x69, 0x73, 0x56, 0x69, 0x72, + 0x74, 0x75, 0x61, 0x6c, 0x12, 0x20, 0x0a, 0x0b, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, + 0x55, 0x72, 0x6c, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x63, 0x61, 0x74, 0x65, 0x67, + 0x6f, 0x72, 0x79, 0x55, 0x72, 0x6c, 0x12, 0x20, 0x0a, 0x0b, 0x72, 0x65, 0x64, 0x69, 0x72, 0x65, + 0x63, 0x74, 0x55, 0x72, 0x6c, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x72, 0x65, 0x64, + 0x69, 0x72, 0x65, 0x63, 0x74, 0x55, 0x72, 0x6c, 0x12, 0x12, 0x0a, 0x04, 0x69, 0x63, 0x6f, 0x6e, + 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x69, 0x63, 0x6f, 0x6e, 0x12, 0x1c, 0x0a, 0x09, + 0x69, 0x63, 0x6f, 0x6e, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x09, 0x69, 0x63, 0x6f, 0x6e, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x6f, + 0x72, 0x74, 0x4e, 0x75, 0x6d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x73, 0x6f, 0x72, + 0x74, 0x4e, 0x75, 0x6d, 0x12, 0x1c, 0x0a, 0x09, 0x66, 0x6c, 0x6f, 0x6f, 0x72, 0x53, 0x68, 0x6f, + 0x77, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x66, 0x6c, 0x6f, 0x6f, 0x72, 0x53, 0x68, + 0x6f, 0x77, 0x12, 0x18, 0x0a, 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x18, 0x0d, 0x20, + 0x01, 0x28, 0x08, 0x52, 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x22, 0x53, 0x0a, 0x1b, + 0x53, 0x61, 0x76, 0x65, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x43, 0x61, 0x74, 0x65, 0x67, + 0x6f, 0x72, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x65, + 0x72, 0x72, 0x6f, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x65, 0x72, 0x72, 0x6f, + 0x72, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, + 0x64, 0x22, 0xc1, 0x01, 0x0a, 0x0d, 0x53, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x54, + 0x72, 0x65, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x69, 0x6d, 0x61, 0x67, 0x65, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x12, 0x10, 0x0a, + 0x03, 0x75, 0x72, 0x6c, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x72, 0x6c, 0x12, + 0x16, 0x0a, 0x06, 0x69, 0x73, 0x4c, 0x65, 0x61, 0x66, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, + 0x06, 0x69, 0x73, 0x4c, 0x65, 0x61, 0x66, 0x12, 0x2a, 0x0a, 0x08, 0x63, 0x68, 0x69, 0x6c, 0x64, + 0x72, 0x65, 0x6e, 0x18, 0x06, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x53, 0x43, 0x61, 0x74, + 0x65, 0x67, 0x6f, 0x72, 0x79, 0x54, 0x72, 0x65, 0x65, 0x52, 0x08, 0x63, 0x68, 0x69, 0x6c, 0x64, + 0x72, 0x65, 0x6e, 0x12, 0x20, 0x0a, 0x0b, 0x6f, 0x6e, 0x46, 0x6c, 0x6f, 0x6f, 0x72, 0x53, 0x68, + 0x6f, 0x77, 0x18, 0x07, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0b, 0x6f, 0x6e, 0x46, 0x6c, 0x6f, 0x6f, + 0x72, 0x53, 0x68, 0x6f, 0x77, 0x22, 0x70, 0x0a, 0x12, 0x47, 0x65, 0x74, 0x43, 0x61, 0x74, 0x65, + 0x67, 0x6f, 0x72, 0x79, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x63, + 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x77, + 0x69, 0x74, 0x68, 0x42, 0x72, 0x61, 0x6e, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, + 0x77, 0x69, 0x74, 0x68, 0x42, 0x72, 0x61, 0x6e, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x77, 0x69, 0x74, + 0x68, 0x4d, 0x6f, 0x64, 0x65, 0x6c, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x77, 0x69, + 0x74, 0x68, 0x4d, 0x6f, 0x64, 0x65, 0x6c, 0x22, 0x8d, 0x01, 0x0a, 0x13, 0x43, 0x61, 0x74, 0x65, + 0x67, 0x6f, 0x72, 0x79, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, + 0x1a, 0x0a, 0x08, 0x70, 0x61, 0x72, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x08, 0x70, 0x61, 0x72, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x6c, + 0x61, 0x7a, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x04, 0x6c, 0x61, 0x7a, 0x79, 0x12, + 0x20, 0x0a, 0x0b, 0x6f, 0x6e, 0x6c, 0x79, 0x45, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x08, 0x52, 0x0b, 0x6f, 0x6e, 0x6c, 0x79, 0x45, 0x6e, 0x61, 0x62, 0x6c, 0x65, + 0x64, 0x12, 0x24, 0x0a, 0x0d, 0x65, 0x78, 0x63, 0x6c, 0x75, 0x64, 0x65, 0x49, 0x64, 0x4c, 0x69, + 0x73, 0x74, 0x18, 0x04, 0x20, 0x03, 0x28, 0x03, 0x52, 0x0d, 0x65, 0x78, 0x63, 0x6c, 0x75, 0x64, + 0x65, 0x49, 0x64, 0x4c, 0x69, 0x73, 0x74, 0x22, 0x3c, 0x0a, 0x14, 0x43, 0x61, 0x74, 0x65, 0x67, + 0x6f, 0x72, 0x79, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, + 0x24, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0e, + 0x2e, 0x53, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x54, 0x72, 0x65, 0x65, 0x52, 0x05, + 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x3b, 0x0a, 0x12, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, + 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x25, 0x0a, 0x04, 0x6c, + 0x69, 0x73, 0x74, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x53, 0x50, 0x72, 0x6f, + 0x64, 0x75, 0x63, 0x74, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x52, 0x04, 0x6c, 0x69, + 0x73, 0x74, 0x22, 0x82, 0x03, 0x0a, 0x08, 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, - 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, - 0x61, 0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x05, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x72, 0x6c, - 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x72, 0x6c, 0x12, 0x16, 0x0a, 0x06, 0x69, - 0x73, 0x4c, 0x65, 0x61, 0x66, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x69, 0x73, 0x4c, - 0x65, 0x61, 0x66, 0x12, 0x2a, 0x0a, 0x08, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x72, 0x65, 0x6e, 0x18, - 0x06, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x53, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, - 0x79, 0x54, 0x72, 0x65, 0x65, 0x52, 0x08, 0x63, 0x68, 0x69, 0x6c, 0x64, 0x72, 0x65, 0x6e, 0x12, - 0x20, 0x0a, 0x0b, 0x6f, 0x6e, 0x46, 0x6c, 0x6f, 0x6f, 0x72, 0x53, 0x68, 0x6f, 0x77, 0x18, 0x07, - 0x20, 0x01, 0x28, 0x08, 0x52, 0x0b, 0x6f, 0x6e, 0x46, 0x6c, 0x6f, 0x6f, 0x72, 0x53, 0x68, 0x6f, - 0x77, 0x22, 0x70, 0x0a, 0x12, 0x47, 0x65, 0x74, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, - 0x6f, 0x72, 0x79, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x63, 0x61, 0x74, - 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x77, 0x69, 0x74, 0x68, 0x42, - 0x72, 0x61, 0x6e, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x77, 0x69, 0x74, 0x68, - 0x42, 0x72, 0x61, 0x6e, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x77, 0x69, 0x74, 0x68, 0x4d, 0x6f, 0x64, - 0x65, 0x6c, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x77, 0x69, 0x74, 0x68, 0x4d, 0x6f, - 0x64, 0x65, 0x6c, 0x22, 0x8d, 0x01, 0x0a, 0x13, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, - 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x70, - 0x61, 0x72, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x70, - 0x61, 0x72, 0x65, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x6c, 0x61, 0x7a, 0x79, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x04, 0x6c, 0x61, 0x7a, 0x79, 0x12, 0x20, 0x0a, 0x0b, 0x6f, - 0x6e, 0x6c, 0x79, 0x45, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, - 0x52, 0x0b, 0x6f, 0x6e, 0x6c, 0x79, 0x45, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x12, 0x24, 0x0a, - 0x0d, 0x65, 0x78, 0x63, 0x6c, 0x75, 0x64, 0x65, 0x49, 0x64, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x04, - 0x20, 0x03, 0x28, 0x03, 0x52, 0x0d, 0x65, 0x78, 0x63, 0x6c, 0x75, 0x64, 0x65, 0x49, 0x64, 0x4c, - 0x69, 0x73, 0x74, 0x22, 0x3c, 0x0a, 0x14, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x54, - 0x72, 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x24, 0x0a, 0x05, 0x76, - 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x53, 0x43, 0x61, - 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x54, 0x72, 0x65, 0x65, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, - 0x65, 0x22, 0x3b, 0x0a, 0x12, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x69, 0x65, 0x73, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x25, 0x0a, 0x04, 0x6c, 0x69, 0x73, 0x74, 0x18, - 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, - 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x52, 0x04, 0x6c, 0x69, 0x73, 0x74, 0x22, 0x82, - 0x03, 0x0a, 0x08, 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, - 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x63, - 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x6e, - 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, - 0x1a, 0x0a, 0x08, 0x76, 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x49, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x08, 0x76, 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x62, - 0x72, 0x61, 0x6e, 0x64, 0x49, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x62, 0x72, - 0x61, 0x6e, 0x64, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x06, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x69, 0x6d, 0x61, - 0x67, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x12, - 0x20, 0x0a, 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x08, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, - 0x6e, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x18, 0x09, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x06, 0x72, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x74, 0x61, - 0x74, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x12, - 0x18, 0x0a, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x05, - 0x52, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, 0x12, 0x28, 0x0a, 0x05, 0x61, 0x74, 0x74, - 0x72, 0x73, 0x18, 0x0c, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x53, 0x50, 0x72, 0x6f, 0x64, - 0x75, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x52, 0x05, 0x61, 0x74, - 0x74, 0x72, 0x73, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, - 0x65, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, - 0x69, 0x6d, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, - 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, - 0x69, 0x6d, 0x65, 0x22, 0xba, 0x03, 0x0a, 0x12, 0x53, 0x61, 0x76, 0x65, 0x50, 0x72, 0x6f, 0x64, - 0x75, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x61, - 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, - 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, - 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x1a, - 0x0a, 0x08, 0x76, 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x49, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x08, 0x76, 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x62, 0x72, - 0x61, 0x6e, 0x64, 0x49, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x62, 0x72, 0x61, - 0x6e, 0x64, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x06, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x69, 0x6d, 0x61, 0x67, - 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x12, 0x20, - 0x0a, 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x08, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, - 0x12, 0x16, 0x0a, 0x06, 0x72, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x06, 0x72, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x12, 0x14, 0x0a, 0x05, 0x73, 0x74, 0x61, 0x74, - 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x12, 0x18, - 0x0a, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x05, 0x52, - 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, 0x12, 0x28, 0x0a, 0x05, 0x61, 0x74, 0x74, 0x72, - 0x73, 0x18, 0x0c, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, - 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x52, 0x05, 0x61, 0x74, 0x74, - 0x72, 0x73, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, - 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, 0x69, - 0x6d, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, - 0x18, 0x0e, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, 0x69, - 0x6d, 0x65, 0x12, 0x2c, 0x0a, 0x11, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x44, 0x65, 0x73, 0x63, - 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x11, 0x75, - 0x70, 0x64, 0x61, 0x74, 0x65, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, - 0x22, 0x46, 0x0a, 0x12, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, - 0x74, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x70, 0x72, 0x6f, 0x64, 0x75, - 0x63, 0x74, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x22, 0x65, 0x0a, 0x13, 0x53, 0x61, 0x76, 0x65, - 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, - 0x18, 0x0a, 0x07, 0x65, 0x72, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, - 0x52, 0x07, 0x65, 0x72, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x65, 0x72, 0x72, - 0x4d, 0x73, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x65, 0x72, 0x72, 0x4d, 0x73, - 0x67, 0x12, 0x1c, 0x0a, 0x09, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, 0x64, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, 0x64, 0x32, - 0xd4, 0x07, 0x0a, 0x0e, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x53, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x12, 0x34, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, - 0x4d, 0x6f, 0x64, 0x65, 0x6c, 0x12, 0x0f, 0x2e, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x4d, - 0x6f, 0x64, 0x65, 0x6c, 0x49, 0x64, 0x1a, 0x0e, 0x2e, 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, - 0x74, 0x4d, 0x6f, 0x64, 0x65, 0x6c, 0x22, 0x00, 0x12, 0x30, 0x0a, 0x09, 0x47, 0x65, 0x74, 0x4d, - 0x6f, 0x64, 0x65, 0x6c, 0x73, 0x12, 0x06, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x19, 0x2e, - 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x4d, 0x6f, 0x64, 0x65, 0x6c, 0x4c, 0x69, 0x73, 0x74, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x2a, 0x0a, 0x07, 0x47, 0x65, - 0x74, 0x41, 0x74, 0x74, 0x72, 0x12, 0x0e, 0x2e, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x41, - 0x74, 0x74, 0x72, 0x49, 0x64, 0x1a, 0x0d, 0x2e, 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, - 0x41, 0x74, 0x74, 0x72, 0x22, 0x00, 0x12, 0x36, 0x0a, 0x0b, 0x47, 0x65, 0x74, 0x41, 0x74, 0x74, - 0x72, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x12, 0x2e, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x41, - 0x74, 0x74, 0x72, 0x49, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x1a, 0x11, 0x2e, 0x53, 0x50, 0x72, 0x6f, - 0x64, 0x75, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x49, 0x74, 0x65, 0x6d, 0x22, 0x00, 0x12, 0x2d, - 0x0a, 0x10, 0x53, 0x61, 0x76, 0x65, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x4d, 0x6f, 0x64, - 0x65, 0x6c, 0x12, 0x0e, 0x2e, 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x4d, 0x6f, 0x64, - 0x65, 0x6c, 0x1a, 0x07, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x2a, 0x0a, - 0x0c, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x4d, 0x6f, 0x64, 0x65, 0x6c, 0x5f, 0x12, 0x0f, 0x2e, - 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x4d, 0x6f, 0x64, 0x65, 0x6c, 0x49, 0x64, 0x1a, 0x07, - 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x24, 0x0a, 0x08, 0x47, 0x65, 0x74, - 0x42, 0x72, 0x61, 0x6e, 0x64, 0x12, 0x06, 0x2e, 0x49, 0x6e, 0x74, 0x36, 0x34, 0x1a, 0x0e, 0x2e, - 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x42, 0x72, 0x61, 0x6e, 0x64, 0x22, 0x00, 0x12, - 0x26, 0x0a, 0x09, 0x53, 0x61, 0x76, 0x65, 0x42, 0x72, 0x61, 0x6e, 0x64, 0x12, 0x0e, 0x2e, 0x53, - 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x42, 0x72, 0x61, 0x6e, 0x64, 0x1a, 0x07, 0x2e, 0x52, - 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x20, 0x0a, 0x0b, 0x44, 0x65, 0x6c, 0x65, 0x74, - 0x65, 0x42, 0x72, 0x61, 0x6e, 0x64, 0x12, 0x06, 0x2e, 0x49, 0x6e, 0x74, 0x36, 0x34, 0x1a, 0x07, - 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x30, 0x0a, 0x09, 0x47, 0x65, 0x74, - 0x42, 0x72, 0x61, 0x6e, 0x64, 0x73, 0x12, 0x06, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x19, - 0x2e, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x42, 0x72, 0x61, 0x6e, 0x64, 0x4c, 0x69, 0x73, - 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x37, 0x0a, 0x0b, 0x47, - 0x65, 0x74, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x12, 0x13, 0x2e, 0x47, 0x65, 0x74, - 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, - 0x11, 0x2e, 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, - 0x72, 0x79, 0x22, 0x00, 0x12, 0x23, 0x0a, 0x0e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x43, 0x61, - 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x12, 0x06, 0x2e, 0x49, 0x6e, 0x74, 0x36, 0x34, 0x1a, 0x07, - 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x4b, 0x0a, 0x0c, 0x53, 0x61, 0x76, - 0x65, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x12, 0x1b, 0x2e, 0x53, 0x61, 0x76, 0x65, - 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1c, 0x2e, 0x53, 0x61, 0x76, 0x65, 0x50, 0x72, 0x6f, - 0x64, 0x75, 0x63, 0x74, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x44, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x43, 0x61, 0x74, - 0x65, 0x67, 0x6f, 0x72, 0x79, 0x54, 0x72, 0x65, 0x65, 0x4e, 0x6f, 0x64, 0x65, 0x12, 0x14, 0x2e, - 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x15, 0x2e, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x54, 0x72, - 0x65, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x3f, 0x0a, 0x12, - 0x46, 0x69, 0x6e, 0x64, 0x50, 0x61, 0x72, 0x65, 0x6e, 0x74, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, - 0x72, 0x79, 0x12, 0x12, 0x2e, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x13, 0x2e, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, - 0x69, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x25, 0x0a, - 0x0a, 0x47, 0x65, 0x74, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x12, 0x0a, 0x2e, 0x50, 0x72, - 0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, 0x64, 0x1a, 0x09, 0x2e, 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, - 0x63, 0x74, 0x22, 0x00, 0x12, 0x3a, 0x0a, 0x0b, 0x53, 0x61, 0x76, 0x65, 0x50, 0x72, 0x6f, 0x64, - 0x75, 0x63, 0x74, 0x12, 0x13, 0x2e, 0x53, 0x61, 0x76, 0x65, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, - 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x14, 0x2e, 0x53, 0x61, 0x76, 0x65, 0x50, - 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, - 0x12, 0x31, 0x0a, 0x0d, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, - 0x74, 0x12, 0x15, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, - 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x07, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, - 0x74, 0x22, 0x00, 0x12, 0x31, 0x0a, 0x0f, 0x53, 0x61, 0x76, 0x65, 0x50, 0x72, 0x6f, 0x64, 0x75, - 0x63, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x13, 0x2e, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, - 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x07, 0x2e, 0x52, 0x65, - 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x42, 0x1f, 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, 0x67, 0x69, - 0x74, 0x68, 0x75, 0x62, 0x2e, 0x67, 0x6f, 0x32, 0x6f, 0x2e, 0x72, 0x70, 0x63, 0x5a, 0x08, 0x2e, - 0x2f, 0x3b, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x1e, 0x0a, 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x12, + 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, + 0x61, 0x6d, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x76, 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x49, 0x64, 0x18, + 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x76, 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x49, 0x64, 0x12, + 0x18, 0x0a, 0x07, 0x62, 0x72, 0x61, 0x6e, 0x64, 0x49, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, + 0x52, 0x07, 0x62, 0x72, 0x61, 0x6e, 0x64, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, + 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x14, 0x0a, + 0x05, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x69, 0x6d, + 0x61, 0x67, 0x65, 0x12, 0x20, 0x0a, 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, + 0x6f, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, + 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x18, + 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x72, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x12, 0x14, 0x0a, + 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x73, 0x74, + 0x61, 0x74, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, 0x18, 0x0b, + 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, 0x12, 0x28, 0x0a, + 0x05, 0x61, 0x74, 0x74, 0x72, 0x73, 0x18, 0x0c, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x53, + 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x56, 0x61, 0x6c, 0x75, 0x65, + 0x52, 0x05, 0x61, 0x74, 0x74, 0x72, 0x73, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, + 0x65, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x63, 0x72, 0x65, + 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, + 0x65, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x75, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x22, 0xba, 0x03, 0x0a, 0x12, 0x53, 0x61, 0x76, 0x65, + 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, + 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x1e, + 0x0a, 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x12, 0x12, + 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, + 0x6d, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x76, 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x49, 0x64, 0x18, 0x04, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x76, 0x65, 0x6e, 0x64, 0x6f, 0x72, 0x49, 0x64, 0x12, 0x18, + 0x0a, 0x07, 0x62, 0x72, 0x61, 0x6e, 0x64, 0x49, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, + 0x07, 0x62, 0x72, 0x61, 0x6e, 0x64, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, + 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x14, 0x0a, 0x05, + 0x69, 0x6d, 0x61, 0x67, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x69, 0x6d, 0x61, + 0x67, 0x65, 0x12, 0x20, 0x0a, 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, + 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x64, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, + 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x18, 0x09, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x72, 0x65, 0x6d, 0x61, 0x72, 0x6b, 0x12, 0x14, 0x0a, 0x05, + 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x73, 0x74, 0x61, + 0x74, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, 0x18, 0x0b, 0x20, + 0x01, 0x28, 0x05, 0x52, 0x07, 0x73, 0x6f, 0x72, 0x74, 0x4e, 0x75, 0x6d, 0x12, 0x28, 0x0a, 0x05, + 0x61, 0x74, 0x74, 0x72, 0x73, 0x18, 0x0c, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x53, 0x50, + 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x52, + 0x05, 0x61, 0x74, 0x74, 0x72, 0x73, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, + 0x54, 0x69, 0x6d, 0x65, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x63, 0x72, 0x65, 0x61, + 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x54, 0x69, 0x6d, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x75, 0x70, 0x64, 0x61, + 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x2c, 0x0a, 0x11, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x0f, 0x20, 0x01, 0x28, + 0x08, 0x52, 0x11, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x44, 0x65, 0x73, 0x63, 0x72, 0x69, 0x70, + 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x46, 0x0a, 0x12, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, + 0x6e, 0x66, 0x6f, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x70, 0x72, + 0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x70, + 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x69, 0x6e, 0x66, 0x6f, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x69, 0x6e, 0x66, 0x6f, 0x22, 0x65, 0x0a, 0x13, + 0x53, 0x61, 0x76, 0x65, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x65, 0x72, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x65, 0x72, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x16, 0x0a, + 0x06, 0x65, 0x72, 0x72, 0x4d, 0x73, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x65, + 0x72, 0x72, 0x4d, 0x73, 0x67, 0x12, 0x1c, 0x0a, 0x09, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, + 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x09, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, + 0x74, 0x49, 0x64, 0x32, 0xde, 0x07, 0x0a, 0x0e, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x53, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x34, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x50, 0x72, 0x6f, + 0x64, 0x75, 0x63, 0x74, 0x4d, 0x6f, 0x64, 0x65, 0x6c, 0x12, 0x0f, 0x2e, 0x50, 0x72, 0x6f, 0x64, + 0x75, 0x63, 0x74, 0x4d, 0x6f, 0x64, 0x65, 0x6c, 0x49, 0x64, 0x1a, 0x0e, 0x2e, 0x53, 0x50, 0x72, + 0x6f, 0x64, 0x75, 0x63, 0x74, 0x4d, 0x6f, 0x64, 0x65, 0x6c, 0x22, 0x00, 0x12, 0x30, 0x0a, 0x09, + 0x47, 0x65, 0x74, 0x4d, 0x6f, 0x64, 0x65, 0x6c, 0x73, 0x12, 0x06, 0x2e, 0x45, 0x6d, 0x70, 0x74, + 0x79, 0x1a, 0x19, 0x2e, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x4d, 0x6f, 0x64, 0x65, 0x6c, + 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x2a, + 0x0a, 0x07, 0x47, 0x65, 0x74, 0x41, 0x74, 0x74, 0x72, 0x12, 0x0e, 0x2e, 0x50, 0x72, 0x6f, 0x64, + 0x75, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x49, 0x64, 0x1a, 0x0d, 0x2e, 0x53, 0x50, 0x72, 0x6f, + 0x64, 0x75, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x22, 0x00, 0x12, 0x36, 0x0a, 0x0b, 0x47, 0x65, + 0x74, 0x41, 0x74, 0x74, 0x72, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x12, 0x2e, 0x50, 0x72, 0x6f, 0x64, + 0x75, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x49, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x1a, 0x11, 0x2e, + 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x41, 0x74, 0x74, 0x72, 0x49, 0x74, 0x65, 0x6d, + 0x22, 0x00, 0x12, 0x37, 0x0a, 0x10, 0x53, 0x61, 0x76, 0x65, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, + 0x74, 0x4d, 0x6f, 0x64, 0x65, 0x6c, 0x12, 0x18, 0x2e, 0x53, 0x61, 0x76, 0x65, 0x50, 0x72, 0x6f, + 0x64, 0x75, 0x63, 0x74, 0x4d, 0x6f, 0x64, 0x65, 0x6c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x07, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x2a, 0x0a, 0x0c, 0x44, + 0x65, 0x6c, 0x65, 0x74, 0x65, 0x4d, 0x6f, 0x64, 0x65, 0x6c, 0x5f, 0x12, 0x0f, 0x2e, 0x50, 0x72, + 0x6f, 0x64, 0x75, 0x63, 0x74, 0x4d, 0x6f, 0x64, 0x65, 0x6c, 0x49, 0x64, 0x1a, 0x07, 0x2e, 0x52, + 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x24, 0x0a, 0x08, 0x47, 0x65, 0x74, 0x42, 0x72, + 0x61, 0x6e, 0x64, 0x12, 0x06, 0x2e, 0x49, 0x6e, 0x74, 0x36, 0x34, 0x1a, 0x0e, 0x2e, 0x53, 0x50, + 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x42, 0x72, 0x61, 0x6e, 0x64, 0x22, 0x00, 0x12, 0x26, 0x0a, + 0x09, 0x53, 0x61, 0x76, 0x65, 0x42, 0x72, 0x61, 0x6e, 0x64, 0x12, 0x0e, 0x2e, 0x53, 0x50, 0x72, + 0x6f, 0x64, 0x75, 0x63, 0x74, 0x42, 0x72, 0x61, 0x6e, 0x64, 0x1a, 0x07, 0x2e, 0x52, 0x65, 0x73, + 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x20, 0x0a, 0x0b, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x42, + 0x72, 0x61, 0x6e, 0x64, 0x12, 0x06, 0x2e, 0x49, 0x6e, 0x74, 0x36, 0x34, 0x1a, 0x07, 0x2e, 0x52, + 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x30, 0x0a, 0x09, 0x47, 0x65, 0x74, 0x42, 0x72, + 0x61, 0x6e, 0x64, 0x73, 0x12, 0x06, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x19, 0x2e, 0x50, + 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x42, 0x72, 0x61, 0x6e, 0x64, 0x4c, 0x69, 0x73, 0x74, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x37, 0x0a, 0x0b, 0x47, 0x65, 0x74, + 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x12, 0x13, 0x2e, 0x47, 0x65, 0x74, 0x43, 0x61, + 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x11, 0x2e, + 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, + 0x22, 0x00, 0x12, 0x23, 0x0a, 0x0e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x43, 0x61, 0x74, 0x65, + 0x67, 0x6f, 0x72, 0x79, 0x12, 0x06, 0x2e, 0x49, 0x6e, 0x74, 0x36, 0x34, 0x1a, 0x07, 0x2e, 0x52, + 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x4b, 0x0a, 0x0c, 0x53, 0x61, 0x76, 0x65, 0x43, + 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x12, 0x1b, 0x2e, 0x53, 0x61, 0x76, 0x65, 0x50, 0x72, + 0x6f, 0x64, 0x75, 0x63, 0x74, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1c, 0x2e, 0x53, 0x61, 0x76, 0x65, 0x50, 0x72, 0x6f, 0x64, 0x75, + 0x63, 0x74, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x00, 0x12, 0x44, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x43, 0x61, 0x74, 0x65, 0x67, + 0x6f, 0x72, 0x79, 0x54, 0x72, 0x65, 0x65, 0x4e, 0x6f, 0x64, 0x65, 0x12, 0x14, 0x2e, 0x43, 0x61, + 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x54, 0x72, 0x65, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x15, 0x2e, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x54, 0x72, 0x65, 0x65, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x3f, 0x0a, 0x12, 0x46, 0x69, + 0x6e, 0x64, 0x50, 0x61, 0x72, 0x65, 0x6e, 0x74, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, + 0x12, 0x12, 0x2e, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x13, 0x2e, 0x43, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x69, 0x65, + 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x25, 0x0a, 0x0a, 0x47, + 0x65, 0x74, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x12, 0x0a, 0x2e, 0x50, 0x72, 0x6f, 0x64, + 0x75, 0x63, 0x74, 0x49, 0x64, 0x1a, 0x09, 0x2e, 0x53, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, + 0x22, 0x00, 0x12, 0x3a, 0x0a, 0x0b, 0x53, 0x61, 0x76, 0x65, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, + 0x74, 0x12, 0x13, 0x2e, 0x53, 0x61, 0x76, 0x65, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x14, 0x2e, 0x53, 0x61, 0x76, 0x65, 0x50, 0x72, 0x6f, + 0x64, 0x75, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x31, + 0x0a, 0x0d, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x12, + 0x15, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x07, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, + 0x00, 0x12, 0x31, 0x0a, 0x0f, 0x53, 0x61, 0x76, 0x65, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, + 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x13, 0x2e, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x74, 0x49, 0x6e, + 0x66, 0x6f, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x07, 0x2e, 0x52, 0x65, 0x73, 0x75, + 0x6c, 0x74, 0x22, 0x00, 0x42, 0x1f, 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, 0x67, 0x69, 0x74, 0x68, + 0x75, 0x62, 0x2e, 0x67, 0x6f, 0x32, 0x6f, 0x2e, 0x72, 0x70, 0x63, 0x5a, 0x08, 0x2e, 0x2f, 0x3b, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -2632,7 +2750,7 @@ func file_product_service_proto_rawDescGZIP() []byte { return file_product_service_proto_rawDescData } -var file_product_service_proto_msgTypes = make([]protoimpl.MessageInfo, 28) +var file_product_service_proto_msgTypes = make([]protoimpl.MessageInfo, 29) var file_product_service_proto_goTypes = []interface{}{ (*CategoryIdRequest)(nil), // 0: CategoryIdRequest (*DeleteProductRequest)(nil), // 1: DeleteProductRequest @@ -2642,89 +2760,92 @@ var file_product_service_proto_goTypes = []interface{}{ (*ProductAttrItemId)(nil), // 5: ProductAttrItemId (*ProductModelListResponse)(nil), // 6: ProductModelListResponse (*SProductModel)(nil), // 7: SProductModel - (*SProductAttr)(nil), // 8: SProductAttr - (*SProductAttrItem)(nil), // 9: SProductAttrItem - (*SProductAttrValue)(nil), // 10: SProductAttrValue - (*SProductSpec)(nil), // 11: SProductSpec - (*SProductSpecItem)(nil), // 12: SProductSpecItem - (*ProductBrandListResponse)(nil), // 13: ProductBrandListResponse - (*SProductBrand)(nil), // 14: SProductBrand - (*SProductCategory)(nil), // 15: SProductCategory - (*SaveProductCategoryRequest)(nil), // 16: SaveProductCategoryRequest - (*SaveProductCategoryResponse)(nil), // 17: SaveProductCategoryResponse - (*SCategoryTree)(nil), // 18: SCategoryTree - (*GetCategoryRequest)(nil), // 19: GetCategoryRequest - (*CategoryTreeRequest)(nil), // 20: CategoryTreeRequest - (*CategoryTreeResponse)(nil), // 21: CategoryTreeResponse - (*CategoriesResponse)(nil), // 22: CategoriesResponse - (*SProduct)(nil), // 23: SProduct - (*SaveProductRequest)(nil), // 24: SaveProductRequest - (*ProductInfoRequest)(nil), // 25: ProductInfoRequest - (*SaveProductResponse)(nil), // 26: SaveProductResponse - nil, // 27: SProductCategory.OptionsEntry - (*Empty)(nil), // 28: Empty - (*Int64)(nil), // 29: Int64 - (*Result)(nil), // 30: Result + (*SaveProductModelRequest)(nil), // 8: SaveProductModelRequest + (*SProductAttr)(nil), // 9: SProductAttr + (*SProductAttrItem)(nil), // 10: SProductAttrItem + (*SProductAttrValue)(nil), // 11: SProductAttrValue + (*SProductSpec)(nil), // 12: SProductSpec + (*SProductSpecItem)(nil), // 13: SProductSpecItem + (*ProductBrandListResponse)(nil), // 14: ProductBrandListResponse + (*SProductBrand)(nil), // 15: SProductBrand + (*SProductCategory)(nil), // 16: SProductCategory + (*SaveProductCategoryRequest)(nil), // 17: SaveProductCategoryRequest + (*SaveProductCategoryResponse)(nil), // 18: SaveProductCategoryResponse + (*SCategoryTree)(nil), // 19: SCategoryTree + (*GetCategoryRequest)(nil), // 20: GetCategoryRequest + (*CategoryTreeRequest)(nil), // 21: CategoryTreeRequest + (*CategoryTreeResponse)(nil), // 22: CategoryTreeResponse + (*CategoriesResponse)(nil), // 23: CategoriesResponse + (*SProduct)(nil), // 24: SProduct + (*SaveProductRequest)(nil), // 25: SaveProductRequest + (*ProductInfoRequest)(nil), // 26: ProductInfoRequest + (*SaveProductResponse)(nil), // 27: SaveProductResponse + nil, // 28: SProductCategory.OptionsEntry + (*Empty)(nil), // 29: Empty + (*Int64)(nil), // 30: Int64 + (*Result)(nil), // 31: Result } var file_product_service_proto_depIdxs = []int32{ 7, // 0: ProductModelListResponse.value:type_name -> SProductModel - 8, // 1: SProductModel.attrs:type_name -> SProductAttr - 11, // 2: SProductModel.specs:type_name -> SProductSpec - 9, // 3: SProductAttr.items:type_name -> SProductAttrItem - 12, // 4: SProductSpec.items:type_name -> SProductSpecItem - 14, // 5: ProductBrandListResponse.value:type_name -> SProductBrand - 15, // 6: SProductCategory.children:type_name -> SProductCategory - 14, // 7: SProductCategory.brands:type_name -> SProductBrand - 7, // 8: SProductCategory.model:type_name -> SProductModel - 27, // 9: SProductCategory.options:type_name -> SProductCategory.OptionsEntry - 18, // 10: SCategoryTree.children:type_name -> SCategoryTree - 18, // 11: CategoryTreeResponse.value:type_name -> SCategoryTree - 15, // 12: CategoriesResponse.list:type_name -> SProductCategory - 10, // 13: SProduct.attrs:type_name -> SProductAttrValue - 10, // 14: SaveProductRequest.attrs:type_name -> SProductAttrValue - 3, // 15: ProductService.GetProductModel:input_type -> ProductModelId - 28, // 16: ProductService.GetModels:input_type -> Empty - 4, // 17: ProductService.GetAttr:input_type -> ProductAttrId - 5, // 18: ProductService.GetAttrItem:input_type -> ProductAttrItemId - 7, // 19: ProductService.SaveProductModel:input_type -> SProductModel - 3, // 20: ProductService.DeleteModel_:input_type -> ProductModelId - 29, // 21: ProductService.GetBrand:input_type -> Int64 - 14, // 22: ProductService.SaveBrand:input_type -> SProductBrand - 29, // 23: ProductService.DeleteBrand:input_type -> Int64 - 28, // 24: ProductService.GetBrands:input_type -> Empty - 19, // 25: ProductService.GetCategory:input_type -> GetCategoryRequest - 29, // 26: ProductService.DeleteCategory:input_type -> Int64 - 16, // 27: ProductService.SaveCategory:input_type -> SaveProductCategoryRequest - 20, // 28: ProductService.GetCategoryTreeNode:input_type -> CategoryTreeRequest - 0, // 29: ProductService.FindParentCategory:input_type -> CategoryIdRequest - 2, // 30: ProductService.GetProduct:input_type -> ProductId - 24, // 31: ProductService.SaveProduct:input_type -> SaveProductRequest - 1, // 32: ProductService.DeleteProduct:input_type -> DeleteProductRequest - 25, // 33: ProductService.SaveProductInfo:input_type -> ProductInfoRequest - 7, // 34: ProductService.GetProductModel:output_type -> SProductModel - 6, // 35: ProductService.GetModels:output_type -> ProductModelListResponse - 8, // 36: ProductService.GetAttr:output_type -> SProductAttr - 9, // 37: ProductService.GetAttrItem:output_type -> SProductAttrItem - 30, // 38: ProductService.SaveProductModel:output_type -> Result - 30, // 39: ProductService.DeleteModel_:output_type -> Result - 14, // 40: ProductService.GetBrand:output_type -> SProductBrand - 30, // 41: ProductService.SaveBrand:output_type -> Result - 30, // 42: ProductService.DeleteBrand:output_type -> Result - 13, // 43: ProductService.GetBrands:output_type -> ProductBrandListResponse - 15, // 44: ProductService.GetCategory:output_type -> SProductCategory - 30, // 45: ProductService.DeleteCategory:output_type -> Result - 17, // 46: ProductService.SaveCategory:output_type -> SaveProductCategoryResponse - 21, // 47: ProductService.GetCategoryTreeNode:output_type -> CategoryTreeResponse - 22, // 48: ProductService.FindParentCategory:output_type -> CategoriesResponse - 23, // 49: ProductService.GetProduct:output_type -> SProduct - 26, // 50: ProductService.SaveProduct:output_type -> SaveProductResponse - 30, // 51: ProductService.DeleteProduct:output_type -> Result - 30, // 52: ProductService.SaveProductInfo:output_type -> Result - 34, // [34:53] is the sub-list for method output_type - 15, // [15:34] is the sub-list for method input_type - 15, // [15:15] is the sub-list for extension type_name - 15, // [15:15] is the sub-list for extension extendee - 0, // [0:15] is the sub-list for field type_name + 9, // 1: SProductModel.attrs:type_name -> SProductAttr + 12, // 2: SProductModel.specs:type_name -> SProductSpec + 9, // 3: SaveProductModelRequest.attrs:type_name -> SProductAttr + 12, // 4: SaveProductModelRequest.specs:type_name -> SProductSpec + 10, // 5: SProductAttr.items:type_name -> SProductAttrItem + 13, // 6: SProductSpec.items:type_name -> SProductSpecItem + 15, // 7: ProductBrandListResponse.value:type_name -> SProductBrand + 16, // 8: SProductCategory.children:type_name -> SProductCategory + 15, // 9: SProductCategory.brands:type_name -> SProductBrand + 7, // 10: SProductCategory.model:type_name -> SProductModel + 28, // 11: SProductCategory.options:type_name -> SProductCategory.OptionsEntry + 19, // 12: SCategoryTree.children:type_name -> SCategoryTree + 19, // 13: CategoryTreeResponse.value:type_name -> SCategoryTree + 16, // 14: CategoriesResponse.list:type_name -> SProductCategory + 11, // 15: SProduct.attrs:type_name -> SProductAttrValue + 11, // 16: SaveProductRequest.attrs:type_name -> SProductAttrValue + 3, // 17: ProductService.GetProductModel:input_type -> ProductModelId + 29, // 18: ProductService.GetModels:input_type -> Empty + 4, // 19: ProductService.GetAttr:input_type -> ProductAttrId + 5, // 20: ProductService.GetAttrItem:input_type -> ProductAttrItemId + 8, // 21: ProductService.SaveProductModel:input_type -> SaveProductModelRequest + 3, // 22: ProductService.DeleteModel_:input_type -> ProductModelId + 30, // 23: ProductService.GetBrand:input_type -> Int64 + 15, // 24: ProductService.SaveBrand:input_type -> SProductBrand + 30, // 25: ProductService.DeleteBrand:input_type -> Int64 + 29, // 26: ProductService.GetBrands:input_type -> Empty + 20, // 27: ProductService.GetCategory:input_type -> GetCategoryRequest + 30, // 28: ProductService.DeleteCategory:input_type -> Int64 + 17, // 29: ProductService.SaveCategory:input_type -> SaveProductCategoryRequest + 21, // 30: ProductService.GetCategoryTreeNode:input_type -> CategoryTreeRequest + 0, // 31: ProductService.FindParentCategory:input_type -> CategoryIdRequest + 2, // 32: ProductService.GetProduct:input_type -> ProductId + 25, // 33: ProductService.SaveProduct:input_type -> SaveProductRequest + 1, // 34: ProductService.DeleteProduct:input_type -> DeleteProductRequest + 26, // 35: ProductService.SaveProductInfo:input_type -> ProductInfoRequest + 7, // 36: ProductService.GetProductModel:output_type -> SProductModel + 6, // 37: ProductService.GetModels:output_type -> ProductModelListResponse + 9, // 38: ProductService.GetAttr:output_type -> SProductAttr + 10, // 39: ProductService.GetAttrItem:output_type -> SProductAttrItem + 31, // 40: ProductService.SaveProductModel:output_type -> Result + 31, // 41: ProductService.DeleteModel_:output_type -> Result + 15, // 42: ProductService.GetBrand:output_type -> SProductBrand + 31, // 43: ProductService.SaveBrand:output_type -> Result + 31, // 44: ProductService.DeleteBrand:output_type -> Result + 14, // 45: ProductService.GetBrands:output_type -> ProductBrandListResponse + 16, // 46: ProductService.GetCategory:output_type -> SProductCategory + 31, // 47: ProductService.DeleteCategory:output_type -> Result + 18, // 48: ProductService.SaveCategory:output_type -> SaveProductCategoryResponse + 22, // 49: ProductService.GetCategoryTreeNode:output_type -> CategoryTreeResponse + 23, // 50: ProductService.FindParentCategory:output_type -> CategoriesResponse + 24, // 51: ProductService.GetProduct:output_type -> SProduct + 27, // 52: ProductService.SaveProduct:output_type -> SaveProductResponse + 31, // 53: ProductService.DeleteProduct:output_type -> Result + 31, // 54: ProductService.SaveProductInfo:output_type -> Result + 36, // [36:55] is the sub-list for method output_type + 17, // [17:36] is the sub-list for method input_type + 17, // [17:17] is the sub-list for extension type_name + 17, // [17:17] is the sub-list for extension extendee + 0, // [0:17] is the sub-list for field type_name } func init() { file_product_service_proto_init() } @@ -2831,7 +2952,7 @@ func file_product_service_proto_init() { } } file_product_service_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SProductAttr); i { + switch v := v.(*SaveProductModelRequest); i { case 0: return &v.state case 1: @@ -2843,7 +2964,7 @@ func file_product_service_proto_init() { } } file_product_service_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SProductAttrItem); i { + switch v := v.(*SProductAttr); i { case 0: return &v.state case 1: @@ -2855,7 +2976,7 @@ func file_product_service_proto_init() { } } file_product_service_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SProductAttrValue); i { + switch v := v.(*SProductAttrItem); i { case 0: return &v.state case 1: @@ -2867,7 +2988,7 @@ func file_product_service_proto_init() { } } file_product_service_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SProductSpec); i { + switch v := v.(*SProductAttrValue); i { case 0: return &v.state case 1: @@ -2879,7 +3000,7 @@ func file_product_service_proto_init() { } } file_product_service_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SProductSpecItem); i { + switch v := v.(*SProductSpec); i { case 0: return &v.state case 1: @@ -2891,7 +3012,7 @@ func file_product_service_proto_init() { } } file_product_service_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ProductBrandListResponse); i { + switch v := v.(*SProductSpecItem); i { case 0: return &v.state case 1: @@ -2903,7 +3024,7 @@ func file_product_service_proto_init() { } } file_product_service_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SProductBrand); i { + switch v := v.(*ProductBrandListResponse); i { case 0: return &v.state case 1: @@ -2915,7 +3036,7 @@ func file_product_service_proto_init() { } } file_product_service_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SProductCategory); i { + switch v := v.(*SProductBrand); i { case 0: return &v.state case 1: @@ -2927,7 +3048,7 @@ func file_product_service_proto_init() { } } file_product_service_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SaveProductCategoryRequest); i { + switch v := v.(*SProductCategory); i { case 0: return &v.state case 1: @@ -2939,7 +3060,7 @@ func file_product_service_proto_init() { } } file_product_service_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SaveProductCategoryResponse); i { + switch v := v.(*SaveProductCategoryRequest); i { case 0: return &v.state case 1: @@ -2951,7 +3072,7 @@ func file_product_service_proto_init() { } } file_product_service_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SCategoryTree); i { + switch v := v.(*SaveProductCategoryResponse); i { case 0: return &v.state case 1: @@ -2963,7 +3084,7 @@ func file_product_service_proto_init() { } } file_product_service_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetCategoryRequest); i { + switch v := v.(*SCategoryTree); i { case 0: return &v.state case 1: @@ -2975,7 +3096,7 @@ func file_product_service_proto_init() { } } file_product_service_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CategoryTreeRequest); i { + switch v := v.(*GetCategoryRequest); i { case 0: return &v.state case 1: @@ -2987,7 +3108,7 @@ func file_product_service_proto_init() { } } file_product_service_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CategoryTreeResponse); i { + switch v := v.(*CategoryTreeRequest); i { case 0: return &v.state case 1: @@ -2999,7 +3120,7 @@ func file_product_service_proto_init() { } } file_product_service_proto_msgTypes[22].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CategoriesResponse); i { + switch v := v.(*CategoryTreeResponse); i { case 0: return &v.state case 1: @@ -3011,7 +3132,7 @@ func file_product_service_proto_init() { } } file_product_service_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SProduct); i { + switch v := v.(*CategoriesResponse); i { case 0: return &v.state case 1: @@ -3023,7 +3144,7 @@ func file_product_service_proto_init() { } } file_product_service_proto_msgTypes[24].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SaveProductRequest); i { + switch v := v.(*SProduct); i { case 0: return &v.state case 1: @@ -3035,7 +3156,7 @@ func file_product_service_proto_init() { } } file_product_service_proto_msgTypes[25].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ProductInfoRequest); i { + switch v := v.(*SaveProductRequest); i { case 0: return &v.state case 1: @@ -3047,6 +3168,18 @@ func file_product_service_proto_init() { } } file_product_service_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ProductInfoRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_product_service_proto_msgTypes[27].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*SaveProductResponse); i { case 0: return &v.state @@ -3065,7 +3198,7 @@ func file_product_service_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_product_service_proto_rawDesc, NumEnums: 0, - NumMessages: 28, + NumMessages: 29, NumExtensions: 0, NumServices: 1, }, diff --git a/core/service/proto/product_service_grpc.pb.go b/core/service/proto/product_service_grpc.pb.go index 446407825..b29cf6e7b 100644 --- a/core/service/proto/product_service_grpc.pb.go +++ b/core/service/proto/product_service_grpc.pb.go @@ -53,7 +53,7 @@ type ProductServiceClient interface { // 获取属性项 GetAttrItem(ctx context.Context, in *ProductAttrItemId, opts ...grpc.CallOption) (*SProductAttrItem, error) // 保存产品模型 - SaveProductModel(ctx context.Context, in *SProductModel, opts ...grpc.CallOption) (*Result, error) + SaveProductModel(ctx context.Context, in *SaveProductModelRequest, opts ...grpc.CallOption) (*Result, error) // 删除产品模型 DeleteModel_(ctx context.Context, in *ProductModelId, opts ...grpc.CallOption) (*Result, error) // Get 产品品牌 @@ -130,7 +130,7 @@ func (c *productServiceClient) GetAttrItem(ctx context.Context, in *ProductAttrI return out, nil } -func (c *productServiceClient) SaveProductModel(ctx context.Context, in *SProductModel, opts ...grpc.CallOption) (*Result, error) { +func (c *productServiceClient) SaveProductModel(ctx context.Context, in *SaveProductModelRequest, opts ...grpc.CallOption) (*Result, error) { out := new(Result) err := c.cc.Invoke(ctx, ProductService_SaveProductModel_FullMethodName, in, out, opts...) if err != nil { @@ -278,7 +278,7 @@ type ProductServiceServer interface { // 获取属性项 GetAttrItem(context.Context, *ProductAttrItemId) (*SProductAttrItem, error) // 保存产品模型 - SaveProductModel(context.Context, *SProductModel) (*Result, error) + SaveProductModel(context.Context, *SaveProductModelRequest) (*Result, error) // 删除产品模型 DeleteModel_(context.Context, *ProductModelId) (*Result, error) // Get 产品品牌 @@ -328,7 +328,7 @@ func (UnimplementedProductServiceServer) GetAttr(context.Context, *ProductAttrId func (UnimplementedProductServiceServer) GetAttrItem(context.Context, *ProductAttrItemId) (*SProductAttrItem, error) { return nil, status.Errorf(codes.Unimplemented, "method GetAttrItem not implemented") } -func (UnimplementedProductServiceServer) SaveProductModel(context.Context, *SProductModel) (*Result, error) { +func (UnimplementedProductServiceServer) SaveProductModel(context.Context, *SaveProductModelRequest) (*Result, error) { return nil, status.Errorf(codes.Unimplemented, "method SaveProductModel not implemented") } func (UnimplementedProductServiceServer) DeleteModel_(context.Context, *ProductModelId) (*Result, error) { @@ -459,7 +459,7 @@ func _ProductService_GetAttrItem_Handler(srv interface{}, ctx context.Context, d } func _ProductService_SaveProductModel_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(SProductModel) + in := new(SaveProductModelRequest) if err := dec(in); err != nil { return nil, err } @@ -471,7 +471,7 @@ func _ProductService_SaveProductModel_Handler(srv interface{}, ctx context.Conte FullMethod: ProductService_SaveProductModel_FullMethodName, } handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ProductServiceServer).SaveProductModel(ctx, req.(*SProductModel)) + return srv.(ProductServiceServer).SaveProductModel(ctx, req.(*SaveProductModelRequest)) } return interceptor(ctx, in, info, handler) } From fa3f21937e321f275795472e33dc3613ba7d1c13 Mon Sep 17 00:00:00 2001 From: jarrysix Date: Thu, 16 Mar 2023 10:04:28 +0800 Subject: [PATCH 17/33] express_service.proto --- core/service/idl/express_service.proto | 2 ++ 1 file changed, 2 insertions(+) diff --git a/core/service/idl/express_service.proto b/core/service/idl/express_service.proto index 30b41b653..cf15fc80b 100644 --- a/core/service/idl/express_service.proto +++ b/core/service/idl/express_service.proto @@ -120,6 +120,8 @@ message SExpressTemplate { int64 addFee = 9; // 是否启用 bool enabled = 10; + // 省 + repeated SExpressAreaTemplate extra; } message ExpressTemplateId { From 9306436ccc59a6186270915e601aed5b5e3e988e Mon Sep 17 00:00:00 2001 From: jarrysix Date: Thu, 16 Mar 2023 16:46:12 +0800 Subject: [PATCH 18/33] feat: merchant express template --- core/domain/express/express.go | 120 +++-- core/domain/interface/express/express.go | 31 +- core/repos/express_repo.go | 15 +- core/service/idl/express_service.proto | 50 +- core/service/impl/2.express_service.go | 172 +++---- core/service/impl/orm_mapping.go | 4 +- core/service/impl/services.go | 2 +- core/service/proto/express_service.pb.go | 471 +++++++++--------- core/service/proto/express_service_grpc.pb.go | 65 +-- 9 files changed, 434 insertions(+), 496 deletions(-) diff --git a/core/domain/express/express.go b/core/domain/express/express.go index 185219bff..a62000377 100755 --- a/core/domain/express/express.go +++ b/core/domain/express/express.go @@ -9,13 +9,14 @@ package express import ( - "github.com/ixre/go2o/core/domain/interface/express" - "github.com/ixre/go2o/core/domain/interface/valueobject" - "github.com/ixre/go2o/core/infrastructure/domain" "math" "strconv" "strings" "sync" + + "github.com/ixre/go2o/core/domain/interface/express" + "github.com/ixre/go2o/core/domain/interface/valueobject" + "github.com/ixre/go2o/core/infrastructure/domain" ) const ( @@ -96,21 +97,23 @@ func (e *userExpressImpl) CreateCalculator() express.IExpressCalculator { var _ express.IExpressTemplate = new(expressTemplateImpl) type expressTemplateImpl struct { - _value *express.ExpressTemplate - _userExpress *userExpressImpl - _rep express.IExpressRepo - _areaList []express.ExpressAreaTemplate - _areaMap map[string]*express.ExpressAreaTemplate - _mux sync.Mutex - _valRepo valueobject.IValueRepo + _value *express.ExpressTemplate + _userExpress *userExpressImpl + _repo express.IExpressRepo + _regionList []express.RegionExpressTemplate + _regionIsChanged bool + _areaMap map[string]*express.RegionExpressTemplate + _mux sync.Mutex + _valRepo valueobject.IValueRepo } + func newExpressTemplate(u *userExpressImpl, v *express.ExpressTemplate, rep express.IExpressRepo, valRepo valueobject.IValueRepo) express.IExpressTemplate { return &expressTemplateImpl{ _value: v, _userExpress: u, - _rep: rep, + _repo: rep, _valRepo: valRepo, } } @@ -165,6 +168,13 @@ func (e *expressTemplateImpl) Set(v *express.ExpressTemplate) error { return err } +// SetRegionExpress implements express.IExpressTemplate +func (e *expressTemplateImpl) SetRegionExpress(arr *[]express.RegionExpressTemplate) error { + e._regionList = *arr + e._regionIsChanged = true + return nil +} + // 是否启用 func (e *expressTemplateImpl) Enabled() bool { return e._value.Enabled == 1 @@ -172,17 +182,52 @@ func (e *expressTemplateImpl) Enabled() bool { // 保存 func (e *expressTemplateImpl) Save() (int, error) { - id, err := e._rep.SaveExpressTemplate(e._value) + id, err := e._repo.SaveExpressTemplate(e._value) if err == nil { e._value.Id = id e._userExpress.arr = nil + if err == nil && e._regionIsChanged { + err = e.saveRegionExpress(e._regionList) + e._regionIsChanged = false + } } return id, err } +// 保存区域快递模板 +func (e *expressTemplateImpl) saveRegionExpress(items []express.RegionExpressTemplate) error { + // 获取存在的项 + old := e._repo.GetExpressTemplateAllAreaSet(e.GetDomainId()) + // 分析当前项目并加入到MAP中 + delList := []int{} + currMap := make(map[int]*express.RegionExpressTemplate, len(items)) + for _, v := range items { + currMap[v.Id] = &v + } + // 筛选出要删除的项 + for _, v := range old { + if currMap[v.Id] == nil { + delList = append(delList, v.Id) + } + } + // 删除项 + for _, v := range delList { + e._repo.DeleteAreaExpressTemplate(e.GetDomainId(), v) + } + // 保存项 + for _, v := range items { + i, err := e.saveAreaTemplate(&v) + if err != nil { + return err + } + v.Id = int(i) + } + e._regionList = items + return nil +} + // 保存地区快递模板 -func (e *expressTemplateImpl) SaveAreaTemplate(t *express.ExpressAreaTemplate) (int32, error) { - e.GetAllAreaTemplate() +func (e *expressTemplateImpl) saveAreaTemplate(t *express.RegionExpressTemplate) (int, error) { arr := e.getAreaCodeArray(t.CodeList) if arr == nil { return 0, express.ErrExpressTemplateMissingAreaCode @@ -201,15 +246,16 @@ func (e *expressTemplateImpl) SaveAreaTemplate(t *express.ExpressAreaTemplate) ( t.NameList = strings.Join(names, ",") // 保存,如果未出错,则更新缓存 - id, err := e._rep.SaveExpressTemplateAreaSet(t) + id, err := e._repo.SaveExpressTemplateAreaSet(t) if err == nil { - e._areaList = nil + e._regionList = nil e._areaMap = nil - e.GetAllAreaTemplate() + e.RegionExpress() } return id, err } +// 获取地区代码列表 func (e *expressTemplateImpl) getAreaCodeArray(codeList string) []string { codeList = strings.Trim(codeList, " ") if codeList == "" { @@ -220,8 +266,8 @@ func (e *expressTemplateImpl) getAreaCodeArray(codeList string) []string { // 初始化地区与运费的映射 func (e *expressTemplateImpl) initAreaMap() { - e._areaMap = make(map[string]*express.ExpressAreaTemplate, len(e._areaList)) - for _, v := range e._areaList { + e._areaMap = make(map[string]*express.RegionExpressTemplate, len(e._regionList)) + for _, v := range e._regionList { arr := e.getAreaCodeArray(v.CodeList) if arr == nil { continue @@ -239,46 +285,22 @@ func (e *expressTemplateImpl) initAreaMap() { } // 获取所有的地区快递模板 -func (e *expressTemplateImpl) GetAllAreaTemplate() []express.ExpressAreaTemplate { +func (e *expressTemplateImpl) RegionExpress() []express.RegionExpressTemplate { e._mux.Lock() - if e._areaList == nil { - e._areaList = e._rep.GetExpressTemplateAllAreaSet(e.GetDomainId()) + if e._regionList == nil { + e._regionList = e._repo.GetExpressTemplateAllAreaSet(e.GetDomainId()) e.initAreaMap() } e._mux.Unlock() - return e._areaList -} - -// 删除模板地区设定 -func (e *expressTemplateImpl) DeleteAreaSet(areaSetId int32) error { - e.GetAllAreaTemplate() - if e.GetAreaExpressTemplate(areaSetId) != nil { - err := e._rep.DeleteAreaExpressTemplate(e.GetDomainId(), areaSetId) - if err == nil { - e._areaList = nil - e._areaMap = nil - } - return err - } - return nil + return e._regionList } // 根据地区编码获取运费模板 -func (e *expressTemplateImpl) GetAreaExpressTemplateByAreaCode(areaCode string) *express.ExpressAreaTemplate { - e.GetAllAreaTemplate() +func (e *expressTemplateImpl) GetAreaExpressTemplateByAreaCode(areaCode string) *express.RegionExpressTemplate { + e.RegionExpress() return e._areaMap[areaCode] } -// 根据编号获取地区的运费模板 -func (e *expressTemplateImpl) GetAreaExpressTemplate(id int32) *express.ExpressAreaTemplate { - for _, v := range e.GetAllAreaTemplate() { - if v.Id == id { - return &v - } - } - return nil -} - type ExpressRepBase struct { } diff --git a/core/domain/interface/express/express.go b/core/domain/interface/express/express.go index 0d677722e..350374f9f 100755 --- a/core/domain/interface/express/express.go +++ b/core/domain/interface/express/express.go @@ -130,6 +130,12 @@ type ( // 设置地区的快递模板 Set(v *ExpressTemplate) error + // 设置地区运费 + SetRegionExpress(arr *[]RegionExpressTemplate) error + + // 地区运费设置 + RegionExpress() []RegionExpressTemplate + // 是否启用 Enabled() bool @@ -137,19 +143,8 @@ type ( Save() (int, error) // 根据地区编码获取运费模板 - GetAreaExpressTemplateByAreaCode(areaCode string) *ExpressAreaTemplate - - // 根据编号获取地区的运费模板 - GetAreaExpressTemplate(id int32) *ExpressAreaTemplate - - // 保存地区快递模板 - SaveAreaTemplate(t *ExpressAreaTemplate) (int32, error) + GetAreaExpressTemplateByAreaCode(areaCode string) *RegionExpressTemplate - // 获取所有的地区快递模板 - GetAllAreaTemplate() []ExpressAreaTemplate - - // 删除模板地区设定 - DeleteAreaSet(areaSetId int32) error } IExpressRepo interface { @@ -175,13 +170,13 @@ type ( SaveExpressTemplate(value *ExpressTemplate) (int, error) // 获取模板的所有地区设置 - GetExpressTemplateAllAreaSet(templateId int) []ExpressAreaTemplate + GetExpressTemplateAllAreaSet(templateId int) []RegionExpressTemplate // 保存模板的地区设置 - SaveExpressTemplateAreaSet(t *ExpressAreaTemplate) (int32, error) + SaveExpressTemplateAreaSet(t *RegionExpressTemplate) (int, error) // 删除模板的地区设置 - DeleteAreaExpressTemplate(templateId int, areaSetId int32) error + DeleteAreaExpressTemplate(templateId int, areaSetId int) error } // 快递服务商 @@ -227,11 +222,11 @@ type ( } // 快递地区模板 - ExpressAreaTemplate struct { + RegionExpressTemplate struct { // 模板编号 - Id int32 `db:"id" pk:"yes" auto:"yes"` + Id int `db:"id" pk:"yes" auto:"yes"` // 运费模板编号 - TemplateId int32 `db:"template_id"` + TemplateId int `db:"template_id"` // 地区编号列表,通常精确到省即可 CodeList string `db:"code_list"` // 地区名称列表 diff --git a/core/repos/express_repo.go b/core/repos/express_repo.go index 9a3375c6f..8f1fdec3a 100755 --- a/core/repos/express_repo.go +++ b/core/repos/express_repo.go @@ -9,12 +9,13 @@ package repos import ( + "sync" + expImpl "github.com/ixre/go2o/core/domain/express" "github.com/ixre/go2o/core/domain/interface/express" "github.com/ixre/go2o/core/domain/interface/valueobject" "github.com/ixre/gof/db" "github.com/ixre/gof/db/orm" - "sync" ) type expressRepo struct { @@ -92,20 +93,20 @@ func (er *expressRepo) SaveExpressTemplate(v *express.ExpressTemplate) (int, err } // 获取模板的所有地区设置 -func (er *expressRepo) GetExpressTemplateAllAreaSet(templateId int) []express.ExpressAreaTemplate { - var list []express.ExpressAreaTemplate +func (er *expressRepo) GetExpressTemplateAllAreaSet(templateId int) []express.RegionExpressTemplate { + var list []express.RegionExpressTemplate er.o.Select(&list, "template_id= $1", templateId) return list } // 保存模板的地区设置 -func (er *expressRepo) SaveExpressTemplateAreaSet(v *express.ExpressAreaTemplate) (int32, error) { - return orm.I32(orm.Save(er.o, v, int(v.Id))) +func (er *expressRepo) SaveExpressTemplateAreaSet(v *express.RegionExpressTemplate) (int, error) { + return orm.Save(er.o, v, int(v.Id)) } // 删除模板的地区设置 -func (er *expressRepo) DeleteAreaExpressTemplate(templateId int, areaSetId int32) error { - _, err := er.o.Delete(express.ExpressAreaTemplate{}, +func (er *expressRepo) DeleteAreaExpressTemplate(templateId int, areaSetId int) error { + _, err := er.o.Delete(express.RegionExpressTemplate{}, "id= $1 AND template_id = $2", areaSetId, templateId) return err } diff --git a/core/service/idl/express_service.proto b/core/service/idl/express_service.proto index cf15fc80b..fbeb9055d 100644 --- a/core/service/idl/express_service.proto +++ b/core/service/idl/express_service.proto @@ -21,7 +21,7 @@ service ExpressService { } // 保存快递模板 - rpc SaveTemplate (SExpressTemplate) returns (SaveTemplateResponse) { + rpc SaveExpressTemplate (SExpressTemplate) returns (SaveTemplateResponse) { } // 获取单个快递模板 rpc GetTemplate (ExpressTemplateId) returns (SExpressTemplate) { @@ -35,19 +35,11 @@ service ExpressService { // 保存地区快递模板 rpc SaveAreaTemplate (SaveAreaExpTemplateRequest) returns (Result) { } - // 删除模板地区设定 - rpc DeleteAreaTemplate (AreaTemplateId) returns (Result) { - } + // 根据地区编码获取运费模板 //rpc GetAreaExpressTemplateByAreaCode(userId int64, // templateId int32, areaCode string) *express.ExpressAreaTemplate - // 根据编号获取地区的运费模板 - //rpc GetAreaExpressTemplate(userId int64, - // templateId int32, id int32) *express.ExpressAreaTemplate - // - // 获取所有的地区快递模板 - //rpc GetAllAreaTemplate(userId int64, - // templateId int32) []express.ExpressAreaTemplate + } message ExpressProviderListResponse { @@ -120,25 +112,12 @@ message SExpressTemplate { int64 addFee = 9; // 是否启用 bool enabled = 10; - // 省 - repeated SExpressAreaTemplate extra; -} - -message ExpressTemplateId { - int64 sellerId = 1; - int64 templateId = 2; -} -message GetTemplatesRequest { - int64 sellerId = 1; - // 仅返回已启用的模板 - bool onlyEnabled = 2; -} -message ExpressTemplateListResponse { - repeated SExpressTemplate value = 1; + // 地区模板设置 + repeated SRegionExpressTemplate regions = 11; } // 快递地区模板 -message SExpressAreaTemplate { +message SRegionExpressTemplate { // 模板编号 int64 id = 1; // 地区编号列表,通常精确到省即可 @@ -155,10 +134,25 @@ message SExpressAreaTemplate { int64 addFee = 7; } +message ExpressTemplateId { + int64 sellerId = 1; + int64 templateId = 2; +} +message GetTemplatesRequest { + int64 sellerId = 1; + // 仅返回已启用的模板 + bool onlyEnabled = 2; +} +message ExpressTemplateListResponse { + repeated SExpressTemplate value = 1; +} + + + message SaveAreaExpTemplateRequest { int64 sellerId = 1; int64 templateId = 2; - SExpressAreaTemplate value = 3; + SRegionExpressTemplate value = 3; } message AreaTemplateId { diff --git a/core/service/impl/2.express_service.go b/core/service/impl/2.express_service.go index cd70c6e0e..f1ee4e969 100755 --- a/core/service/impl/2.express_service.go +++ b/core/service/impl/2.express_service.go @@ -18,26 +18,26 @@ import ( "github.com/ixre/gof/types" ) -var _ proto.ExpressServiceServer = new(expressService) +var _ proto.ExpressServiceServer = new(expressServiceImpl) -type expressService struct { - _rep express.IExpressRepo +type expressServiceImpl struct { + _repo express.IExpressRepo serviceUtil proto.UnimplementedExpressServiceServer } // 获取快递服务 -func NewExpressService(rep express.IExpressRepo) *expressService { - return &expressService{ - _rep: rep, +func NewExpressService(rep express.IExpressRepo) *expressServiceImpl { + return &expressServiceImpl{ + _repo: rep, } } // 获取快递公司 -func (e *expressService) GetExpressProvider(_ context.Context, name *proto.IdOrName) (*proto.SExpressProvider, error) { +func (e *expressServiceImpl) GetExpressProvider(_ context.Context, name *proto.IdOrName) (*proto.SExpressProvider, error) { var v *express.Provider if name.Id > 0 { - v = e._rep.GetExpressProvider(int32(name.Id)) + v = e._repo.GetExpressProvider(int32(name.Id)) } else { //v = e._rep.GetExpressProviderByName(name.Name) } @@ -47,17 +47,17 @@ func (e *expressService) GetExpressProvider(_ context.Context, name *proto.IdOrN return nil, express.ErrNotSupportProvider } -// 保存快递公司 -func (e *expressService) SaveExpressProvider(_ context.Context, r *proto.SExpressProvider) (*proto.Result, error) { +// SaveExpressProvider 保存快递公司 +func (e *expressServiceImpl) SaveExpressProvider(_ context.Context, r *proto.SExpressProvider) (*proto.Result, error) { v := e.parseProvider(r) - _, err := e._rep.SaveExpressProvider(v) + _, err := e._repo.SaveExpressProvider(v) return e.error(err), nil } -// 获取卖家的快递公司 -func (e *expressService) GetProviders(_ context.Context, _ *proto.Empty) (*proto.ExpressProviderListResponse, error) { +// GetProviders 获取卖家的快递公司 +func (e *expressServiceImpl) GetProviders(_ context.Context, _ *proto.Empty) (*proto.ExpressProviderListResponse, error) { var arr []*proto.SExpressProvider - list := e._rep.GetExpressProviders() + list := e._repo.GetExpressProviders() for _, v := range list { if v.Enabled == 1 { arr = append(arr, e.parseProviderDto(v)) @@ -69,8 +69,8 @@ func (e *expressService) GetProviders(_ context.Context, _ *proto.Empty) (*proto } // 获取卖家的快递公司分组 -func (e *expressService) GetProviderGroup(_ context.Context, _ *proto.Empty) (*proto.ExpressProviderGroupResponse, error) { - list := e._rep.GetExpressProviders() +func (e *expressServiceImpl) GetProviderGroup(_ context.Context, _ *proto.Empty) (*proto.ExpressProviderGroupResponse, error) { + list := e._repo.GetExpressProviders() for i, v := range list { if v.Enabled == 0 { list = append(list[:i], list[i+1:]...) @@ -115,8 +115,8 @@ func (e *expressService) GetProviderGroup(_ context.Context, _ *proto.Empty) (*p } // 保存快递模板 -func (e *expressService) SaveTemplate(_ context.Context, r *proto.SExpressTemplate) (*proto.SaveTemplateResponse, error) { - u := e._rep.GetUserExpress(int(r.SellerId)) +func (e *expressServiceImpl) SaveExpressTemplate(_ context.Context, r *proto.SExpressTemplate) (*proto.SaveTemplateResponse, error) { + u := e._repo.GetUserExpress(int(r.SellerId)) v := e.parseExpressTemplate(r) var ie express.IExpressTemplate if r.Id > 0 { @@ -129,6 +129,7 @@ func (e *expressService) SaveTemplate(_ context.Context, r *proto.SExpressTempla var id int err := ie.Set(v) if err == nil { + ie.SetRegionExpress(e.parseRegionsTemplate(r.Regions)) id, err = ie.Save() } ret := &proto.SaveTemplateResponse{ @@ -142,19 +143,22 @@ func (e *expressService) SaveTemplate(_ context.Context, r *proto.SExpressTempla } // 获取快递模板 -func (e *expressService) GetTemplate(_ context.Context, id *proto.ExpressTemplateId) (*proto.SExpressTemplate, error) { - u := e._rep.GetUserExpress(int(id.SellerId)) +func (e *expressServiceImpl) GetTemplate(_ context.Context, id *proto.ExpressTemplateId) (*proto.SExpressTemplate, error) { + u := e._repo.GetUserExpress(int(id.SellerId)) t := u.GetTemplate(int(id.TemplateId)) if t != nil { v := t.Value() - return e.parseExpressTemplateDto(&v), nil + v2 := t.RegionExpress() + ret := e.parseExpressTemplateDto(&v) + ret.Regions = e.parseExpressRegions(&v2) + return ret, nil } return nil, express.ErrNoSuchTemplate } // 获取所有的快递模板 -func (e *expressService) GetAllTemplate(userId int32) []*express.ExpressTemplate { - u := e._rep.GetUserExpress(int(userId)) +func (e *expressServiceImpl) GetAllTemplate(userId int32) []*express.ExpressTemplate { + u := e._repo.GetUserExpress(int(userId)) list := u.GetAllTemplate() arr := make([]*express.ExpressTemplate, len(list)) for i, v := range list { @@ -165,8 +169,8 @@ func (e *expressService) GetAllTemplate(userId int32) []*express.ExpressTemplate } // 获取可有的快递模板 -func (e *expressService) GetTemplates(_ context.Context, r *proto.GetTemplatesRequest) (*proto.ExpressTemplateListResponse, error) { - u := e._rep.GetUserExpress(int(r.SellerId)) +func (e *expressServiceImpl) GetTemplates(_ context.Context, r *proto.GetTemplatesRequest) (*proto.ExpressTemplateListResponse, error) { + u := e._repo.GetUserExpress(int(r.SellerId)) list := u.GetAllTemplate() var arr []*proto.SExpressTemplate for _, v := range list { @@ -181,81 +185,13 @@ func (e *expressService) GetTemplates(_ context.Context, r *proto.GetTemplatesRe } // 删除模板 -func (e *expressService) DeleteTemplate(_ context.Context, id *proto.ExpressTemplateId) (*proto.Result, error) { - u := e._rep.GetUserExpress(int(id.SellerId)) +func (e *expressServiceImpl) DeleteTemplate(_ context.Context, id *proto.ExpressTemplateId) (*proto.Result, error) { + u := e._repo.GetUserExpress(int(id.SellerId)) err := u.DeleteTemplate(int(id.TemplateId)) return e.error(err), nil } -// 保存地区快递模板 -func (e *expressService) SaveAreaTemplate(_ context.Context, r *proto.SaveAreaExpTemplateRequest) (*proto.Result, error) { - u := e._rep.GetUserExpress(int(r.SellerId)) - t := u.GetTemplate(int(r.TemplateId)) - var err error - if t == nil { - err = express.ErrNoSuchTemplate - } else { - v := e.parseAreaTemplate(r.Value) - v.TemplateId = int32(r.TemplateId) - _, err = t.SaveAreaTemplate(v) - } - return e.error(err), nil -} - -// 删除模板地区设定 -func (e *expressService) DeleteAreaTemplate(_ context.Context, id *proto.AreaTemplateId) (*proto.Result, error) { - u := e._rep.GetUserExpress(int(id.SellerId)) - t := u.GetTemplate(int(id.TemplateId)) - var err error - if t == nil { - err = express.ErrNoSuchTemplate - } else { - err = t.DeleteAreaSet(int32(id.AreaTemplateId)) - } - return e.error(err), nil -} - -//// 获取快递费,传入地区编码,根据单位值,如总重量。 -//func (e *expressService) GetExpressFee(userId int32,templateId int32, -// areaCode string, basisUnit float32) float32 { -// u := e.repo.GetUserExpress(userId) -// return u.GetExpressFee(templateId, areaCode, basisUnit) -//} - -// 根据地区编码获取运费模板 -func (e *expressService) GetAreaExpressTemplateByAreaCode(userId int64, - templateId int32, areaCode string) *express.ExpressAreaTemplate { - u := e._rep.GetUserExpress(int(userId)) - t := u.GetTemplate(int(templateId)) - if t != nil { - return t.GetAreaExpressTemplateByAreaCode(areaCode) - } - return nil -} - -// 根据编号获取地区的运费模板 -func (e *expressService) GetAreaExpressTemplate(userId int64, - templateId int32, id int32) *express.ExpressAreaTemplate { - u := e._rep.GetUserExpress(int(userId)) - t := u.GetTemplate(int(templateId)) - if t != nil { - return t.GetAreaExpressTemplate(id) - } - return nil -} - -// 获取所有的地区快递模板 -func (e *expressService) GetAllAreaTemplate(userId int64, - templateId int32) []express.ExpressAreaTemplate { - u := e._rep.GetUserExpress(int(userId)) - t := u.GetTemplate(int(templateId)) - if t != nil { - return t.GetAllAreaTemplate() - } - return []express.ExpressAreaTemplate{} -} - -func (e *expressService) parseProviderDto(v *express.Provider) *proto.SExpressProvider { +func (e *expressServiceImpl) parseProviderDto(v *express.Provider) *proto.SExpressProvider { return &proto.SExpressProvider{ Id: int64(v.Id), Name: v.Name, @@ -267,7 +203,7 @@ func (e *expressService) parseProviderDto(v *express.Provider) *proto.SExpressPr } } -func (e *expressService) parseProvider(r *proto.SExpressProvider) *express.Provider { +func (e *expressServiceImpl) parseProvider(r *proto.SExpressProvider) *express.Provider { return &express.Provider{ Id: int32(r.Id), Name: r.Name, @@ -279,7 +215,7 @@ func (e *expressService) parseProvider(r *proto.SExpressProvider) *express.Provi } } -func (e *expressService) parseExpressTemplate(r *proto.SExpressTemplate) *express.ExpressTemplate { +func (e *expressServiceImpl) parseExpressTemplate(r *proto.SExpressTemplate) *express.ExpressTemplate { return &express.ExpressTemplate{ Id: int(r.Id), VendorId: int(r.SellerId), @@ -294,7 +230,7 @@ func (e *expressService) parseExpressTemplate(r *proto.SExpressTemplate) *expres } } -func (e *expressService) parseExpressTemplateDto(v *express.ExpressTemplate) *proto.SExpressTemplate { +func (e *expressServiceImpl) parseExpressTemplateDto(v *express.ExpressTemplate) *proto.SExpressTemplate { return &proto.SExpressTemplate{ Id: int64(v.Id), SellerId: int64(v.VendorId), @@ -309,14 +245,34 @@ func (e *expressService) parseExpressTemplateDto(v *express.ExpressTemplate) *pr } } -func (e *expressService) parseAreaTemplate(v *proto.SExpressAreaTemplate) *express.ExpressAreaTemplate { - return &express.ExpressAreaTemplate{ - Id: int32(v.Id), - CodeList: v.CodeList, - NameList: v.NameList, - FirstUnit: v.FirstUnit, - FirstFee: v.FirstFee, - AddUnit: v.AddUnit, - AddFee: v.AddFee, +func (e *expressServiceImpl) parseExpressRegions(regions *[]express.RegionExpressTemplate) []*proto.SRegionExpressTemplate { + arr := make([]*proto.SRegionExpressTemplate, 0) + for _, v := range *regions { + arr = append(arr, &proto.SRegionExpressTemplate{ + Id: int64(v.Id), + CodeList: v.CodeList, + NameList: v.NameList, + FirstUnit: v.FirstUnit, + FirstFee: v.FirstFee, + AddUnit: v.AddUnit, + AddFee: v.AddFee, + }) + } + return arr +} + +func (e *expressServiceImpl) parseRegionsTemplate(regions []*proto.SRegionExpressTemplate) *[]express.RegionExpressTemplate { + arr := make([]express.RegionExpressTemplate, 0) + for _, v := range regions { + arr = append(arr, express.RegionExpressTemplate{ + Id: int(v.Id), + CodeList: v.CodeList, + NameList: v.NameList, + FirstUnit: v.FirstUnit, + FirstFee: v.FirstFee, + AddUnit: v.AddUnit, + AddFee: v.AddFee, + }) } + return &arr } diff --git a/core/service/impl/orm_mapping.go b/core/service/impl/orm_mapping.go index fe415daad..e8d37443d 100644 --- a/core/service/impl/orm_mapping.go +++ b/core/service/impl/orm_mapping.go @@ -14,7 +14,7 @@ import ( "github.com/ixre/go2o/core/domain/interface/merchant/shop" "github.com/ixre/go2o/core/domain/interface/merchant/user" "github.com/ixre/go2o/core/domain/interface/merchant/wholesaler" - "github.com/ixre/go2o/core/domain/interface/message" + mss "github.com/ixre/go2o/core/domain/interface/message" "github.com/ixre/go2o/core/domain/interface/order" "github.com/ixre/go2o/core/domain/interface/payment" "github.com/ixre/go2o/core/domain/interface/personfinance" @@ -102,7 +102,7 @@ func OrmMapping(orm orm.Orm) { // Express orm.Mapping(express.Provider{}, "express_provider") orm.Mapping(express.ExpressTemplate{}, "mch_express_template") - orm.Mapping(express.ExpressAreaTemplate{}, "express_area_set") + orm.Mapping(express.RegionExpressTemplate{}, "express_area_set") // Shipment orm.Mapping(shipment.ShipmentOrder{}, "ship_order") diff --git a/core/service/impl/services.go b/core/service/impl/services.go index 9629b89ac..7ce55c505 100755 --- a/core/service/impl/services.go +++ b/core/service/impl/services.go @@ -60,7 +60,7 @@ var ( // 消息服务 MessageService *messageService // 快递服务 - ExpressService *expressService + ExpressService *expressServiceImpl // 配送服务 ShipmentService *shipmentServiceImpl // 内容服务 diff --git a/core/service/proto/express_service.pb.go b/core/service/proto/express_service.pb.go index ebb446b50..2b96b8903 100644 --- a/core/service/proto/express_service.pb.go +++ b/core/service/proto/express_service.pb.go @@ -370,6 +370,8 @@ type SExpressTemplate struct { AddFee int64 `protobuf:"varint,9,opt,name=addFee,proto3" json:"addFee"` // 是否启用 Enabled bool `protobuf:"varint,10,opt,name=enabled,proto3" json:"enabled"` + // 地区模板设置 + Regions []*SRegionExpressTemplate `protobuf:"bytes,11,rep,name=regions,proto3" json:"regions"` } func (x *SExpressTemplate) Reset() { @@ -474,17 +476,37 @@ func (x *SExpressTemplate) GetEnabled() bool { return false } -type ExpressTemplateId struct { +func (x *SExpressTemplate) GetRegions() []*SRegionExpressTemplate { + if x != nil { + return x.Regions + } + return nil +} + +// 快递地区模板 +type SRegionExpressTemplate struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - SellerId int64 `protobuf:"varint,1,opt,name=sellerId,proto3" json:"sellerId"` - TemplateId int64 `protobuf:"varint,2,opt,name=templateId,proto3" json:"templateId"` + // 模板编号 + Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id"` + // 地区编号列表,通常精确到省即可 + CodeList string `protobuf:"bytes,2,opt,name=codeList,proto3" json:"codeList"` + // 地区名称列表 + NameList string `protobuf:"bytes,3,opt,name=nameList,proto3" json:"nameList"` + // 首次数值,如 首重为2kg + FirstUnit int32 `protobuf:"varint,4,opt,name=firstUnit,proto3" json:"firstUnit"` + // 首次金额,如首重10元 + FirstFee int64 `protobuf:"varint,5,opt,name=firstFee,proto3" json:"firstFee"` + // 增加数值,如续重1kg + AddUnit int32 `protobuf:"varint,6,opt,name=addUnit,proto3" json:"addUnit"` + // 增加产生费用,如续重1kg 10元 + AddFee int64 `protobuf:"varint,7,opt,name=addFee,proto3" json:"addFee"` } -func (x *ExpressTemplateId) Reset() { - *x = ExpressTemplateId{} +func (x *SRegionExpressTemplate) Reset() { + *x = SRegionExpressTemplate{} if protoimpl.UnsafeEnabled { mi := &file_express_service_proto_msgTypes[6] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -492,13 +514,13 @@ func (x *ExpressTemplateId) Reset() { } } -func (x *ExpressTemplateId) String() string { +func (x *SRegionExpressTemplate) String() string { return protoimpl.X.MessageStringOf(x) } -func (*ExpressTemplateId) ProtoMessage() {} +func (*SRegionExpressTemplate) ProtoMessage() {} -func (x *ExpressTemplateId) ProtoReflect() protoreflect.Message { +func (x *SRegionExpressTemplate) ProtoReflect() protoreflect.Message { mi := &file_express_service_proto_msgTypes[6] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -510,37 +532,71 @@ func (x *ExpressTemplateId) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use ExpressTemplateId.ProtoReflect.Descriptor instead. -func (*ExpressTemplateId) Descriptor() ([]byte, []int) { +// Deprecated: Use SRegionExpressTemplate.ProtoReflect.Descriptor instead. +func (*SRegionExpressTemplate) Descriptor() ([]byte, []int) { return file_express_service_proto_rawDescGZIP(), []int{6} } -func (x *ExpressTemplateId) GetSellerId() int64 { +func (x *SRegionExpressTemplate) GetId() int64 { if x != nil { - return x.SellerId + return x.Id } return 0 } -func (x *ExpressTemplateId) GetTemplateId() int64 { +func (x *SRegionExpressTemplate) GetCodeList() string { if x != nil { - return x.TemplateId + return x.CodeList + } + return "" +} + +func (x *SRegionExpressTemplate) GetNameList() string { + if x != nil { + return x.NameList + } + return "" +} + +func (x *SRegionExpressTemplate) GetFirstUnit() int32 { + if x != nil { + return x.FirstUnit } return 0 } -type GetTemplatesRequest struct { +func (x *SRegionExpressTemplate) GetFirstFee() int64 { + if x != nil { + return x.FirstFee + } + return 0 +} + +func (x *SRegionExpressTemplate) GetAddUnit() int32 { + if x != nil { + return x.AddUnit + } + return 0 +} + +func (x *SRegionExpressTemplate) GetAddFee() int64 { + if x != nil { + return x.AddFee + } + return 0 +} + +type ExpressTemplateId struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - SellerId int64 `protobuf:"varint,1,opt,name=sellerId,proto3" json:"sellerId"` - // 仅返回已启用的模板 - OnlyEnabled bool `protobuf:"varint,2,opt,name=onlyEnabled,proto3" json:"onlyEnabled"` + SellerId int64 `protobuf:"varint,1,opt,name=sellerId,proto3" json:"sellerId"` + TemplateId int64 `protobuf:"varint,2,opt,name=templateId,proto3" json:"templateId"` } -func (x *GetTemplatesRequest) Reset() { - *x = GetTemplatesRequest{} +func (x *ExpressTemplateId) Reset() { + *x = ExpressTemplateId{} if protoimpl.UnsafeEnabled { mi := &file_express_service_proto_msgTypes[7] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -548,13 +604,13 @@ func (x *GetTemplatesRequest) Reset() { } } -func (x *GetTemplatesRequest) String() string { +func (x *ExpressTemplateId) String() string { return protoimpl.X.MessageStringOf(x) } -func (*GetTemplatesRequest) ProtoMessage() {} +func (*ExpressTemplateId) ProtoMessage() {} -func (x *GetTemplatesRequest) ProtoReflect() protoreflect.Message { +func (x *ExpressTemplateId) ProtoReflect() protoreflect.Message { mi := &file_express_service_proto_msgTypes[7] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -566,35 +622,37 @@ func (x *GetTemplatesRequest) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use GetTemplatesRequest.ProtoReflect.Descriptor instead. -func (*GetTemplatesRequest) Descriptor() ([]byte, []int) { +// Deprecated: Use ExpressTemplateId.ProtoReflect.Descriptor instead. +func (*ExpressTemplateId) Descriptor() ([]byte, []int) { return file_express_service_proto_rawDescGZIP(), []int{7} } -func (x *GetTemplatesRequest) GetSellerId() int64 { +func (x *ExpressTemplateId) GetSellerId() int64 { if x != nil { return x.SellerId } return 0 } -func (x *GetTemplatesRequest) GetOnlyEnabled() bool { +func (x *ExpressTemplateId) GetTemplateId() int64 { if x != nil { - return x.OnlyEnabled + return x.TemplateId } - return false + return 0 } -type ExpressTemplateListResponse struct { +type GetTemplatesRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Value []*SExpressTemplate `protobuf:"bytes,1,rep,name=value,proto3" json:"value"` + SellerId int64 `protobuf:"varint,1,opt,name=sellerId,proto3" json:"sellerId"` + // 仅返回已启用的模板 + OnlyEnabled bool `protobuf:"varint,2,opt,name=onlyEnabled,proto3" json:"onlyEnabled"` } -func (x *ExpressTemplateListResponse) Reset() { - *x = ExpressTemplateListResponse{} +func (x *GetTemplatesRequest) Reset() { + *x = GetTemplatesRequest{} if protoimpl.UnsafeEnabled { mi := &file_express_service_proto_msgTypes[8] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -602,13 +660,13 @@ func (x *ExpressTemplateListResponse) Reset() { } } -func (x *ExpressTemplateListResponse) String() string { +func (x *GetTemplatesRequest) String() string { return protoimpl.X.MessageStringOf(x) } -func (*ExpressTemplateListResponse) ProtoMessage() {} +func (*GetTemplatesRequest) ProtoMessage() {} -func (x *ExpressTemplateListResponse) ProtoReflect() protoreflect.Message { +func (x *GetTemplatesRequest) ProtoReflect() protoreflect.Message { mi := &file_express_service_proto_msgTypes[8] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -620,42 +678,35 @@ func (x *ExpressTemplateListResponse) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use ExpressTemplateListResponse.ProtoReflect.Descriptor instead. -func (*ExpressTemplateListResponse) Descriptor() ([]byte, []int) { +// Deprecated: Use GetTemplatesRequest.ProtoReflect.Descriptor instead. +func (*GetTemplatesRequest) Descriptor() ([]byte, []int) { return file_express_service_proto_rawDescGZIP(), []int{8} } -func (x *ExpressTemplateListResponse) GetValue() []*SExpressTemplate { +func (x *GetTemplatesRequest) GetSellerId() int64 { if x != nil { - return x.Value + return x.SellerId } - return nil + return 0 } -// 快递地区模板 -type SExpressAreaTemplate struct { +func (x *GetTemplatesRequest) GetOnlyEnabled() bool { + if x != nil { + return x.OnlyEnabled + } + return false +} + +type ExpressTemplateListResponse struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - // 模板编号 - Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id"` - // 地区编号列表,通常精确到省即可 - CodeList string `protobuf:"bytes,2,opt,name=codeList,proto3" json:"codeList"` - // 地区名称列表 - NameList string `protobuf:"bytes,3,opt,name=nameList,proto3" json:"nameList"` - // 首次数值,如 首重为2kg - FirstUnit int32 `protobuf:"varint,4,opt,name=firstUnit,proto3" json:"firstUnit"` - // 首次金额,如首重10元 - FirstFee int64 `protobuf:"varint,5,opt,name=firstFee,proto3" json:"firstFee"` - // 增加数值,如续重1kg - AddUnit int32 `protobuf:"varint,6,opt,name=addUnit,proto3" json:"addUnit"` - // 增加产生费用,如续重1kg 10元 - AddFee int64 `protobuf:"varint,7,opt,name=addFee,proto3" json:"addFee"` + Value []*SExpressTemplate `protobuf:"bytes,1,rep,name=value,proto3" json:"value"` } -func (x *SExpressAreaTemplate) Reset() { - *x = SExpressAreaTemplate{} +func (x *ExpressTemplateListResponse) Reset() { + *x = ExpressTemplateListResponse{} if protoimpl.UnsafeEnabled { mi := &file_express_service_proto_msgTypes[9] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -663,13 +714,13 @@ func (x *SExpressAreaTemplate) Reset() { } } -func (x *SExpressAreaTemplate) String() string { +func (x *ExpressTemplateListResponse) String() string { return protoimpl.X.MessageStringOf(x) } -func (*SExpressAreaTemplate) ProtoMessage() {} +func (*ExpressTemplateListResponse) ProtoMessage() {} -func (x *SExpressAreaTemplate) ProtoReflect() protoreflect.Message { +func (x *ExpressTemplateListResponse) ProtoReflect() protoreflect.Message { mi := &file_express_service_proto_msgTypes[9] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -681,58 +732,16 @@ func (x *SExpressAreaTemplate) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use SExpressAreaTemplate.ProtoReflect.Descriptor instead. -func (*SExpressAreaTemplate) Descriptor() ([]byte, []int) { +// Deprecated: Use ExpressTemplateListResponse.ProtoReflect.Descriptor instead. +func (*ExpressTemplateListResponse) Descriptor() ([]byte, []int) { return file_express_service_proto_rawDescGZIP(), []int{9} } -func (x *SExpressAreaTemplate) GetId() int64 { - if x != nil { - return x.Id - } - return 0 -} - -func (x *SExpressAreaTemplate) GetCodeList() string { - if x != nil { - return x.CodeList - } - return "" -} - -func (x *SExpressAreaTemplate) GetNameList() string { - if x != nil { - return x.NameList - } - return "" -} - -func (x *SExpressAreaTemplate) GetFirstUnit() int32 { - if x != nil { - return x.FirstUnit - } - return 0 -} - -func (x *SExpressAreaTemplate) GetFirstFee() int64 { - if x != nil { - return x.FirstFee - } - return 0 -} - -func (x *SExpressAreaTemplate) GetAddUnit() int32 { - if x != nil { - return x.AddUnit - } - return 0 -} - -func (x *SExpressAreaTemplate) GetAddFee() int64 { +func (x *ExpressTemplateListResponse) GetValue() []*SExpressTemplate { if x != nil { - return x.AddFee + return x.Value } - return 0 + return nil } type SaveAreaExpTemplateRequest struct { @@ -740,9 +749,9 @@ type SaveAreaExpTemplateRequest struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - SellerId int64 `protobuf:"varint,1,opt,name=sellerId,proto3" json:"sellerId"` - TemplateId int64 `protobuf:"varint,2,opt,name=templateId,proto3" json:"templateId"` - Value *SExpressAreaTemplate `protobuf:"bytes,3,opt,name=value,proto3" json:"value"` + SellerId int64 `protobuf:"varint,1,opt,name=sellerId,proto3" json:"sellerId"` + TemplateId int64 `protobuf:"varint,2,opt,name=templateId,proto3" json:"templateId"` + Value *SRegionExpressTemplate `protobuf:"bytes,3,opt,name=value,proto3" json:"value"` } func (x *SaveAreaExpTemplateRequest) Reset() { @@ -791,7 +800,7 @@ func (x *SaveAreaExpTemplateRequest) GetTemplateId() int64 { return 0 } -func (x *SaveAreaExpTemplateRequest) GetValue() *SExpressAreaTemplate { +func (x *SaveAreaExpTemplateRequest) GetValue() *SRegionExpressTemplate { if x != nil { return x.Value } @@ -961,7 +970,7 @@ var file_express_service_proto_rawDesc = []byte{ 0x12, 0x18, 0x0a, 0x07, 0x61, 0x70, 0x69, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x61, 0x70, 0x69, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x18, 0x07, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x65, 0x6e, 0x61, - 0x62, 0x6c, 0x65, 0x64, 0x22, 0x86, 0x02, 0x0a, 0x10, 0x53, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, + 0x62, 0x6c, 0x65, 0x64, 0x22, 0xb9, 0x02, 0x0a, 0x10, 0x53, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x65, 0x6c, 0x6c, 0x65, 0x72, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x73, 0x65, 0x6c, @@ -977,97 +986,98 @@ var file_express_service_proto_rawDesc = []byte{ 0x28, 0x05, 0x52, 0x07, 0x61, 0x64, 0x64, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x61, 0x64, 0x64, 0x46, 0x65, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x61, 0x64, 0x64, 0x46, 0x65, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x18, 0x0a, - 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x22, 0x4f, 0x0a, - 0x11, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, - 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x65, 0x6c, 0x6c, 0x65, 0x72, 0x49, 0x64, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x73, 0x65, 0x6c, 0x6c, 0x65, 0x72, 0x49, 0x64, 0x12, 0x1e, - 0x0a, 0x0a, 0x74, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x0a, 0x74, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x49, 0x64, 0x22, 0x53, - 0x0a, 0x13, 0x47, 0x65, 0x74, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x65, 0x6c, 0x6c, 0x65, 0x72, 0x49, - 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x73, 0x65, 0x6c, 0x6c, 0x65, 0x72, 0x49, - 0x64, 0x12, 0x20, 0x0a, 0x0b, 0x6f, 0x6e, 0x6c, 0x79, 0x45, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0b, 0x6f, 0x6e, 0x6c, 0x79, 0x45, 0x6e, 0x61, 0x62, - 0x6c, 0x65, 0x64, 0x22, 0x46, 0x0a, 0x1b, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x65, - 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x12, 0x27, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x03, 0x28, - 0x0b, 0x32, 0x11, 0x2e, 0x53, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x65, 0x6d, 0x70, - 0x6c, 0x61, 0x74, 0x65, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0xca, 0x01, 0x0a, 0x14, - 0x53, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x41, 0x72, 0x65, 0x61, 0x54, 0x65, 0x6d, 0x70, - 0x6c, 0x61, 0x74, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x02, 0x69, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x63, 0x6f, 0x64, 0x65, 0x4c, 0x69, 0x73, 0x74, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x63, 0x6f, 0x64, 0x65, 0x4c, 0x69, 0x73, 0x74, - 0x12, 0x1a, 0x0a, 0x08, 0x6e, 0x61, 0x6d, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x08, 0x6e, 0x61, 0x6d, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x1c, 0x0a, 0x09, - 0x66, 0x69, 0x72, 0x73, 0x74, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, - 0x09, 0x66, 0x69, 0x72, 0x73, 0x74, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x66, 0x69, - 0x72, 0x73, 0x74, 0x46, 0x65, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x66, 0x69, - 0x72, 0x73, 0x74, 0x46, 0x65, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x55, 0x6e, 0x69, - 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x61, 0x64, 0x64, 0x55, 0x6e, 0x69, 0x74, - 0x12, 0x16, 0x0a, 0x06, 0x61, 0x64, 0x64, 0x46, 0x65, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x06, 0x61, 0x64, 0x64, 0x46, 0x65, 0x65, 0x22, 0x85, 0x01, 0x0a, 0x1a, 0x53, 0x61, 0x76, - 0x65, 0x41, 0x72, 0x65, 0x61, 0x45, 0x78, 0x70, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, + 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x64, 0x12, 0x31, 0x0a, + 0x07, 0x72, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x0b, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x17, + 0x2e, 0x53, 0x52, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, + 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x52, 0x07, 0x72, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x73, + 0x22, 0xcc, 0x01, 0x0a, 0x16, 0x53, 0x52, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x45, 0x78, 0x70, 0x72, + 0x65, 0x73, 0x73, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, + 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x63, + 0x6f, 0x64, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x63, + 0x6f, 0x64, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x6e, 0x61, 0x6d, 0x65, 0x4c, + 0x69, 0x73, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x6e, 0x61, 0x6d, 0x65, 0x4c, + 0x69, 0x73, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x66, 0x69, 0x72, 0x73, 0x74, 0x55, 0x6e, 0x69, 0x74, + 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x66, 0x69, 0x72, 0x73, 0x74, 0x55, 0x6e, 0x69, + 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x66, 0x69, 0x72, 0x73, 0x74, 0x46, 0x65, 0x65, 0x18, 0x05, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x08, 0x66, 0x69, 0x72, 0x73, 0x74, 0x46, 0x65, 0x65, 0x12, 0x18, 0x0a, + 0x07, 0x61, 0x64, 0x64, 0x55, 0x6e, 0x69, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, + 0x61, 0x64, 0x64, 0x55, 0x6e, 0x69, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x61, 0x64, 0x64, 0x46, 0x65, + 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x61, 0x64, 0x64, 0x46, 0x65, 0x65, 0x22, + 0x4f, 0x0a, 0x11, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, + 0x74, 0x65, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x65, 0x6c, 0x6c, 0x65, 0x72, 0x49, 0x64, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x73, 0x65, 0x6c, 0x6c, 0x65, 0x72, 0x49, 0x64, + 0x12, 0x1e, 0x0a, 0x0a, 0x74, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x49, 0x64, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x74, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x49, 0x64, + 0x22, 0x53, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x65, 0x6c, 0x6c, 0x65, 0x72, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x73, 0x65, 0x6c, 0x6c, 0x65, - 0x72, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x74, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x49, - 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x74, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, - 0x65, 0x49, 0x64, 0x12, 0x2b, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x15, 0x2e, 0x53, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x41, 0x72, 0x65, - 0x61, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, - 0x22, 0x74, 0x0a, 0x0e, 0x41, 0x72, 0x65, 0x61, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, - 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x65, 0x6c, 0x6c, 0x65, 0x72, 0x49, 0x64, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x73, 0x65, 0x6c, 0x6c, 0x65, 0x72, 0x49, 0x64, 0x12, 0x1e, - 0x0a, 0x0a, 0x74, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x0a, 0x74, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x49, 0x64, 0x12, 0x26, - 0x0a, 0x0e, 0x61, 0x72, 0x65, 0x61, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x49, 0x64, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x61, 0x72, 0x65, 0x61, 0x54, 0x65, 0x6d, 0x70, - 0x6c, 0x61, 0x74, 0x65, 0x49, 0x64, 0x22, 0x68, 0x0a, 0x14, 0x53, 0x61, 0x76, 0x65, 0x54, 0x65, - 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, - 0x0a, 0x07, 0x65, 0x72, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, - 0x07, 0x65, 0x72, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x65, 0x72, 0x72, 0x4d, - 0x73, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x65, 0x72, 0x72, 0x4d, 0x73, 0x67, - 0x12, 0x1e, 0x0a, 0x0a, 0x74, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x49, 0x64, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x74, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x49, 0x64, - 0x32, 0xc9, 0x04, 0x0a, 0x0e, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x53, 0x65, 0x72, 0x76, - 0x69, 0x63, 0x65, 0x12, 0x34, 0x0a, 0x12, 0x47, 0x65, 0x74, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, - 0x73, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x12, 0x09, 0x2e, 0x49, 0x64, 0x4f, 0x72, - 0x4e, 0x61, 0x6d, 0x65, 0x1a, 0x11, 0x2e, 0x53, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x50, - 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x22, 0x00, 0x12, 0x33, 0x0a, 0x13, 0x53, 0x61, 0x76, - 0x65, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, - 0x12, 0x11, 0x2e, 0x53, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x50, 0x72, 0x6f, 0x76, 0x69, - 0x64, 0x65, 0x72, 0x1a, 0x07, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x36, - 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x73, 0x12, 0x06, - 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x1c, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, - 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x3b, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x50, 0x72, 0x6f, - 0x76, 0x69, 0x64, 0x65, 0x72, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x12, 0x06, 0x2e, 0x45, 0x6d, 0x70, - 0x74, 0x79, 0x1a, 0x1d, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x50, 0x72, 0x6f, 0x76, - 0x69, 0x64, 0x65, 0x72, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x00, 0x12, 0x3a, 0x0a, 0x0c, 0x53, 0x61, 0x76, 0x65, 0x54, 0x65, 0x6d, 0x70, 0x6c, - 0x61, 0x74, 0x65, 0x12, 0x11, 0x2e, 0x53, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x65, - 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x1a, 0x15, 0x2e, 0x53, 0x61, 0x76, 0x65, 0x54, 0x65, 0x6d, - 0x70, 0x6c, 0x61, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, - 0x36, 0x0a, 0x0b, 0x47, 0x65, 0x74, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x12, 0x12, - 0x2e, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, - 0x49, 0x64, 0x1a, 0x11, 0x2e, 0x53, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x65, 0x6d, - 0x70, 0x6c, 0x61, 0x74, 0x65, 0x22, 0x00, 0x12, 0x44, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x54, 0x65, - 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x12, 0x14, 0x2e, 0x47, 0x65, 0x74, 0x54, 0x65, 0x6d, - 0x70, 0x6c, 0x61, 0x74, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1c, 0x2e, - 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x4c, - 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x2f, 0x0a, - 0x0e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x12, - 0x12, 0x2e, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, - 0x65, 0x49, 0x64, 0x1a, 0x07, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x3a, - 0x0a, 0x10, 0x53, 0x61, 0x76, 0x65, 0x41, 0x72, 0x65, 0x61, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, - 0x74, 0x65, 0x12, 0x1b, 0x2e, 0x53, 0x61, 0x76, 0x65, 0x41, 0x72, 0x65, 0x61, 0x45, 0x78, 0x70, - 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, - 0x07, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x30, 0x0a, 0x12, 0x44, 0x65, - 0x6c, 0x65, 0x74, 0x65, 0x41, 0x72, 0x65, 0x61, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, - 0x12, 0x0f, 0x2e, 0x41, 0x72, 0x65, 0x61, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x49, - 0x64, 0x1a, 0x07, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x42, 0x1f, 0x0a, 0x13, - 0x63, 0x6f, 0x6d, 0x2e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x67, 0x6f, 0x32, 0x6f, 0x2e, - 0x72, 0x70, 0x63, 0x5a, 0x08, 0x2e, 0x2f, 0x3b, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x06, 0x70, - 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x72, 0x49, 0x64, 0x12, 0x20, 0x0a, 0x0b, 0x6f, 0x6e, 0x6c, 0x79, 0x45, 0x6e, 0x61, 0x62, 0x6c, + 0x65, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0b, 0x6f, 0x6e, 0x6c, 0x79, 0x45, 0x6e, + 0x61, 0x62, 0x6c, 0x65, 0x64, 0x22, 0x46, 0x0a, 0x1b, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, + 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x27, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, + 0x03, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x53, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x65, + 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x87, 0x01, + 0x0a, 0x1a, 0x53, 0x61, 0x76, 0x65, 0x41, 0x72, 0x65, 0x61, 0x45, 0x78, 0x70, 0x54, 0x65, 0x6d, + 0x70, 0x6c, 0x61, 0x74, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1a, 0x0a, 0x08, + 0x73, 0x65, 0x6c, 0x6c, 0x65, 0x72, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, + 0x73, 0x65, 0x6c, 0x6c, 0x65, 0x72, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x74, 0x65, 0x6d, 0x70, + 0x6c, 0x61, 0x74, 0x65, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x74, 0x65, + 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x49, 0x64, 0x12, 0x2d, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, + 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x53, 0x52, 0x65, 0x67, 0x69, 0x6f, + 0x6e, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, + 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x74, 0x0a, 0x0e, 0x41, 0x72, 0x65, 0x61, 0x54, + 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x65, 0x6c, + 0x6c, 0x65, 0x72, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x73, 0x65, 0x6c, + 0x6c, 0x65, 0x72, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x74, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, + 0x65, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x74, 0x65, 0x6d, 0x70, 0x6c, + 0x61, 0x74, 0x65, 0x49, 0x64, 0x12, 0x26, 0x0a, 0x0e, 0x61, 0x72, 0x65, 0x61, 0x54, 0x65, 0x6d, + 0x70, 0x6c, 0x61, 0x74, 0x65, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0e, 0x61, + 0x72, 0x65, 0x61, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x49, 0x64, 0x22, 0x68, 0x0a, + 0x14, 0x53, 0x61, 0x76, 0x65, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x65, 0x72, 0x72, 0x43, 0x6f, 0x64, 0x65, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x65, 0x72, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x12, + 0x16, 0x0a, 0x06, 0x65, 0x72, 0x72, 0x4d, 0x73, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x06, 0x65, 0x72, 0x72, 0x4d, 0x73, 0x67, 0x12, 0x1e, 0x0a, 0x0a, 0x74, 0x65, 0x6d, 0x70, 0x6c, + 0x61, 0x74, 0x65, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x74, 0x65, 0x6d, + 0x70, 0x6c, 0x61, 0x74, 0x65, 0x49, 0x64, 0x32, 0x9e, 0x04, 0x0a, 0x0e, 0x45, 0x78, 0x70, 0x72, + 0x65, 0x73, 0x73, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x34, 0x0a, 0x12, 0x47, 0x65, + 0x74, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, + 0x12, 0x09, 0x2e, 0x49, 0x64, 0x4f, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x1a, 0x11, 0x2e, 0x53, 0x45, + 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x22, 0x00, + 0x12, 0x33, 0x0a, 0x13, 0x53, 0x61, 0x76, 0x65, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x50, + 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x12, 0x11, 0x2e, 0x53, 0x45, 0x78, 0x70, 0x72, 0x65, + 0x73, 0x73, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x1a, 0x07, 0x2e, 0x52, 0x65, 0x73, + 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x36, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x50, 0x72, 0x6f, 0x76, + 0x69, 0x64, 0x65, 0x72, 0x73, 0x12, 0x06, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x1c, 0x2e, + 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x4c, + 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x3b, 0x0a, + 0x10, 0x47, 0x65, 0x74, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x47, 0x72, 0x6f, 0x75, + 0x70, 0x12, 0x06, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x1d, 0x2e, 0x45, 0x78, 0x70, 0x72, + 0x65, 0x73, 0x73, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x47, 0x72, 0x6f, 0x75, 0x70, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x41, 0x0a, 0x13, 0x53, 0x61, + 0x76, 0x65, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, + 0x65, 0x12, 0x11, 0x2e, 0x53, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x65, 0x6d, 0x70, + 0x6c, 0x61, 0x74, 0x65, 0x1a, 0x15, 0x2e, 0x53, 0x61, 0x76, 0x65, 0x54, 0x65, 0x6d, 0x70, 0x6c, + 0x61, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x36, 0x0a, + 0x0b, 0x47, 0x65, 0x74, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x12, 0x12, 0x2e, 0x45, + 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x49, 0x64, + 0x1a, 0x11, 0x2e, 0x53, 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x65, 0x6d, 0x70, 0x6c, + 0x61, 0x74, 0x65, 0x22, 0x00, 0x12, 0x44, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x54, 0x65, 0x6d, 0x70, + 0x6c, 0x61, 0x74, 0x65, 0x73, 0x12, 0x14, 0x2e, 0x47, 0x65, 0x74, 0x54, 0x65, 0x6d, 0x70, 0x6c, + 0x61, 0x74, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1c, 0x2e, 0x45, 0x78, + 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x4c, 0x69, 0x73, + 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x2f, 0x0a, 0x0e, 0x44, + 0x65, 0x6c, 0x65, 0x74, 0x65, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x12, 0x12, 0x2e, + 0x45, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x49, + 0x64, 0x1a, 0x07, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x3a, 0x0a, 0x10, + 0x53, 0x61, 0x76, 0x65, 0x41, 0x72, 0x65, 0x61, 0x54, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, + 0x12, 0x1b, 0x2e, 0x53, 0x61, 0x76, 0x65, 0x41, 0x72, 0x65, 0x61, 0x45, 0x78, 0x70, 0x54, 0x65, + 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x07, 0x2e, + 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x42, 0x1f, 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, + 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x67, 0x6f, 0x32, 0x6f, 0x2e, 0x72, 0x70, 0x63, 0x5a, + 0x08, 0x2e, 0x2f, 0x3b, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x33, } var ( @@ -1090,10 +1100,10 @@ var file_express_service_proto_goTypes = []interface{}{ (*SMinifiyExpressProvider)(nil), // 3: SMinifiyExpressProvider (*SExpressProvider)(nil), // 4: SExpressProvider (*SExpressTemplate)(nil), // 5: SExpressTemplate - (*ExpressTemplateId)(nil), // 6: ExpressTemplateId - (*GetTemplatesRequest)(nil), // 7: GetTemplatesRequest - (*ExpressTemplateListResponse)(nil), // 8: ExpressTemplateListResponse - (*SExpressAreaTemplate)(nil), // 9: SExpressAreaTemplate + (*SRegionExpressTemplate)(nil), // 6: SRegionExpressTemplate + (*ExpressTemplateId)(nil), // 7: ExpressTemplateId + (*GetTemplatesRequest)(nil), // 8: GetTemplatesRequest + (*ExpressTemplateListResponse)(nil), // 9: ExpressTemplateListResponse (*SaveAreaExpTemplateRequest)(nil), // 10: SaveAreaExpTemplateRequest (*AreaTemplateId)(nil), // 11: AreaTemplateId (*SaveTemplateResponse)(nil), // 12: SaveTemplateResponse @@ -1105,33 +1115,32 @@ var file_express_service_proto_depIdxs = []int32{ 4, // 0: ExpressProviderListResponse.value:type_name -> SExpressProvider 2, // 1: ExpressProviderGroupResponse.list:type_name -> SExpressProviderGroup 3, // 2: SExpressProviderGroup.list:type_name -> SMinifiyExpressProvider - 5, // 3: ExpressTemplateListResponse.value:type_name -> SExpressTemplate - 9, // 4: SaveAreaExpTemplateRequest.value:type_name -> SExpressAreaTemplate - 13, // 5: ExpressService.GetExpressProvider:input_type -> IdOrName - 4, // 6: ExpressService.SaveExpressProvider:input_type -> SExpressProvider - 14, // 7: ExpressService.GetProviders:input_type -> Empty - 14, // 8: ExpressService.GetProviderGroup:input_type -> Empty - 5, // 9: ExpressService.SaveTemplate:input_type -> SExpressTemplate - 6, // 10: ExpressService.GetTemplate:input_type -> ExpressTemplateId - 7, // 11: ExpressService.GetTemplates:input_type -> GetTemplatesRequest - 6, // 12: ExpressService.DeleteTemplate:input_type -> ExpressTemplateId - 10, // 13: ExpressService.SaveAreaTemplate:input_type -> SaveAreaExpTemplateRequest - 11, // 14: ExpressService.DeleteAreaTemplate:input_type -> AreaTemplateId + 6, // 3: SExpressTemplate.regions:type_name -> SRegionExpressTemplate + 5, // 4: ExpressTemplateListResponse.value:type_name -> SExpressTemplate + 6, // 5: SaveAreaExpTemplateRequest.value:type_name -> SRegionExpressTemplate + 13, // 6: ExpressService.GetExpressProvider:input_type -> IdOrName + 4, // 7: ExpressService.SaveExpressProvider:input_type -> SExpressProvider + 14, // 8: ExpressService.GetProviders:input_type -> Empty + 14, // 9: ExpressService.GetProviderGroup:input_type -> Empty + 5, // 10: ExpressService.SaveExpressTemplate:input_type -> SExpressTemplate + 7, // 11: ExpressService.GetTemplate:input_type -> ExpressTemplateId + 8, // 12: ExpressService.GetTemplates:input_type -> GetTemplatesRequest + 7, // 13: ExpressService.DeleteTemplate:input_type -> ExpressTemplateId + 10, // 14: ExpressService.SaveAreaTemplate:input_type -> SaveAreaExpTemplateRequest 4, // 15: ExpressService.GetExpressProvider:output_type -> SExpressProvider 15, // 16: ExpressService.SaveExpressProvider:output_type -> Result 0, // 17: ExpressService.GetProviders:output_type -> ExpressProviderListResponse 1, // 18: ExpressService.GetProviderGroup:output_type -> ExpressProviderGroupResponse - 12, // 19: ExpressService.SaveTemplate:output_type -> SaveTemplateResponse + 12, // 19: ExpressService.SaveExpressTemplate:output_type -> SaveTemplateResponse 5, // 20: ExpressService.GetTemplate:output_type -> SExpressTemplate - 8, // 21: ExpressService.GetTemplates:output_type -> ExpressTemplateListResponse + 9, // 21: ExpressService.GetTemplates:output_type -> ExpressTemplateListResponse 15, // 22: ExpressService.DeleteTemplate:output_type -> Result 15, // 23: ExpressService.SaveAreaTemplate:output_type -> Result - 15, // 24: ExpressService.DeleteAreaTemplate:output_type -> Result - 15, // [15:25] is the sub-list for method output_type - 5, // [5:15] is the sub-list for method input_type - 5, // [5:5] is the sub-list for extension type_name - 5, // [5:5] is the sub-list for extension extendee - 0, // [0:5] is the sub-list for field type_name + 15, // [15:24] is the sub-list for method output_type + 6, // [6:15] is the sub-list for method input_type + 6, // [6:6] is the sub-list for extension type_name + 6, // [6:6] is the sub-list for extension extendee + 0, // [0:6] is the sub-list for field type_name } func init() { file_express_service_proto_init() } @@ -1214,7 +1223,7 @@ func file_express_service_proto_init() { } } file_express_service_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ExpressTemplateId); i { + switch v := v.(*SRegionExpressTemplate); i { case 0: return &v.state case 1: @@ -1226,7 +1235,7 @@ func file_express_service_proto_init() { } } file_express_service_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetTemplatesRequest); i { + switch v := v.(*ExpressTemplateId); i { case 0: return &v.state case 1: @@ -1238,7 +1247,7 @@ func file_express_service_proto_init() { } } file_express_service_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ExpressTemplateListResponse); i { + switch v := v.(*GetTemplatesRequest); i { case 0: return &v.state case 1: @@ -1250,7 +1259,7 @@ func file_express_service_proto_init() { } } file_express_service_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SExpressAreaTemplate); i { + switch v := v.(*ExpressTemplateListResponse); i { case 0: return &v.state case 1: diff --git a/core/service/proto/express_service_grpc.pb.go b/core/service/proto/express_service_grpc.pb.go index 0555340f8..e4a64f330 100644 --- a/core/service/proto/express_service_grpc.pb.go +++ b/core/service/proto/express_service_grpc.pb.go @@ -23,12 +23,11 @@ const ( ExpressService_SaveExpressProvider_FullMethodName = "/ExpressService/SaveExpressProvider" ExpressService_GetProviders_FullMethodName = "/ExpressService/GetProviders" ExpressService_GetProviderGroup_FullMethodName = "/ExpressService/GetProviderGroup" - ExpressService_SaveTemplate_FullMethodName = "/ExpressService/SaveTemplate" + ExpressService_SaveExpressTemplate_FullMethodName = "/ExpressService/SaveExpressTemplate" ExpressService_GetTemplate_FullMethodName = "/ExpressService/GetTemplate" ExpressService_GetTemplates_FullMethodName = "/ExpressService/GetTemplates" ExpressService_DeleteTemplate_FullMethodName = "/ExpressService/DeleteTemplate" ExpressService_SaveAreaTemplate_FullMethodName = "/ExpressService/SaveAreaTemplate" - ExpressService_DeleteAreaTemplate_FullMethodName = "/ExpressService/DeleteAreaTemplate" ) // ExpressServiceClient is the client API for ExpressService service. @@ -44,7 +43,7 @@ type ExpressServiceClient interface { // 获取可用的快递公司分组 GetProviderGroup(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*ExpressProviderGroupResponse, error) // 保存快递模板 - SaveTemplate(ctx context.Context, in *SExpressTemplate, opts ...grpc.CallOption) (*SaveTemplateResponse, error) + SaveExpressTemplate(ctx context.Context, in *SExpressTemplate, opts ...grpc.CallOption) (*SaveTemplateResponse, error) // 获取单个快递模板 GetTemplate(ctx context.Context, in *ExpressTemplateId, opts ...grpc.CallOption) (*SExpressTemplate, error) // 获取卖家的快递模板 @@ -53,8 +52,6 @@ type ExpressServiceClient interface { DeleteTemplate(ctx context.Context, in *ExpressTemplateId, opts ...grpc.CallOption) (*Result, error) // 保存地区快递模板 SaveAreaTemplate(ctx context.Context, in *SaveAreaExpTemplateRequest, opts ...grpc.CallOption) (*Result, error) - // 删除模板地区设定 - DeleteAreaTemplate(ctx context.Context, in *AreaTemplateId, opts ...grpc.CallOption) (*Result, error) } type expressServiceClient struct { @@ -101,9 +98,9 @@ func (c *expressServiceClient) GetProviderGroup(ctx context.Context, in *Empty, return out, nil } -func (c *expressServiceClient) SaveTemplate(ctx context.Context, in *SExpressTemplate, opts ...grpc.CallOption) (*SaveTemplateResponse, error) { +func (c *expressServiceClient) SaveExpressTemplate(ctx context.Context, in *SExpressTemplate, opts ...grpc.CallOption) (*SaveTemplateResponse, error) { out := new(SaveTemplateResponse) - err := c.cc.Invoke(ctx, ExpressService_SaveTemplate_FullMethodName, in, out, opts...) + err := c.cc.Invoke(ctx, ExpressService_SaveExpressTemplate_FullMethodName, in, out, opts...) if err != nil { return nil, err } @@ -146,15 +143,6 @@ func (c *expressServiceClient) SaveAreaTemplate(ctx context.Context, in *SaveAre return out, nil } -func (c *expressServiceClient) DeleteAreaTemplate(ctx context.Context, in *AreaTemplateId, opts ...grpc.CallOption) (*Result, error) { - out := new(Result) - err := c.cc.Invoke(ctx, ExpressService_DeleteAreaTemplate_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - // ExpressServiceServer is the server API for ExpressService service. // All implementations must embed UnimplementedExpressServiceServer // for forward compatibility @@ -168,7 +156,7 @@ type ExpressServiceServer interface { // 获取可用的快递公司分组 GetProviderGroup(context.Context, *Empty) (*ExpressProviderGroupResponse, error) // 保存快递模板 - SaveTemplate(context.Context, *SExpressTemplate) (*SaveTemplateResponse, error) + SaveExpressTemplate(context.Context, *SExpressTemplate) (*SaveTemplateResponse, error) // 获取单个快递模板 GetTemplate(context.Context, *ExpressTemplateId) (*SExpressTemplate, error) // 获取卖家的快递模板 @@ -177,8 +165,6 @@ type ExpressServiceServer interface { DeleteTemplate(context.Context, *ExpressTemplateId) (*Result, error) // 保存地区快递模板 SaveAreaTemplate(context.Context, *SaveAreaExpTemplateRequest) (*Result, error) - // 删除模板地区设定 - DeleteAreaTemplate(context.Context, *AreaTemplateId) (*Result, error) mustEmbedUnimplementedExpressServiceServer() } @@ -198,8 +184,8 @@ func (UnimplementedExpressServiceServer) GetProviders(context.Context, *Empty) ( func (UnimplementedExpressServiceServer) GetProviderGroup(context.Context, *Empty) (*ExpressProviderGroupResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method GetProviderGroup not implemented") } -func (UnimplementedExpressServiceServer) SaveTemplate(context.Context, *SExpressTemplate) (*SaveTemplateResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method SaveTemplate not implemented") +func (UnimplementedExpressServiceServer) SaveExpressTemplate(context.Context, *SExpressTemplate) (*SaveTemplateResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method SaveExpressTemplate not implemented") } func (UnimplementedExpressServiceServer) GetTemplate(context.Context, *ExpressTemplateId) (*SExpressTemplate, error) { return nil, status.Errorf(codes.Unimplemented, "method GetTemplate not implemented") @@ -213,9 +199,6 @@ func (UnimplementedExpressServiceServer) DeleteTemplate(context.Context, *Expres func (UnimplementedExpressServiceServer) SaveAreaTemplate(context.Context, *SaveAreaExpTemplateRequest) (*Result, error) { return nil, status.Errorf(codes.Unimplemented, "method SaveAreaTemplate not implemented") } -func (UnimplementedExpressServiceServer) DeleteAreaTemplate(context.Context, *AreaTemplateId) (*Result, error) { - return nil, status.Errorf(codes.Unimplemented, "method DeleteAreaTemplate not implemented") -} func (UnimplementedExpressServiceServer) mustEmbedUnimplementedExpressServiceServer() {} // UnsafeExpressServiceServer may be embedded to opt out of forward compatibility for this service. @@ -301,20 +284,20 @@ func _ExpressService_GetProviderGroup_Handler(srv interface{}, ctx context.Conte return interceptor(ctx, in, info, handler) } -func _ExpressService_SaveTemplate_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { +func _ExpressService_SaveExpressTemplate_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(SExpressTemplate) if err := dec(in); err != nil { return nil, err } if interceptor == nil { - return srv.(ExpressServiceServer).SaveTemplate(ctx, in) + return srv.(ExpressServiceServer).SaveExpressTemplate(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: ExpressService_SaveTemplate_FullMethodName, + FullMethod: ExpressService_SaveExpressTemplate_FullMethodName, } handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ExpressServiceServer).SaveTemplate(ctx, req.(*SExpressTemplate)) + return srv.(ExpressServiceServer).SaveExpressTemplate(ctx, req.(*SExpressTemplate)) } return interceptor(ctx, in, info, handler) } @@ -391,24 +374,6 @@ func _ExpressService_SaveAreaTemplate_Handler(srv interface{}, ctx context.Conte return interceptor(ctx, in, info, handler) } -func _ExpressService_DeleteAreaTemplate_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(AreaTemplateId) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(ExpressServiceServer).DeleteAreaTemplate(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: ExpressService_DeleteAreaTemplate_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ExpressServiceServer).DeleteAreaTemplate(ctx, req.(*AreaTemplateId)) - } - return interceptor(ctx, in, info, handler) -} - // ExpressService_ServiceDesc is the grpc.ServiceDesc for ExpressService service. // It's only intended for direct use with grpc.RegisterService, // and not to be introspected or modified (even as a copy) @@ -433,8 +398,8 @@ var ExpressService_ServiceDesc = grpc.ServiceDesc{ Handler: _ExpressService_GetProviderGroup_Handler, }, { - MethodName: "SaveTemplate", - Handler: _ExpressService_SaveTemplate_Handler, + MethodName: "SaveExpressTemplate", + Handler: _ExpressService_SaveExpressTemplate_Handler, }, { MethodName: "GetTemplate", @@ -452,10 +417,6 @@ var ExpressService_ServiceDesc = grpc.ServiceDesc{ MethodName: "SaveAreaTemplate", Handler: _ExpressService_SaveAreaTemplate_Handler, }, - { - MethodName: "DeleteAreaTemplate", - Handler: _ExpressService_DeleteAreaTemplate_Handler, - }, }, Streams: []grpc.StreamDesc{}, Metadata: "express_service.proto", From 950757299d38e2dc5197ffb946cdf858caeb9b40 Mon Sep 17 00:00:00 2001 From: jarrysix Date: Thu, 16 Mar 2023 18:16:14 +0800 Subject: [PATCH 19/33] feat: brand error hint --- core/domain/interface/product/product.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/domain/interface/product/product.go b/core/domain/interface/product/product.go index 29527ef5b..963577c7b 100755 --- a/core/domain/interface/product/product.go +++ b/core/domain/interface/product/product.go @@ -22,7 +22,7 @@ var ( ErrNoBrand = domain.NewError( "err_product_no_brand", "未设置商品品牌") ErrBrandIsUsed = domain.NewError( - "err_product_brand_is_used", "品牌已关联模型%s") + "err_product_brand_is_used", "品牌被模型\"%s\"使用,无法删除") ErrVendor = domain.NewError( "err_not_be_review", "商品供应商不正确") From ad7fb1ee1c6f7c261566560c199151399c0f0f33 Mon Sep 17 00:00:00 2001 From: jarrysix Date: Thu, 16 Mar 2023 18:30:59 +0800 Subject: [PATCH 20/33] fix: item shelve down --- core/domain/item/item.go | 2 +- tests/domain/item_test.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/core/domain/item/item.go b/core/domain/item/item.go index 36c0380d4..bec2bf8cb 100755 --- a/core/domain/item/item.go +++ b/core/domain/item/item.go @@ -631,7 +631,7 @@ func (i *itemImpl) SetShelve(state int32, remark string) error { _, err := i.Save() // 下架删除快照 if err == nil { - if i.value.ShelveState == 0 { + if i.value.ShelveState == item.ShelvesDown { i.removeSnapshot() } } diff --git a/tests/domain/item_test.go b/tests/domain/item_test.go index 855e3545c..db5a208a8 100755 --- a/tests/domain/item_test.go +++ b/tests/domain/item_test.go @@ -234,7 +234,7 @@ func TestAuditItem(t *testing.T) { // 测试商品下架 func TestItemShelveDown(t *testing.T) { - var itemId int64 = 3252 + var itemId int64 = 3273 repo := ti.Factory.GetItemRepo() it := repo.GetItem(itemId) err := it.SetShelve(0, "测试下架") From d44540e9a01f77e04d7c105f60e5c95fae65a949 Mon Sep 17 00:00:00 2001 From: jarrysix Date: Fri, 17 Mar 2023 10:12:14 +0800 Subject: [PATCH 21/33] feat: product model destory --- core/domain/interface/pro_model/product_model.go | 4 ++-- core/domain/pro_model/pro_model.go | 5 +++++ core/domain/product/category_service.go | 5 +---- core/repos/product_model_repo.go | 4 ++-- core/service/impl/2.product_service.go | 9 ++++++--- 5 files changed, 16 insertions(+), 11 deletions(-) diff --git a/core/domain/interface/pro_model/product_model.go b/core/domain/interface/pro_model/product_model.go index 7090665dd..5bd006426 100755 --- a/core/domain/interface/pro_model/product_model.go +++ b/core/domain/interface/pro_model/product_model.go @@ -54,6 +54,8 @@ type IProductModel interface { SetBrands(brandId []int) error // 保存 Save() (int, error) + // 删除模型 + Destroy() error } type IProductModelRepo interface { @@ -72,8 +74,6 @@ type IProductModelRepo interface { // 获取模型的商品品牌 GetModelBrands(proModel int) []*ProductBrand - // Get ProductModel - GetProModel(primary interface{}) *ProductModel // Select ProductModel SelectProModel(where string, v ...interface{}) []*ProductModel // Save ProductModel diff --git a/core/domain/pro_model/pro_model.go b/core/domain/pro_model/pro_model.go index 9e4e69120..1691003c0 100755 --- a/core/domain/pro_model/pro_model.go +++ b/core/domain/pro_model/pro_model.go @@ -246,3 +246,8 @@ func (m *modelImpl) saveModelBrand(brandIds []int) (err error) { } return nil } + +// Destroy implements promodel.IProductModel +func (*modelImpl) Destroy() error { + panic("unimplemented") +} diff --git a/core/domain/product/category_service.go b/core/domain/product/category_service.go index 11fb62f27..0a66ae760 100755 --- a/core/domain/product/category_service.go +++ b/core/domain/product/category_service.go @@ -172,10 +172,7 @@ func (c *categoryImpl) GetModel() promodel.IProductModel { parentId = p.GetValue().ParentId } // 查询模型 - v := c._modelRepo.GetProModel(mid) - if v != nil { - c._model = c._modelRepo.CreateModel(v) - } + c._model = c._modelRepo.GetModel(mid) } return c._model } diff --git a/core/repos/product_model_repo.go b/core/repos/product_model_repo.go index 13953775b..548c796d3 100755 --- a/core/repos/product_model_repo.go +++ b/core/repos/product_model_repo.go @@ -36,7 +36,7 @@ func (p *proModelRepo) CreateModel(v *promodel.ProductModel) promodel.IProductMo // 获取商品模型 func (p *proModelRepo) GetModel(id int) promodel.IProductModel { - v := p.GetProModel(id) + v := p.getProModel(id) if v != nil { return p.CreateModel(v) } @@ -82,7 +82,7 @@ func (p *proModelRepo) GetModelBrands(proModel int) []*promodel.ProductBrand { } // Get ProductModel -func (p *proModelRepo) GetProModel(primary interface{}) *promodel.ProductModel { +func (p *proModelRepo) getProModel(primary interface{}) *promodel.ProductModel { e := promodel.ProductModel{} err := p.o.Get(primary, &e) if err == nil { diff --git a/core/service/impl/2.product_service.go b/core/service/impl/2.product_service.go index 268eac501..da81d6c68 100755 --- a/core/service/impl/2.product_service.go +++ b/core/service/impl/2.product_service.go @@ -284,9 +284,12 @@ func (p *productService) SaveProductModel(_ context.Context, r *proto.SaveProduc // DeleteModel_ 删除产品模型 func (p *productService) DeleteModel_(_ context.Context, id *proto.ProductModelId) (*proto.Result, error) { - //err := p.pmRepo.DeleteProModel(id) - //todo: 暂时不允许删除模型 - return p.result(errors.New("暂时不允许删除模型")), nil + model := p.pmRepo.GetModel(int(id.Value)) + if model == nil { + return p.result(errors.New("商品模型不存在")), nil + } + err := model.Destroy() + return p.result(err), nil } // GetBrand 获取产品品牌 From 6c60b7c0f06b23ac3d3ccfd70a7b8e3eeafbbac9 Mon Sep 17 00:00:00 2001 From: jarrysix Date: Fri, 17 Mar 2023 10:52:21 +0800 Subject: [PATCH 22/33] feat: product model destory --- .../interface/pro_model/product_model.go | 9 +++- core/domain/pro_model/pro_model.go | 42 +++++++++++++------ core/repos/product_model_repo.go | 17 ++++++++ 3 files changed, 54 insertions(+), 14 deletions(-) diff --git a/core/domain/interface/pro_model/product_model.go b/core/domain/interface/pro_model/product_model.go index 5bd006426..25180641e 100755 --- a/core/domain/interface/pro_model/product_model.go +++ b/core/domain/interface/pro_model/product_model.go @@ -1,6 +1,8 @@ package promodel -import "github.com/ixre/go2o/core/infrastructure/domain" +import ( + "github.com/ixre/go2o/core/infrastructure/domain" +) var ( ErrEmptyAttrArray = domain.NewError( @@ -11,6 +13,8 @@ var ( "err_empty_brand_array", "模型至少包含一个品牌") ErrExistsBrand = domain.NewError( "err_exists_brand", "已存在相同名称的品牌") + ErrModelIsUsed = domain.NewError( + "err_product_model_is_used", "模型已被分类\"%s\"使用") ) type ProductModel struct { @@ -74,6 +78,9 @@ type IProductModelRepo interface { // 获取模型的商品品牌 GetModelBrands(proModel int) []*ProductBrand + // 检查模块是否关联分类 + CheckModelIsUsed(modelId int) (bool, string) + // Select ProductModel SelectProModel(where string, v ...interface{}) []*ProductModel // Save ProductModel diff --git a/core/domain/pro_model/pro_model.go b/core/domain/pro_model/pro_model.go index 1691003c0..240aeb4d8 100755 --- a/core/domain/pro_model/pro_model.go +++ b/core/domain/pro_model/pro_model.go @@ -2,6 +2,7 @@ package promodel import ( "errors" + "fmt" promodel "github.com/ixre/go2o/core/domain/interface/pro_model" "github.com/ixre/go2o/core/infrastructure/format" @@ -10,7 +11,7 @@ import ( var _ promodel.IProductModel = new(modelImpl) type modelImpl struct { - rep promodel.IProductModelRepo + repo promodel.IProductModelRepo value *promodel.ProductModel attrService promodel.IAttrService specService promodel.ISpecService @@ -21,7 +22,7 @@ func NewModel(v *promodel.ProductModel, rep promodel.IProductModelRepo, attrService promodel.IAttrService, specService promodel.ISpecService, brandService promodel.IBrandService) promodel.IProductModel { return &modelImpl{ - rep: rep, + repo: rep, value: v, attrService: attrService, specService: specService, @@ -85,7 +86,7 @@ func (m *modelImpl) SetSpecs(s []*promodel.Spec) error { // 获取关联的品牌编号 func (m *modelImpl) Brands() []*promodel.ProductBrand { - return m.rep.BrandService().Brands(m.GetAggregateRootId()) + return m.repo.BrandService().Brands(m.GetAggregateRootId()) } // 关联品牌 @@ -102,7 +103,7 @@ func (m *modelImpl) Save() (id int, err error) { var i int // 新增模型 if m.GetAggregateRootId() <= 0 { - i, err = m.rep.SaveProModel(m.value) + i, err = m.repo.SaveProModel(m.value) if err == nil { m.value.Id = i } else { @@ -137,7 +138,7 @@ func (m *modelImpl) Save() (id int, err error) { } // 保存商品模型 if err == nil { - i, err = m.rep.SaveProModel(m.value) + i, err = m.repo.SaveProModel(m.value) if err == nil { m.value.Id = i } @@ -149,7 +150,7 @@ func (m *modelImpl) Save() (id int, err error) { func (m *modelImpl) saveModelSpecs(specs []*promodel.Spec) (err error) { pk := m.GetAggregateRootId() // 获取存在的项 - old := m.rep.SelectSpec("prod_model = $1", pk) + old := m.repo.SelectSpec("prod_model = $1", pk) // 分析当前项目并加入到MAP中 delList := []int{} currMap := make(map[int]*promodel.Spec, len(specs)) @@ -183,7 +184,7 @@ func (m *modelImpl) saveModelSpecs(specs []*promodel.Spec) (err error) { func (m *modelImpl) saveModelAttrs(attrs []*promodel.Attr) (err error) { pk := m.GetAggregateRootId() // 获取存在的项 - old := m.rep.SelectAttr("prod_model = $1", pk) + old := m.repo.SelectAttr("prod_model = $1", pk) // 分析当前项目并加入到MAP中 delList := []int{} currMap := make(map[int]*promodel.Attr, len(attrs)) @@ -216,11 +217,11 @@ func (m *modelImpl) saveModelAttrs(attrs []*promodel.Attr) (err error) { func (m *modelImpl) saveModelBrand(brandIds []int) (err error) { pk := m.GetAggregateRootId() //获取存在的品牌 - old := m.rep.SelectProModelBrand("prod_model = $1", pk) + old := m.repo.SelectProModelBrand("prod_model = $1", pk) //删除不包括的品牌 idArrStr := format.IntArrStrJoin(brandIds) if len(old) > 0 { - m.rep.BatchDeleteProModelBrand("prod_model = $1"+ + m.repo.BatchDeleteProModelBrand("prod_model = $1"+ " AND brand_id NOT IN("+idArrStr+")", pk) } //写入品牌 @@ -238,7 +239,7 @@ func (m *modelImpl) saveModelBrand(brandIds []int) (err error) { BrandId: v, ModelId: pk, } - _, err = m.rep.SaveProModelBrand(e) + _, err = m.repo.SaveProModelBrand(e) if err != nil { return err } @@ -247,7 +248,22 @@ func (m *modelImpl) saveModelBrand(brandIds []int) (err error) { return nil } -// Destroy implements promodel.IProductModel -func (*modelImpl) Destroy() error { - panic("unimplemented") +// Destroy 删除产品模型 +func (m *modelImpl) Destroy() error { + b, cat := m.repo.CheckModelIsUsed(m.GetAggregateRootId()) + if b { + return fmt.Errorf(promodel.ErrEmptyAttrArray.Error(), cat) + } + var err error + for _, v := range m.Specs() { + if err = m.specService.DeleteSpec(v.Id); err != nil { + return err + } + } + for _, v := range m.Attrs() { + if err = m.attrService.DeleteAttr(v.Id); err != nil { + return err + } + } + return m.repo.DeleteProModel(m.GetAggregateRootId()) } diff --git a/core/repos/product_model_repo.go b/core/repos/product_model_repo.go index 548c796d3..811550a28 100755 --- a/core/repos/product_model_repo.go +++ b/core/repos/product_model_repo.go @@ -5,6 +5,7 @@ import ( "log" promodel "github.com/ixre/go2o/core/domain/interface/pro_model" + "github.com/ixre/go2o/core/domain/interface/product" pmImpl "github.com/ixre/go2o/core/domain/pro_model" "github.com/ixre/gof/db" "github.com/ixre/gof/db/orm" @@ -94,6 +95,22 @@ func (p *proModelRepo) getProModel(primary interface{}) *promodel.ProductModel { return nil } + +// 获取模块关联的分类 +func (c *proModelRepo) CheckModelIsUsed(modelId int) (bool, string) { + var list []*product.Category + err := c.o.Select(&list, "model_id=$1", modelId) + + if err == nil { + log.Printf("[ Orm][ Error]:%s; Entity:ProdCategory \n", err.Error()) + return true, "未知分类" + } + if len(list) > 0 { + return true, list[0].Name + } + return false, "" +} + // Select ProductModel func (p *proModelRepo) SelectProModel(where string, v ...interface{}) []*promodel.ProductModel { var list []*promodel.ProductModel From 811b6366acebb4490073391754c8126fe057c5f3 Mon Sep 17 00:00:00 2001 From: jarrysix Date: Fri, 17 Mar 2023 10:56:07 +0800 Subject: [PATCH 23/33] feat: product model destory --- core/repos/product_model_repo.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/core/repos/product_model_repo.go b/core/repos/product_model_repo.go index 811550a28..498912f7a 100755 --- a/core/repos/product_model_repo.go +++ b/core/repos/product_model_repo.go @@ -95,13 +95,12 @@ func (p *proModelRepo) getProModel(primary interface{}) *promodel.ProductModel { return nil } - // 获取模块关联的分类 func (c *proModelRepo) CheckModelIsUsed(modelId int) (bool, string) { var list []*product.Category err := c.o.Select(&list, "model_id=$1", modelId) - if err == nil { + if err != nil { log.Printf("[ Orm][ Error]:%s; Entity:ProdCategory \n", err.Error()) return true, "未知分类" } From 3b184495e5840f000237f9f5803e179e34a9525c Mon Sep 17 00:00:00 2001 From: jarrysix Date: Fri, 17 Mar 2023 11:02:19 +0800 Subject: [PATCH 24/33] feat: product model destory --- core/domain/pro_model/pro_model.go | 2 +- core/repos/product_model_repo.go | 1 - tests/domain/product_test.go | 12 ++++++++++++ 3 files changed, 13 insertions(+), 2 deletions(-) diff --git a/core/domain/pro_model/pro_model.go b/core/domain/pro_model/pro_model.go index 240aeb4d8..eaed97bd7 100755 --- a/core/domain/pro_model/pro_model.go +++ b/core/domain/pro_model/pro_model.go @@ -252,7 +252,7 @@ func (m *modelImpl) saveModelBrand(brandIds []int) (err error) { func (m *modelImpl) Destroy() error { b, cat := m.repo.CheckModelIsUsed(m.GetAggregateRootId()) if b { - return fmt.Errorf(promodel.ErrEmptyAttrArray.Error(), cat) + return fmt.Errorf(promodel.ErrModelIsUsed.Error(), cat) } var err error for _, v := range m.Specs() { diff --git a/core/repos/product_model_repo.go b/core/repos/product_model_repo.go index 498912f7a..c07b30d6d 100755 --- a/core/repos/product_model_repo.go +++ b/core/repos/product_model_repo.go @@ -99,7 +99,6 @@ func (p *proModelRepo) getProModel(primary interface{}) *promodel.ProductModel { func (c *proModelRepo) CheckModelIsUsed(modelId int) (bool, string) { var list []*product.Category err := c.o.Select(&list, "model_id=$1", modelId) - if err != nil { log.Printf("[ Orm][ Error]:%s; Entity:ProdCategory \n", err.Error()) return true, "未知分类" diff --git a/tests/domain/product_test.go b/tests/domain/product_test.go index 28b0ffea3..5b98f0258 100644 --- a/tests/domain/product_test.go +++ b/tests/domain/product_test.go @@ -48,3 +48,15 @@ func TestGetModelSortedSpecItems(t *testing.T) { } } } + +// 测试销毁产品模型 +func TestDestoryProductModel(t *testing.T) { + var modelId int = 8 + repo := ti.Factory.GetProModelRepo() + im := repo.GetModel(modelId) + err := im.Destroy() + if err != nil { + t.Error(err) + t.FailNow() + } +} From 772cdf32fdc4ff0ba5fd9c1f9c47aad34d33a90f Mon Sep 17 00:00:00 2001 From: jarrysix Date: Fri, 17 Mar 2023 11:05:30 +0800 Subject: [PATCH 25/33] feat: product model destory --- core/repos/product_model_repo.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/repos/product_model_repo.go b/core/repos/product_model_repo.go index c07b30d6d..63cd65683 100755 --- a/core/repos/product_model_repo.go +++ b/core/repos/product_model_repo.go @@ -98,7 +98,7 @@ func (p *proModelRepo) getProModel(primary interface{}) *promodel.ProductModel { // 获取模块关联的分类 func (c *proModelRepo) CheckModelIsUsed(modelId int) (bool, string) { var list []*product.Category - err := c.o.Select(&list, "model_id=$1", modelId) + err := c.o.Select(&list, "prod_model=$1", modelId) if err != nil { log.Printf("[ Orm][ Error]:%s; Entity:ProdCategory \n", err.Error()) return true, "未知分类" From 18574da28356e2d8f5c3ab8024e5622069a4e511 Mon Sep 17 00:00:00 2001 From: jarrysix Date: Fri, 17 Mar 2023 11:32:03 +0800 Subject: [PATCH 26/33] fix: item query --- core/query/item_query.go | 7 +- core/service/idl/item_service.proto | 13 +- core/service/idl/query_service.proto | 12 +- core/service/impl/2.item_service.go | 91 ---- core/service/impl/2.query_service.go | 71 +++- core/service/proto/item_service.pb.go | 457 ++++++++------------- core/service/proto/item_service_grpc.pb.go | 39 -- core/service/proto/query_service.pb.go | 376 +++++++++-------- tests/service/query_service_test.go | 8 +- 9 files changed, 453 insertions(+), 621 deletions(-) diff --git a/core/query/item_query.go b/core/query/item_query.go index 987726524..9558559ad 100755 --- a/core/query/item_query.go +++ b/core/query/item_query.go @@ -115,7 +115,7 @@ func (i ItemQuery) GetOnShelvesItem(catIdArr []int, begin, end int, WHERE item_snapshot.cat_id IN(%s) %s ORDER BY item_snapshot.update_time DESC LIMIT $3 OFFSET $2`, catIdStr, where) i.o.SelectByQuery(&list, sql, - begin, end-begin) + begin, end-begin) } return list } @@ -163,12 +163,16 @@ func (i ItemQuery) GetRandomItem(catIdArr []int, begin, end int, where string) [ // GetPagingOnShelvesGoods 获取已上架的商品 func (i ItemQuery) GetPagingOnShelvesGoods(shopId int64, catIds []int, flag int, start, end int, + keyword string, where, orderBy string) (int, []*valueobject.Goods) { total := 0 if len(catIds) > 0 { where += fmt.Sprintf(" AND item_snapshot.cat_id IN (%s)", format.IntArrStrJoin(catIds)) } + if len(keyword) > 0{ + where += "item_snapshot.title LIKE '%" + keyword + "%'" + } if flag > 0 { where += fmt.Sprintf(" AND (item_snapshot.item_flag & %d = %d)", flag, flag) } @@ -195,7 +199,6 @@ func (i ItemQuery) GetPagingOnShelvesGoods(shopId int64, if err != nil { log.Println("[ GO2O][ Repo][ Error]:", err.Error(), s) } - log.Println("sql=", s) return total, list } diff --git a/core/service/idl/item_service.proto b/core/service/idl/item_service.proto index ce2d42fee..9b80cb9ef 100755 --- a/core/service/idl/item_service.proto +++ b/core/service/idl/item_service.proto @@ -54,9 +54,7 @@ service ItemService { // rpc GetValueGoodsBySaleLabel (GetItemsByLabelRequest) returns (PagingShopGoodsResponse) { // } - // 获取上架商品数据(分页) - rpc GetPagingOnShelvesItem (PagingGoodsRequest) returns (PagingGoodsResponse) { - } + // 获取上架商品数据 rpc GetItems (GetItemsRequest) returns (PagingGoodsResponse) { } @@ -93,15 +91,6 @@ service ItemService { } -message PagingGoodsRequest { - EItemSalesType itemType = 1; - int64 sellerId = 2; - int64 categoryId = 3; - // 关键词 - string keyword = 4; - SPagingParams params = 5; -} - message SaleLabelItemsRequest_ { int64 shopId = 1; diff --git a/core/service/idl/query_service.proto b/core/service/idl/query_service.proto index fc05c8e37..bacc85f02 100644 --- a/core/service/idl/query_service.proto +++ b/core/service/idl/query_service.proto @@ -242,14 +242,18 @@ message PagingAccountLogRequest { // 分页店铺商品请求 message PagingShopGoodsRequest { + // 商品类型 + EItemSalesType itemType = 1; // 店铺编号 - int64 shopId = 1; + int64 shopId = 2; // 分类编号 - int64 categoryId = 2; + int64 categoryId = 3; // 商品标签 - int32 flag = 3; + int32 flag = 4; + // 关键词 + string keyword = 5; // 分页参数 - SPagingParams params = 4; + SPagingParams params = 6; } diff --git a/core/service/impl/2.item_service.go b/core/service/impl/2.item_service.go index d3ea097ab..30e11c650 100755 --- a/core/service/impl/2.item_service.go +++ b/core/service/impl/2.item_service.go @@ -12,10 +12,7 @@ package impl import ( "context" "errors" - "strconv" - "strings" - "github.com/ixre/go2o/core/domain/interface/domain/enum" "github.com/ixre/go2o/core/domain/interface/item" "github.com/ixre/go2o/core/domain/interface/merchant" promodel "github.com/ixre/go2o/core/domain/interface/pro_model" @@ -280,94 +277,6 @@ func (i *itemService) GetItemDetailData(_ context.Context, request *proto.ItemDe return &proto.String{Value: "不支持的商品类型"}, nil } -// 获取上架商品数据(分页) -func (i *itemService) GetPagingOnShelvesItem(_ context.Context, r *proto.PagingGoodsRequest) (*proto.PagingGoodsResponse, error) { - ret := &proto.PagingGoodsResponse{ - Total: 0, - Data: make([]*proto.SUnifiedViewItem, 0), - } - where := r.Params.Where - if wd := strings.TrimSpace(r.Keyword); len(wd) > 0 { - where += " AND item_snapshot.title LIKE '%" + r.Keyword + "%'" - } - - var total int32 - var list []*proto.SUnifiedViewItem - switch r.ItemType { - case proto.EItemSalesType_IT_NORMAL: - total, list = i.getPagingOnShelvesItem( - int32(r.CategoryId), - int32(r.Params.Begin), - int32(r.Params.End), - where, - r.Params.SortBy) - case proto.EItemSalesType_IT_WHOLESALE: - total, list = i.getPagedOnShelvesItemForWholesale( - int32(r.CategoryId), - int32(r.Params.Begin), - int32(r.Params.End), - where, - r.Params.SortBy) - } - ret.Total = int64(total) - ret.Data = list - return ret, nil -} -func (i *itemService) getPagingOnShelvesItem(catId int32, start, - end int32, where, sortBy string) (int32, []*proto.SUnifiedViewItem) { - - total, list := i.itemQuery.GetPagingOnShelvesItem(catId, - start, end, where, sortBy) - arr := make([]*proto.SUnifiedViewItem, len(list)) - for i, v := range list { - v.Image = format.GetGoodsImageUrl(v.Image) - arr[i] = parser.ItemDtoV2(*v) - } - return total, arr -} - -func (i *itemService) getPagedOnShelvesItemForWholesale(catId int32, start, - end int32, where, sortBy string) (int32, []*proto.SUnifiedViewItem) { - - total, list := i.itemQuery.GetPagingOnShelvesItemForWholesale(catId, - start, end, where, sortBy) - arr := make([]*proto.SUnifiedViewItem, len(list)) - for j, v := range list { - v.Image = format.GetGoodsImageUrl(v.Image) - dto := parser.ItemDtoV2(*v) - i.attachWholesaleItemDataV2(dto) - arr[j] = dto - } - return total, arr -} - -// 附加批发商品的信息 -func (i *itemService) attachWholesaleItemDataV2(dto *proto.SUnifiedViewItem) { - dto.Data = make(map[string]string) - vendor := i.mchRepo.GetMerchant(int(dto.VendorId)) - if vendor != nil { - vv := vendor.GetValue() - pStr := i.valueRepo.GetAreaName(int32(vv.Province)) - cStr := i.valueRepo.GetAreaName(int32(vv.City)) - dto.Data["VendorName"] = vv.CompanyName - dto.Data["ShipArea"] = pStr + cStr - // 认证信息 - ei := vendor.ProfileManager().GetEnterpriseInfo() - if ei != nil && ei.Reviewed == enum.ReviewPass { - dto.Data["Authorized"] = "true" - } else { - dto.Data["Authorized"] = "false" - } - // 品牌 - b := i.promRepo.BrandService().Get(int(dto.BrandId)) - if b != nil { - dto.Data["BrandName"] = b.Name - dto.Data["BrandImage"] = b.Image - dto.Data["BrandId"] = strconv.Itoa(int(b.Id)) - } - } -} - // 获取上架商品数据 func (i *itemService) GetItems(_ context.Context, r *proto.GetItemsRequest) (*proto.PagingGoodsResponse, error) { c := i.cateRepo.GlobCatService().GetCategory(int(r.CategoryId)) diff --git a/core/service/impl/2.query_service.go b/core/service/impl/2.query_service.go index 70c2da44c..f664d3f7d 100644 --- a/core/service/impl/2.query_service.go +++ b/core/service/impl/2.query_service.go @@ -11,6 +11,7 @@ import ( "github.com/ixre/go2o/core/dto" "github.com/ixre/go2o/core/infrastructure/format" "github.com/ixre/go2o/core/query" + "github.com/ixre/go2o/core/service/parser" "github.com/ixre/go2o/core/service/proto" "github.com/ixre/go2o/core/variable" "github.com/ixre/gof/db/orm" @@ -337,8 +338,6 @@ func (q *queryService) PagingOnShelvesGoods(_ context.Context, r *proto.PagingSh Total: 0, Data: make([]*proto.SGoods, 0), } - var list []*valueobject.Goods - var total int var ids []int if r.CategoryId > 0 { cat := q.catRepo.GlobCatService().GetCategory(int(r.CategoryId)) @@ -352,12 +351,26 @@ func (q *queryService) PagingOnShelvesGoods(_ context.Context, r *proto.PagingSh if len(strings.TrimSpace(r.Params.SortBy)) == 0 { r.Params.SortBy = "item_snapshot.update_time DESC" } - total, list = q.itemQuery.GetPagingOnShelvesGoods( - r.ShopId, ids, int(r.Flag), - int(r.Params.Begin), - int(r.Params.End), - r.Params.Where, - r.Params.SortBy) + var total int + var list []*valueobject.Goods + switch r.ItemType { + case proto.EItemSalesType_IT_NORMAL: + total, list = q.itemQuery.GetPagingOnShelvesGoods( + r.ShopId, ids, int(r.Flag), + int(r.Params.Begin), + int(r.Params.End), + r.Keyword, + r.Params.Where, + r.Params.SortBy) + case proto.EItemSalesType_IT_WHOLESALE: + // total, list = q.getPagedOnShelvesItemForWholesale( + // int32(r.CategoryId), + // int32(r.Params.Begin), + // int32(r.Params.End), + // where, + // r.Params.SortBy) + } + ret.Total = int64(total) for _, v := range list { v.Image = format.GetGoodsImageUrl(v.Image) @@ -431,3 +444,45 @@ func (q *queryService) SearchItem(_ context.Context, req *proto.SearchItemReques } return ret, nil } + +func (q *queryService) getPagedOnShelvesItemForWholesale(catId int32, start, + end int32, where, sortBy string) (int32, []*proto.SUnifiedViewItem) { + + total, list := q.itemQuery.GetPagingOnShelvesItemForWholesale(catId, + start, end, where, sortBy) + arr := make([]*proto.SUnifiedViewItem, len(list)) + for j, v := range list { + v.Image = format.GetGoodsImageUrl(v.Image) + dto := parser.ItemDtoV2(*v) + q.attachWholesaleItemDataV2(dto) + arr[j] = dto + } + return total, arr +} + +// 附加批发商品的信息 +func (q *queryService) attachWholesaleItemDataV2(dto *proto.SUnifiedViewItem) { + dto.Data = make(map[string]string) + // vendor := q.mchRepo.GetMerchant(int(dto.VendorId)) + // if vendor != nil { + // vv := vendor.GetValue() + // pStr := q.valueRepo.GetAreaName(int32(vv.Province)) + // cStr := q.valueRepo.GetAreaName(int32(vv.City)) + // dto.Data["VendorName"] = vv.CompanyName + // dto.Data["ShipArea"] = pStr + cStr + // // 认证信息 + // ei := vendor.ProfileManager().GetEnterpriseInfo() + // if ei != nil && ei.Reviewed == enum.ReviewPass { + // dto.Data["Authorized"] = "true" + // } else { + // dto.Data["Authorized"] = "false" + // } + // // 品牌 + // b := q.promRepo.BrandService().Get(int(dto.BrandId)) + // if b != nil { + // dto.Data["BrandName"] = b.Name + // dto.Data["BrandImage"] = b.Image + // dto.Data["BrandId"] = strconv.Itoa(int(b.Id)) + // } + // } +} diff --git a/core/service/proto/item_service.pb.go b/core/service/proto/item_service.pb.go index 9ac63d899..ccd4c8a54 100644 --- a/core/service/proto/item_service.pb.go +++ b/core/service/proto/item_service.pb.go @@ -75,86 +75,6 @@ func (x *ItemDetailRequest) GetItemType() int32 { return 0 } -type PagingGoodsRequest struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - ItemType EItemSalesType `protobuf:"varint,1,opt,name=itemType,proto3,enum=EItemSalesType" json:"itemType"` - SellerId int64 `protobuf:"varint,2,opt,name=sellerId,proto3" json:"sellerId"` - CategoryId int64 `protobuf:"varint,3,opt,name=categoryId,proto3" json:"categoryId"` - // 关键词 - Keyword string `protobuf:"bytes,4,opt,name=keyword,proto3" json:"keyword"` - Params *SPagingParams `protobuf:"bytes,5,opt,name=params,proto3" json:"params"` -} - -func (x *PagingGoodsRequest) Reset() { - *x = PagingGoodsRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_item_service_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *PagingGoodsRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*PagingGoodsRequest) ProtoMessage() {} - -func (x *PagingGoodsRequest) ProtoReflect() protoreflect.Message { - mi := &file_item_service_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 PagingGoodsRequest.ProtoReflect.Descriptor instead. -func (*PagingGoodsRequest) Descriptor() ([]byte, []int) { - return file_item_service_proto_rawDescGZIP(), []int{1} -} - -func (x *PagingGoodsRequest) GetItemType() EItemSalesType { - if x != nil { - return x.ItemType - } - return EItemSalesType_IT_NORMAL -} - -func (x *PagingGoodsRequest) GetSellerId() int64 { - if x != nil { - return x.SellerId - } - return 0 -} - -func (x *PagingGoodsRequest) GetCategoryId() int64 { - if x != nil { - return x.CategoryId - } - return 0 -} - -func (x *PagingGoodsRequest) GetKeyword() string { - if x != nil { - return x.Keyword - } - return "" -} - -func (x *PagingGoodsRequest) GetParams() *SPagingParams { - if x != nil { - return x.Params - } - return nil -} - type SaleLabelItemsRequest_ struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -168,7 +88,7 @@ type SaleLabelItemsRequest_ struct { func (x *SaleLabelItemsRequest_) Reset() { *x = SaleLabelItemsRequest_{} if protoimpl.UnsafeEnabled { - mi := &file_item_service_proto_msgTypes[2] + mi := &file_item_service_proto_msgTypes[1] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -181,7 +101,7 @@ func (x *SaleLabelItemsRequest_) String() string { func (*SaleLabelItemsRequest_) ProtoMessage() {} func (x *SaleLabelItemsRequest_) ProtoReflect() protoreflect.Message { - mi := &file_item_service_proto_msgTypes[2] + mi := &file_item_service_proto_msgTypes[1] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -194,7 +114,7 @@ func (x *SaleLabelItemsRequest_) ProtoReflect() protoreflect.Message { // Deprecated: Use SaleLabelItemsRequest_.ProtoReflect.Descriptor instead. func (*SaleLabelItemsRequest_) Descriptor() ([]byte, []int) { - return file_item_service_proto_rawDescGZIP(), []int{2} + return file_item_service_proto_rawDescGZIP(), []int{1} } func (x *SaleLabelItemsRequest_) GetShopId() int64 { @@ -229,108 +149,91 @@ var file_item_service_proto_rawDesc = []byte{ 0x16, 0x0a, 0x06, 0x49, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x12, 0x52, 0x06, 0x49, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x49, 0x74, 0x65, 0x6d, 0x54, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x11, 0x52, 0x08, 0x49, 0x74, 0x65, 0x6d, 0x54, - 0x79, 0x70, 0x65, 0x22, 0xbf, 0x01, 0x0a, 0x12, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x47, 0x6f, - 0x6f, 0x64, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x2b, 0x0a, 0x08, 0x69, 0x74, - 0x65, 0x6d, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x0f, 0x2e, 0x45, - 0x49, 0x74, 0x65, 0x6d, 0x53, 0x61, 0x6c, 0x65, 0x73, 0x54, 0x79, 0x70, 0x65, 0x52, 0x08, 0x69, - 0x74, 0x65, 0x6d, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x65, 0x6c, 0x6c, 0x65, - 0x72, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x73, 0x65, 0x6c, 0x6c, 0x65, - 0x72, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, - 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, - 0x79, 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x6b, 0x65, 0x79, 0x77, 0x6f, 0x72, 0x64, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6b, 0x65, 0x79, 0x77, 0x6f, 0x72, 0x64, 0x12, 0x26, 0x0a, - 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, - 0x53, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x06, 0x70, - 0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0x72, 0x0a, 0x16, 0x53, 0x61, 0x6c, 0x65, 0x4c, 0x61, 0x62, - 0x65, 0x6c, 0x49, 0x74, 0x65, 0x6d, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x5f, 0x12, - 0x16, 0x0a, 0x06, 0x73, 0x68, 0x6f, 0x70, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, - 0x06, 0x73, 0x68, 0x6f, 0x70, 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x6c, 0x61, 0x62, 0x65, 0x6c, - 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x49, - 0x64, 0x12, 0x26, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x0e, 0x2e, 0x53, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x50, 0x61, 0x72, 0x61, 0x6d, - 0x73, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x32, 0xef, 0x09, 0x0a, 0x0b, 0x49, 0x74, - 0x65, 0x6d, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x30, 0x0a, 0x07, 0x47, 0x65, 0x74, - 0x49, 0x74, 0x65, 0x6d, 0x12, 0x0f, 0x2e, 0x47, 0x65, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x12, 0x2e, 0x53, 0x49, 0x74, 0x65, 0x6d, 0x44, 0x61, 0x74, - 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x31, 0x0a, 0x08, 0x53, - 0x61, 0x76, 0x65, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x10, 0x2e, 0x53, 0x61, 0x76, 0x65, 0x49, 0x74, - 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x11, 0x2e, 0x53, 0x61, 0x76, 0x65, - 0x49, 0x74, 0x65, 0x6d, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x36, - 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x42, 0x79, 0x53, 0x6b, 0x75, 0x12, 0x11, - 0x2e, 0x49, 0x74, 0x65, 0x6d, 0x42, 0x79, 0x53, 0x6b, 0x75, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x11, 0x2e, 0x53, 0x55, 0x6e, 0x69, 0x66, 0x69, 0x65, 0x64, 0x56, 0x69, 0x65, 0x77, - 0x49, 0x74, 0x65, 0x6d, 0x22, 0x00, 0x12, 0x49, 0x0a, 0x12, 0x47, 0x65, 0x74, 0x49, 0x74, 0x65, - 0x6d, 0x41, 0x6e, 0x64, 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x12, 0x1a, 0x2e, 0x47, - 0x65, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x41, 0x6e, 0x64, 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, - 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x15, 0x2e, 0x49, 0x74, 0x65, 0x6d, 0x53, - 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x00, 0x12, 0x2d, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x54, 0x72, 0x61, 0x64, 0x65, 0x53, 0x6e, 0x61, - 0x70, 0x73, 0x68, 0x6f, 0x74, 0x12, 0x06, 0x2e, 0x49, 0x6e, 0x74, 0x36, 0x34, 0x1a, 0x0f, 0x2e, - 0x53, 0x54, 0x72, 0x61, 0x64, 0x65, 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x22, 0x00, - 0x12, 0x19, 0x0a, 0x06, 0x47, 0x65, 0x74, 0x53, 0x6b, 0x75, 0x12, 0x06, 0x2e, 0x53, 0x6b, 0x75, - 0x49, 0x64, 0x1a, 0x05, 0x2e, 0x53, 0x53, 0x6b, 0x75, 0x22, 0x00, 0x12, 0x2b, 0x0a, 0x0a, 0x52, - 0x65, 0x76, 0x69, 0x65, 0x77, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x12, 0x2e, 0x49, 0x74, 0x65, 0x6d, - 0x52, 0x65, 0x76, 0x69, 0x65, 0x77, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x07, 0x2e, - 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x2d, 0x0a, 0x0b, 0x52, 0x65, 0x63, 0x79, - 0x63, 0x6c, 0x65, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x13, 0x2e, 0x52, 0x65, 0x63, 0x79, 0x63, 0x6c, - 0x65, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x07, 0x2e, 0x52, - 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x34, 0x0a, 0x0f, 0x53, 0x61, 0x76, 0x65, 0x4c, - 0x65, 0x76, 0x65, 0x6c, 0x50, 0x72, 0x69, 0x63, 0x65, 0x73, 0x12, 0x16, 0x2e, 0x53, 0x61, 0x76, - 0x65, 0x4c, 0x65, 0x76, 0x65, 0x6c, 0x50, 0x72, 0x69, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x07, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x2f, 0x0a, - 0x0d, 0x53, 0x69, 0x67, 0x6e, 0x41, 0x73, 0x49, 0x6c, 0x6c, 0x65, 0x67, 0x61, 0x6c, 0x12, 0x13, - 0x2e, 0x49, 0x74, 0x65, 0x6d, 0x49, 0x6c, 0x6c, 0x65, 0x67, 0x61, 0x6c, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x07, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x30, - 0x0a, 0x0e, 0x53, 0x65, 0x74, 0x53, 0x68, 0x65, 0x6c, 0x76, 0x65, 0x53, 0x74, 0x61, 0x74, 0x65, - 0x12, 0x13, 0x2e, 0x53, 0x68, 0x65, 0x6c, 0x76, 0x65, 0x53, 0x74, 0x61, 0x74, 0x65, 0x52, 0x65, + 0x79, 0x70, 0x65, 0x22, 0x72, 0x0a, 0x16, 0x53, 0x61, 0x6c, 0x65, 0x4c, 0x61, 0x62, 0x65, 0x6c, + 0x49, 0x74, 0x65, 0x6d, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x5f, 0x12, 0x16, 0x0a, + 0x06, 0x73, 0x68, 0x6f, 0x70, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x73, + 0x68, 0x6f, 0x70, 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x49, 0x64, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x49, 0x64, 0x12, + 0x26, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x0e, 0x2e, 0x53, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, + 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x32, 0xa8, 0x09, 0x0a, 0x0b, 0x49, 0x74, 0x65, 0x6d, + 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x30, 0x0a, 0x07, 0x47, 0x65, 0x74, 0x49, 0x74, + 0x65, 0x6d, 0x12, 0x0f, 0x2e, 0x47, 0x65, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x12, 0x2e, 0x53, 0x49, 0x74, 0x65, 0x6d, 0x44, 0x61, 0x74, 0x61, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x31, 0x0a, 0x08, 0x53, 0x61, 0x76, + 0x65, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x10, 0x2e, 0x53, 0x61, 0x76, 0x65, 0x49, 0x74, 0x65, 0x6d, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x11, 0x2e, 0x53, 0x61, 0x76, 0x65, 0x49, 0x74, + 0x65, 0x6d, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x36, 0x0a, 0x0c, + 0x47, 0x65, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x42, 0x79, 0x53, 0x6b, 0x75, 0x12, 0x11, 0x2e, 0x49, + 0x74, 0x65, 0x6d, 0x42, 0x79, 0x53, 0x6b, 0x75, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x11, 0x2e, 0x53, 0x55, 0x6e, 0x69, 0x66, 0x69, 0x65, 0x64, 0x56, 0x69, 0x65, 0x77, 0x49, 0x74, + 0x65, 0x6d, 0x22, 0x00, 0x12, 0x49, 0x0a, 0x12, 0x47, 0x65, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x41, + 0x6e, 0x64, 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x12, 0x1a, 0x2e, 0x47, 0x65, 0x74, + 0x49, 0x74, 0x65, 0x6d, 0x41, 0x6e, 0x64, 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x15, 0x2e, 0x49, 0x74, 0x65, 0x6d, 0x53, 0x6e, 0x61, + 0x70, 0x73, 0x68, 0x6f, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, + 0x2d, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x54, 0x72, 0x61, 0x64, 0x65, 0x53, 0x6e, 0x61, 0x70, 0x73, + 0x68, 0x6f, 0x74, 0x12, 0x06, 0x2e, 0x49, 0x6e, 0x74, 0x36, 0x34, 0x1a, 0x0f, 0x2e, 0x53, 0x54, + 0x72, 0x61, 0x64, 0x65, 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x22, 0x00, 0x12, 0x19, + 0x0a, 0x06, 0x47, 0x65, 0x74, 0x53, 0x6b, 0x75, 0x12, 0x06, 0x2e, 0x53, 0x6b, 0x75, 0x49, 0x64, + 0x1a, 0x05, 0x2e, 0x53, 0x53, 0x6b, 0x75, 0x22, 0x00, 0x12, 0x2b, 0x0a, 0x0a, 0x52, 0x65, 0x76, + 0x69, 0x65, 0x77, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x12, 0x2e, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x65, + 0x76, 0x69, 0x65, 0x77, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x07, 0x2e, 0x52, 0x65, + 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x2d, 0x0a, 0x0b, 0x52, 0x65, 0x63, 0x79, 0x63, 0x6c, + 0x65, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x13, 0x2e, 0x52, 0x65, 0x63, 0x79, 0x63, 0x6c, 0x65, 0x49, + 0x74, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x07, 0x2e, 0x52, 0x65, 0x73, + 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x34, 0x0a, 0x0f, 0x53, 0x61, 0x76, 0x65, 0x4c, 0x65, 0x76, + 0x65, 0x6c, 0x50, 0x72, 0x69, 0x63, 0x65, 0x73, 0x12, 0x16, 0x2e, 0x53, 0x61, 0x76, 0x65, 0x4c, + 0x65, 0x76, 0x65, 0x6c, 0x50, 0x72, 0x69, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x07, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x2f, 0x0a, 0x0d, 0x53, + 0x69, 0x67, 0x6e, 0x41, 0x73, 0x49, 0x6c, 0x6c, 0x65, 0x67, 0x61, 0x6c, 0x12, 0x13, 0x2e, 0x49, + 0x74, 0x65, 0x6d, 0x49, 0x6c, 0x6c, 0x65, 0x67, 0x61, 0x6c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x07, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x30, 0x0a, 0x0e, + 0x53, 0x65, 0x74, 0x53, 0x68, 0x65, 0x6c, 0x76, 0x65, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x13, + 0x2e, 0x53, 0x68, 0x65, 0x6c, 0x76, 0x65, 0x53, 0x74, 0x61, 0x74, 0x65, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x07, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x32, + 0x0a, 0x11, 0x47, 0x65, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x44, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x44, + 0x61, 0x74, 0x61, 0x12, 0x12, 0x2e, 0x49, 0x74, 0x65, 0x6d, 0x44, 0x65, 0x74, 0x61, 0x69, 0x6c, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x07, 0x2e, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, + 0x22, 0x00, 0x12, 0x34, 0x0a, 0x08, 0x47, 0x65, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x73, 0x12, 0x10, + 0x2e, 0x47, 0x65, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x14, 0x2e, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x47, 0x6f, 0x6f, 0x64, 0x73, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x3c, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x57, + 0x68, 0x6f, 0x6c, 0x65, 0x73, 0x61, 0x6c, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x41, 0x72, 0x72, + 0x61, 0x79, 0x12, 0x06, 0x2e, 0x53, 0x6b, 0x75, 0x49, 0x64, 0x1a, 0x18, 0x2e, 0x53, 0x57, 0x73, + 0x53, 0x6b, 0x75, 0x50, 0x72, 0x69, 0x63, 0x65, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x36, 0x0a, 0x12, 0x53, 0x61, 0x76, 0x65, 0x57, 0x68, + 0x6f, 0x6c, 0x65, 0x73, 0x61, 0x6c, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x15, 0x2e, 0x53, + 0x61, 0x76, 0x65, 0x53, 0x6b, 0x75, 0x50, 0x72, 0x69, 0x63, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x07, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x52, + 0x0a, 0x19, 0x47, 0x65, 0x74, 0x57, 0x68, 0x6f, 0x6c, 0x65, 0x73, 0x61, 0x6c, 0x65, 0x44, 0x69, + 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x41, 0x72, 0x72, 0x61, 0x79, 0x12, 0x15, 0x2e, 0x47, 0x65, + 0x74, 0x57, 0x73, 0x44, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x1c, 0x2e, 0x53, 0x57, 0x73, 0x49, 0x74, 0x65, 0x6d, 0x44, 0x69, 0x73, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x00, 0x12, 0x3c, 0x0a, 0x15, 0x53, 0x61, 0x76, 0x65, 0x57, 0x68, 0x6f, 0x6c, 0x65, 0x73, + 0x61, 0x6c, 0x65, 0x44, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x18, 0x2e, 0x53, 0x61, + 0x76, 0x65, 0x49, 0x74, 0x65, 0x6d, 0x44, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x07, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, - 0x12, 0x32, 0x0a, 0x11, 0x47, 0x65, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x44, 0x65, 0x74, 0x61, 0x69, - 0x6c, 0x44, 0x61, 0x74, 0x61, 0x12, 0x12, 0x2e, 0x49, 0x74, 0x65, 0x6d, 0x44, 0x65, 0x74, 0x61, - 0x69, 0x6c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x07, 0x2e, 0x53, 0x74, 0x72, 0x69, - 0x6e, 0x67, 0x22, 0x00, 0x12, 0x45, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x50, 0x61, 0x67, 0x69, 0x6e, - 0x67, 0x4f, 0x6e, 0x53, 0x68, 0x65, 0x6c, 0x76, 0x65, 0x73, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x13, - 0x2e, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x47, 0x6f, 0x6f, 0x64, 0x73, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x14, 0x2e, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x47, 0x6f, 0x6f, 0x64, - 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x34, 0x0a, 0x08, 0x47, - 0x65, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x73, 0x12, 0x10, 0x2e, 0x47, 0x65, 0x74, 0x49, 0x74, 0x65, - 0x6d, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x14, 0x2e, 0x50, 0x61, 0x67, 0x69, - 0x6e, 0x67, 0x47, 0x6f, 0x6f, 0x64, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x00, 0x12, 0x3c, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x57, 0x68, 0x6f, 0x6c, 0x65, 0x73, 0x61, 0x6c, - 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x41, 0x72, 0x72, 0x61, 0x79, 0x12, 0x06, 0x2e, 0x53, 0x6b, - 0x75, 0x49, 0x64, 0x1a, 0x18, 0x2e, 0x53, 0x57, 0x73, 0x53, 0x6b, 0x75, 0x50, 0x72, 0x69, 0x63, - 0x65, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, - 0x36, 0x0a, 0x12, 0x53, 0x61, 0x76, 0x65, 0x57, 0x68, 0x6f, 0x6c, 0x65, 0x73, 0x61, 0x6c, 0x65, - 0x50, 0x72, 0x69, 0x63, 0x65, 0x12, 0x15, 0x2e, 0x53, 0x61, 0x76, 0x65, 0x53, 0x6b, 0x75, 0x50, - 0x72, 0x69, 0x63, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x07, 0x2e, 0x52, - 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x52, 0x0a, 0x19, 0x47, 0x65, 0x74, 0x57, 0x68, - 0x6f, 0x6c, 0x65, 0x73, 0x61, 0x6c, 0x65, 0x44, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x41, - 0x72, 0x72, 0x61, 0x79, 0x12, 0x15, 0x2e, 0x47, 0x65, 0x74, 0x57, 0x73, 0x44, 0x69, 0x73, 0x63, - 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1c, 0x2e, 0x53, 0x57, - 0x73, 0x49, 0x74, 0x65, 0x6d, 0x44, 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x4c, 0x69, 0x73, - 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x3c, 0x0a, 0x15, 0x53, - 0x61, 0x76, 0x65, 0x57, 0x68, 0x6f, 0x6c, 0x65, 0x73, 0x61, 0x6c, 0x65, 0x44, 0x69, 0x73, 0x63, - 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x18, 0x2e, 0x53, 0x61, 0x76, 0x65, 0x49, 0x74, 0x65, 0x6d, 0x44, - 0x69, 0x73, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x07, - 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x34, 0x0a, 0x10, 0x47, 0x65, 0x74, - 0x41, 0x6c, 0x6c, 0x53, 0x61, 0x6c, 0x65, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x73, 0x12, 0x06, 0x2e, - 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x16, 0x2e, 0x49, 0x74, 0x65, 0x6d, 0x4c, 0x61, 0x62, 0x65, - 0x6c, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, - 0x28, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x53, 0x61, 0x6c, 0x65, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x12, - 0x09, 0x2e, 0x49, 0x64, 0x4f, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x1a, 0x0b, 0x2e, 0x53, 0x49, 0x74, - 0x65, 0x6d, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x00, 0x12, 0x27, 0x0a, 0x0d, 0x53, 0x61, 0x76, - 0x65, 0x53, 0x61, 0x6c, 0x65, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x12, 0x0b, 0x2e, 0x53, 0x49, 0x74, - 0x65, 0x6d, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x1a, 0x07, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, - 0x22, 0x00, 0x12, 0x24, 0x0a, 0x0f, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x53, 0x61, 0x6c, 0x65, - 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x12, 0x06, 0x2e, 0x49, 0x6e, 0x74, 0x36, 0x34, 0x1a, 0x07, 0x2e, - 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x51, 0x0a, 0x1e, 0x47, 0x65, 0x74, 0x50, - 0x61, 0x67, 0x65, 0x64, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x47, 0x6f, 0x6f, 0x64, 0x73, 0x42, 0x79, - 0x53, 0x61, 0x6c, 0x65, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x5f, 0x12, 0x17, 0x2e, 0x53, 0x61, 0x6c, - 0x65, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x49, 0x74, 0x65, 0x6d, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x5f, 0x1a, 0x14, 0x2e, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x47, 0x6f, 0x6f, 0x64, - 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, 0x1f, 0x0a, 0x13, 0x63, - 0x6f, 0x6d, 0x2e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x67, 0x6f, 0x32, 0x6f, 0x2e, 0x72, - 0x70, 0x63, 0x5a, 0x08, 0x2e, 0x2f, 0x3b, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x06, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x33, + 0x12, 0x34, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x53, 0x61, 0x6c, 0x65, 0x4c, 0x61, + 0x62, 0x65, 0x6c, 0x73, 0x12, 0x06, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x16, 0x2e, 0x49, + 0x74, 0x65, 0x6d, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x28, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x53, 0x61, 0x6c, + 0x65, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x12, 0x09, 0x2e, 0x49, 0x64, 0x4f, 0x72, 0x4e, 0x61, 0x6d, + 0x65, 0x1a, 0x0b, 0x2e, 0x53, 0x49, 0x74, 0x65, 0x6d, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x22, 0x00, + 0x12, 0x27, 0x0a, 0x0d, 0x53, 0x61, 0x76, 0x65, 0x53, 0x61, 0x6c, 0x65, 0x4c, 0x61, 0x62, 0x65, + 0x6c, 0x12, 0x0b, 0x2e, 0x53, 0x49, 0x74, 0x65, 0x6d, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x1a, 0x07, + 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, 0x24, 0x0a, 0x0f, 0x44, 0x65, 0x6c, + 0x65, 0x74, 0x65, 0x53, 0x61, 0x6c, 0x65, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x12, 0x06, 0x2e, 0x49, + 0x6e, 0x74, 0x36, 0x34, 0x1a, 0x07, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x00, 0x12, + 0x51, 0x0a, 0x1e, 0x47, 0x65, 0x74, 0x50, 0x61, 0x67, 0x65, 0x64, 0x56, 0x61, 0x6c, 0x75, 0x65, + 0x47, 0x6f, 0x6f, 0x64, 0x73, 0x42, 0x79, 0x53, 0x61, 0x6c, 0x65, 0x4c, 0x61, 0x62, 0x65, 0x6c, + 0x5f, 0x12, 0x17, 0x2e, 0x53, 0x61, 0x6c, 0x65, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x49, 0x74, 0x65, + 0x6d, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x5f, 0x1a, 0x14, 0x2e, 0x50, 0x61, 0x67, + 0x69, 0x6e, 0x67, 0x47, 0x6f, 0x6f, 0x64, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x00, 0x42, 0x1f, 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, + 0x2e, 0x67, 0x6f, 0x32, 0x6f, 0x2e, 0x72, 0x70, 0x63, 0x5a, 0x08, 0x2e, 0x2f, 0x3b, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -345,99 +248,93 @@ func file_item_service_proto_rawDescGZIP() []byte { return file_item_service_proto_rawDescData } -var file_item_service_proto_msgTypes = make([]protoimpl.MessageInfo, 3) +var file_item_service_proto_msgTypes = make([]protoimpl.MessageInfo, 2) var file_item_service_proto_goTypes = []interface{}{ (*ItemDetailRequest)(nil), // 0: ItemDetailRequest - (*PagingGoodsRequest)(nil), // 1: PagingGoodsRequest - (*SaleLabelItemsRequest_)(nil), // 2: SaleLabelItemsRequest_ - (EItemSalesType)(0), // 3: EItemSalesType - (*SPagingParams)(nil), // 4: SPagingParams - (*GetItemRequest)(nil), // 5: GetItemRequest - (*SaveItemRequest)(nil), // 6: SaveItemRequest - (*ItemBySkuRequest)(nil), // 7: ItemBySkuRequest - (*GetItemAndSnapshotRequest)(nil), // 8: GetItemAndSnapshotRequest - (*Int64)(nil), // 9: Int64 - (*SkuId)(nil), // 10: SkuId - (*ItemReviewRequest)(nil), // 11: ItemReviewRequest - (*RecycleItemRequest)(nil), // 12: RecycleItemRequest - (*SaveLevelPriceRequest)(nil), // 13: SaveLevelPriceRequest - (*ItemIllegalRequest)(nil), // 14: ItemIllegalRequest - (*ShelveStateRequest)(nil), // 15: ShelveStateRequest - (*GetItemsRequest)(nil), // 16: GetItemsRequest - (*SaveSkuPricesRequest)(nil), // 17: SaveSkuPricesRequest - (*GetWsDiscountRequest)(nil), // 18: GetWsDiscountRequest - (*SaveItemDiscountRequest)(nil), // 19: SaveItemDiscountRequest - (*Empty)(nil), // 20: Empty - (*IdOrName)(nil), // 21: IdOrName - (*SItemLabel)(nil), // 22: SItemLabel - (*SItemDataResponse)(nil), // 23: SItemDataResponse - (*SaveItemResponse)(nil), // 24: SaveItemResponse - (*SUnifiedViewItem)(nil), // 25: SUnifiedViewItem - (*ItemSnapshotResponse)(nil), // 26: ItemSnapshotResponse - (*STradeSnapshot)(nil), // 27: STradeSnapshot - (*SSku)(nil), // 28: SSku - (*Result)(nil), // 29: Result - (*String)(nil), // 30: String - (*PagingGoodsResponse)(nil), // 31: PagingGoodsResponse - (*SWsSkuPriceListResponse)(nil), // 32: SWsSkuPriceListResponse - (*SWsItemDiscountListResponse)(nil), // 33: SWsItemDiscountListResponse - (*ItemLabelListResponse)(nil), // 34: ItemLabelListResponse + (*SaleLabelItemsRequest_)(nil), // 1: SaleLabelItemsRequest_ + (*SPagingParams)(nil), // 2: SPagingParams + (*GetItemRequest)(nil), // 3: GetItemRequest + (*SaveItemRequest)(nil), // 4: SaveItemRequest + (*ItemBySkuRequest)(nil), // 5: ItemBySkuRequest + (*GetItemAndSnapshotRequest)(nil), // 6: GetItemAndSnapshotRequest + (*Int64)(nil), // 7: Int64 + (*SkuId)(nil), // 8: SkuId + (*ItemReviewRequest)(nil), // 9: ItemReviewRequest + (*RecycleItemRequest)(nil), // 10: RecycleItemRequest + (*SaveLevelPriceRequest)(nil), // 11: SaveLevelPriceRequest + (*ItemIllegalRequest)(nil), // 12: ItemIllegalRequest + (*ShelveStateRequest)(nil), // 13: ShelveStateRequest + (*GetItemsRequest)(nil), // 14: GetItemsRequest + (*SaveSkuPricesRequest)(nil), // 15: SaveSkuPricesRequest + (*GetWsDiscountRequest)(nil), // 16: GetWsDiscountRequest + (*SaveItemDiscountRequest)(nil), // 17: SaveItemDiscountRequest + (*Empty)(nil), // 18: Empty + (*IdOrName)(nil), // 19: IdOrName + (*SItemLabel)(nil), // 20: SItemLabel + (*SItemDataResponse)(nil), // 21: SItemDataResponse + (*SaveItemResponse)(nil), // 22: SaveItemResponse + (*SUnifiedViewItem)(nil), // 23: SUnifiedViewItem + (*ItemSnapshotResponse)(nil), // 24: ItemSnapshotResponse + (*STradeSnapshot)(nil), // 25: STradeSnapshot + (*SSku)(nil), // 26: SSku + (*Result)(nil), // 27: Result + (*String)(nil), // 28: String + (*PagingGoodsResponse)(nil), // 29: PagingGoodsResponse + (*SWsSkuPriceListResponse)(nil), // 30: SWsSkuPriceListResponse + (*SWsItemDiscountListResponse)(nil), // 31: SWsItemDiscountListResponse + (*ItemLabelListResponse)(nil), // 32: ItemLabelListResponse } var file_item_service_proto_depIdxs = []int32{ - 3, // 0: PagingGoodsRequest.itemType:type_name -> EItemSalesType - 4, // 1: PagingGoodsRequest.params:type_name -> SPagingParams - 4, // 2: SaleLabelItemsRequest_.params:type_name -> SPagingParams - 5, // 3: ItemService.GetItem:input_type -> GetItemRequest - 6, // 4: ItemService.SaveItem:input_type -> SaveItemRequest - 7, // 5: ItemService.GetItemBySku:input_type -> ItemBySkuRequest - 8, // 6: ItemService.GetItemAndSnapshot:input_type -> GetItemAndSnapshotRequest - 9, // 7: ItemService.GetTradeSnapshot:input_type -> Int64 - 10, // 8: ItemService.GetSku:input_type -> SkuId - 11, // 9: ItemService.ReviewItem:input_type -> ItemReviewRequest - 12, // 10: ItemService.RecycleItem:input_type -> RecycleItemRequest - 13, // 11: ItemService.SaveLevelPrices:input_type -> SaveLevelPriceRequest - 14, // 12: ItemService.SignAsIllegal:input_type -> ItemIllegalRequest - 15, // 13: ItemService.SetShelveState:input_type -> ShelveStateRequest - 0, // 14: ItemService.GetItemDetailData:input_type -> ItemDetailRequest - 1, // 15: ItemService.GetPagingOnShelvesItem:input_type -> PagingGoodsRequest - 16, // 16: ItemService.GetItems:input_type -> GetItemsRequest - 10, // 17: ItemService.GetWholesalePriceArray:input_type -> SkuId - 17, // 18: ItemService.SaveWholesalePrice:input_type -> SaveSkuPricesRequest - 18, // 19: ItemService.GetWholesaleDiscountArray:input_type -> GetWsDiscountRequest - 19, // 20: ItemService.SaveWholesaleDiscount:input_type -> SaveItemDiscountRequest - 20, // 21: ItemService.GetAllSaleLabels:input_type -> Empty - 21, // 22: ItemService.GetSaleLabel:input_type -> IdOrName - 22, // 23: ItemService.SaveSaleLabel:input_type -> SItemLabel - 9, // 24: ItemService.DeleteSaleLabel:input_type -> Int64 - 2, // 25: ItemService.GetPagedValueGoodsBySaleLabel_:input_type -> SaleLabelItemsRequest_ - 23, // 26: ItemService.GetItem:output_type -> SItemDataResponse - 24, // 27: ItemService.SaveItem:output_type -> SaveItemResponse - 25, // 28: ItemService.GetItemBySku:output_type -> SUnifiedViewItem - 26, // 29: ItemService.GetItemAndSnapshot:output_type -> ItemSnapshotResponse - 27, // 30: ItemService.GetTradeSnapshot:output_type -> STradeSnapshot - 28, // 31: ItemService.GetSku:output_type -> SSku - 29, // 32: ItemService.ReviewItem:output_type -> Result - 29, // 33: ItemService.RecycleItem:output_type -> Result - 29, // 34: ItemService.SaveLevelPrices:output_type -> Result - 29, // 35: ItemService.SignAsIllegal:output_type -> Result - 29, // 36: ItemService.SetShelveState:output_type -> Result - 30, // 37: ItemService.GetItemDetailData:output_type -> String - 31, // 38: ItemService.GetPagingOnShelvesItem:output_type -> PagingGoodsResponse - 31, // 39: ItemService.GetItems:output_type -> PagingGoodsResponse - 32, // 40: ItemService.GetWholesalePriceArray:output_type -> SWsSkuPriceListResponse - 29, // 41: ItemService.SaveWholesalePrice:output_type -> Result - 33, // 42: ItemService.GetWholesaleDiscountArray:output_type -> SWsItemDiscountListResponse - 29, // 43: ItemService.SaveWholesaleDiscount:output_type -> Result - 34, // 44: ItemService.GetAllSaleLabels:output_type -> ItemLabelListResponse - 22, // 45: ItemService.GetSaleLabel:output_type -> SItemLabel - 29, // 46: ItemService.SaveSaleLabel:output_type -> Result - 29, // 47: ItemService.DeleteSaleLabel:output_type -> Result - 31, // 48: ItemService.GetPagedValueGoodsBySaleLabel_:output_type -> PagingGoodsResponse - 26, // [26:49] is the sub-list for method output_type - 3, // [3:26] is the sub-list for method input_type - 3, // [3:3] is the sub-list for extension type_name - 3, // [3:3] is the sub-list for extension extendee - 0, // [0:3] is the sub-list for field type_name + 2, // 0: SaleLabelItemsRequest_.params:type_name -> SPagingParams + 3, // 1: ItemService.GetItem:input_type -> GetItemRequest + 4, // 2: ItemService.SaveItem:input_type -> SaveItemRequest + 5, // 3: ItemService.GetItemBySku:input_type -> ItemBySkuRequest + 6, // 4: ItemService.GetItemAndSnapshot:input_type -> GetItemAndSnapshotRequest + 7, // 5: ItemService.GetTradeSnapshot:input_type -> Int64 + 8, // 6: ItemService.GetSku:input_type -> SkuId + 9, // 7: ItemService.ReviewItem:input_type -> ItemReviewRequest + 10, // 8: ItemService.RecycleItem:input_type -> RecycleItemRequest + 11, // 9: ItemService.SaveLevelPrices:input_type -> SaveLevelPriceRequest + 12, // 10: ItemService.SignAsIllegal:input_type -> ItemIllegalRequest + 13, // 11: ItemService.SetShelveState:input_type -> ShelveStateRequest + 0, // 12: ItemService.GetItemDetailData:input_type -> ItemDetailRequest + 14, // 13: ItemService.GetItems:input_type -> GetItemsRequest + 8, // 14: ItemService.GetWholesalePriceArray:input_type -> SkuId + 15, // 15: ItemService.SaveWholesalePrice:input_type -> SaveSkuPricesRequest + 16, // 16: ItemService.GetWholesaleDiscountArray:input_type -> GetWsDiscountRequest + 17, // 17: ItemService.SaveWholesaleDiscount:input_type -> SaveItemDiscountRequest + 18, // 18: ItemService.GetAllSaleLabels:input_type -> Empty + 19, // 19: ItemService.GetSaleLabel:input_type -> IdOrName + 20, // 20: ItemService.SaveSaleLabel:input_type -> SItemLabel + 7, // 21: ItemService.DeleteSaleLabel:input_type -> Int64 + 1, // 22: ItemService.GetPagedValueGoodsBySaleLabel_:input_type -> SaleLabelItemsRequest_ + 21, // 23: ItemService.GetItem:output_type -> SItemDataResponse + 22, // 24: ItemService.SaveItem:output_type -> SaveItemResponse + 23, // 25: ItemService.GetItemBySku:output_type -> SUnifiedViewItem + 24, // 26: ItemService.GetItemAndSnapshot:output_type -> ItemSnapshotResponse + 25, // 27: ItemService.GetTradeSnapshot:output_type -> STradeSnapshot + 26, // 28: ItemService.GetSku:output_type -> SSku + 27, // 29: ItemService.ReviewItem:output_type -> Result + 27, // 30: ItemService.RecycleItem:output_type -> Result + 27, // 31: ItemService.SaveLevelPrices:output_type -> Result + 27, // 32: ItemService.SignAsIllegal:output_type -> Result + 27, // 33: ItemService.SetShelveState:output_type -> Result + 28, // 34: ItemService.GetItemDetailData:output_type -> String + 29, // 35: ItemService.GetItems:output_type -> PagingGoodsResponse + 30, // 36: ItemService.GetWholesalePriceArray:output_type -> SWsSkuPriceListResponse + 27, // 37: ItemService.SaveWholesalePrice:output_type -> Result + 31, // 38: ItemService.GetWholesaleDiscountArray:output_type -> SWsItemDiscountListResponse + 27, // 39: ItemService.SaveWholesaleDiscount:output_type -> Result + 32, // 40: ItemService.GetAllSaleLabels:output_type -> ItemLabelListResponse + 20, // 41: ItemService.GetSaleLabel:output_type -> SItemLabel + 27, // 42: ItemService.SaveSaleLabel:output_type -> Result + 27, // 43: ItemService.DeleteSaleLabel:output_type -> Result + 29, // 44: ItemService.GetPagedValueGoodsBySaleLabel_:output_type -> PagingGoodsResponse + 23, // [23:45] is the sub-list for method output_type + 1, // [1:23] is the sub-list for method input_type + 1, // [1:1] is the sub-list for extension type_name + 1, // [1:1] is the sub-list for extension extendee + 0, // [0:1] is the sub-list for field type_name } func init() { file_item_service_proto_init() } @@ -461,18 +358,6 @@ func file_item_service_proto_init() { } } file_item_service_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*PagingGoodsRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_item_service_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*SaleLabelItemsRequest_); i { case 0: return &v.state @@ -491,7 +376,7 @@ func file_item_service_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_item_service_proto_rawDesc, NumEnums: 0, - NumMessages: 3, + NumMessages: 2, NumExtensions: 0, NumServices: 1, }, diff --git a/core/service/proto/item_service_grpc.pb.go b/core/service/proto/item_service_grpc.pb.go index 2c2f553e2..d429c02f3 100644 --- a/core/service/proto/item_service_grpc.pb.go +++ b/core/service/proto/item_service_grpc.pb.go @@ -31,7 +31,6 @@ const ( ItemService_SignAsIllegal_FullMethodName = "/ItemService/SignAsIllegal" ItemService_SetShelveState_FullMethodName = "/ItemService/SetShelveState" ItemService_GetItemDetailData_FullMethodName = "/ItemService/GetItemDetailData" - ItemService_GetPagingOnShelvesItem_FullMethodName = "/ItemService/GetPagingOnShelvesItem" ItemService_GetItems_FullMethodName = "/ItemService/GetItems" ItemService_GetWholesalePriceArray_FullMethodName = "/ItemService/GetWholesalePriceArray" ItemService_SaveWholesalePrice_FullMethodName = "/ItemService/SaveWholesalePrice" @@ -72,8 +71,6 @@ type ItemServiceClient interface { SetShelveState(ctx context.Context, in *ShelveStateRequest, opts ...grpc.CallOption) (*Result, error) // 获取商品详细数据 GetItemDetailData(ctx context.Context, in *ItemDetailRequest, opts ...grpc.CallOption) (*String, error) - // 获取上架商品数据(分页) - GetPagingOnShelvesItem(ctx context.Context, in *PagingGoodsRequest, opts ...grpc.CallOption) (*PagingGoodsResponse, error) // 获取上架商品数据 GetItems(ctx context.Context, in *GetItemsRequest, opts ...grpc.CallOption) (*PagingGoodsResponse, error) // 获取批发价格数组 @@ -212,15 +209,6 @@ func (c *itemServiceClient) GetItemDetailData(ctx context.Context, in *ItemDetai return out, nil } -func (c *itemServiceClient) GetPagingOnShelvesItem(ctx context.Context, in *PagingGoodsRequest, opts ...grpc.CallOption) (*PagingGoodsResponse, error) { - out := new(PagingGoodsResponse) - err := c.cc.Invoke(ctx, ItemService_GetPagingOnShelvesItem_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - func (c *itemServiceClient) GetItems(ctx context.Context, in *GetItemsRequest, opts ...grpc.CallOption) (*PagingGoodsResponse, error) { out := new(PagingGoodsResponse) err := c.cc.Invoke(ctx, ItemService_GetItems_FullMethodName, in, out, opts...) @@ -339,8 +327,6 @@ type ItemServiceServer interface { SetShelveState(context.Context, *ShelveStateRequest) (*Result, error) // 获取商品详细数据 GetItemDetailData(context.Context, *ItemDetailRequest) (*String, error) - // 获取上架商品数据(分页) - GetPagingOnShelvesItem(context.Context, *PagingGoodsRequest) (*PagingGoodsResponse, error) // 获取上架商品数据 GetItems(context.Context, *GetItemsRequest) (*PagingGoodsResponse, error) // 获取批发价格数组 @@ -404,9 +390,6 @@ func (UnimplementedItemServiceServer) SetShelveState(context.Context, *ShelveSta func (UnimplementedItemServiceServer) GetItemDetailData(context.Context, *ItemDetailRequest) (*String, error) { return nil, status.Errorf(codes.Unimplemented, "method GetItemDetailData not implemented") } -func (UnimplementedItemServiceServer) GetPagingOnShelvesItem(context.Context, *PagingGoodsRequest) (*PagingGoodsResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method GetPagingOnShelvesItem not implemented") -} func (UnimplementedItemServiceServer) GetItems(context.Context, *GetItemsRequest) (*PagingGoodsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method GetItems not implemented") } @@ -666,24 +649,6 @@ func _ItemService_GetItemDetailData_Handler(srv interface{}, ctx context.Context return interceptor(ctx, in, info, handler) } -func _ItemService_GetPagingOnShelvesItem_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(PagingGoodsRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(ItemServiceServer).GetPagingOnShelvesItem(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: ItemService_GetPagingOnShelvesItem_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ItemServiceServer).GetPagingOnShelvesItem(ctx, req.(*PagingGoodsRequest)) - } - return interceptor(ctx, in, info, handler) -} - func _ItemService_GetItems_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(GetItemsRequest) if err := dec(in); err != nil { @@ -919,10 +884,6 @@ var ItemService_ServiceDesc = grpc.ServiceDesc{ MethodName: "GetItemDetailData", Handler: _ItemService_GetItemDetailData_Handler, }, - { - MethodName: "GetPagingOnShelvesItem", - Handler: _ItemService_GetPagingOnShelvesItem_Handler, - }, { MethodName: "GetItems", Handler: _ItemService_GetItems_Handler, diff --git a/core/service/proto/query_service.pb.go b/core/service/proto/query_service.pb.go index ad3b4ac59..1e87ab6a1 100644 --- a/core/service/proto/query_service.pb.go +++ b/core/service/proto/query_service.pb.go @@ -1469,14 +1469,18 @@ type PagingShopGoodsRequest struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields + // 商品类型 + ItemType EItemSalesType `protobuf:"varint,1,opt,name=itemType,proto3,enum=EItemSalesType" json:"itemType"` // 店铺编号 - ShopId int64 `protobuf:"varint,1,opt,name=shopId,proto3" json:"shopId"` + ShopId int64 `protobuf:"varint,2,opt,name=shopId,proto3" json:"shopId"` // 分类编号 - CategoryId int64 `protobuf:"varint,2,opt,name=categoryId,proto3" json:"categoryId"` + CategoryId int64 `protobuf:"varint,3,opt,name=categoryId,proto3" json:"categoryId"` // 商品标签 - Flag int32 `protobuf:"varint,3,opt,name=flag,proto3" json:"flag"` + Flag int32 `protobuf:"varint,4,opt,name=flag,proto3" json:"flag"` + // 关键词 + Keyword string `protobuf:"bytes,5,opt,name=keyword,proto3" json:"keyword"` // 分页参数 - Params *SPagingParams `protobuf:"bytes,4,opt,name=params,proto3" json:"params"` + Params *SPagingParams `protobuf:"bytes,6,opt,name=params,proto3" json:"params"` } func (x *PagingShopGoodsRequest) Reset() { @@ -1511,6 +1515,13 @@ func (*PagingShopGoodsRequest) Descriptor() ([]byte, []int) { return file_query_service_proto_rawDescGZIP(), []int{20} } +func (x *PagingShopGoodsRequest) GetItemType() EItemSalesType { + if x != nil { + return x.ItemType + } + return EItemSalesType_IT_NORMAL +} + func (x *PagingShopGoodsRequest) GetShopId() int64 { if x != nil { return x.ShopId @@ -1532,6 +1543,13 @@ func (x *PagingShopGoodsRequest) GetFlag() int32 { return 0 } +func (x *PagingShopGoodsRequest) GetKeyword() string { + if x != nil { + return x.Keyword + } + return "" +} + func (x *PagingShopGoodsRequest) GetParams() *SPagingParams { if x != nil { return x.Params @@ -2224,139 +2242,143 @@ var file_query_service_proto_rawDesc = []byte{ 0x61, 0x6c, 0x75, 0x65, 0x46, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x12, 0x26, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x53, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, - 0x6d, 0x73, 0x22, 0x8c, 0x01, 0x0a, 0x16, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x53, 0x68, 0x6f, - 0x70, 0x47, 0x6f, 0x6f, 0x64, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, - 0x06, 0x73, 0x68, 0x6f, 0x70, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x73, - 0x68, 0x6f, 0x70, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, - 0x79, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, - 0x6f, 0x72, 0x79, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x66, 0x6c, 0x61, 0x67, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x05, 0x52, 0x04, 0x66, 0x6c, 0x61, 0x67, 0x12, 0x26, 0x0a, 0x06, 0x70, 0x61, 0x72, - 0x61, 0x6d, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x53, 0x50, 0x61, 0x67, - 0x69, 0x6e, 0x67, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, - 0x73, 0x22, 0x4c, 0x0a, 0x17, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x53, 0x68, 0x6f, 0x70, 0x47, - 0x6f, 0x6f, 0x64, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x14, 0x0a, 0x05, - 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x74, 0x6f, 0x74, - 0x61, 0x6c, 0x12, 0x1b, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, - 0x32, 0x07, 0x2e, 0x53, 0x47, 0x6f, 0x6f, 0x64, 0x73, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x22, - 0x80, 0x01, 0x0a, 0x1c, 0x51, 0x75, 0x65, 0x72, 0x79, 0x49, 0x74, 0x65, 0x6d, 0x53, 0x61, 0x6c, - 0x65, 0x73, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, - 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x73, 0x69, 0x7a, 0x65, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x12, 0x16, 0x0a, 0x06, - 0x72, 0x61, 0x6e, 0x64, 0x6f, 0x6d, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x72, 0x61, - 0x6e, 0x64, 0x6f, 0x6d, 0x12, 0x1c, 0x0a, 0x09, 0x6d, 0x61, 0x73, 0x6b, 0x42, 0x75, 0x79, 0x65, - 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x6d, 0x61, 0x73, 0x6b, 0x42, 0x75, 0x79, - 0x65, 0x72, 0x22, 0xc1, 0x01, 0x0a, 0x11, 0x53, 0x49, 0x74, 0x65, 0x6d, 0x53, 0x61, 0x6c, 0x65, - 0x73, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x12, 0x24, 0x0a, 0x0d, 0x62, 0x75, 0x79, 0x65, - 0x72, 0x55, 0x73, 0x65, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0d, 0x62, 0x75, 0x79, 0x65, 0x72, 0x55, 0x73, 0x65, 0x72, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x1c, - 0x0a, 0x09, 0x62, 0x75, 0x79, 0x65, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x09, 0x62, 0x75, 0x79, 0x65, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x24, 0x0a, 0x0d, - 0x62, 0x75, 0x79, 0x65, 0x72, 0x50, 0x6f, 0x72, 0x74, 0x72, 0x61, 0x69, 0x74, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x0d, 0x62, 0x75, 0x79, 0x65, 0x72, 0x50, 0x6f, 0x72, 0x74, 0x72, 0x61, - 0x69, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x62, 0x75, 0x79, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x04, 0x20, - 0x01, 0x28, 0x03, 0x52, 0x07, 0x62, 0x75, 0x79, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x28, 0x0a, 0x0f, - 0x69, 0x73, 0x46, 0x69, 0x6e, 0x69, 0x73, 0x68, 0x50, 0x61, 0x79, 0x6d, 0x65, 0x6e, 0x74, 0x18, - 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0f, 0x69, 0x73, 0x46, 0x69, 0x6e, 0x69, 0x73, 0x68, 0x50, - 0x61, 0x79, 0x6d, 0x65, 0x6e, 0x74, 0x22, 0x49, 0x0a, 0x1d, 0x51, 0x75, 0x65, 0x72, 0x79, 0x49, - 0x74, 0x65, 0x6d, 0x53, 0x61, 0x6c, 0x65, 0x73, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x28, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, - 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x53, 0x49, 0x74, 0x65, 0x6d, 0x53, 0x61, - 0x6c, 0x65, 0x73, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, - 0x65, 0x22, 0x59, 0x0a, 0x11, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x49, 0x74, 0x65, 0x6d, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x68, 0x6f, 0x70, 0x49, 0x64, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x73, 0x68, 0x6f, 0x70, 0x49, 0x64, 0x12, 0x18, - 0x0a, 0x07, 0x6b, 0x65, 0x79, 0x77, 0x6f, 0x72, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x07, 0x6b, 0x65, 0x79, 0x77, 0x6f, 0x72, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x73, 0x69, 0x7a, 0x65, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x22, 0x3e, 0x0a, 0x12, - 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x12, 0x28, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x03, 0x28, - 0x0b, 0x32, 0x12, 0x2e, 0x53, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x49, 0x74, 0x65, 0x6d, 0x52, - 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0xdf, 0x01, 0x0a, - 0x11, 0x53, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x65, 0x73, 0x75, - 0x6c, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x69, 0x74, - 0x65, 0x6d, 0x46, 0x6c, 0x61, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x69, 0x74, - 0x65, 0x6d, 0x46, 0x6c, 0x61, 0x67, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x65, - 0x6c, 0x6c, 0x65, 0x72, 0x49, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x73, 0x65, - 0x6c, 0x6c, 0x65, 0x72, 0x49, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, - 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x12, 0x14, 0x0a, 0x05, - 0x69, 0x6d, 0x61, 0x67, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x69, 0x6d, 0x61, - 0x67, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x70, 0x72, 0x69, 0x63, 0x65, 0x52, 0x61, 0x6e, 0x67, 0x65, - 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x70, 0x72, 0x69, 0x63, 0x65, 0x52, 0x61, 0x6e, - 0x67, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x74, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x08, - 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x73, 0x74, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x32, 0xad, - 0x08, 0x0a, 0x0c, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, - 0x4a, 0x0a, 0x11, 0x53, 0x75, 0x6d, 0x6d, 0x61, 0x72, 0x79, 0x53, 0x74, 0x61, 0x74, 0x69, 0x73, - 0x74, 0x69, 0x63, 0x73, 0x12, 0x19, 0x2e, 0x53, 0x75, 0x6d, 0x6d, 0x61, 0x72, 0x79, 0x53, 0x74, - 0x61, 0x74, 0x69, 0x73, 0x74, 0x69, 0x63, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, - 0x1a, 0x2e, 0x53, 0x75, 0x6d, 0x6d, 0x61, 0x72, 0x79, 0x53, 0x74, 0x61, 0x74, 0x69, 0x73, 0x74, - 0x69, 0x63, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x49, 0x0a, 0x10, 0x4d, - 0x65, 0x6d, 0x62, 0x65, 0x72, 0x53, 0x74, 0x61, 0x74, 0x69, 0x73, 0x74, 0x69, 0x63, 0x73, 0x12, - 0x18, 0x2e, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x53, 0x74, 0x61, 0x74, 0x69, 0x73, 0x74, 0x69, - 0x63, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x4d, 0x65, 0x6d, 0x62, - 0x65, 0x72, 0x53, 0x74, 0x61, 0x74, 0x69, 0x73, 0x74, 0x69, 0x63, 0x73, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x41, 0x0a, 0x0b, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, - 0x53, 0x68, 0x6f, 0x70, 0x73, 0x12, 0x17, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x67, - 0x69, 0x6e, 0x67, 0x53, 0x68, 0x6f, 0x70, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x19, - 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x53, 0x68, 0x6f, 0x70, - 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x4d, 0x0a, 0x12, 0x4d, 0x65, 0x6d, - 0x62, 0x65, 0x72, 0x4e, 0x6f, 0x72, 0x6d, 0x61, 0x6c, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x73, 0x12, - 0x19, 0x2e, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x50, 0x61, 0x67, - 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1a, 0x2e, 0x4d, 0x65, 0x6d, - 0x62, 0x65, 0x72, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x4f, 0x0a, 0x14, 0x51, 0x75, 0x65, 0x72, - 0x79, 0x57, 0x68, 0x6f, 0x6c, 0x65, 0x73, 0x61, 0x6c, 0x65, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x73, - 0x12, 0x19, 0x2e, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x50, 0x61, - 0x67, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1a, 0x2e, 0x4d, 0x65, - 0x6d, 0x62, 0x65, 0x72, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x4b, 0x0a, 0x10, 0x51, 0x75, 0x65, - 0x72, 0x79, 0x54, 0x72, 0x61, 0x64, 0x65, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x73, 0x12, 0x19, 0x2e, - 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x50, 0x61, 0x67, 0x69, 0x6e, - 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1a, 0x2e, 0x4d, 0x65, 0x6d, 0x62, 0x65, - 0x72, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x3c, 0x0a, 0x0f, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4d, - 0x65, 0x6d, 0x62, 0x65, 0x72, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x12, 0x2e, 0x4d, 0x65, 0x6d, 0x62, - 0x65, 0x72, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x13, 0x2e, - 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x22, 0x00, 0x12, 0x3c, 0x0a, 0x0d, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x4d, 0x65, - 0x6d, 0x62, 0x65, 0x72, 0x73, 0x12, 0x14, 0x2e, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x53, 0x65, - 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x13, 0x2e, 0x4d, 0x65, - 0x6d, 0x62, 0x65, 0x72, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x22, 0x00, 0x12, 0x50, 0x0a, 0x18, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4d, 0x65, 0x6d, 0x62, 0x65, - 0x72, 0x46, 0x61, 0x76, 0x6f, 0x72, 0x69, 0x74, 0x65, 0x53, 0x68, 0x6f, 0x70, 0x73, 0x12, 0x15, - 0x2e, 0x46, 0x61, 0x76, 0x6f, 0x72, 0x69, 0x74, 0x65, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1b, 0x2e, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x53, 0x68, - 0x6f, 0x70, 0x46, 0x61, 0x76, 0x6f, 0x72, 0x69, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x22, 0x00, 0x12, 0x51, 0x0a, 0x18, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4d, 0x65, 0x6d, - 0x62, 0x65, 0x72, 0x46, 0x61, 0x76, 0x6f, 0x72, 0x69, 0x74, 0x65, 0x47, 0x6f, 0x6f, 0x64, 0x73, - 0x12, 0x15, 0x2e, 0x46, 0x61, 0x76, 0x6f, 0x72, 0x69, 0x74, 0x65, 0x51, 0x75, 0x65, 0x72, 0x79, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1c, 0x2e, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, - 0x47, 0x6f, 0x6f, 0x64, 0x73, 0x46, 0x61, 0x76, 0x6f, 0x72, 0x69, 0x74, 0x65, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x55, 0x0a, 0x16, 0x50, 0x61, 0x67, 0x69, 0x6e, - 0x67, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x4c, 0x6f, - 0x67, 0x12, 0x18, 0x2e, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, - 0x74, 0x4c, 0x6f, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1f, 0x2e, 0x4d, 0x65, - 0x6d, 0x62, 0x65, 0x72, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x50, 0x61, 0x67, 0x69, 0x6e, - 0x67, 0x4c, 0x6f, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x4b, - 0x0a, 0x14, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x4f, 0x6e, 0x53, 0x68, 0x65, 0x6c, 0x76, 0x65, - 0x73, 0x47, 0x6f, 0x6f, 0x64, 0x73, 0x12, 0x17, 0x2e, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x53, - 0x68, 0x6f, 0x70, 0x47, 0x6f, 0x6f, 0x64, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, - 0x18, 0x2e, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x53, 0x68, 0x6f, 0x70, 0x47, 0x6f, 0x6f, 0x64, - 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x58, 0x0a, 0x15, 0x51, - 0x75, 0x65, 0x72, 0x79, 0x49, 0x74, 0x65, 0x6d, 0x53, 0x61, 0x6c, 0x65, 0x73, 0x48, 0x69, 0x73, - 0x74, 0x6f, 0x72, 0x79, 0x12, 0x1d, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x49, 0x74, 0x65, 0x6d, - 0x53, 0x61, 0x6c, 0x65, 0x73, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x49, 0x74, 0x65, 0x6d, 0x53, - 0x61, 0x6c, 0x65, 0x73, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x37, 0x0a, 0x0a, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x49, - 0x74, 0x65, 0x6d, 0x12, 0x12, 0x2e, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x49, 0x74, 0x65, 0x6d, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x13, 0x2e, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, - 0x49, 0x74, 0x65, 0x6d, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, 0x1f, - 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x67, 0x6f, 0x32, - 0x6f, 0x2e, 0x72, 0x70, 0x63, 0x5a, 0x08, 0x2e, 0x2f, 0x3b, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, - 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x6d, 0x73, 0x22, 0xd3, 0x01, 0x0a, 0x16, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x53, 0x68, 0x6f, + 0x70, 0x47, 0x6f, 0x6f, 0x64, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x2b, 0x0a, + 0x08, 0x69, 0x74, 0x65, 0x6d, 0x54, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, + 0x0f, 0x2e, 0x45, 0x49, 0x74, 0x65, 0x6d, 0x53, 0x61, 0x6c, 0x65, 0x73, 0x54, 0x79, 0x70, 0x65, + 0x52, 0x08, 0x69, 0x74, 0x65, 0x6d, 0x54, 0x79, 0x70, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x68, + 0x6f, 0x70, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x73, 0x68, 0x6f, 0x70, + 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, 0x49, 0x64, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0a, 0x63, 0x61, 0x74, 0x65, 0x67, 0x6f, 0x72, 0x79, + 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x66, 0x6c, 0x61, 0x67, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, + 0x52, 0x04, 0x66, 0x6c, 0x61, 0x67, 0x12, 0x18, 0x0a, 0x07, 0x6b, 0x65, 0x79, 0x77, 0x6f, 0x72, + 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6b, 0x65, 0x79, 0x77, 0x6f, 0x72, 0x64, + 0x12, 0x26, 0x0a, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x0e, 0x2e, 0x53, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, + 0x52, 0x06, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0x4c, 0x0a, 0x17, 0x50, 0x61, 0x67, 0x69, + 0x6e, 0x67, 0x53, 0x68, 0x6f, 0x70, 0x47, 0x6f, 0x6f, 0x64, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x05, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x12, 0x1b, 0x0a, 0x04, 0x64, 0x61, 0x74, + 0x61, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x07, 0x2e, 0x53, 0x47, 0x6f, 0x6f, 0x64, 0x73, + 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x22, 0x80, 0x01, 0x0a, 0x1c, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x49, 0x74, 0x65, 0x6d, 0x53, 0x61, 0x6c, 0x65, 0x73, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, + 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, 0x64, 0x12, + 0x12, 0x0a, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x73, + 0x69, 0x7a, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x61, 0x6e, 0x64, 0x6f, 0x6d, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x08, 0x52, 0x06, 0x72, 0x61, 0x6e, 0x64, 0x6f, 0x6d, 0x12, 0x1c, 0x0a, 0x09, 0x6d, + 0x61, 0x73, 0x6b, 0x42, 0x75, 0x79, 0x65, 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, + 0x6d, 0x61, 0x73, 0x6b, 0x42, 0x75, 0x79, 0x65, 0x72, 0x22, 0xc1, 0x01, 0x0a, 0x11, 0x53, 0x49, + 0x74, 0x65, 0x6d, 0x53, 0x61, 0x6c, 0x65, 0x73, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x12, + 0x24, 0x0a, 0x0d, 0x62, 0x75, 0x79, 0x65, 0x72, 0x55, 0x73, 0x65, 0x72, 0x43, 0x6f, 0x64, 0x65, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x62, 0x75, 0x79, 0x65, 0x72, 0x55, 0x73, 0x65, + 0x72, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x62, 0x75, 0x79, 0x65, 0x72, 0x4e, 0x61, + 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x62, 0x75, 0x79, 0x65, 0x72, 0x4e, + 0x61, 0x6d, 0x65, 0x12, 0x24, 0x0a, 0x0d, 0x62, 0x75, 0x79, 0x65, 0x72, 0x50, 0x6f, 0x72, 0x74, + 0x72, 0x61, 0x69, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x62, 0x75, 0x79, 0x65, + 0x72, 0x50, 0x6f, 0x72, 0x74, 0x72, 0x61, 0x69, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x62, 0x75, 0x79, + 0x54, 0x69, 0x6d, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x62, 0x75, 0x79, 0x54, + 0x69, 0x6d, 0x65, 0x12, 0x28, 0x0a, 0x0f, 0x69, 0x73, 0x46, 0x69, 0x6e, 0x69, 0x73, 0x68, 0x50, + 0x61, 0x79, 0x6d, 0x65, 0x6e, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0f, 0x69, 0x73, + 0x46, 0x69, 0x6e, 0x69, 0x73, 0x68, 0x50, 0x61, 0x79, 0x6d, 0x65, 0x6e, 0x74, 0x22, 0x49, 0x0a, + 0x1d, 0x51, 0x75, 0x65, 0x72, 0x79, 0x49, 0x74, 0x65, 0x6d, 0x53, 0x61, 0x6c, 0x65, 0x73, 0x48, + 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x28, + 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x12, 0x2e, + 0x53, 0x49, 0x74, 0x65, 0x6d, 0x53, 0x61, 0x6c, 0x65, 0x73, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, + 0x79, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x59, 0x0a, 0x11, 0x53, 0x65, 0x61, 0x72, + 0x63, 0x68, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, + 0x06, 0x73, 0x68, 0x6f, 0x70, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x06, 0x73, + 0x68, 0x6f, 0x70, 0x49, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x6b, 0x65, 0x79, 0x77, 0x6f, 0x72, 0x64, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6b, 0x65, 0x79, 0x77, 0x6f, 0x72, 0x64, 0x12, + 0x12, 0x0a, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x73, + 0x69, 0x7a, 0x65, 0x22, 0x3e, 0x0a, 0x12, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x49, 0x74, 0x65, + 0x6d, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x28, 0x0a, 0x05, 0x76, 0x61, 0x6c, + 0x75, 0x65, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x53, 0x53, 0x65, 0x61, 0x72, + 0x63, 0x68, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, 0x05, 0x76, 0x61, + 0x6c, 0x75, 0x65, 0x22, 0xdf, 0x01, 0x0a, 0x11, 0x53, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x49, + 0x74, 0x65, 0x6d, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x69, 0x74, 0x65, + 0x6d, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x69, 0x74, 0x65, 0x6d, 0x49, + 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x69, 0x74, 0x65, 0x6d, 0x46, 0x6c, 0x61, 0x67, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x05, 0x52, 0x08, 0x69, 0x74, 0x65, 0x6d, 0x46, 0x6c, 0x61, 0x67, 0x12, 0x12, 0x0a, + 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x63, 0x6f, 0x64, + 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x65, 0x6c, 0x6c, 0x65, 0x72, 0x49, 0x64, 0x18, 0x04, 0x20, + 0x01, 0x28, 0x03, 0x52, 0x08, 0x73, 0x65, 0x6c, 0x6c, 0x65, 0x72, 0x49, 0x64, 0x12, 0x14, 0x0a, + 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x69, + 0x74, 0x6c, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x18, 0x06, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x05, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x70, 0x72, 0x69, + 0x63, 0x65, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x70, + 0x72, 0x69, 0x63, 0x65, 0x52, 0x61, 0x6e, 0x67, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x74, 0x6f, + 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x18, 0x08, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x73, 0x74, 0x6f, + 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x32, 0xad, 0x08, 0x0a, 0x0c, 0x51, 0x75, 0x65, 0x72, 0x79, 0x53, + 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x4a, 0x0a, 0x11, 0x53, 0x75, 0x6d, 0x6d, 0x61, 0x72, + 0x79, 0x53, 0x74, 0x61, 0x74, 0x69, 0x73, 0x74, 0x69, 0x63, 0x73, 0x12, 0x19, 0x2e, 0x53, 0x75, + 0x6d, 0x6d, 0x61, 0x72, 0x79, 0x53, 0x74, 0x61, 0x74, 0x69, 0x73, 0x74, 0x69, 0x63, 0x73, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1a, 0x2e, 0x53, 0x75, 0x6d, 0x6d, 0x61, 0x72, 0x79, + 0x53, 0x74, 0x61, 0x74, 0x69, 0x73, 0x74, 0x69, 0x63, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x12, 0x49, 0x0a, 0x10, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x53, 0x74, 0x61, 0x74, + 0x69, 0x73, 0x74, 0x69, 0x63, 0x73, 0x12, 0x18, 0x2e, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x53, + 0x74, 0x61, 0x74, 0x69, 0x73, 0x74, 0x69, 0x63, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x19, 0x2e, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x53, 0x74, 0x61, 0x74, 0x69, 0x73, 0x74, + 0x69, 0x63, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x41, 0x0a, + 0x0b, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x53, 0x68, 0x6f, 0x70, 0x73, 0x12, 0x17, 0x2e, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x53, 0x68, 0x6f, 0x70, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x50, 0x61, 0x67, + 0x69, 0x6e, 0x67, 0x53, 0x68, 0x6f, 0x70, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x4d, 0x0a, 0x12, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x4e, 0x6f, 0x72, 0x6d, 0x61, 0x6c, + 0x4f, 0x72, 0x64, 0x65, 0x72, 0x73, 0x12, 0x19, 0x2e, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x4f, + 0x72, 0x64, 0x65, 0x72, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x1a, 0x2e, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x50, + 0x61, 0x67, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, + 0x4f, 0x0a, 0x14, 0x51, 0x75, 0x65, 0x72, 0x79, 0x57, 0x68, 0x6f, 0x6c, 0x65, 0x73, 0x61, 0x6c, + 0x65, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x73, 0x12, 0x19, 0x2e, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, + 0x4f, 0x72, 0x64, 0x65, 0x72, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x1a, 0x2e, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x4f, 0x72, 0x64, 0x65, 0x72, + 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, + 0x12, 0x4b, 0x0a, 0x10, 0x51, 0x75, 0x65, 0x72, 0x79, 0x54, 0x72, 0x61, 0x64, 0x65, 0x4f, 0x72, + 0x64, 0x65, 0x72, 0x73, 0x12, 0x19, 0x2e, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x4f, 0x72, 0x64, + 0x65, 0x72, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x1a, 0x2e, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x4f, 0x72, 0x64, 0x65, 0x72, 0x50, 0x61, 0x67, + 0x69, 0x6e, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x3c, 0x0a, + 0x0f, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x4c, 0x69, 0x73, 0x74, + 0x12, 0x12, 0x2e, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x1a, 0x13, 0x2e, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x4c, 0x69, 0x73, + 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x3c, 0x0a, 0x0d, 0x53, + 0x65, 0x61, 0x72, 0x63, 0x68, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, 0x12, 0x14, 0x2e, 0x4d, + 0x65, 0x6d, 0x62, 0x65, 0x72, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x13, 0x2e, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x4c, 0x69, 0x73, 0x74, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x50, 0x0a, 0x18, 0x51, 0x75, 0x65, + 0x72, 0x79, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x46, 0x61, 0x76, 0x6f, 0x72, 0x69, 0x74, 0x65, + 0x53, 0x68, 0x6f, 0x70, 0x73, 0x12, 0x15, 0x2e, 0x46, 0x61, 0x76, 0x6f, 0x72, 0x69, 0x74, 0x65, + 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1b, 0x2e, 0x50, + 0x61, 0x67, 0x69, 0x6e, 0x67, 0x53, 0x68, 0x6f, 0x70, 0x46, 0x61, 0x76, 0x6f, 0x72, 0x69, 0x74, + 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x51, 0x0a, 0x18, 0x51, + 0x75, 0x65, 0x72, 0x79, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x46, 0x61, 0x76, 0x6f, 0x72, 0x69, + 0x74, 0x65, 0x47, 0x6f, 0x6f, 0x64, 0x73, 0x12, 0x15, 0x2e, 0x46, 0x61, 0x76, 0x6f, 0x72, 0x69, + 0x74, 0x65, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1c, + 0x2e, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x47, 0x6f, 0x6f, 0x64, 0x73, 0x46, 0x61, 0x76, 0x6f, + 0x72, 0x69, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x55, + 0x0a, 0x16, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x41, 0x63, + 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x4c, 0x6f, 0x67, 0x12, 0x18, 0x2e, 0x50, 0x61, 0x67, 0x69, 0x6e, + 0x67, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x4c, 0x6f, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x1f, 0x2e, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x41, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x4c, 0x6f, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x4b, 0x0a, 0x14, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x4f, + 0x6e, 0x53, 0x68, 0x65, 0x6c, 0x76, 0x65, 0x73, 0x47, 0x6f, 0x6f, 0x64, 0x73, 0x12, 0x17, 0x2e, + 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x53, 0x68, 0x6f, 0x70, 0x47, 0x6f, 0x6f, 0x64, 0x73, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x18, 0x2e, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x53, + 0x68, 0x6f, 0x70, 0x47, 0x6f, 0x6f, 0x64, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x00, 0x12, 0x58, 0x0a, 0x15, 0x51, 0x75, 0x65, 0x72, 0x79, 0x49, 0x74, 0x65, 0x6d, 0x53, + 0x61, 0x6c, 0x65, 0x73, 0x48, 0x69, 0x73, 0x74, 0x6f, 0x72, 0x79, 0x12, 0x1d, 0x2e, 0x51, 0x75, + 0x65, 0x72, 0x79, 0x49, 0x74, 0x65, 0x6d, 0x53, 0x61, 0x6c, 0x65, 0x73, 0x48, 0x69, 0x73, 0x74, + 0x6f, 0x72, 0x79, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x2e, 0x51, 0x75, 0x65, + 0x72, 0x79, 0x49, 0x74, 0x65, 0x6d, 0x53, 0x61, 0x6c, 0x65, 0x73, 0x48, 0x69, 0x73, 0x74, 0x6f, + 0x72, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x37, 0x0a, 0x0a, + 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x12, 0x2e, 0x53, 0x65, 0x61, + 0x72, 0x63, 0x68, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x13, + 0x2e, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x49, 0x74, 0x65, 0x6d, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, 0x1f, 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, 0x67, 0x69, 0x74, + 0x68, 0x75, 0x62, 0x2e, 0x67, 0x6f, 0x32, 0x6f, 0x2e, 0x72, 0x70, 0x63, 0x5a, 0x08, 0x2e, 0x2f, + 0x3b, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -2403,8 +2425,9 @@ var file_query_service_proto_goTypes = []interface{}{ (*SSearchItemResult)(nil), // 27: SSearchItemResult (*SPagingParams)(nil), // 28: SPagingParams (*SOrderItem)(nil), // 29: SOrderItem - (*SGoods)(nil), // 30: SGoods - (*MemberAccountPagingLogResponse)(nil), // 31: MemberAccountPagingLogResponse + (EItemSalesType)(0), // 30: EItemSalesType + (*SGoods)(nil), // 31: SGoods + (*MemberAccountPagingLogResponse)(nil), // 32: MemberAccountPagingLogResponse } var file_query_service_proto_depIdxs = []int32{ 2, // 0: PagingShopFavoriteResponse.data:type_name -> SPagingShopFavorite @@ -2416,43 +2439,44 @@ var file_query_service_proto_depIdxs = []int32{ 29, // 6: SMemberPagingOrder.items:type_name -> SOrderItem 14, // 7: MemberListResponse.value:type_name -> MemberListSingle 28, // 8: PagingAccountLogRequest.params:type_name -> SPagingParams - 28, // 9: PagingShopGoodsRequest.params:type_name -> SPagingParams - 30, // 10: PagingShopGoodsResponse.data:type_name -> SGoods - 23, // 11: QueryItemSalesHistoryResponse.value:type_name -> SItemSalesHistory - 27, // 12: SearchItemResponse.value:type_name -> SSearchItemResult - 15, // 13: QueryService.SummaryStatistics:input_type -> SummaryStatisticsRequest - 17, // 14: QueryService.MemberStatistics:input_type -> MemberStatisticsRequest - 5, // 15: QueryService.PagingShops:input_type -> QueryPagingShopRequest - 8, // 16: QueryService.MemberNormalOrders:input_type -> MemberOrderPagingRequest - 8, // 17: QueryService.QueryWholesaleOrders:input_type -> MemberOrderPagingRequest - 8, // 18: QueryService.QueryTradeOrders:input_type -> MemberOrderPagingRequest - 11, // 19: QueryService.QueryMemberList:input_type -> MemberListRequest - 12, // 20: QueryService.SearchMembers:input_type -> MemberSearchRequest - 0, // 21: QueryService.QueryMemberFavoriteShops:input_type -> FavoriteQueryRequest - 0, // 22: QueryService.QueryMemberFavoriteGoods:input_type -> FavoriteQueryRequest - 19, // 23: QueryService.PagingMemberAccountLog:input_type -> PagingAccountLogRequest - 20, // 24: QueryService.PagingOnShelvesGoods:input_type -> PagingShopGoodsRequest - 22, // 25: QueryService.QueryItemSalesHistory:input_type -> QueryItemSalesHistoryRequest - 25, // 26: QueryService.SearchItem:input_type -> SearchItemRequest - 16, // 27: QueryService.SummaryStatistics:output_type -> SummaryStatisticsResponse - 18, // 28: QueryService.MemberStatistics:output_type -> MemberStatisticsResponse - 6, // 29: QueryService.PagingShops:output_type -> QueryPagingShopsResponse - 9, // 30: QueryService.MemberNormalOrders:output_type -> MemberOrderPagingResponse - 9, // 31: QueryService.QueryWholesaleOrders:output_type -> MemberOrderPagingResponse - 9, // 32: QueryService.QueryTradeOrders:output_type -> MemberOrderPagingResponse - 13, // 33: QueryService.QueryMemberList:output_type -> MemberListResponse - 13, // 34: QueryService.SearchMembers:output_type -> MemberListResponse - 1, // 35: QueryService.QueryMemberFavoriteShops:output_type -> PagingShopFavoriteResponse - 3, // 36: QueryService.QueryMemberFavoriteGoods:output_type -> PagingGoodsFavoriteResponse - 31, // 37: QueryService.PagingMemberAccountLog:output_type -> MemberAccountPagingLogResponse - 21, // 38: QueryService.PagingOnShelvesGoods:output_type -> PagingShopGoodsResponse - 24, // 39: QueryService.QueryItemSalesHistory:output_type -> QueryItemSalesHistoryResponse - 26, // 40: QueryService.SearchItem:output_type -> SearchItemResponse - 27, // [27:41] is the sub-list for method output_type - 13, // [13:27] is the sub-list for method input_type - 13, // [13:13] is the sub-list for extension type_name - 13, // [13:13] is the sub-list for extension extendee - 0, // [0:13] is the sub-list for field type_name + 30, // 9: PagingShopGoodsRequest.itemType:type_name -> EItemSalesType + 28, // 10: PagingShopGoodsRequest.params:type_name -> SPagingParams + 31, // 11: PagingShopGoodsResponse.data:type_name -> SGoods + 23, // 12: QueryItemSalesHistoryResponse.value:type_name -> SItemSalesHistory + 27, // 13: SearchItemResponse.value:type_name -> SSearchItemResult + 15, // 14: QueryService.SummaryStatistics:input_type -> SummaryStatisticsRequest + 17, // 15: QueryService.MemberStatistics:input_type -> MemberStatisticsRequest + 5, // 16: QueryService.PagingShops:input_type -> QueryPagingShopRequest + 8, // 17: QueryService.MemberNormalOrders:input_type -> MemberOrderPagingRequest + 8, // 18: QueryService.QueryWholesaleOrders:input_type -> MemberOrderPagingRequest + 8, // 19: QueryService.QueryTradeOrders:input_type -> MemberOrderPagingRequest + 11, // 20: QueryService.QueryMemberList:input_type -> MemberListRequest + 12, // 21: QueryService.SearchMembers:input_type -> MemberSearchRequest + 0, // 22: QueryService.QueryMemberFavoriteShops:input_type -> FavoriteQueryRequest + 0, // 23: QueryService.QueryMemberFavoriteGoods:input_type -> FavoriteQueryRequest + 19, // 24: QueryService.PagingMemberAccountLog:input_type -> PagingAccountLogRequest + 20, // 25: QueryService.PagingOnShelvesGoods:input_type -> PagingShopGoodsRequest + 22, // 26: QueryService.QueryItemSalesHistory:input_type -> QueryItemSalesHistoryRequest + 25, // 27: QueryService.SearchItem:input_type -> SearchItemRequest + 16, // 28: QueryService.SummaryStatistics:output_type -> SummaryStatisticsResponse + 18, // 29: QueryService.MemberStatistics:output_type -> MemberStatisticsResponse + 6, // 30: QueryService.PagingShops:output_type -> QueryPagingShopsResponse + 9, // 31: QueryService.MemberNormalOrders:output_type -> MemberOrderPagingResponse + 9, // 32: QueryService.QueryWholesaleOrders:output_type -> MemberOrderPagingResponse + 9, // 33: QueryService.QueryTradeOrders:output_type -> MemberOrderPagingResponse + 13, // 34: QueryService.QueryMemberList:output_type -> MemberListResponse + 13, // 35: QueryService.SearchMembers:output_type -> MemberListResponse + 1, // 36: QueryService.QueryMemberFavoriteShops:output_type -> PagingShopFavoriteResponse + 3, // 37: QueryService.QueryMemberFavoriteGoods:output_type -> PagingGoodsFavoriteResponse + 32, // 38: QueryService.PagingMemberAccountLog:output_type -> MemberAccountPagingLogResponse + 21, // 39: QueryService.PagingOnShelvesGoods:output_type -> PagingShopGoodsResponse + 24, // 40: QueryService.QueryItemSalesHistory:output_type -> QueryItemSalesHistoryResponse + 26, // 41: QueryService.SearchItem:output_type -> SearchItemResponse + 28, // [28:42] is the sub-list for method output_type + 14, // [14:28] is the sub-list for method input_type + 14, // [14:14] is the sub-list for extension type_name + 14, // [14:14] is the sub-list for extension extendee + 0, // [0:14] is the sub-list for field type_name } func init() { file_query_service_proto_init() } diff --git a/tests/service/query_service_test.go b/tests/service/query_service_test.go index a11979071..b17a6f1d5 100644 --- a/tests/service/query_service_test.go +++ b/tests/service/query_service_test.go @@ -105,9 +105,11 @@ func TestMemberStatifics(t *testing.T) { func TestQuerySearchItem(t *testing.T) { list, err := impl.QueryService.SearchItem(context.TODO(), &proto.SearchItemRequest{ - ShopId: 0, - Keyword: "1", - Size: 10, + ShopId: 0, + Keyword: "1", + CategoryId: 0, + Begin: 0, + Size: 10, }) if err != nil { From 7ebc9c38585766878e2c62a3e241bf59d87054ea Mon Sep 17 00:00:00 2001 From: jarrysix Date: Fri, 17 Mar 2023 11:40:04 +0800 Subject: [PATCH 27/33] fix: item query --- core/query/item_query.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/query/item_query.go b/core/query/item_query.go index 9558559ad..60caa331f 100755 --- a/core/query/item_query.go +++ b/core/query/item_query.go @@ -170,8 +170,8 @@ func (i ItemQuery) GetPagingOnShelvesGoods(shopId int64, where += fmt.Sprintf(" AND item_snapshot.cat_id IN (%s)", format.IntArrStrJoin(catIds)) } - if len(keyword) > 0{ - where += "item_snapshot.title LIKE '%" + keyword + "%'" + if len(keyword) > 0 { + where += " AND item_snapshot.title LIKE '%" + keyword + "%'" } if flag > 0 { where += fmt.Sprintf(" AND (item_snapshot.item_flag & %d = %d)", flag, flag) From 149fac38a5e70a020856157aa87f150fda7b4903 Mon Sep 17 00:00:00 2001 From: jarrysix Date: Fri, 17 Mar 2023 12:01:00 +0800 Subject: [PATCH 28/33] fix: order item stock tips --- core/domain/cart/normal_cart.go | 7 ++++--- core/domain/cart/wholesale_cart.go | 7 ++++--- core/domain/interface/item/error.go | 2 +- core/domain/interface/item/item.go | 2 +- 4 files changed, 10 insertions(+), 8 deletions(-) diff --git a/core/domain/cart/normal_cart.go b/core/domain/cart/normal_cart.go index 91c02ca72..a64ee469f 100755 --- a/core/domain/cart/normal_cart.go +++ b/core/domain/cart/normal_cart.go @@ -2,6 +2,7 @@ package cart import ( "errors" + "fmt" "time" "github.com/ixre/go2o/core/domain/interface/cart" @@ -120,7 +121,7 @@ func (c *cartImpl) check() error { } } if stock == 0 { - return item.ErrFullOfStock // 已经卖完了 + return fmt.Errorf(item.ErrFullOfStock.Error(), it.GetValue().Title) // 已经卖完了 } if stock < v.Quantity { return item.ErrOutOfStock // 超出库存 @@ -247,7 +248,7 @@ func (c *cartImpl) put(itemId, skuId int64, num int32, reset bool, checkOnly boo // 判断是否上架 if iv.ShelveState != item.ShelvesOn { - return nil, item.ErrNotOnShelves //未上架 + return nil, fmt.Errorf(item.ErrNotOnShelves.Error(), iv.Title) //未上架 } // 判断商品SkuId if skuId > 0 { @@ -261,7 +262,7 @@ func (c *cartImpl) put(itemId, skuId int64, num int32, reset bool, checkOnly boo } // 检查是否已经卖完了 if stock == 0 { - return nil, item.ErrFullOfStock + return nil, fmt.Errorf(item.ErrFullOfStock.Error(), it.GetValue().Title) // 已经卖完了 } // 添加数量 diff --git a/core/domain/cart/wholesale_cart.go b/core/domain/cart/wholesale_cart.go index 785565c1c..7f7131606 100755 --- a/core/domain/cart/wholesale_cart.go +++ b/core/domain/cart/wholesale_cart.go @@ -3,6 +3,7 @@ package cart import ( "encoding/json" "errors" + "fmt" "strconv" "time" @@ -129,7 +130,7 @@ func (c *wholesaleCartImpl) check() error { } } if stock == 0 { - return item.ErrFullOfStock // 已经卖完了 + return fmt.Errorf(item.ErrFullOfStock.Error(), it.GetValue().Title) // 已经卖完了 } if stock < v.Quantity { return item.ErrOutOfStock // 超出库存 @@ -268,7 +269,7 @@ func (c *wholesaleCartImpl) put(itemId, skuId int64, quantity int32, reset bool, stock := iv.StockNum // 判断是否上架 if iv.ShelveState != item.ShelvesOn { - return nil, item.ErrNotOnShelves //未上架 + return nil, fmt.Errorf(item.ErrNotOnShelves.Error(), iv.Title) //未上架 } // 验证批发权限 wsIt := it.Wholesale() @@ -290,7 +291,7 @@ func (c *wholesaleCartImpl) put(itemId, skuId int64, quantity int32, reset bool, } // 检查是否已经卖完了 if stock == 0 { - return nil, item.ErrFullOfStock + return nil, fmt.Errorf(item.ErrFullOfStock.Error(), it.GetValue().Title) // 已经卖完了 } // 添加数量 for _, v := range c.value.Items { diff --git a/core/domain/interface/item/error.go b/core/domain/interface/item/error.go index 9e042e785..c79115b33 100755 --- a/core/domain/interface/item/error.go +++ b/core/domain/interface/item/error.go @@ -33,7 +33,7 @@ var ( "err_out_of_stock", "库存不足") ErrFullOfStock = domain.NewError( - "err_full_of_stock", "商品已经售完") + "err_full_of_stock", "商品\"%s\"已经售完") ErrInternalDisallow = domain.NewError( "err_sale_tag_internal_disallow", "不允许删除内置销售标签!") diff --git a/core/domain/interface/item/item.go b/core/domain/interface/item/item.go index 3e7cfcdb2..48ea4fa0e 100755 --- a/core/domain/interface/item/item.go +++ b/core/domain/interface/item/item.go @@ -75,7 +75,7 @@ var ( "no_such_snapshot", "商品快照不存在") ErrNotOnShelves = domain.NewError( - "not_on_shelves", "商品已下架") + "not_on_shelves", "商品\"%s\"已下架") ErrGoodsMinProfitRate = domain.NewError( "err_goods_min_profit_rate", "商品利润率不能低于%s") From d8af6b822f2b621f720c461b394cd5594b7c4ac1 Mon Sep 17 00:00:00 2001 From: jarrysix Date: Fri, 17 Mar 2023 14:02:17 +0800 Subject: [PATCH 29/33] fix:cart remove offline items --- core/domain/cart/normal_cart.go | 39 +++++++++++++++++++-------------- tests/domain/cart_test.go | 9 ++++++++ 2 files changed, 32 insertions(+), 16 deletions(-) diff --git a/core/domain/cart/normal_cart.go b/core/domain/cart/normal_cart.go index a64ee469f..e0257d8d7 100755 --- a/core/domain/cart/normal_cart.go +++ b/core/domain/cart/normal_cart.go @@ -8,7 +8,6 @@ import ( "github.com/ixre/go2o/core/domain/interface/cart" "github.com/ixre/go2o/core/domain/interface/item" "github.com/ixre/go2o/core/domain/interface/member" - "github.com/ixre/go2o/core/domain/interface/merchant/shop" "github.com/ixre/go2o/core/infrastructure/domain" "github.com/ixre/go2o/core/infrastructure/log" ) @@ -21,10 +20,10 @@ type cartImpl struct { rep cart.ICartRepo goodsRepo item.IItemRepo memberRepo member.IMemberRepo - summary string - shop shop.IShop - deliver member.IDeliverAddress - snapMap map[int64]*item.Snapshot + //summary string + //shop shop.IShop + //deliver member.IDeliverAddress + snapMap map[int64]*item.Snapshot } func NewNormalCart(val *cart.NormalCart, rep cart.ICartRepo, @@ -71,6 +70,13 @@ func (c *cartImpl) init() cart.ICart { // 初始化购物车的信息 if c.value != nil && c.value.Items != nil { c.setAttachGoodsInfo(c.value.Items) + arr := c.value.Items + c.value.Items = make([]*cart.NormalCartItem, 0) + for _, v := range arr { + if v.Sku != nil { + c.value.Items = append(c.value.Items, v) + } + } } return c } @@ -184,20 +190,21 @@ func (c *cartImpl) setAttachGoodsInfo(items []*cart.NormalCartItem) { if v.SkuId > 0 { sku = it.GetSku(v.SkuId) } else { + in := list[v.ItemId] iv := it.GetValue() sku = &item.Sku{ - ProductId: iv.ProductId, - ItemId: iv.Id, - Title: iv.Title, - Image: iv.Image, + ProductId: in.ProductId, + ItemId: v.ItemId, + Title: in.Title, + Image: in.Image, SpecData: "", SpecWord: "", - Code: iv.Code, - OriginPrice: iv.OriginPrice, - Price: iv.Price, - Cost: iv.Cost, - Weight: iv.Weight, - Bulk: iv.Bulk, + Code: in.Code, + OriginPrice: in.OriginPrice, + Price: in.Price, + Cost: in.Cost, + Weight: in.Weight, + Bulk: in.Bulk, Stock: iv.StockNum, SaleNum: iv.SaleNum, } @@ -421,7 +428,7 @@ func (c *cartImpl) CheckedItems(checked map[int64][]int64) []*cart.ItemPair { if checked != nil { for _, v := range c.value.Items { arr, ok := checked[int64(v.ItemId)] - if !ok { + if ok { continue } for _, skuId := range arr { diff --git a/tests/domain/cart_test.go b/tests/domain/cart_test.go index 9855f0aee..de2344d49 100755 --- a/tests/domain/cart_test.go +++ b/tests/domain/cart_test.go @@ -11,6 +11,15 @@ import ( "github.com/ixre/gof/types/typeconv" ) +func TestGetNormalCartItems(t *testing.T) { + var cartId = 596 + repo := ti.Factory.GetCartRepo() + c := repo.GetNormalCart(int32(cartId)).(cart.INormalCart) + for _, v := range c.Items() { + t.Log(v.Id, v.ItemId, v.Sku == nil) + } +} + // 测试普通购物车 func TestNormalCart(t *testing.T) { repo := ti.Factory.GetCartRepo() From c00d4d558938fe4c8f11edf0f9b82a5419fd07b0 Mon Sep 17 00:00:00 2001 From: jarrysix Date: Fri, 17 Mar 2023 15:48:50 +0800 Subject: [PATCH 30/33] fix:member quantity --- core/query/member_query.go | 7 +++++-- tests/service/query_service_test.go | 4 ++-- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/core/query/member_query.go b/core/query/member_query.go index 601eb4b30..17e406c2a 100755 --- a/core/query/member_query.go +++ b/core/query/member_query.go @@ -394,10 +394,10 @@ func (m *MemberQuery) InviteMembersQuantity(memberId int64, where string) int { // 获取订单状态及其数量 func (m *MemberQuery) OrdersQuantity(memberId int64) map[int]int { mp := make(map[int]int, 0) - m.Connector.Query(` + err := m.Connector.Query(` SELECT o.status,COUNT(0) as n FROM sale_sub_order o GROUP BY o.status,o.buyer_id,is_forbidden,break_status - having is_forbidden = 0 AND break_status <> 0cd + having is_forbidden = 0 AND break_status <> 0 AND o.buyer_id = $1`, func(rows *sql.Rows) { s, n := 0, 0 for rows.Next() { @@ -405,5 +405,8 @@ func (m *MemberQuery) OrdersQuantity(memberId int64) map[int]int { mp[s] = n } }, memberId) + if err != nil { + log.Println("[ GO2O][ ERROR]: query order quantity failed! ", err.Error()) + } return mp } diff --git a/tests/service/query_service_test.go b/tests/service/query_service_test.go index b17a6f1d5..46de98ac9 100644 --- a/tests/service/query_service_test.go +++ b/tests/service/query_service_test.go @@ -107,8 +107,8 @@ func TestQuerySearchItem(t *testing.T) { list, err := impl.QueryService.SearchItem(context.TODO(), &proto.SearchItemRequest{ ShopId: 0, Keyword: "1", - CategoryId: 0, - Begin: 0, + //CategoryId: 0, + //Begin: 0, Size: 10, }) From 0ea52e7051d672134dc9d6e5ed5b240a99c8fdcb Mon Sep 17 00:00:00 2001 From: jarrysix Date: Fri, 17 Mar 2023 15:53:38 +0800 Subject: [PATCH 31/33] fix:member quantity --- core/domain/cart/normal_cart.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/core/domain/cart/normal_cart.go b/core/domain/cart/normal_cart.go index e0257d8d7..cb47f3656 100755 --- a/core/domain/cart/normal_cart.go +++ b/core/domain/cart/normal_cart.go @@ -183,6 +183,10 @@ func (c *cartImpl) setAttachGoodsInfo(items []*cart.NormalCartItem) { } var sku *item.Sku for _, v := range items { + in := list[v.ItemId] + if in == nil { + continue + } it := c.goodsRepo.GetItem(v.ItemId) if it == nil { continue @@ -190,7 +194,6 @@ func (c *cartImpl) setAttachGoodsInfo(items []*cart.NormalCartItem) { if v.SkuId > 0 { sku = it.GetSku(v.SkuId) } else { - in := list[v.ItemId] iv := it.GetValue() sku = &item.Sku{ ProductId: in.ProductId, From 83cf9edaac452add81c4e11218160aac2f4b2712 Mon Sep 17 00:00:00 2001 From: jarrysix Date: Fri, 17 Mar 2023 16:46:33 +0800 Subject: [PATCH 32/33] Update README.md --- core/domain/interface/order/README.md | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/core/domain/interface/order/README.md b/core/domain/interface/order/README.md index ff17f5fa0..5a4b462d3 100755 --- a/core/domain/interface/order/README.md +++ b/core/domain/interface/order/README.md @@ -73,7 +73,6 @@ 为什么要做这么复杂?我们希望送到用户手中的每一个包裹在系统中都有详细的数据记录,而不会因为有些数据空白而产生纠纷。 -作者:涛涛记得笑 -链接:https://www.jianshu.com/p/8c30b7503f48 -来源:简书 -著作权归作者所有。商业转载请联系作者获得授权,非商业转载请注明出处。 \ No newline at end of file + +## 支付订单 +https://www.woshipm.com/pd/2972697.html From 86c44dc5b2a090b3a448b6566d67e0d0ae16734d Mon Sep 17 00:00:00 2001 From: jarrysix Date: Fri, 17 Mar 2023 18:38:02 +0800 Subject: [PATCH 33/33] Update README.md --- core/domain/interface/order/README.md | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/core/domain/interface/order/README.md b/core/domain/interface/order/README.md index 5a4b462d3..e9ddebb87 100755 --- a/core/domain/interface/order/README.md +++ b/core/domain/interface/order/README.md @@ -76,3 +76,16 @@ ## 支付订单 https://www.woshipm.com/pd/2972697.html + + +用户把订单提交后此时后台会有两步操作: + +1)拆单 + +多商家情况下,提交订单就进行拆单,拆后流转至对应的商家后台,用户也会看到多个子订单;其他还可以按发货仓库等维度拆; + +2)生成账单 + +生成账单的目的是为了记录该笔母订单的金额,如商品金额、抵扣总金额、各商品分别抵扣金额、用户需支付金额等,用户将要支付的是母订单的账单,当该笔账单已完成,则各子订单状态跳转为待发货; + +注意,如果用户在支付页面退出,此时账单也会随着商家拆分成各子账单,因为用户可以在订单列表里分别对拆分后的子订单进行支付