Commit d5d4ffe7 authored by shiyu's avatar shiyu

根据标签查询,排除复制转拍卖的商品

parent e345e9f5
......@@ -138,6 +138,11 @@ public class SupplierItemRequestDto extends BaseRequestDto implements Entity {
*/
private Integer type;
/**
* 排除的商品类型
*/
private List<Integer> filterType;
/**
* 商品类型1一口价2竞拍3用户上传
*/
......
......@@ -38,6 +38,7 @@ public class SupplierItemDaoImpl implements SupplierItemDao {
}
JdbcHelper.ifPresent(dto.getTypeList(), criteria::andTypeIn);
JdbcHelper.ifPresent(dto.getType(), criteria::andTypeEqualTo);
JdbcHelper.ifPresent(dto.getFilterType(), criteria::andTypeNotIn);
JdbcHelper.ifPresent(dto.getStatus(), criteria::andStatusEqualTo);
JdbcHelper.ifPresent(dto.getStock(), criteria::andStockGreaterThan);
JdbcHelper.ifPresent(dto.getIsOnSale(), criteria::andIsOnSaleEqualTo);
......
......@@ -194,12 +194,14 @@ public class CollectionItemsRelationServiceImpl implements CollectionItemsRelati
} else if (dto.getCollectionBookId().longValue() == CollectionBookConstants.DefaultBookEnum.SALEING.getId()) {
//换藏中, 表示上架售卖中
supplierItemRequestDto.setCreatorId(targetUserId);
supplierItemRequestDto.setFilterType(Arrays.asList(DistributionEnum.DistributionTypeEnum.AUCTION.getCode()));
supplierItemRequestDto.setIsOnSale(true);
supplierItemRequestDto.setIsDeleted(false);
supplierItemList = supplierItemDao.findList(supplierItemRequestDto);
pageInfo = new PageInfo<>(supplierItemList);
} else if (dto.getCollectionBookId().longValue() == CollectionBookConstants.DefaultBookEnum.FINISHED.getId()) {
//已结缘, 表示卖完了
supplierItemRequestDto.setFilterType(Arrays.asList(DistributionEnum.DistributionTypeEnum.AUCTION.getCode()));
supplierItemRequestDto.setCreatorId(targetUserId);
supplierItemRequestDto.setStock(0);
supplierItemList = supplierItemDao.findSellOutList(supplierItemRequestDto);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment