更新
This commit is contained in:
0
wcs/hd/logPath_IS_UNDEFINED/2022-07-04.0.log
Normal file
0
wcs/hd/logPath_IS_UNDEFINED/2022-07-04.0.log
Normal file
0
wcs/hd/logPath_IS_UNDEFINED/2022-07-07.0.log
Normal file
0
wcs/hd/logPath_IS_UNDEFINED/2022-07-07.0.log
Normal file
@@ -311,8 +311,6 @@ public class HailiangPackerStationDeviceDriver extends AbstractOpcDeviceDriver i
|
||||
logServer.deviceLogToacs(this.device_code, "", "", device_code + ":,move:" + move + ",mode:" + mode + ",requireSucess:" + requireSucess + "开始申请请求取走空料斗任务");
|
||||
apply_take_empty_task();
|
||||
}
|
||||
logServer.deviceLogToacs(this.device_code, "", "", "lack_req:" + lack_req + "move:" + move + "req_task_empty:" + req_task_empty);
|
||||
|
||||
} else {
|
||||
logServer.deviceLogToacs(this.device_code, "", "", "是否请求成功:requireSucess:" + requireSucess);
|
||||
}
|
||||
@@ -541,7 +539,8 @@ public class HailiangPackerStationDeviceDriver extends AbstractOpcDeviceDriver i
|
||||
logServer.deviceLogToacs(this.device_code, "", "", device_code + ":关联设备" + link_device + "未找到对应设备工单");
|
||||
throw new BadRequestException(this.device_code + ":关联设备" + link_device + "未找到对应设备工单");
|
||||
}
|
||||
if (order.getIs_needmove().equals("0")) {
|
||||
|
||||
if (StrUtil.isNotEmpty(order.getIs_needmove()) && order.getIs_needmove().equals("0")) {
|
||||
logServer.deviceLogToacs(this.device_code, "", "", device_code + ":关联设备" + link_device + "工单,不需要agv搬运");
|
||||
return false;
|
||||
}
|
||||
@@ -562,8 +561,9 @@ public class HailiangPackerStationDeviceDriver extends AbstractOpcDeviceDriver i
|
||||
if (num != 0) {
|
||||
continue;
|
||||
}
|
||||
String material = hailiangEngravingCacheDeviceDriver.getMaterial();
|
||||
String material = route_link_device.getMaterial_type();
|
||||
if (StrUtil.isEmpty(material)) {
|
||||
logServer.deviceLogToacs(this.device_code, "", "", hailiangEngravingCacheDeviceDriver.getDevice_code() + ":缓存位物料为空");
|
||||
continue;
|
||||
}
|
||||
if (material.equals(cpbh)) {
|
||||
|
||||
@@ -28,9 +28,19 @@ public class AutoCleanUpLogs {
|
||||
|
||||
public void run() throws Exception {
|
||||
try {
|
||||
Date now = DateUtil.parse(DateUtil.now());
|
||||
DateTime bzdate = DateUtil.offsetDay(now, -5);
|
||||
String formatbz = DateUtil.formatDateTime(bzdate);
|
||||
Query bzquery = new Query().addCriteria(Criteria.where("create_time").lte(formatbz));
|
||||
System.out.println("BZ01设备日志开始清除---------------------");
|
||||
mongoTemplate.remove(bzquery,"BZ01");
|
||||
System.out.println("BZ01设备日志清除成功---------------------");
|
||||
|
||||
System.out.println("BZ02设备日志开始清除---------------------");
|
||||
mongoTemplate.remove(bzquery,"BZ02");
|
||||
System.out.println("BZ02设备日志清除成功---------------------");
|
||||
WQLObject wo = WQLObject.getWQLObject("acs_device");
|
||||
JSONArray array = wo.query("1=1","device_code").getResultJSONArray(0);
|
||||
Date now = DateUtil.parse(DateUtil.now());
|
||||
DateTime dateTime = DateUtil.offsetDay(now, -15);
|
||||
String formatDateTime = DateUtil.formatDateTime(dateTime);
|
||||
Query query = new Query().addCriteria(Criteria.where("create_time").lte(formatDateTime));
|
||||
@@ -38,6 +48,9 @@ public class AutoCleanUpLogs {
|
||||
for (int i = 0; i < array.size(); i++) {
|
||||
JSONObject jsonObject = array.getJSONObject(i);
|
||||
String device_code = jsonObject.getString("device_code");
|
||||
if (device_code.equals("BZ01") || device_code.equals("BZ02")){
|
||||
continue;
|
||||
}
|
||||
mongoTemplate.remove(query,device_code);
|
||||
System.out.println(device_code+"设备日志清除成功---------------------");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user