Skip to content

Commit

Permalink
Merge pull request #6 from tarmo-randma/master
Browse files Browse the repository at this point in the history
Added fild 'Added' and 'LastModified' to products.Product
  • Loading branch information
Dysar authored May 8, 2020
2 parents a1ce193 + 97f67ee commit be2ce42
Showing 1 changed file with 20 additions and 17 deletions.
37 changes: 20 additions & 17 deletions pkg/api/products/models.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,34 +44,37 @@ type (
//Product ...
Product struct {
ProductID int `json:"productID"`
ParentProductID int `json:"parentProductID"`
Type string `json:"type"`
Name string `json:"name"`
NameEng string `json:"nameENG"`
Description string `json:"description"`
DescriptionEng string `json:"descriptionENG"`
DescriptionLong string `json:"longdesc"`
DescriptionLongEng string `json:"longdescENG"`
Status string `json:"status"`
Code string `json:"code"`
Code2 string `json:"code2"`
Code3 *string `json:"code3"`
GroupID uint `json:"groupID"`
Price float64 `json:"price"`
PriceWithVat float32 `json:"priceWithVat"`
UnitName *string `json:"unitName"`
Images []ProductImage `json:"images"`
DisplayedInWebshop byte `json:"displayedInWebshop"`
CategoryId uint `json:"categoryID"`
CategoryName string `json:"categoryName"`
BrandID uint `json:"brandID"`
Description string `json:"description"`
DescriptionLong string `json:"longdesc"`
DescriptionEng string `json:"descriptionENG"`
DescriptionLongEng string `json:"longdescENG"`
Added uint64 `json:"added"`
LastModified uint64 `json:"lastModified"`
Vatrate float64 `json:"vatrate"`
PriceWithVat float32 `json:"priceWithVat"`
UnitName *string `json:"unitName"`
BrandName string `json:"brandName"`
GroupID uint `json:"groupID"`
GroupName string `json:"groupName"`
Warehouses map[uint]StockInfo `json:"warehouses"`
RelatedProducts []string `json:"relatedProducts"`
Vatrate float64 `json:"vatrate"`
CategoryId uint `json:"categoryID"`
CategoryName string `json:"categoryName"`
Status string `json:"status"`
Images []ProductImage `json:"images"`
ProductVariations []string `json:"productVariations"` // Variations of matrix product
VariationList []ProductVariaton `json:"variationList"`
ParentProductID int `json:"parentProductID"`
Type string `json:"type"`
Warehouses map[uint]StockInfo `json:"warehouses"`

RelatedProducts []string `json:"relatedProducts"`
VariationList []ProductVariaton `json:"variationList"`
}

StockInfo struct {
Expand Down

0 comments on commit be2ce42

Please sign in to comment.