This commit is contained in:
parent
7abecbd672
commit
92a0b6679c
|
|
@ -1497,24 +1497,21 @@ public class BomNewEbomParentService extends ServiceImpl<BomNewEbomParentMapper,
|
|||
|
||||
if (CollectionUtil.isNotEmpty(eBomDel.getDelEBom())) {
|
||||
//取bom信息删除
|
||||
this.getBaseMapper().delBatch(eBomDel.getDelEBom().stream()
|
||||
.map(BomNewEbomParentVO::getRowId)
|
||||
.collect(Collectors.toList()));
|
||||
List<Long> parentList= eBomDel.getDelEBom().stream().filter(u -> (ObjectUtil.isNotNull(u.getBomRowId()) && u.getBomRowId() > 0))
|
||||
.map(BomNewEbomParentVO::getBomRowId).collect(Collectors.toList());
|
||||
List<Long> childList= eBomDel.getDelEBom().stream().filter(u -> (ObjectUtil.isNull(u.getBomRowId()) || u.getBomRowId().longValue()==0l))
|
||||
.map(BomNewEbomParentVO::getRowId).collect(Collectors.toList());
|
||||
|
||||
this.getBaseMapper().delBatch(parentList);
|
||||
|
||||
// List<Long> parentList= eBomDel.getDelEBom().stream().filter(u -> (ObjectUtil.isNotNull(u.getBomRowId()) && u.getBomRowId() > 0))
|
||||
// .map(BomNewEbomParentVO::getBomRowId).collect(Collectors.toList());
|
||||
// List<Long> childList= eBomDel.getDelEBom().stream().filter(u -> (ObjectUtil.isNull(u.getBomRowId()) || u.getBomRowId().longValue()==0l))
|
||||
// .map(BomNewEbomParentVO::getRowId).collect(Collectors.toList());
|
||||
//
|
||||
//
|
||||
// QueryWrapper<BomNewEbomParentEntity> parentWrapper=new QueryWrapper<>();
|
||||
// parentWrapper.lambda().in(BomNewEbomParentEntity::getRowId,parentList);
|
||||
//
|
||||
// QueryWrapper<BomNewEbomChildEntity> childWrapper=new QueryWrapper<>();
|
||||
// childWrapper.lambda().in(BomNewEbomChildEntity::getRowId,childList);
|
||||
QueryWrapper<BomNewEbomChildEntity> childWrapper=new QueryWrapper<>();
|
||||
childWrapper.lambda().in(BomNewEbomChildEntity::getRowId,childList);
|
||||
//
|
||||
// this.remove(parentWrapper);
|
||||
// SpringUtil.getBean(BomNewEbomChildService.class).remove(childWrapper);
|
||||
SpringUtil.getBean(BomNewEbomChildService.class).remove(childWrapper);
|
||||
}else{
|
||||
VUtils.isTure(true).throwMessage("未找到你删除的数据");
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue