diff --git a/cash-service/product-service/src/main/resources/mapper/ProductMapper.xml b/cash-service/product-service/src/main/resources/mapper/ProductMapper.xml index 9ae2bcc91..1bb8409c0 100644 --- a/cash-service/product-service/src/main/resources/mapper/ProductMapper.xml +++ b/cash-service/product-service/src/main/resources/mapper/ProductMapper.xml @@ -166,7 +166,7 @@ select ROUND( ST_Distance_Sphere(POINT(b.lng, b.lat), POINT(#{lng}, #{lat})) / 1000, 2) AS distance, c.name, a.origin_price, a.sale_price, b.shop_name, b.districts, c.cover_img, b.logo, c.id, - a.real_sales_number saleNum, round(a.sale_price / a.origin_price, 2) * 10 discount, + a.real_sales_number saleNum, (round(a.sale_price / a.origin_price, 2) * 10) AS discount, c.id productId, a.id skuId, b.id shopId from tb_prod_sku as a left join tb_product c on c.id=a.product_id