|
|
|
@ -174,6 +174,7 @@ func QueryGoodsListByDiscountPrice(c *gin.Context) {
|
|
|
|
|
order := fmt.Sprintf("discount_price %s", p.Order)
|
|
|
|
|
dbc.DB.Select("SUM(inventory) AS inventory, "+
|
|
|
|
|
"SUM(sales_volume) AS sales_volume, "+
|
|
|
|
|
"SUM(sales_volume_inc) AS sales_volume_inc, "+
|
|
|
|
|
"MIN(original_price) AS original_price, "+
|
|
|
|
|
"MIN(discount_price) AS discount_price, "+
|
|
|
|
|
"MIN(purchase_price) AS purchase_price, "+
|
|
|
|
@ -200,6 +201,7 @@ func GetGoodsRespByInfoList(goodsList []goods.Information, userID uint) []QueryC
|
|
|
|
|
"MIN(name), "+
|
|
|
|
|
"SUM(inventory) AS inventory, "+
|
|
|
|
|
"SUM(sales_volume) AS sales_volume, "+
|
|
|
|
|
"SUM(sales_volume_inc) AS sales_volume_inc, "+
|
|
|
|
|
"MIN(purchase_price) AS purchase_price,"+
|
|
|
|
|
"MIN(original_price) AS original_price, "+
|
|
|
|
|
"MIN(discount_price) AS discount_price, "+
|
|
|
|
|