1.商品查询库存不准确问题
This commit is contained in:
@@ -51,7 +51,7 @@ public interface TbProductSkuMapper {
|
||||
@Update("update tb_product_sku set stock_number=stock_number-#{num} WHERE id=#{id} ")
|
||||
int decrStockUnCheck(String id, int num);
|
||||
|
||||
@Select("select * from tb_product_sku where is_grounding=1 and product_id=#{id}")
|
||||
@Select("select * from tb_product_sku where is_grounding=1 and product_id=#{id} and is_del=0")
|
||||
List<TbProductSku> selectByProductCheckGrounding(@Param("id") Integer id);
|
||||
|
||||
@Select("select * from tb_product_sku where is_grounding=1 and is_del=0 and product_id=#{id}")
|
||||
@@ -62,4 +62,7 @@ public interface TbProductSkuMapper {
|
||||
|
||||
@Update("update tb_product_sku set stock_number=#{stock} where product_id=#{skuId} and shop_id=#{shopId}")
|
||||
int updateStock(@Param("shopId") Integer shopId, @Param("skuId") Integer skuId, @Param("stock") Integer stock);
|
||||
|
||||
@Select("select * from tb_product_sku where product_id=#{id} and is_del=0")
|
||||
List<TbProductSku> selectByProductId(Integer id);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user