自动化立体仓库 - WCS系统
#
yxFwq
2025-03-27 e7eefd68dcb095ddd33321192755116f4d4586d9
src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java
@@ -8101,6 +8101,40 @@
                            }
                            break;
                        }
                    } else if (staProtocol.isAutoing()
                            && !staProtocol.isLoading()
                            && staProtocol.getWorkNo() == 0
                            && staProtocol.isPakMk()) {
                        for (DevpSlave.Jar jar : inSta.getJarList()) {
                            SteThread steThread = (SteThread) SlaveConnection.get(SlaveType.Ste, jar.getJarNo()<3? 1:2);
                            if (steThread == null) {
                                continue;
                            }
                            SteProtocol steProtocol = steThread.getSteProtocol();
                            if (steProtocol == null) {
                                continue;
                            }
                            if (!Cools.isEmpty(steProtocol.getLocaType()) && !steProtocol.getLocaType().equals(SteLocaType.NONE) && steProtocol.getStatusType().equals(SteStatusType.IDLE)) {
                                // 判断重复工作档
                                List<BasJarMast> basJarMastList = basJarMastService.getJarMastByJarIdAndStatusListB(jar.getBurial(), new ArrayList<Integer>() {{
                                    add(9);
                                    add(11);
                                }});
                                if (basJarMastList.isEmpty()){
                                    continue;
                                }
                                BasJarMast jarMastByWrkNo = basJarMastList.get(0);
                                WrkMastExecute wrkMastExecute = wrkMastExecuteService.selectOne(new EntityWrapper<WrkMastExecute>().eq("wrk_no", jarMastByWrkNo.getWrkNo()));
                                if (Cools.isEmpty(wrkMastExecute)){
                                    jarMastByWrkNo.setStatus(jarMastByWrkNo.getStatusComplete(6));
                                    if (!basJarMastService.updateById(jarMastByWrkNo)){
                                        log.error("硫化区域分段任务完成异常,BasJarMast={},异常信息={}",JSON.toJSONString(jarMastByWrkNo),"更新basJarMast失败");
//                                    throw new CoolException("更新basJarMast失败");
                                    }
                                }
                                break;
                            }
                        }
                    }
                }
            }