回传信息
This commit is contained in:
@@ -58,6 +58,7 @@ public class MonitoringThread implements Runnable {
|
||||
param.setTaskNo(msgDdj.getRwh() + "");
|
||||
param.setDeviceId(String.valueOf(msgDdj.getId()));
|
||||
param.setDeviceType("DDJ");
|
||||
param.setFault(msgDdj.getSbzt() + "");
|
||||
param.setJobId("0");
|
||||
List<BasFaultRecord> basFaultRecords = basFaultRecordService.selectBasFaultRecordList(param);
|
||||
if (CollUtil.isEmpty(basFaultRecords)) {
|
||||
@@ -76,9 +77,9 @@ public class MonitoringThread implements Runnable {
|
||||
}
|
||||
if (msgDdj.getSbzt() < 1000 && msgDdj.getCzfs() == 5){
|
||||
BasFaultRecord param = new BasFaultRecord();
|
||||
param.setTaskNo(msgDdj.getRwh() + "");
|
||||
param.setDeviceId(String.valueOf(msgDdj.getId()));
|
||||
param.setDeviceType("DDJ");
|
||||
param.setJobId("0");
|
||||
List<BasFaultRecord> basFaultRecords = basFaultRecordService.selectBasFaultRecordList(param);
|
||||
if (CollUtil.isNotEmpty(basFaultRecords)) {
|
||||
BasFaultRecord faultRecord = basFaultRecords.get(0);
|
||||
|
||||
@@ -125,14 +125,8 @@ public class Floor2RoadWaySsjThread implements Runnable {
|
||||
|
||||
mydoJob.setExecutionPhase(TASK_EP_DDJ);
|
||||
mydoJobService.updateMydoJob(mydoJob);
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -109,15 +109,12 @@ public class LineSsjThread implements Runnable {
|
||||
if (!mydoJobs.isEmpty()) {
|
||||
//永远有且只有一条
|
||||
mydoJob = mydoJobs.get(0);
|
||||
|
||||
int i = writeToSsj(SsjDevice.getPlcDbWriteAddress(), mydoJob.getTaskNo(), 1, 1);
|
||||
if (i == 1) {
|
||||
mydoJob.setExecutionPhase(TASK_EP_LINE_SSJ);
|
||||
mydoJobService.updateMydoJob(mydoJob);
|
||||
log.info("G1005产线输送机下发任务号成功:" + mydoJob.getTaskNo());
|
||||
}
|
||||
|
||||
|
||||
} else {
|
||||
|
||||
//请求wms生成入库作业
|
||||
@@ -152,13 +149,8 @@ public class LineSsjThread implements Runnable {
|
||||
//7是报工单失败,不处理
|
||||
if(!"7".equals(Integer.parseInt(ajaxResult.get("code").toString()))){
|
||||
createMoveToPort(SsjDevice);
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -27,7 +27,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectDeviceSsjVo">
|
||||
select id, device_code , name , type, plc_db_read_address, is_active, create_time, plc_db_write_address, rkqq, kx, dw, tray_code, task_no,exception,tray_size,allow_put,ip_address , port from device_ssj
|
||||
select id, device_code , name , type, plc_db_read_address, is_active, create_time, plc_db_write_address,
|
||||
rkqq, kx, dw, tray_code, task_no,exception,tray_size,allow_put,ip_address , port from device_ssj
|
||||
</sql>
|
||||
|
||||
<select id="selectDeviceSsjList" parameterType="DeviceSsj" resultMap="DeviceSsjResult">
|
||||
|
||||
@@ -60,6 +60,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
and entrance_id in
|
||||
<foreach item="item" index="index" collection="epList" separator="," open="(" close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
Reference in New Issue
Block a user