rev:接口

This commit is contained in:
2026-01-16 10:09:49 +08:00
parent ead6b83e2c
commit 48ff85d0ca
4 changed files with 14 additions and 7 deletions

View File

@@ -44,7 +44,7 @@ public class AcsToMesServiceImpl implements AcsToMesService {
@Override @Override
public HttpResponse taskFeedback(JSONObject whereJson) { public HttpResponse taskFeedback(JSONObject whereJson) {
//TODO:改成中鼎 //TODO:改成中鼎
String wmsUrl = "10.10.188.151:8098"; String wmsUrl = paramService.findByCode("mes_url").getValue();
AddressDto addressDto = addressService.findByCode("feedMesAgvTaskStatus"); AddressDto addressDto = addressService.findByCode("feedMesAgvTaskStatus");
String methods_url = addressDto.getMethods_url(); String methods_url = addressDto.getMethods_url();
String url = wmsUrl + methods_url; String url = wmsUrl + methods_url;
@@ -66,7 +66,7 @@ public class AcsToMesServiceImpl implements AcsToMesService {
@Override @Override
public HttpResponse taskDeprecate(JSONObject whereJson) { public HttpResponse taskDeprecate(JSONObject whereJson) {
String wmsUrl = "10.10.188.151:8098"; String wmsUrl = paramService.findByCode("mes_url").getValue();
AddressDto addressDto = addressService.findByCode("acsCancelBack"); AddressDto addressDto = addressService.findByCode("acsCancelBack");
String methods_url = addressDto.getMethods_url(); String methods_url = addressDto.getMethods_url();
String url = wmsUrl + methods_url; String url = wmsUrl + methods_url;
@@ -88,7 +88,7 @@ public class AcsToMesServiceImpl implements AcsToMesService {
@Override @Override
public HttpResponse deviceStatusUpdate(JSONObject whereJson) { public HttpResponse deviceStatusUpdate(JSONObject whereJson) {
String wmsUrl = "10.10.188.151:8098"; String wmsUrl = paramService.findByCode("mes_url").getValue();
AddressDto addressDto = addressService.findByCode("deviceStatusUpdate"); AddressDto addressDto = addressService.findByCode("deviceStatusUpdate");
String methods_url = addressDto.getMethods_url(); String methods_url = addressDto.getMethods_url();
String url = wmsUrl + methods_url; String url = wmsUrl + methods_url;

View File

@@ -45,7 +45,8 @@ public class AcsToZDWmsServiceImpl implements AcsToZDWmsService {
@Override @Override
public HttpResponse taskFeedback(JSONObject whereJson) { public HttpResponse taskFeedback(JSONObject whereJson) {
//TODO:改成中鼎 //TODO:改成中鼎
String wmsUrl = "172.30.15.32:30010"; //String wmsUrl = "172.30.15.32:30010";
String wmsUrl = paramService.findByCode("wms_url").getValue();
AddressDto addressDto = addressService.findByCode("feedZdAgvTaskStatus"); AddressDto addressDto = addressService.findByCode("feedZdAgvTaskStatus");
String methods_url = addressDto.getMethods_url(); String methods_url = addressDto.getMethods_url();
String url = wmsUrl + methods_url; String url = wmsUrl + methods_url;
@@ -67,7 +68,7 @@ public class AcsToZDWmsServiceImpl implements AcsToZDWmsService {
@Override @Override
public HttpResponse taskDeprecate(JSONObject whereJson) { public HttpResponse taskDeprecate(JSONObject whereJson) {
String wmsUrl = "172.30.15.32:30010"; String wmsUrl = paramService.findByCode("wms_url").getValue();
AddressDto addressDto = addressService.findByCode("acsCancelBack"); AddressDto addressDto = addressService.findByCode("acsCancelBack");
String methods_url = addressDto.getMethods_url(); String methods_url = addressDto.getMethods_url();
String url = wmsUrl + methods_url; String url = wmsUrl + methods_url;
@@ -89,7 +90,7 @@ public class AcsToZDWmsServiceImpl implements AcsToZDWmsService {
@Override @Override
public HttpResponse deviceStatusUpdate(JSONObject whereJson) { public HttpResponse deviceStatusUpdate(JSONObject whereJson) {
String wmsUrl = "172.30.15.32:30010"; String wmsUrl = paramService.findByCode("wms_url").getValue();
AddressDto addressDto = addressService.findByCode("deviceStatusUpdate"); AddressDto addressDto = addressService.findByCode("deviceStatusUpdate");
String methods_url = addressDto.getMethods_url(); String methods_url = addressDto.getMethods_url();
String url = wmsUrl + methods_url; String url = wmsUrl + methods_url;

View File

@@ -92,6 +92,8 @@ public class TaskServiceImpl implements TaskService, ApplicationAutoInitial {
InstructionService instructionService; InstructionService instructionService;
@Autowired @Autowired
StorageCellService storageCellService; StorageCellService storageCellService;
@Autowired
private TaskService taskService;
@Override @Override
public void autoInitial() throws Exception { public void autoInitial() throws Exception {
@@ -1334,6 +1336,10 @@ public class TaskServiceImpl implements TaskService, ApplicationAutoInitial {
} catch (Exception e) { } catch (Exception e) {
acsTask.setRemark(e.getMessage()); acsTask.setRemark(e.getMessage());
} }
if (acsTask.getTask_status().equals("0")){
acsTask.setTask_status("1");
taskService.update(acsTask);
}
} }
@Override @Override

View File

@@ -81,7 +81,7 @@ public class AutoCreateInst {
} }
String start_point = acsTask.getStart_device_code(); String start_point = acsTask.getStart_device_code();
Device device = appService.findDeviceByCode(start_point); Device device = appService.findDeviceByCode(start_point);
if (StrUtil.equals(acsTask.getTask_type(), "1") && device.getDeviceDriver() instanceof StandardInspectSiteDeviceDriver) { if (StrUtil.equals(acsTask.getTask_type(), "1") && device != null &&device.getDeviceDriver() instanceof StandardInspectSiteDeviceDriver) {
List<String> deviceCodes = ((StandardInspectSiteDeviceDriver) device.getDeviceDriver()).getExtraDeviceCodes("link_device_code"); List<String> deviceCodes = ((StandardInspectSiteDeviceDriver) device.getDeviceDriver()).getExtraDeviceCodes("link_device_code");
if (ObjectUtil.isNotEmpty(deviceCodes)) { if (ObjectUtil.isNotEmpty(deviceCodes)) {
String linkDeviceCode = deviceCodes.get(0); String linkDeviceCode = deviceCodes.get(0);