|
@@ -105,8 +105,7 @@ public class BillCleanServiceImpl extends ServiceImpl<BillCleanMapper, BillClean
|
|
|
.eq("test_location_id", baseLocation.getId()).eq("bill_status", 0);
|
|
|
|
|
|
return new Result(ResultCode.SUCCESS, cleanMapper.selectPage(page, queryWrapper), cleanMapper.selectCount(queryWrapper2));
|
|
|
- }
|
|
|
- else if ("5".equals(type)) {
|
|
|
+ } else if ("5".equals(type)) {
|
|
|
Page<CleanDryGoodsVo> cleanDryGoodPage = null;
|
|
|
Page<CleanDryGoodsVo> page = new Page<>(Integer.parseInt(pageNum), Integer.parseInt(pageSize));
|
|
|
QueryWrapper<BillClean> queryWrapper = new QueryWrapper<>();
|
|
@@ -145,11 +144,11 @@ public class BillCleanServiceImpl extends ServiceImpl<BillCleanMapper, BillClean
|
|
|
}
|
|
|
queryWrapper.eq("img_status", 0);
|
|
|
queryWrapper2.eq("img_status", 0);
|
|
|
- queryWrapper3.eq("status", 0);
|
|
|
+ queryWrapper3.eq("bill_status", 0);
|
|
|
Integer integer = cleanMapper.selectCount(queryWrapper);
|
|
|
Integer integer1 = dryMapper.selectCount(queryWrapper2);
|
|
|
Integer integer2 = inventoryMapper.selectCount(queryWrapper3);
|
|
|
- return new Result(ResultCode.SUCCESS, cleanDryGoodPage, integer+ integer1+ integer2);
|
|
|
+ return new Result(ResultCode.SUCCESS, cleanDryGoodPage, integer + integer1 + integer2);
|
|
|
} else {
|
|
|
Page<CleanAndDryVo2> cleanAndDryVo2Page = null;
|
|
|
Page<CleanAndDryVo2> page = new Page<>(Integer.parseInt(pageNum), Integer.parseInt(pageSize));
|
|
@@ -192,6 +191,36 @@ public class BillCleanServiceImpl extends ServiceImpl<BillCleanMapper, BillClean
|
|
|
}
|
|
|
|
|
|
@Override
|
|
|
+ public Result listPersonCleanAndDryAndGoods(HttpServletRequest httpServletRequest, Map<String, String> paramsMap) {
|
|
|
+ String farmId = paramsMap.get("farmId");
|
|
|
+ String pageNum = paramsMap.get("pageNum");
|
|
|
+ String pageSize = paramsMap.get("pageSize");
|
|
|
+ Page<CleanDryGoodsVo> cleanDryGoodPage = null;
|
|
|
+ Page<CleanDryGoodsVo> page = new Page<>(Integer.parseInt(pageNum), Integer.parseInt(pageSize));
|
|
|
+ QueryWrapper<BillClean> queryWrapper = new QueryWrapper<>();
|
|
|
+ queryWrapper.eq("farm_id", farmId).eq("vistit_type", 5);
|
|
|
+ QueryWrapper<BillDry> queryWrapper2 = new QueryWrapper<>();
|
|
|
+ queryWrapper2.eq("farm_id", farmId).eq("vistit_type", 5);
|
|
|
+ QueryWrapper<BillGoodsInventory> queryWrapper3 = new QueryWrapper<>();
|
|
|
+ queryWrapper3.eq("farm_id", farmId);
|
|
|
+
|
|
|
+ String[] s = {TokenSign.getWorkIdByJwtToken(httpServletRequest)};
|
|
|
+ System.out.println("传入自定义sql的位置参数形式:" + s);
|
|
|
+ cleanDryGoodPage = cleanMapper.listCleanDryGoods(page, farmId, "5", "0,1".split(","), s);
|
|
|
+// queryWrapper.in("test_location_id", TokenSign.getWorkIdByJwtToken(httpServletRequest));
|
|
|
+// queryWrapper2.in("test_location_id", TokenSign.getWorkIdByJwtToken(httpServletRequest));
|
|
|
+// queryWrapper3.in("current_location_id", TokenSign.getWorkIdByJwtToken(httpServletRequest));
|
|
|
+
|
|
|
+ queryWrapper.eq("img_status", 0);
|
|
|
+ queryWrapper2.eq("img_status", 0);
|
|
|
+ queryWrapper3.eq("bill_status", 0);
|
|
|
+ Integer integer = cleanMapper.selectCount(queryWrapper);
|
|
|
+ Integer integer1 = dryMapper.selectCount(queryWrapper2);
|
|
|
+ Integer integer2 = inventoryMapper.selectCount(queryWrapper3);
|
|
|
+ return new Result(ResultCode.SUCCESS, cleanDryGoodPage, integer + integer1 + integer2);
|
|
|
+ }
|
|
|
+
|
|
|
+ @Override
|
|
|
public Result listById(HttpServletRequest httpServletRequest, Map<String, String> paramsMap) {
|
|
|
String id = paramsMap.get("id");
|
|
|
BillClean billClean = cleanMapper.selectById(id);
|
|
@@ -989,7 +1018,7 @@ public class BillCleanServiceImpl extends ServiceImpl<BillCleanMapper, BillClean
|
|
|
before.setCleanId(billClean.getCleanId());
|
|
|
}
|
|
|
beforeMapper.insert(before);
|
|
|
- }else if (Integer.parseInt(splits[1]) == 7) {
|
|
|
+ } else if (Integer.parseInt(splits[1]) == 7) {
|
|
|
//新增洗澡前拍照
|
|
|
BillGoodsInventory before = (BillGoodsInventory) entity;
|
|
|
if (billClean.getVistitType() != 0) {
|
|
@@ -1015,7 +1044,7 @@ public class BillCleanServiceImpl extends ServiceImpl<BillCleanMapper, BillClean
|
|
|
baseProcess.setAllLocationStatus("2,2,2,1,0");
|
|
|
}
|
|
|
}
|
|
|
- }else if (nextId == 1) {
|
|
|
+ } else if (nextId == 1) {
|
|
|
//新增采样
|
|
|
BillSampling billSampling = (BillSampling) newObject;
|
|
|
if (billClean.getVistitType() != 0) {
|
|
@@ -1030,7 +1059,7 @@ public class BillCleanServiceImpl extends ServiceImpl<BillCleanMapper, BillClean
|
|
|
}
|
|
|
samplingMapper.insert(billSampling);
|
|
|
baseProcess.setCurrentFlowId(baseProcess.getCurrentFlowId() + "," + nextId);
|
|
|
- }else if (nextId == 2) {
|
|
|
+ } else if (nextId == 2) {
|
|
|
//新增pcr
|
|
|
BillPcr billClean1 = (BillPcr) newObject;
|
|
|
if (billClean.getVistitType() != 0) {
|
|
@@ -1045,7 +1074,7 @@ public class BillCleanServiceImpl extends ServiceImpl<BillCleanMapper, BillClean
|
|
|
}
|
|
|
pcrMapper.insert(billClean1);
|
|
|
baseProcess.setCurrentFlowId(baseProcess.getCurrentFlowId() + "," + nextId);
|
|
|
- }else if (nextId == 3) {
|
|
|
+ } else if (nextId == 3) {
|
|
|
//新增洗澡
|
|
|
BillClean billClean2 = (BillClean) newObject;
|
|
|
if (billClean.getVistitType() != 0) {
|
|
@@ -1060,7 +1089,7 @@ public class BillCleanServiceImpl extends ServiceImpl<BillCleanMapper, BillClean
|
|
|
}
|
|
|
cleanMapper.insert(billClean2);
|
|
|
baseProcess.setCurrentFlowId(baseProcess.getCurrentFlowId() + "," + nextId);
|
|
|
- }else if (nextId == 4) {
|
|
|
+ } else if (nextId == 4) {
|
|
|
//新增隔离
|
|
|
BillIsolate pcr = (BillIsolate) newObject;
|
|
|
if (billClean.getVistitType() != 0) {
|
|
@@ -1075,7 +1104,7 @@ public class BillCleanServiceImpl extends ServiceImpl<BillCleanMapper, BillClean
|
|
|
}
|
|
|
isolateMapper.insert(pcr);
|
|
|
baseProcess.setCurrentFlowId(baseProcess.getCurrentFlowId() + "," + nextId);
|
|
|
- }else if (nextId == 5) {
|
|
|
+ } else if (nextId == 5) {
|
|
|
BillDry billClean2 = (BillDry) newObject;
|
|
|
if (billClean.getVistitType() != 0) {
|
|
|
billClean2.setCarNum(billClean.getCarNum());
|
|
@@ -1090,7 +1119,7 @@ public class BillCleanServiceImpl extends ServiceImpl<BillCleanMapper, BillClean
|
|
|
dryMapper.insert(billClean2);
|
|
|
baseProcess.setCurrentFlowId(baseProcess.getCurrentFlowId() + "," + nextId);
|
|
|
//新增烘干
|
|
|
- }else if (nextId == 6) {
|
|
|
+ } else if (nextId == 6) {
|
|
|
//新增洗澡前拍照
|
|
|
BillCleanBefore before = (BillCleanBefore) newObject;
|
|
|
if (billClean.getVistitType() != 0) {
|
|
@@ -1105,7 +1134,7 @@ public class BillCleanServiceImpl extends ServiceImpl<BillCleanMapper, BillClean
|
|
|
}
|
|
|
beforeMapper.insert(before);
|
|
|
baseProcess.setCurrentFlowId(baseProcess.getCurrentFlowId() + "," + nextId);
|
|
|
- }else if (nextId == 7) {
|
|
|
+ } else if (nextId == 7) {
|
|
|
//新增洗澡前拍照
|
|
|
BillGoodsInventory before = (BillGoodsInventory) newObject;
|
|
|
if (billClean.getVistitType() != 0) {
|
|
@@ -1306,7 +1335,7 @@ public class BillCleanServiceImpl extends ServiceImpl<BillCleanMapper, BillClean
|
|
|
before.setCleanId(billClean.getCleanId());
|
|
|
}
|
|
|
beforeMapper.insert(before);
|
|
|
- }else if (Integer.parseInt(splits[1]) == 7) {
|
|
|
+ } else if (Integer.parseInt(splits[1]) == 7) {
|
|
|
//新增洗澡前拍照
|
|
|
BillGoodsInventory before = (BillGoodsInventory) entity;
|
|
|
if (billClean.getVistitType() != 0) {
|
|
@@ -1347,7 +1376,7 @@ public class BillCleanServiceImpl extends ServiceImpl<BillCleanMapper, BillClean
|
|
|
}
|
|
|
samplingMapper.insert(billSampling);
|
|
|
baseProcess.setCurrentFlowId(baseProcess.getCurrentFlowId() + "," + nextId);
|
|
|
- }else if (nextId == 2) {
|
|
|
+ } else if (nextId == 2) {
|
|
|
//新增pcr
|
|
|
BillPcr billClean1 = (BillPcr) newObject;
|
|
|
if (billClean.getVistitType() != 0) {
|
|
@@ -1362,7 +1391,7 @@ public class BillCleanServiceImpl extends ServiceImpl<BillCleanMapper, BillClean
|
|
|
}
|
|
|
pcrMapper.insert(billClean1);
|
|
|
baseProcess.setCurrentFlowId(baseProcess.getCurrentFlowId() + "," + nextId);
|
|
|
- }else if (nextId == 3) {
|
|
|
+ } else if (nextId == 3) {
|
|
|
//新增洗澡
|
|
|
BillClean billClean2 = (BillClean) newObject;
|
|
|
if (billClean.getVistitType() != 0) {
|
|
@@ -1377,7 +1406,7 @@ public class BillCleanServiceImpl extends ServiceImpl<BillCleanMapper, BillClean
|
|
|
}
|
|
|
cleanMapper.insert(billClean2);
|
|
|
baseProcess.setCurrentFlowId(baseProcess.getCurrentFlowId() + "," + nextId);
|
|
|
- }else if (nextId == 4) {
|
|
|
+ } else if (nextId == 4) {
|
|
|
//新增隔离
|
|
|
BillIsolate pcr = (BillIsolate) newObject;
|
|
|
if (billClean.getVistitType() != 0) {
|
|
@@ -1392,7 +1421,7 @@ public class BillCleanServiceImpl extends ServiceImpl<BillCleanMapper, BillClean
|
|
|
}
|
|
|
isolateMapper.insert(pcr);
|
|
|
baseProcess.setCurrentFlowId(baseProcess.getCurrentFlowId() + "," + nextId);
|
|
|
- }else if (nextId == 5) {
|
|
|
+ } else if (nextId == 5) {
|
|
|
BillDry billClean2 = (BillDry) newObject;
|
|
|
if (billClean.getVistitType() != 0) {
|
|
|
billClean2.setCarNum(billClean.getCarNum());
|
|
@@ -1407,7 +1436,7 @@ public class BillCleanServiceImpl extends ServiceImpl<BillCleanMapper, BillClean
|
|
|
dryMapper.insert(billClean2);
|
|
|
baseProcess.setCurrentFlowId(baseProcess.getCurrentFlowId() + "," + nextId);
|
|
|
//新增烘干
|
|
|
- }else if (nextId == 6) {
|
|
|
+ } else if (nextId == 6) {
|
|
|
//新增洗澡前拍照
|
|
|
BillCleanBefore before = (BillCleanBefore) newObject;
|
|
|
if (billClean.getVistitType() != 0) {
|
|
@@ -1422,7 +1451,7 @@ public class BillCleanServiceImpl extends ServiceImpl<BillCleanMapper, BillClean
|
|
|
}
|
|
|
beforeMapper.insert(before);
|
|
|
baseProcess.setCurrentFlowId(baseProcess.getCurrentFlowId() + "," + nextId);
|
|
|
- }else if (nextId == 7) {
|
|
|
+ } else if (nextId == 7) {
|
|
|
//新增洗澡前拍照
|
|
|
BillGoodsInventory before = (BillGoodsInventory) newObject;
|
|
|
if (billClean.getVistitType() != 0) {
|