From 21dedbb10f307260ac6fd77b826fc9158160c2bb Mon Sep 17 00:00:00 2001 From: Crunchy <3114200645@qq.com> Date: 星期三, 24 七月 2024 15:20:22 +0800 Subject: [PATCH] 数采bug调整 --- inspect-server/src/main/java/com/yuanchu/mom/service/impl/StandardProductListServiceImpl.java | 16 ++++++++-------- 1 files changed, 8 insertions(+), 8 deletions(-) diff --git a/inspect-server/src/main/java/com/yuanchu/mom/service/impl/StandardProductListServiceImpl.java b/inspect-server/src/main/java/com/yuanchu/mom/service/impl/StandardProductListServiceImpl.java index 9a38d4b..d0c90bc 100644 --- a/inspect-server/src/main/java/com/yuanchu/mom/service/impl/StandardProductListServiceImpl.java +++ b/inspect-server/src/main/java/com/yuanchu/mom/service/impl/StandardProductListServiceImpl.java @@ -58,20 +58,18 @@ @Override public List<StandardProductList> selectStandardProductList(InsSample insSample) { String[] models = insSample.getModel().split("-(?=[^-]*$)");//鎷嗗垎鏈�鍚庝竴涓��-銆� - String[] factorys = insSample.getFactory().split(" - "); - //List<StandardProductList> list = standardProductListMapper.selectList(Wrappers.<StandardProductList>lambdaQuery().eq(StandardProductList::getStandardMethodListId, insSample.getStandardMethodListId()).eq(StandardProductList::getState, 1).eq(StandardProductList::getModel, models[0]).eq(StandardProductList::getSampleType, factorys[2])); List<StandardProductList> list = standardProductListMapper.selectDetail(insSample.getStandardMethodListId(), 1, models[0]); if (list.size() == 0) { if (Objects.equals(insSample.getFactory(), "") || insSample.getFactory() == null) { return null; } String[] split = insSample.getFactory().split(" - "); - list = standardProductListMapper.selectDetail2(insSample.getStandardMethodListId(), 1, split[0] + " - " + split[1] + " - " + split[2] + " - " + split[3]); - /* list = standardProductListMapper.selectList(Wrappers.<StandardProductList>lambdaQuery() - .eq(StandardProductList::getStandardMethodListId, insSample.getStandardMethodListId()) - .eq(StandardProductList::getState, 1) - .like(StandardProductList::getTree, split[0] + " - " + split[1] + " - " + split[2] + " - " + split[3]));*/ - + String tree = split[0] + " - " + split[1] + " - " + split[2] + " - " + split[3] + " - null"; + list = standardProductListMapper.selectDetail2(insSample.getStandardMethodListId(), 1, tree); + if (list.size()==0){ + String tree1 = split[0] + " - " + split[1] + " - " + split[2] + " - null - " + split[3] ; + list = standardProductListMapper.selectDetail2(insSample.getStandardMethodListId(), 1, tree1); + } } list = list.stream().filter(a -> { try { @@ -237,6 +235,7 @@ if (page == 1) { Integer userId = getLook.selectPowerByMethodAndUserId(null).get("userId"); CompletableFuture.supplyAsync(() -> { + System.out.println("寮�濮嬪紑濮嬪紑濮嬪紑濮�!!!!!!!!!!"); if (trees.length == 5) { standardProductListMapper.delete(Wrappers.<StandardProductList>lambdaUpdate().eq(StandardProductList::getStandardMethodListId, id).eq(StandardProductList::getTree, tree)); } else { @@ -251,6 +250,7 @@ a.setStandardMethodListId(id); return a; }).collect(Collectors.toList())); + System.out.println("缁撴潫缁撴潫缁撴潫缁撴潫@@@@@@@@@@@@"); return null; }).thenAccept(res -> { }).exceptionally(e -> { -- Gitblit v1.9.3