51 lines
1.3 KiB
Go
51 lines
1.3 KiB
Go
package coach_client
|
|
|
|
type PageDataResponse struct {
|
|
Total int `json:"total"`
|
|
Page int `json:"page"`
|
|
TotalPages int `json:"totalPages"`
|
|
PageSize int `json:"pageSize"`
|
|
Products []Product `json:"products"`
|
|
}
|
|
type Product struct {
|
|
Name string `json:"name"`
|
|
Colors []Color `json:"colors"`
|
|
VariantsOnSale []Variant `json:"variantsOnSale"`
|
|
}
|
|
|
|
type Color struct {
|
|
Id string `json:"id"` //"id": "IMDQC",
|
|
Text string `json:"text"` //颜色的描述
|
|
Orderable bool `json:"orderable"`
|
|
Media Media `json:"media"`
|
|
Url string `json:"url"` //"/products/eliza-flap-crossbody-bag-in-signature-canvas/CP009-IMDQC.html",
|
|
VgId string `json:"vgId"` // "vgId": "CP009-IMDQC",
|
|
MasterId string `json:"masterId"` //"masterId": "CP009"
|
|
}
|
|
|
|
type Media struct {
|
|
Thumbnail Thumbnail `json:"thumbnail"`
|
|
}
|
|
|
|
type Thumbnail struct {
|
|
Src string `json:"src"`
|
|
}
|
|
|
|
type Variant struct {
|
|
Id string `json:"id"`
|
|
OnSale bool `json:"onSale"`
|
|
Price Price `json:"price"`
|
|
}
|
|
|
|
type Price struct {
|
|
Sales Sales `json:"sales"`
|
|
MarkdownDiscPercent float32 `json:"markdownDiscPercent"`
|
|
}
|
|
|
|
type Sales struct {
|
|
Value float64 `json:"value"`
|
|
Currency string `json:"currency"`
|
|
Formatted string `json:"formatted"`
|
|
DecimalPrice string `json:"decimalPrice"`
|
|
}
|