src/main/java/com/zy/asrs/controller/AgvOpenController.java | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
src/main/java/com/zy/asrs/controller/AgvWrkMastLogController.java | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
src/main/java/com/zy/asrs/service/impl/AgvWorkServiceImpl.java | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
src/main/java/com/zy/asrs/service/impl/AgvWrkMastServiceImp.java | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
src/main/resources/application.yml | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 |
src/main/java/com/zy/asrs/controller/AgvOpenController.java
@@ -90,6 +90,15 @@ return r; } } try { if (!Cools.isEmpty(agvWrkMast.getBarcode()) && !Cools.isEmpty(param.getPodCode())) { if (!agvWrkMast.getBarcode().equals(param.getPodCode())) { log.info("AGV回调的返回的托盘码和工作档托盘不一致,{}{}", agvWrkMast.getBarcode(), param.getPodCode()); } } } catch (Exception e) { e.printStackTrace(); } if (agvWrkMast.getIoType().equals(121)) { try { if (agvWrkMast.getWrkSts().equals(12L)) { @@ -173,17 +182,7 @@ end { @Transactional public void success(AgvWrkMast agvWrkMast, AgvTaskCallBackParam param) { try { if (!Cools.isEmpty(agvWrkMast.getBarcode()) && !Cools.isEmpty(param.getPodCode())) { if (!agvWrkMast.getBarcode().equals(param.getPodCode())) { agvWrkMast.setTakeNone(agvWrkMast.getBarcode() + "!=" + param.getPodCode()); log.info("AGV回调的返回的托盘码和工作档托盘不一致,{}{}", agvWrkMast.getBarcode(), param.getPodCode()); log.error("AGV回调的返回的托盘码和工作档托盘不一致,{}{}", agvWrkMast.getBarcode(), param.getPodCode()); } } } catch (Exception e) { } //修改AGV工作档的工作状态为205.工作完成 agvWrkMast.setWrkSts(205L); @@ -367,6 +366,15 @@ } } public static void main(String[] args) { try { String s = null; System.out.println(s.equals("1")); }catch (Exception e){ } } } src/main/java/com/zy/asrs/controller/AgvWrkMastLogController.java
@@ -115,9 +115,12 @@ wrapper.like(entry.getKey().replace("%", ""), val, SqlLike.LEFT); } else if (key.endsWith("%")) { wrapper.like(entry.getKey().replace("%", ""), val, SqlLike.RIGHT); } else if (entry.getKey().equals("manu_type")) { wrapper.like(entry.getKey(), val); } else { wrapper.eq(entry.getKey(), val); } } } } src/main/java/com/zy/asrs/service/impl/AgvWorkServiceImpl.java
@@ -495,6 +495,10 @@ if (Cools.isEmpty(agvBasDevp)) { throw new CoolException("暂无" + station + "站点"); } AgvBasDevp agvBasDevp2 = agvBasDevpService.selectOne(new EntityWrapper<AgvBasDevp>().eq("barcode", containerCode).ne("dev_no", agvBasDevp.getDevNo())); if (!Cools.isEmpty(agvBasDevp2)) { throw new CoolException(station + "站点绑定该货架,无法入库"); } int br = 0; if (containerType == 21 && agvBasDevp.getFloor() == 2) { containerType = 20; @@ -645,6 +649,15 @@ if (Cools.isEmpty(agvBasDevp)) { throw new CoolException("暂无" + station + "站点"); } AgvBasDevp agvBasDevp2 = agvBasDevpService.selectOne(new EntityWrapper<AgvBasDevp>().eq("barcode", containerCode).ne("dev_no", agvBasDevp.getDevNo())); if (!Cools.isEmpty(agvBasDevp2)) { throw new CoolException(station + "站点绑定该货架,无法入库"); } if (Cools.isEmpty(agvBasDevp)) { throw new CoolException("暂无" + station + "站点"); } int br = 0; if (containerType == 21 && agvBasDevp.getFloor() == 2) { containerType = 20; @@ -800,6 +813,10 @@ AgvBasDevp agvBasDevp = agvBasDevpService.selectById(station); if (Cools.isEmpty(agvBasDevp)) { throw new CoolException("暂无" + station + "站点"); } AgvBasDevp agvBasDevp2 = agvBasDevpService.selectOne(new EntityWrapper<AgvBasDevp>().eq("barcode", containerCode).ne("dev_no", agvBasDevp.getDevNo())); if (!Cools.isEmpty(agvBasDevp2)) { throw new CoolException(station + "站点绑定该货架,无法入库"); } int br = 0; if (containerType == 21 && agvBasDevp.getFloor() == 2) { @@ -1390,8 +1407,8 @@ if (!orderDetlService.update(orderDetl, new EntityWrapper<OrderDetl>().eq("order_no", "DB" + agvLocDetl.getOrderNo()).eq("matnr", agvLocDetl.getMatnr()).eq("three_code", agvLocDetl.getThreeCode()))) { throw new CoolException("修改订单明细失败,请联系管理员" + agvLocDetl.getOrderNo() + agvLocDetl.getMatnr()); } }else { orderDetl = orderDetlService.selectOne(new EntityWrapper<OrderDetl>().eq("matnr", agvLocDetl.getMatnr()).eq("three_code", agvLocDetl.getThreeCode()).eq("source",33).ge("qty",agvLocDetl.getAnfme())); } else { orderDetl = orderDetlService.selectOne(new EntityWrapper<OrderDetl>().eq("matnr", agvLocDetl.getMatnr()).eq("three_code", agvLocDetl.getThreeCode()).eq("source", 33).ge("qty", agvLocDetl.getAnfme())); if (orderDetl != null) { orderDetl.setQty(orderDetl.getQty() - agvLocDetl.getAnfme()); if (!orderDetlService.update(orderDetl, new EntityWrapper<OrderDetl>().eq("order_no", orderDetl.getOrderNo()).eq("matnr", agvLocDetl.getMatnr()).eq("three_code", agvLocDetl.getThreeCode()))) { @@ -1538,9 +1555,13 @@ throw new CoolException("删除失败,请联系管理员"); } if (type == 2) { //调用agv取消任务接口 agvWrkMastService.callCancelTask(wrkMast.getWrkNo()); if (type == 2 || type == 5) { try { //调用agv取消任务接口 agvWrkMastService.callCancelTask(wrkMast.getWrkNo()); } catch (Exception e) { log.info("调用agv取消任务接口失败"); } } } } src/main/java/com/zy/asrs/service/impl/AgvWrkMastServiceImp.java
@@ -16,6 +16,7 @@ import com.zy.asrs.service.*; import com.zy.common.service.AgvCommonService; import com.zy.common.utils.HttpHandler; import com.zy.system.entity.Config; import com.zy.system.service.ConfigService; import lombok.extern.slf4j.Slf4j; import org.springframework.beans.factory.annotation.Autowired; @@ -275,8 +276,17 @@ } break; } if (!Cools.isEmpty(agvWrkMast.getBarcode())) { agvTaskCreateParam.setPodCode(agvWrkMast.getBarcode()); try { Config config = configService.selectOne(new EntityWrapper<Config>().eq("code", "BARCODE")); boolean flag = false; if (!Cools.isEmpty(config)) { flag = config.getValue().equals("Y"); } if (!Cools.isEmpty(agvWrkMast.getBarcode()) && flag) { agvTaskCreateParam.setPodCode(agvWrkMast.getBarcode()); } }catch (Exception e){ } agvTaskCreateParam.setPositionCodePath(agvTaskParamList); src/main/resources/application.yml
@@ -1,4 +1,4 @@ spring: profiles: #dev loc prod active: prod active: dev