Compare commits

..

No commits in common. 'bdd3b67f9ddddb025c80ed48be5f4421b0f03c33' and '729d89d81b1bca5541fcc0413bebf5c594c4eaee' have entirely different histories.

@ -41,7 +41,6 @@ import java.io.IOException;
import java.io.InputStream;
import java.math.BigDecimal;
import java.util.*;
import java.util.function.Function;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
import java.util.stream.Collectors;
@ -2051,10 +2050,7 @@ public class BomUploadServiceImpl {
}else{
dmYdjh.setLx("B");
}
if(null!=bchxmxp){
dmYdjh.setDcFd(StringUtils.isBlank(bchxmxp.getWph()) ? "" : bchxmxp.getWph().substring(0, 4));
}
dmYdjh.setDcFd(StringUtils.isBlank(bchxmxp.getWph()) ? "" : bchxmxp.getWph().substring(0, 4));
dmYdjh.setBmxgrq(DateUtil.format(DateUtil.date(), "yyyy/MM/dd HH:mm"));
dmYdjh.setBmxgry((String) req.getAttribute("yhms"));
if(StringUtils.isNotBlank(dmYdjh.getSlxhth())){ // 说明已经上料 需要修正数据
@ -2141,9 +2137,8 @@ public class BomUploadServiceImpl {
}else{
dmYdjh.setLx("B");
}
if(null!=bchxmxp) {
dmYdjh.setDcFd(StringUtils.isBlank(bchxmxp.getWph()) ? "" : bchxmxp.getWph().substring(0, 4));
}
dmYdjh.setDcFd(StringUtils.isBlank(bchxmxp.getWph()) ? "" : bchxmxp.getWph().substring(0, 4));
dmYdjh.setBmxgrq(DateUtil.format(DateUtil.date(), "yyyy/MM/dd HH:mm"));
dmYdjh.setBmxgry((String) req.getAttribute("yhms"));
if(StringUtils.isNotBlank(dmYdjh.getSlxhth())){ // 说明已经上料 需要修正数据
@ -2288,16 +2283,6 @@ public class BomUploadServiceImpl {
.eq("DC_PL_z", dcpl)
);
List<DmBchxylp> tjListOld = bchxylpService.list(new QueryWrapper<DmBchxylp>().eq("dc_ch", dcch).eq("dc_pl", dcpl));
/// 去掉重复数据
tjListOld = tjListOld.stream()
.collect(Collectors.collectingAndThen(
Collectors.toMap(
DmBchxylp::getTzbh, // 以 tzbh 作为键
Function.identity(), // 保留原对象
(existing, replacement) -> existing // 遇到重复时保留第一个
),
map -> new ArrayList<>(map.values()) // 将 Map 的值转为 List
));
List<DmYdjh> ydjhs = dmYdjhService.list(new QueryWrapper<DmYdjh>().eq("dc_ch", dcch )
.eq("dc_pl",dcpl)
);
@ -2343,11 +2328,8 @@ public class BomUploadServiceImpl {
.filter(fst -> StringUtils.isNotBlank(fst.getWpgg())
&& StringUtils.isNotBlank(fst.getWpxh())
&& fst.getWpgg().equalsIgnoreCase(dmBchxylp1.getWpgg())
&& (
fst.getWpxh().equalsIgnoreCase(dmBchxylp1.getWpxh())
|| (cjs1 + fst.getWpxh()).equalsIgnoreCase(dmBchxylp1.getWpxh())
|| ( fst.getWpxh()).equalsIgnoreCase(cjs1 +dmBchxylp1.getWpxh())
)
&& (fst.getWpxh().equalsIgnoreCase(dmBchxylp1.getWpxh())
|| (cjs1 + fst.getWpxh()).equalsIgnoreCase(dmBchxylp1.getWpxh()) || ( fst.getWpxh()).equalsIgnoreCase(cjs1 +dmBchxylp1.getWpxh()))
&& fst.getTzbh().equalsIgnoreCase(dmBchxylp1.getTzbh())
)
.findFirst()

Loading…
Cancel
Save