From 77a16f04c0f314d6e0fa9a344997f5f78c1be0e3 Mon Sep 17 00:00:00 2001 From: sian Date: Thu, 6 Apr 2023 13:20:47 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=89=B9=E5=8F=91=E5=95=86?= =?UTF-8?q?=E5=93=81=E6=90=9C=E7=B4=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- wholesale/channel/sku.go | 73 ++++++++++++++++++++++------------------ 1 file changed, 41 insertions(+), 32 deletions(-) diff --git a/wholesale/channel/sku.go b/wholesale/channel/sku.go index 6f92044..10d7d0b 100644 --- a/wholesale/channel/sku.go +++ b/wholesale/channel/sku.go @@ -27,40 +27,44 @@ type ArgsSkuList struct { Search SkuSearch Page bean.Page } +type SkuItemHighlight struct { + Name string `json:"name"` +} type SkuItem struct { - Id uint `json:"id"` - Name string `json:"name"` - BrandId uint `json:"brandId"` - BrandName string `json:"brandName"` - FirstCategoryId uint `json:"firstCategoryId"` - FirstCategoryName string `json:"firstCategoryName"` - SecondCategoryId uint `json:"secondCategoryId"` - SecondCategoryName string `json:"secondCategoryName"` - ThirdCategoryId uint `json:"thirdCategoryId"` - ThirdCategoryName string `json:"thirdCategoryName"` - Price decimal.Decimal `json:"price"` - Discount decimal.Decimal `json:"discount"` - GuidePrice decimal.Decimal `json:"guidePrice"` - ImgUrl string `json:"imgUrl"` - Profit decimal.Decimal `json:"profit"` - Size string `json:"size"` - Color string `json:"color"` - Tax string `json:"tax"` - Unit string `json:"unit"` - UpcCode string `json:"upcCode"` - TaxName string `json:"taxName"` - TaxCode string `json:"taxCode"` - Status uint `json:"status"` - Length decimal.Decimal `json:"length"` // 长 - Width decimal.Decimal `json:"width"` // 宽 - Height decimal.Decimal `json:"height"` // 高 - Weight decimal.Decimal `json:"weight"` // 重 - PackingRate uint `json:"packingRate"` // 装箱率 - StartingBatch uint `json:"startingBatch"` // 起批量 - InitialFreight decimal.Decimal `json:"initialFreight"` // 起批运费 - CreatedAt int64 `json:"createdAt"` - UpdatedAt int64 `json:"updatedAt"` + Id uint `json:"id"` + Name string `json:"name"` + BrandId uint `json:"brandId"` + BrandName string `json:"brandName"` + FirstCategoryId uint `json:"firstCategoryId"` + FirstCategoryName string `json:"firstCategoryName"` + SecondCategoryId uint `json:"secondCategoryId"` + SecondCategoryName string `json:"secondCategoryName"` + ThirdCategoryId uint `json:"thirdCategoryId"` + ThirdCategoryName string `json:"thirdCategoryName"` + Price decimal.Decimal `json:"price"` + Discount decimal.Decimal `json:"discount"` + GuidePrice decimal.Decimal `json:"guidePrice"` + ImgUrl string `json:"imgUrl"` + Profit decimal.Decimal `json:"profit"` + Size string `json:"size"` + Color string `json:"color"` + Tax string `json:"tax"` + Unit string `json:"unit"` + UpcCode string `json:"upcCode"` + TaxName string `json:"taxName"` + TaxCode string `json:"taxCode"` + Status uint `json:"status"` + Length decimal.Decimal `json:"length"` // 长 + Width decimal.Decimal `json:"width"` // 宽 + Height decimal.Decimal `json:"height"` // 高 + Weight decimal.Decimal `json:"weight"` // 重 + PackingRate uint `json:"packingRate"` // 装箱率 + StartingBatch uint `json:"startingBatch"` // 起批量 + InitialFreight decimal.Decimal `json:"initialFreight"` // 起批运费 + CreatedAt int64 `json:"createdAt"` + UpdatedAt int64 `json:"updatedAt"` + Highlight SkuItemHighlight `json:"highlight"` } type ReplySkuList struct { @@ -112,8 +116,13 @@ type CustomerSearch struct { BrandName string } +type SkuEsConfig struct { + Highlight bool +} + type ArgsSkuListsEs struct { Search SkuEsSearch + Config SkuEsConfig Page bean.Page }