修改类目中的设置的时候显示全部的类目
This commit is contained in:
parent
f68eb53363
commit
5b8fe3cd58
|
|
@ -106,4 +106,6 @@ public class DeptGoodsCategory extends GoodsCategory {
|
|||
private String shopInsuranceIds;
|
||||
|
||||
private Long customerId;
|
||||
|
||||
private Integer isSetting;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -105,12 +105,16 @@ public class DeptGoodsCategoryServiceImpl implements DeptGoodsCategoryService {
|
|||
List<DeptGoodsCategory> goodsCategoryList =new ArrayList<>();
|
||||
log.info("用户id{}获取到的类目列表{}",customerId,customerSelections);
|
||||
// 第一层
|
||||
if (deptGoodsCategory.getIsSetting()==1){
|
||||
goodsCategoryList = deptGoodsCategoryMapper.appList(deptGoodsCategory);
|
||||
}else{
|
||||
for (CustomerSelection customerSelection1 : customerSelections) {
|
||||
DeptGoodsCategory deptGoodsCategory1=deptGoodsCategoryMapper.selectOneByGoodsCategoryId(customerSelection1.getDeptCategoryId());
|
||||
if (customerSelection1.getSelectionType()==1&& Objects.equals(deptGoodsCategory.getType(), deptGoodsCategory1.getType())){
|
||||
goodsCategoryList.add(deptGoodsCategory1);
|
||||
}
|
||||
}
|
||||
}
|
||||
log.info("筛选完的类目列表{}",goodsCategoryList);
|
||||
// 第二层
|
||||
this.fillChild(goodsCategoryList);
|
||||
|
|
|
|||
Loading…
Reference in New Issue