From 7e6373f44de6dfea87d084dd7ce5d61cedf2324f Mon Sep 17 00:00:00 2001 From: gengby <858962040@qq.com> Date: Wed, 7 Dec 2022 19:08:39 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../org/nl/acs/agv/server/impl/XianGongAgvServiceImpl.java | 2 +- .../device_driver/maGang/MaGangConveyorDeviceDriver.java | 3 +++ .../nl/acs/ext/wms/service/impl/AgvToAcsServiceImpl.java | 2 +- .../src/main/resources/config/application-dev.yml | 6 +++--- 4 files changed, 8 insertions(+), 5 deletions(-) diff --git a/acs/nladmin-system/src/main/java/org/nl/acs/agv/server/impl/XianGongAgvServiceImpl.java b/acs/nladmin-system/src/main/java/org/nl/acs/agv/server/impl/XianGongAgvServiceImpl.java index a72b31e..cba57e9 100644 --- a/acs/nladmin-system/src/main/java/org/nl/acs/agv/server/impl/XianGongAgvServiceImpl.java +++ b/acs/nladmin-system/src/main/java/org/nl/acs/agv/server/impl/XianGongAgvServiceImpl.java @@ -260,7 +260,7 @@ public class XianGongAgvServiceImpl implements XianGongAgvService { JSONObject jo1 = new JSONObject(); jo1.put("blockId", IdUtil.simpleUUID()); jo1.put("location", inst.getStart_point_code()); - jo1.put("operation", "Jackload"); + jo1.put("operation", "JackLoad"); ja.add(jo1); //取货完成等待 diff --git a/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/maGang/MaGangConveyorDeviceDriver.java b/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/maGang/MaGangConveyorDeviceDriver.java index 836a35e..4a69f90 100644 --- a/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/maGang/MaGangConveyorDeviceDriver.java +++ b/acs/nladmin-system/src/main/java/org/nl/acs/device_driver/maGang/MaGangConveyorDeviceDriver.java @@ -220,6 +220,9 @@ public class MaGangConveyorDeviceDriver extends AbstractOpcDeviceDriver implemen //将扩展表中的字符串数据转换成集合 public List getExtraDeviceCodes(String extraName) { String extraValue = (String) this.getDevice().getExtraValue().get(extraName); + if (StrUtil.isEmpty(extraValue)){ + return new ArrayList<>(); + } String devicesString = extraValue.substring(1, extraValue.length() - 1); List devicesList = new ArrayList<>(); String[] devices = devicesString.split(","); diff --git a/acs/nladmin-system/src/main/java/org/nl/acs/ext/wms/service/impl/AgvToAcsServiceImpl.java b/acs/nladmin-system/src/main/java/org/nl/acs/ext/wms/service/impl/AgvToAcsServiceImpl.java index 625a7ad..4c80bbb 100644 --- a/acs/nladmin-system/src/main/java/org/nl/acs/ext/wms/service/impl/AgvToAcsServiceImpl.java +++ b/acs/nladmin-system/src/main/java/org/nl/acs/ext/wms/service/impl/AgvToAcsServiceImpl.java @@ -36,7 +36,7 @@ public class AgvToAcsServiceImpl implements AgvToAcsService { //车号 String vehicle_code = param.getString("device_code"); String deviceCode = RouteUtil.getDeviceCode(address); - Instruction instructionDto = instructionService.findByCode(inst_code); + Instruction instructionDto = instructionService.findByCodeFromCache(inst_code); if (ObjectUtil.isEmpty(instructionDto)) { logService.deviceExecuteLog(deviceCode, vehicle_code, inst_code, "请求路径:api/agv/waitpointRequest,请求参数:" + param.toString() + ",请求失败-原因:指令任务号不存在! 指令号:" + inst_code); throw new BadRequestException("请求失败,指令任务号不存在!"); diff --git a/acs/nladmin-system/src/main/resources/config/application-dev.yml b/acs/nladmin-system/src/main/resources/config/application-dev.yml index 64cf625..a75e18c 100644 --- a/acs/nladmin-system/src/main/resources/config/application-dev.yml +++ b/acs/nladmin-system/src/main/resources/config/application-dev.yml @@ -6,10 +6,10 @@ spring: druid: db-type: com.alibaba.druid.pool.DruidDataSource driverClassName: net.sf.log4jdbc.sql.jdbcapi.DriverSpy - url: jdbc:log4jdbc:mysql://${DB_HOST:47.111.78.178}:${DB_PORT:3306}/${DB_NAME:magang_acs}?serverTimezone=Asia/Shanghai&characterEncoding=utf8&useSSL=false&useOldAliasMetadataBehavior=true + url: jdbc:log4jdbc:mysql://${DB_HOST:127.0.0.1}:${DB_PORT:3306}/${DB_NAME:magang_acs}?serverTimezone=Asia/Shanghai&characterEncoding=utf8&useSSL=false&useOldAliasMetadataBehavior=true # url: jdbc:log4jdbc:mysql://${DB_HOST:192.168.81.252}:${DB_PORT:3306}/${DB_NAME:ndxy3_acs}?serverTimezone=Asia/Shanghai&characterEncoding=utf8&useSSL=false&useOldAliasMetadataBehavior=true username: ${DB_USER:root} - password: ${DB_PWD:P@ssw0rd} + password: ${DB_PWD:password} # password: ${DB_PWD:Root.123456} # 初始连接数 initial-size: 5 @@ -54,7 +54,7 @@ spring: multi-statement-allow: true redis: #数据库索引 - database: ${REDIS_DB:15} + database: ${REDIS_DB:9} host: ${REDIS_HOST:127.0.0.1} port: ${REDIS_PORT:6379} password: ${REDIS_PWD:}