Merge remote-tracking branch 'origin/master'
This commit is contained in:
@@ -357,11 +357,10 @@ public class DeviceServiceImpl extends CommonServiceImpl<DeviceMapper, Device> i
|
||||
String device_code = deviceJson.getDevice_code();
|
||||
log.debug("删除设备时候判断路由是否存在,如果存在,则不允许删除设备!");
|
||||
// JSONObject json = routeLineTab.query("device_code = '" + device_code + "' or next_device_code = '" + device_code + "'").uniqueResult(0);
|
||||
RouteLine json = new LambdaQueryChainWrapper<>(routeLineMapper)
|
||||
LambdaQueryChainWrapper<RouteLine> eq = new LambdaQueryChainWrapper<>(routeLineMapper)
|
||||
.eq(RouteLine::getDevice_code, device_code)
|
||||
.or().eq(RouteLine::getNext_device_code, device_code)
|
||||
.one();
|
||||
if (json != null) {
|
||||
.or().eq(RouteLine::getNext_device_code, device_code);
|
||||
if (eq != null && eq.count() > 0) {
|
||||
throw new BadRequestException(LangProcess.msg("device_checkRoute", device_code));
|
||||
}
|
||||
log.debug("删除舞台里面的设备!");
|
||||
|
||||
@@ -303,12 +303,13 @@ public class AgvNdcTwoDeviceDriver extends AbstractDeviceDriver implements Devic
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
if (paperTubePickSiteDeviceDriver.getMove() > 0) {
|
||||
if (paperTubePickSiteDeviceDriver.getMove() > 0 && paperTubePickSiteDeviceDriver.getAction() == 1
|
||||
&& paperTubePickSiteDeviceDriver.getError() == 0 && paperTubePickSiteDeviceDriver.getMode() == 2) {
|
||||
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0, 0, 0);
|
||||
} else {
|
||||
message = "设备号:" + device_code + "光电信号:" + paperTubePickSiteDeviceDriver.getMove() + ",动作信号:" + paperTubePickSiteDeviceDriver.getAction() + "报警信号:" + paperTubePickSiteDeviceDriver.getError() + ",指令号:" + ikey + "不满足取货条件";
|
||||
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足取货条件,指令号{}", device_code, paperTubePickSiteDeviceDriver.getMove(), paperTubePickSiteDeviceDriver.getAction()
|
||||
, paperTubePickSiteDeviceDriver.getError(), ikey);
|
||||
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},设备状态{},不满足取货条件,指令号{}", device_code, paperTubePickSiteDeviceDriver.getMove(), paperTubePickSiteDeviceDriver.getAction()
|
||||
, paperTubePickSiteDeviceDriver.getError(), paperTubePickSiteDeviceDriver.getMode(), ikey);
|
||||
}
|
||||
} else if (device.getDeviceDriver() instanceof RangingStationsDeviceDriver) {
|
||||
rangingStationsDeviceDriver = (RangingStationsDeviceDriver) device.getDeviceDriver();
|
||||
@@ -450,12 +451,13 @@ public class AgvNdcTwoDeviceDriver extends AbstractDeviceDriver implements Devic
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
if (paperTubePickSiteDeviceDriver.getMove() == 0) {
|
||||
if (paperTubePickSiteDeviceDriver.getMove() == 0 && paperTubePickSiteDeviceDriver.getAction() == 1
|
||||
&& paperTubePickSiteDeviceDriver.getError() == 0 && paperTubePickSiteDeviceDriver.getMode() == 2) {
|
||||
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0, 0, 0);
|
||||
} else {
|
||||
message = "设备号:" + device_code + "光电信号:" + paperTubePickSiteDeviceDriver.getMove() + ",动作信号:" + paperTubePickSiteDeviceDriver.getAction() + "报警信号:" + paperTubePickSiteDeviceDriver.getError() + ",指令号:" + ikey + "不满足取货条件";
|
||||
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足取货条件,指令号{}", device_code, paperTubePickSiteDeviceDriver.getMove(), paperTubePickSiteDeviceDriver.getAction()
|
||||
, paperTubePickSiteDeviceDriver.getError(), ikey);
|
||||
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},设备状态{},不满足取货完成反馈,指令号{}", device_code, paperTubePickSiteDeviceDriver.getMove(), paperTubePickSiteDeviceDriver.getAction()
|
||||
, paperTubePickSiteDeviceDriver.getError(), paperTubePickSiteDeviceDriver.getMode(), ikey);
|
||||
}
|
||||
} else if (device.getDeviceDriver() instanceof StandardInspectSiteDeviceDriver) {
|
||||
standardInspectSiteDeviceDriver = (StandardInspectSiteDeviceDriver) device.getDeviceDriver();
|
||||
@@ -571,12 +573,13 @@ public class AgvNdcTwoDeviceDriver extends AbstractDeviceDriver implements Devic
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
if (paperTubePickSiteDeviceDriver.getMove() == 1) {
|
||||
if (paperTubePickSiteDeviceDriver.getMove() == 1 && paperTubePickSiteDeviceDriver.getAction() == 1
|
||||
&& paperTubePickSiteDeviceDriver.getError() == 0 && paperTubePickSiteDeviceDriver.getMode() == 2) {
|
||||
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0, 0, 0);
|
||||
} else {
|
||||
message = "设备号:" + device_code + "光电信号:" + paperTubePickSiteDeviceDriver.getMove() + ",动作信号:" + paperTubePickSiteDeviceDriver.getAction() + "报警信号:" + paperTubePickSiteDeviceDriver.getError() + ",指令号:" + ikey + "不满足取货条件";
|
||||
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足取货条件,指令号{}", device_code, paperTubePickSiteDeviceDriver.getMove(), paperTubePickSiteDeviceDriver.getAction()
|
||||
, paperTubePickSiteDeviceDriver.getError(), ikey);
|
||||
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},设备状态{},不满足取货条件,指令号{}", device_code, paperTubePickSiteDeviceDriver.getMove(), paperTubePickSiteDeviceDriver.getAction()
|
||||
, paperTubePickSiteDeviceDriver.getError(), paperTubePickSiteDeviceDriver.getMode(), ikey);
|
||||
}
|
||||
} else if (device.getDeviceDriver() instanceof HongXiangStationDeviceDriver) {
|
||||
hongXiangStationDeviceDriver = (HongXiangStationDeviceDriver) device.getDeviceDriver();
|
||||
@@ -841,12 +844,13 @@ public class AgvNdcTwoDeviceDriver extends AbstractDeviceDriver implements Devic
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
if (paperTubePickSiteDeviceDriver.getMove() == 0) {
|
||||
if (paperTubePickSiteDeviceDriver.getMove() == 0 && paperTubePickSiteDeviceDriver.getAction() == 1
|
||||
&& paperTubePickSiteDeviceDriver.getError() == 0 && paperTubePickSiteDeviceDriver.getMode() == 2) {
|
||||
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0, 0, 0);
|
||||
} else {
|
||||
message = "设备号:" + device_code + "光电信号:" + paperTubePickSiteDeviceDriver.getMove() + ",动作信号:" + paperTubePickSiteDeviceDriver.getAction() + "报警信号:" + paperTubePickSiteDeviceDriver.getError() + ",指令号:" + ikey + "不满足取货条件";
|
||||
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足取货条件,指令号{}", device_code, paperTubePickSiteDeviceDriver.getMove(), paperTubePickSiteDeviceDriver.getAction()
|
||||
, paperTubePickSiteDeviceDriver.getError(), ikey);
|
||||
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},设备状态{},不满足放货条件,指令号{}", device_code, paperTubePickSiteDeviceDriver.getMove(), paperTubePickSiteDeviceDriver.getAction()
|
||||
, paperTubePickSiteDeviceDriver.getError(), paperTubePickSiteDeviceDriver.getMode(), ikey);
|
||||
}
|
||||
} else if (device.getDeviceDriver() instanceof ManipulatorAgvStationDeviceDriver) {
|
||||
manipulatorAgvStationDeviceDriver = (ManipulatorAgvStationDeviceDriver) device.getDeviceDriver();
|
||||
@@ -990,7 +994,7 @@ public class AgvNdcTwoDeviceDriver extends AbstractDeviceDriver implements Devic
|
||||
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0, 0, 0);
|
||||
} else {
|
||||
message = "设备号:" + device_code + "光电信号:" + hongXiangStationDeviceDriver.getMove() + ",动作信号:" + hongXiangStationDeviceDriver.getAction() + "报警信号:" + hongXiangStationDeviceDriver.getError() + ",指令号:" + ikey + "不满足取货条件";
|
||||
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足取货条件,指令号{}", device_code, hongXiangStationDeviceDriver.getMove(), hongXiangStationDeviceDriver.getAction()
|
||||
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足放货完成反馈,指令号{}", device_code, hongXiangStationDeviceDriver.getMove(), hongXiangStationDeviceDriver.getAction()
|
||||
, hongXiangStationDeviceDriver.getError(), ikey);
|
||||
}
|
||||
} else if (device.getDeviceDriver() instanceof PaperTubePickSiteDeviceDriver) {
|
||||
@@ -1000,12 +1004,13 @@ public class AgvNdcTwoDeviceDriver extends AbstractDeviceDriver implements Devic
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
if (paperTubePickSiteDeviceDriver.getMove() > 0) {
|
||||
if (paperTubePickSiteDeviceDriver.getMove() == 1 && paperTubePickSiteDeviceDriver.getAction() == 1
|
||||
&& paperTubePickSiteDeviceDriver.getError() == 0 && paperTubePickSiteDeviceDriver.getMode() == 2) {
|
||||
data = ndcAgvService.sendAgvTwoModeInst(phase, index, 0, 0, 0);
|
||||
} else {
|
||||
message = "设备号:" + device_code + "光电信号:" + paperTubePickSiteDeviceDriver.getMove() + ",动作信号:" + paperTubePickSiteDeviceDriver.getAction() + "报警信号:" + paperTubePickSiteDeviceDriver.getError() + ",指令号:" + ikey + "不满足取货条件";
|
||||
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},不满足取货条件,指令号{}", device_code, paperTubePickSiteDeviceDriver.getMove(), paperTubePickSiteDeviceDriver.getAction()
|
||||
, paperTubePickSiteDeviceDriver.getError(), ikey);
|
||||
log.info("设备{}当前光电信号{},动作信号{} ,错误信号{},设备状态{},不满足取货条件,指令号{}", device_code, paperTubePickSiteDeviceDriver.getMove(), paperTubePickSiteDeviceDriver.getAction()
|
||||
, paperTubePickSiteDeviceDriver.getError(), paperTubePickSiteDeviceDriver.getMode(), ikey);
|
||||
}
|
||||
} else if (device.getDeviceDriver() instanceof StandardInspectSiteDeviceDriver) {
|
||||
standardInspectSiteDeviceDriver = (StandardInspectSiteDeviceDriver) device.getDeviceDriver();
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
package org.nl.acs.device_driver.autodoor.standard_autodoor;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import lombok.Data;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
@@ -12,7 +13,10 @@ import org.nl.acs.log.service.DeviceExecuteLogService;
|
||||
import org.nl.acs.monitor.DeviceStageMonitor;
|
||||
import org.nl.acs.utils.ReadUtil;
|
||||
import org.nl.config.SpringContextHolder;
|
||||
import org.nl.config.lucene.service.LuceneExecuteLogService;
|
||||
import org.nl.config.lucene.service.dto.LuceneLogDto;
|
||||
import org.openscada.opc.lib.da.Server;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
@@ -27,6 +31,8 @@ import java.util.Map;
|
||||
public class StandardAutodoorDeviceDriver extends AbstractOpcDeviceDriver implements DeviceDriver, ExecutableDeviceDriver, DeviceStageMonitor {
|
||||
protected ItemProtocol itemProtocol = new ItemProtocol(this);
|
||||
DeviceExecuteLogService logServer = SpringContextHolder.getBean("deviceExecuteLogServiceImpl");
|
||||
@Autowired
|
||||
LuceneExecuteLogService luceneExecuteLogService = SpringContextHolder.getBean(LuceneExecuteLogService.class);
|
||||
|
||||
int open = 0;
|
||||
int close = 0;
|
||||
@@ -89,7 +95,12 @@ public class StandardAutodoorDeviceDriver extends AbstractOpcDeviceDriver implem
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
logServer.deviceExecuteLog(device_code, "", "", "下发电气信号设备号:" + device_code + ",下发电气:" + to_param + ",下发电气值:" + value);
|
||||
LuceneLogDto logDto = LuceneLogDto.builder()
|
||||
.device_code(device_code)
|
||||
.content("下发门信号:" + itemMap)
|
||||
.build();
|
||||
logDto.setLog_level(4);
|
||||
luceneExecuteLogService.deviceExecuteLog(logDto);
|
||||
}
|
||||
|
||||
public void writing(String param, int command) {
|
||||
|
||||
@@ -27,7 +27,7 @@ public class ItemProtocol {
|
||||
/**
|
||||
* 托盘方向
|
||||
*/
|
||||
public static String item_container_direction = "container_direction";
|
||||
public static String item_container_direction = "carrier_direction";
|
||||
|
||||
/**
|
||||
* 载具类型
|
||||
|
||||
@@ -116,8 +116,8 @@ public class BlankManipulatorDeviceDriver extends AbstractOpcDeviceDriver implem
|
||||
/**
|
||||
* 重量
|
||||
*/
|
||||
int weight = 0;
|
||||
int last_weight = 0;
|
||||
Float weight = 0.0F;
|
||||
Float last_weight = 0.0F;
|
||||
|
||||
/**
|
||||
* 条码
|
||||
@@ -243,41 +243,26 @@ public class BlankManipulatorDeviceDriver extends AbstractOpcDeviceDriver implem
|
||||
/**
|
||||
* 反馈重量
|
||||
*/
|
||||
if (mode == 3 && action == 5 && move == 1 && task > 0) {
|
||||
if (mode == 3 && action == 5 && move == 1 && task > 0 && weight > 1.0F) {
|
||||
Instruction inst2 = instructionService.findByCodeFromCache(String.valueOf(task));
|
||||
if (ObjectUtil.isNotEmpty(inst2)) {
|
||||
String taskCode = inst2.getTask_code();
|
||||
TaskDto dto = taskserver.findByCode(taskCode);
|
||||
JSONObject jo = new JSONObject();
|
||||
jo.put("task_id", dto.getTask_id());
|
||||
jo.put("task_code", dto.getTask_code());
|
||||
jo.put("task_status", dto.getTask_status());
|
||||
jo.put("productin_qty", String.valueOf(this.weight));
|
||||
jo.put("scroll_code", String.valueOf(this.barcode));
|
||||
JSONArray ja = new JSONArray();
|
||||
ja.add(jo);
|
||||
HttpResponse body = acsToWmsService.feedbackTaskStatusToWms(ja);
|
||||
if (body.getStatus() == 200) {
|
||||
message = "two_message1";
|
||||
requireSucess = true;
|
||||
if(StrUtil.isNotBlank(dto.getTask_code()) && Long.parseLong(dto.getTask_code()) > 1){
|
||||
dto.setWeight(String.valueOf(this.weight));
|
||||
taskserver.update(dto);
|
||||
LuceneLogDto logDto = LuceneLogDto.builder()
|
||||
.device_code(device_code)
|
||||
.content("反馈请求成功,响应参数:" + JSON.toJSONString(body))
|
||||
.content("表处下料,分切上料反馈LMS母卷重量:" + this.weight)
|
||||
.build();
|
||||
logDto.setLog_level(4);
|
||||
luceneExecuteLogService.deviceExecuteLog(logDto);
|
||||
Map<String, Object> map = new LinkedHashMap<>();
|
||||
map.put("to_command", "5");
|
||||
this.writing(map);
|
||||
} else {
|
||||
message = "two_message2";
|
||||
requireSucess = false;
|
||||
LuceneLogDto logDto = LuceneLogDto.builder()
|
||||
.device_code(device_code)
|
||||
.content("反馈重量以及收卷轴LMS失败...")
|
||||
.build();
|
||||
logDto.setLog_level(4);
|
||||
luceneExecuteLogService.deviceExecuteLog(logDto);
|
||||
}else{
|
||||
Map<String, Object> map = new LinkedHashMap<>();
|
||||
map.put("to_command", "5");
|
||||
this.writing(map);
|
||||
}
|
||||
} else {
|
||||
LuceneLogDto logDto = LuceneLogDto.builder()
|
||||
@@ -447,6 +432,7 @@ public class BlankManipulatorDeviceDriver extends AbstractOpcDeviceDriver implem
|
||||
map.put("to_task", instruction.getInstruction_code());
|
||||
map.put("to_target", nextAddr);
|
||||
map.put("to_command", CommonFinalParam.ONE);
|
||||
map.put("to_type", taskDto.getTruss_type());
|
||||
|
||||
if (StrUtil.isNotEmpty(startCode2)){
|
||||
Device startDevice2 = deviceAppService.findDeviceByCode(startCode2);
|
||||
@@ -534,12 +520,29 @@ public class BlankManipulatorDeviceDriver extends AbstractOpcDeviceDriver implem
|
||||
throw new BadRequestException(LangProcess.msg("device_checkAdd", nextDevice.getDevice_code()));
|
||||
|
||||
}
|
||||
try {
|
||||
instructionService.create(instdto);
|
||||
} catch (Exception e) {
|
||||
notCreateInstMessage = e.getMessage();
|
||||
LuceneLogDto logDto = LuceneLogDto.builder()
|
||||
.device_code(device_code)
|
||||
.content(LangProcess.msg("universal_message9") + e.getMessage())
|
||||
.build();
|
||||
logDto.setLog_level(2);
|
||||
luceneExecuteLogService.deviceExecuteLog(logDto);
|
||||
return false;
|
||||
}
|
||||
task.setTask_status(TaskStatusEnum.BUSY.getIndex());
|
||||
task.setUpdate_time(DateUtil.now());
|
||||
taskserver.update(task);
|
||||
|
||||
String startAddr = startDevice.getExtraValue().get("address").toString();
|
||||
String nextAddr = nextDevice.getExtraValue().get("address").toString();
|
||||
map.put("to_command", CommonFinalParam.ONE);
|
||||
map.put("to_onset", startAddr);
|
||||
map.put("to_task", instdto.getInstruction_code());
|
||||
map.put("to_target", nextAddr);
|
||||
map.put("to_type", task.getTruss_type());
|
||||
|
||||
if (StrUtil.isNotEmpty(startDeviceCode2)){
|
||||
//判断任务点位是否配置电气信号
|
||||
@@ -560,23 +563,7 @@ public class BlankManipulatorDeviceDriver extends AbstractOpcDeviceDriver implem
|
||||
map.put("to_onset2", start_addr2);
|
||||
map.put("to_target2", next_addr2);
|
||||
}
|
||||
try {
|
||||
instructionService.create(instdto);
|
||||
} catch (Exception e) {
|
||||
notCreateInstMessage = e.getMessage();
|
||||
LuceneLogDto logDto = LuceneLogDto.builder()
|
||||
.device_code(device_code)
|
||||
.content(LangProcess.msg("universal_message9") + e.getMessage())
|
||||
.build();
|
||||
logDto.setLog_level(2);
|
||||
luceneExecuteLogService.deviceExecuteLog(logDto);
|
||||
return false;
|
||||
}
|
||||
//创建指令后修改任务状态
|
||||
task.setTask_status(TaskStatusEnum.BUSY.getIndex());
|
||||
task.setUpdate_time(DateUtil.now());
|
||||
taskserver.update(task);
|
||||
|
||||
this.writing(map);
|
||||
this.setRequireSucess(true);
|
||||
notCreateInstMessage = "";
|
||||
|
||||
@@ -83,8 +83,8 @@ public class ItemProtocol {
|
||||
return this.getOpcIntegerValue(item_barcode);
|
||||
}
|
||||
|
||||
public int getWeight(){
|
||||
return this.getOpcIntegerValue(item_weight);
|
||||
public Float getWeight(){
|
||||
return this.getOpcFloatValue(item_weight);
|
||||
}
|
||||
|
||||
public int getTo_task() {
|
||||
@@ -132,6 +132,19 @@ public class ItemProtocol {
|
||||
|
||||
}
|
||||
|
||||
public float getOpcFloatValue(String protocol) {
|
||||
Float value = this.driver.getDoubleValue(protocol);
|
||||
if (value == null) {
|
||||
// log.error(this.getDriver().getDeviceCode() + ":protocol " + protocol + " 信号同步异常!");
|
||||
setIsonline(false);
|
||||
} else {
|
||||
setIsonline(true);
|
||||
return value;
|
||||
}
|
||||
return 0;
|
||||
|
||||
}
|
||||
|
||||
public String getOpcStringValue(String protocol) {
|
||||
String value = this.driver.getStringValue(protocol);
|
||||
if (StrUtil.isEmpty(value)) {
|
||||
|
||||
@@ -158,19 +158,19 @@ public class BlankingButtonDriver extends AbstractOpcDeviceDriver implements Dev
|
||||
break;
|
||||
case 9:
|
||||
// 表处下满料请求
|
||||
if (move > 0 && !requireSucess) {
|
||||
if (!requireSucess) {
|
||||
applyTakeFullVolume();
|
||||
}
|
||||
break;
|
||||
case 10:
|
||||
//表处上空轴请求
|
||||
if (move > 0 && !requireSucess) {
|
||||
if (!requireSucess) {
|
||||
applyTakeEmptyShaft();
|
||||
}
|
||||
break;
|
||||
case 11:
|
||||
// 取消任务
|
||||
if (move > 0 && !requireSucess) {
|
||||
if (!requireSucess) {
|
||||
cancelTask();
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -25,9 +25,7 @@ import java.util.Map;
|
||||
**/
|
||||
@RestController
|
||||
@RequiredArgsConstructor
|
||||
|
||||
@RequestMapping("/api/deviceErrorLog")
|
||||
@Slf4j
|
||||
public class DeviceErrorLogController {
|
||||
|
||||
private final DeviceErrorLogService acsDeviceErrorLogService;
|
||||
|
||||
@@ -415,7 +415,8 @@ public class DeviceOpcProtocolRunable implements Runnable, DataCallback, ServerC
|
||||
Object obj = accessor_value.getValue(relate);
|
||||
sb.append("key:" + relate + "value:" + obj + ";");
|
||||
}
|
||||
if (!itemDto.getItem_code().endsWith("heartbeat") && !itemDto.getItem_code().endsWith("time") && !itemDto.getItem_code().endsWith("consumption")) {
|
||||
if (!itemDto.getItem_code().endsWith("heartbeat") && !itemDto.getItem_code().endsWith("time") && !itemDto.getItem_code().endsWith("consumption")
|
||||
&& !itemDto.getItem_code().endsWith("x") && !itemDto.getItem_code().endsWith("y")) {
|
||||
// 存在上次点位值为null情况 则不记录日志
|
||||
if(!(his instanceof Float) && !(value instanceof Float)){
|
||||
LuceneLogDto luceneLogDto = new LuceneLogDto(itemDto.getOpc_server_code(), itemDto.getOpc_plc_code(),4, itemDto.getDevice_code(), itemDto.getItem_code().substring(itemDto.getItem_code().lastIndexOf(".") + 1),
|
||||
@@ -428,7 +429,8 @@ public class DeviceOpcProtocolRunable implements Runnable, DataCallback, ServerC
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if (!itemDto.getItem_code().endsWith("heartbeat") && !itemDto.getItem_code().endsWith("time") && !itemDto.getItem_code().endsWith("consumption")) {
|
||||
if (!itemDto.getItem_code().endsWith("heartbeat") && !itemDto.getItem_code().endsWith("time") && !itemDto.getItem_code().endsWith("consumption")
|
||||
&& !itemDto.getItem_code().endsWith("x") && !itemDto.getItem_code().endsWith("y")) {
|
||||
if(!(his instanceof Float) && !(value instanceof Float)){
|
||||
LuceneLogDto luceneLogDto = new LuceneLogDto(itemDto.getOpc_server_code(), itemDto.getOpc_plc_code(),4, itemDto.getDevice_code(), itemDto.getItem_code().substring(itemDto.getItem_code().lastIndexOf(".") + 1),
|
||||
String.valueOf(his), String.valueOf(value));
|
||||
|
||||
@@ -36,7 +36,6 @@ public class UdwManagerController {
|
||||
// }
|
||||
|
||||
@GetMapping
|
||||
|
||||
@SaIgnore
|
||||
//@PreAuthorize("@el.check('device:list')")
|
||||
public ResponseEntity<Object> query(@RequestParam Map whereJson, Pageable page) {
|
||||
|
||||
Reference in New Issue
Block a user