opt: 优化日志和创建者
This commit is contained in:
@@ -86,7 +86,7 @@ public class TwoNDCSocketConnectionAutoRun extends AbstractAutoRunnable {
|
||||
DeviceExecuteLogService logServer = SpringContextHolder.getBean(DeviceExecuteLogService.class);
|
||||
|
||||
try {
|
||||
System.out.println("2楼1区域AGV系统链接开始");
|
||||
log.info("2楼1区域AGV系统链接开始");
|
||||
ip = paramService.findByCode(AcsConfig.AGVURL).getValue();
|
||||
port = Integer.parseInt(paramService.findByCode(AcsConfig.AGVPORT).getValue());
|
||||
// byte[] b = new byte[1024];
|
||||
|
||||
@@ -84,7 +84,11 @@ public class StandardAutodoorDeviceDriver extends AbstractOpcDeviceDriver implem
|
||||
Map<String, Object> itemMap = new HashMap<String, Object>();
|
||||
itemMap.put(to_param, Integer.parseInt(value));
|
||||
|
||||
this.control(itemMap);
|
||||
try {
|
||||
this.checkcontrol(itemMap);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
logServer.deviceExecuteLog(device_code, "", "", "下发电气信号设备号:" + device_code + ",下发电气:" + to_param + ",下发电气值:" + value);
|
||||
}
|
||||
|
||||
|
||||
@@ -414,23 +414,23 @@ public class ItemProtocol {
|
||||
list.add(new ItemDto(item_heartbeat, "心跳", "DB101.BO"));
|
||||
list.add(new ItemDto(item_deviceCode, "堆垛机号", "DB101.B1"));
|
||||
list.add(new ItemDto(item_mode, "工作模式", "DB101.B2"));
|
||||
list.add(new ItemDto(item_command, "作业状态", "DB101.B3"));
|
||||
list.add(new ItemDto(item_task, "任务号", "DB101.D4"));
|
||||
list.add(new ItemDto(item_error, "Y轴报警(载货台)", "DB101.B8"));
|
||||
list.add(new ItemDto(item_z, "行走排号", "DB101.B9"));
|
||||
list.add(new ItemDto(item_x, "行走列号", "DB101.B10"));
|
||||
list.add(new ItemDto(item_y, "行走层号", "DB101.B11"));
|
||||
list.add(new ItemDto(item_move, "行走开关信号", "DB101.B12"));
|
||||
list.add(new ItemDto(item_cargoMove, "载货台开关信号", "DB101.B13"));
|
||||
list.add(new ItemDto(item_action, "行走动作信号", "DB101.B14"));
|
||||
list.add(new ItemDto(item_command, "作业状态", "DB101.B31"));
|
||||
list.add(new ItemDto(item_task, "任务号", "DB101.D32"));
|
||||
list.add(new ItemDto(item_error, "Y轴报警(载货台)", "DB101.B36"));
|
||||
list.add(new ItemDto(item_z, "行走排号", "DB101.B38"));
|
||||
list.add(new ItemDto(item_x, "行走列号", "DB101.B39"));
|
||||
list.add(new ItemDto(item_y, "行走层号", "DB101.B40"));
|
||||
list.add(new ItemDto(item_move, "行走开关信号", "DB101.B4"));
|
||||
list.add(new ItemDto(item_cargoMove, "载货台开关信号", "DB101.B41"));
|
||||
list.add(new ItemDto(item_action, "行走动作信号", "DB101.B5"));
|
||||
list.add(new ItemDto(item_distancex, "行走激光数值", "DB101.D16"));
|
||||
list.add(new ItemDto(item_distancey, "起升激光数值", "DB101.D20"));
|
||||
list.add(new ItemDto(item_cargoError, "载货台超限信号", "DB101.B24"));
|
||||
list.add(new ItemDto(item_forkCargo, "货叉探货信号", "DB101.B25"));
|
||||
list.add(new ItemDto(item_forkLocation, "货叉位置信号", "DB101.B26"));
|
||||
list.add(new ItemDto(item_forkAction, "货叉动作信号", "DB101.B27"));
|
||||
list.add(new ItemDto(item_special1, "特殊开关量1", "DB101.B28"));
|
||||
list.add(new ItemDto(item_special2, "特殊开关量2", "DB101.B29"));
|
||||
list.add(new ItemDto(item_distancey, "起升激光数值", "DB101.D44"));
|
||||
list.add(new ItemDto(item_cargoError, "载货台超限信号", "DB101.B43"));
|
||||
list.add(new ItemDto(item_forkCargo, "货叉探货信号", "DB101.B48"));
|
||||
list.add(new ItemDto(item_forkLocation, "货叉位置信号", "DB101.B49"));
|
||||
list.add(new ItemDto(item_forkAction, "货叉动作信号", "DB101.B50"));
|
||||
list.add(new ItemDto(item_special1, "特殊开关量1", "DB101.B10"));
|
||||
list.add(new ItemDto(item_special2, "特殊开关量2", "DB101.B11"));
|
||||
list.add(new ItemDto(item_trayCode, "托盘条码", "DB101.B30.20"));
|
||||
list.add(new ItemDto(item_storage_cache, "水箱和消防缓存位有无货", "DB101.B50"));
|
||||
list.add(new ItemDto(item_stacker_rpm, "速度(转/分钟)", "DB101.W52"));
|
||||
@@ -454,10 +454,10 @@ public class ItemProtocol {
|
||||
list.add(new ItemDto(item_to_device_code, "堆垛机号", "DB100.B1"));
|
||||
list.add(new ItemDto(item_to_command, "作业命令", "DB100.B2"));
|
||||
list.add(new ItemDto(item_to_type, "物料类型", "DB100.B3"));
|
||||
list.add(new ItemDto(item_to_task, "任务号", "DB100.D4"));
|
||||
list.add(new ItemDto(item_to_z, "作业排", "DB100.B8"));
|
||||
list.add(new ItemDto(item_to_x, "作业列", "DB100.B9"));
|
||||
list.add(new ItemDto(item_to_y, "作业层", "DB100.B10"));
|
||||
list.add(new ItemDto(item_to_task, "任务号", "DB100.D10"));
|
||||
list.add(new ItemDto(item_to_z, "作业排", "DB100.B6"));
|
||||
list.add(new ItemDto(item_to_x, "作业列", "DB100.B7"));
|
||||
list.add(new ItemDto(item_to_y, "作业层", "DB100.B8"));
|
||||
list.add(new ItemDto(item_to_trayCode, "托盘号", "DB100.B11.20"));
|
||||
return list;
|
||||
}
|
||||
|
||||
@@ -27,20 +27,11 @@ public class SecurityUtils {
|
||||
JSONObject json = (JSONObject) StpUtil.getExtra("loginInfo");
|
||||
if (ObjectUtil.isNotEmpty(json)) {
|
||||
return json.toBean(CurrentUser.class);
|
||||
} else {
|
||||
CurrentUser currentUser = new CurrentUser();
|
||||
currentUser.setId("2");
|
||||
currentUser.setPresonName("LMS系统用户");
|
||||
currentUser.setUsername("LMS");
|
||||
return currentUser;
|
||||
}
|
||||
} catch (Exception e) {
|
||||
CurrentUser currentUser = new CurrentUser();
|
||||
currentUser.setId("2");
|
||||
currentUser.setPresonName("LMS系统用户");
|
||||
currentUser.setUsername("LMS");
|
||||
return currentUser;
|
||||
return new CurrentUser();
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -50,7 +50,6 @@ public class AutoCreateInst {
|
||||
InstructionService instructionService = SpringContextHolder.getBean(InstructionService.class);
|
||||
RouteLineService routeLineService = SpringContextHolder.getBean(RouteLineService.class);
|
||||
DeviceAppService appService = SpringContextHolder.getBean(DeviceAppServiceImpl.class);
|
||||
LimitRegionalService limitRegionalService = SpringContextHolder.getBean(LimitRegionalService.class);
|
||||
LuceneExecuteLogService luceneExecuteLogService = SpringContextHolder.getBean(LuceneExecuteLogServiceImpl.class);
|
||||
List<TaskDto> list = taskserver.queryAllByStatus("0");
|
||||
for (int i = 0; i < list.size(); i++) {
|
||||
@@ -101,7 +100,7 @@ public class AutoCreateInst {
|
||||
continue;
|
||||
}
|
||||
|
||||
if (!StrUtil.equals(shortPathsList.get(0).getType(), CommonFinalParam.ONE) && !StrUtil.equals(shortPathsList.get(0).getType(), CommonFinalParam.TWO)) {
|
||||
if (!StrUtil.equals(shortPathsList.get(0).getType(), CommonFinalParam.ONE)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user