1.余料库存管理(未完成)

master
董哲奇 4 weeks ago
parent 08cb3ea60c
commit ed5d9d2985

@ -36,6 +36,9 @@ public class YlController {
ylInfoService.list(Wrappers.<DmYlInfo>lambdaQuery()
.eq(DmYlInfo::get,dto.getDcCh())
.eq(DmYlInfo::get使,dto.getStatus())
.eq(StrUtil.isNotEmpty(dto.getDcPl()),DmYlInfo::get,dto.getDcPl())
.eq(StrUtil.isNotEmpty(dto.getTzbh()),DmYlInfo::get,dto.getTzbh())
.like(dto.isGd()&&dto.getStatus()==2,DmYlInfo::get使,"N8GX")
//查询结果使用最小匹配原则为按规格匹配上料提供匹配顺序
.orderByAsc(DmYlInfo::get,DmYlInfo::get)
)
@ -136,7 +139,7 @@ public class YlController {
List<DmYdjh> list = ydjhService.list(Wrappers.<DmYdjh>lambdaQuery()
.eq(DmYdjh::getDcCh, dto.getDcCh())
.eq(DmYdjh::getDcPl, dto.getDcPl())
.eq(DmYdjh::getYlbs,"Y")
.eq(DmYdjh::getYlbs,"Y").ne(DmYdjh::getKw,"17")//不包含光电,光电单独上料
.and(item->item.isNull(DmYdjh::getYlCh).or().eq(DmYdjh::getYlCh,""))
.eq(StrUtil.isNotEmpty(dto.getTzbh()),DmYdjh::getTzbh,dto.getTzbh())
.orderByDesc(DmYdjh::getWpgg)
@ -164,4 +167,50 @@ public class YlController {
return new ResultBean<>();
}
/**
*
*/
@PostMapping("gdsl")
public ResultBean<?> gdsl(@RequestBody YlSlDto dto){
if (!dto.isAllow()){
throw new ServiceException(99999,"请填写需求船号和批次");
}
if (ObjectUtil.isEmpty(dto.getYlList())){
return new ResultBean<>(new ArrayList<>());
}
List<DmYdjh> list = ydjhService.list(Wrappers.<DmYdjh>lambdaQuery()
.eq(DmYdjh::getDcCh, dto.getDcCh())
.eq(DmYdjh::getDcPl, dto.getDcPl())
.eq(DmYdjh::getYlbs,"Y").eq(DmYdjh::getKw,"17")//光电单独上料
.and(item->item.isNull(DmYdjh::getYlCh).or().eq(DmYdjh::getYlCh,""))
.eq(StrUtil.isNotEmpty(dto.getTzbh()),DmYdjh::getTzbh,dto.getTzbh())
.orderByDesc(DmYdjh::getWpgg)
);
List<DmYlInfo> =new ArrayList<>();
out:
for (DmYdjh ydjh:list){
for(DmYlInfo ylInfo:dto.getYlList()){
if (ylInfo.(ydjh.getJhsyylbh())&&ylInfo.(ydjh)){//暂时不支持,仅保留分支流程
ylInfo.(ydjh);
.add(ylInfo);
continue out;
}
}
for (DmYlInfo ylInfo:dto.getYlList()){
if (ylInfo.(ydjh)){
ylInfo.(ydjh);
.add(ylInfo);
continue out;
}
}
}
return new ResultBean<>();
}
}

@ -18,6 +18,7 @@ public class YlSlDto {
private String gg;
private String lph;
private Integer status;
private boolean isGd=false;
private List<DmYlInfo> ylList;

Loading…
Cancel
Save