查询商品库存 增加分类功能 - 解决 jpa sql 类型不一致问题

This commit is contained in:
GYJ 2024-07-08 14:19:03 +08:00
parent 6629f09f98
commit 2d5ca75942
2 changed files with 2 additions and 2 deletions

View File

@ -10,7 +10,7 @@ public class StockQueryDto {
private String shopId;
private Double num;
private Integer isStock;
private Integer categoryId;
private String categoryId;
public void setName(String name) {
if (StringUtils.isNotBlank(name)) {

View File

@ -71,7 +71,7 @@ public interface TbProductSkuRepository extends JpaRepository<TbProductSku, Inte
"group by pro.id " +
"order by number asc ")
Page<StockV2Vo> searchProStockV2(@Param("shopId") String shopId, @Param("proName") String proName, @Param("isStock")Integer isStock,
@Param("categoryId") Integer categoryId, Pageable pageable);
@Param("categoryId") String categoryId, Pageable pageable);
@Query("SELECT new cn.ysk.cashier.vo.StockV2Vo(" +
"sku.id,pro.id,pro.coverImg,pro.name,unit.name,pro.typeEnum,sku.specSnap,pro.isStock, " +