rev 优化驱动
This commit is contained in:
@@ -933,6 +933,10 @@ public class DeviceServiceImpl implements DeviceService, ApplicationAutoInitial
|
||||
wo.insert(param);
|
||||
}
|
||||
}
|
||||
|
||||
deviceAppService.removeDevice(device_code);
|
||||
|
||||
deviceAppService.addDevice(device_code);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
package org.nl.acs.device_driver;
|
||||
|
||||
import cn.hutool.core.util.ObjectUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import org.nl.acs.opc.Device;
|
||||
|
||||
@@ -37,4 +38,15 @@ public interface DeviceDriver {
|
||||
return devicesList;
|
||||
}
|
||||
|
||||
default String getModeName(String mode){
|
||||
if(StrUtil.equals("0",mode)){
|
||||
mode = "脱机";
|
||||
} else if (StrUtil.equals("2",mode)) {
|
||||
mode = "联机";
|
||||
} else {
|
||||
mode = RequestMethodEnum.getName(mode);
|
||||
}
|
||||
return ObjectUtil.isEmpty(mode)? "未定义":mode;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -118,7 +118,7 @@ public enum RequestMethodEnum {
|
||||
|
||||
public static String getName(String code) {
|
||||
for (RequestMethodEnum c : RequestMethodEnum.values()) {
|
||||
if (c.code == code) {
|
||||
if ( StrUtil.equals(c.code,code)) {
|
||||
return c.name;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -485,7 +485,7 @@ public class LnshStationDeviceDriver extends AbstractOpcDeviceDriver implements
|
||||
|
||||
JSONObject jo = new JSONObject();
|
||||
jo.put("device_name", this.getDevice().getDevice_name());
|
||||
jo.put("mode", mode);
|
||||
jo.put("mode", getModeName(this.getDevice().getExtraValue().get(mode).toString()));
|
||||
jo.put("move", move);
|
||||
jo.put("action", action);
|
||||
jo.put("io_action", io_action);
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
package org.nl.acs.ext.wms.data.WmstoAcsData.createOrder;
|
||||
|
||||
import lombok.Data;
|
||||
import org.nl.acs.ext.wms.data.BaseRequest;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
public class CreateOrderRequest extends BaseRequest {
|
||||
|
||||
/**
|
||||
* 任务数组
|
||||
*/
|
||||
private List<OrderDto> list = null;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
package org.nl.acs.ext.wms.data.WmstoAcsData.createOrder;
|
||||
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
import lombok.Data;
|
||||
import org.nl.acs.ext.wms.data.BaseResponse;
|
||||
|
||||
@Data
|
||||
public class CreateOrderResponse extends BaseResponse {
|
||||
|
||||
private JSONArray errArr = new JSONArray();
|
||||
|
||||
}
|
||||
@@ -0,0 +1,31 @@
|
||||
package org.nl.acs.ext.wms.data.WmstoAcsData.createOrder;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
@Data
|
||||
public class OrderDto {
|
||||
|
||||
private String workorder_code; // 工单编码
|
||||
private String device_code; // 设备编码
|
||||
private String material_code; // 半成品物料编码 - 工单物料编码
|
||||
private String product_code; // 产品代号 - 成品
|
||||
private String formula; // 配方-泥料
|
||||
private String brick_code; // 砖型编码
|
||||
private String plan_qty; // 计划数量
|
||||
private String a; // a边
|
||||
private String b; //
|
||||
private String h;
|
||||
private String w;
|
||||
private String size_error; // 尺寸允许误差
|
||||
private String single_weight; // 单重允许误差
|
||||
private String drawing_address; // 图纸地址
|
||||
private String standard_size_height1; // 标准尺寸1
|
||||
private String standard_size_height2; // 标准尺寸2
|
||||
private String standard_size_height3; // 标准尺寸3
|
||||
private String standard_size_height4; // 标准尺寸4
|
||||
private String standard_weight; // 标准重量
|
||||
private String detection_error; // 检测误差值
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -49,7 +49,7 @@ public class WmsToAcsController {
|
||||
@PostMapping("/order")
|
||||
@Log("接收WMS排产单")
|
||||
@ApiOperation("接收WMS排产单")
|
||||
public ResponseEntity<Object> createOrder(@RequestBody String whereJson) throws Exception {
|
||||
public ResponseEntity<Object> createOrder(@RequestBody JSONObject whereJson) throws Exception {
|
||||
return new ResponseEntity<>(wmstoacsService.createOrder(whereJson), HttpStatus.OK);
|
||||
}
|
||||
|
||||
|
||||
@@ -30,7 +30,7 @@ public interface WmsToAcsService {
|
||||
* @param jsonObject 条件
|
||||
* @return Map<String, Object>
|
||||
*/
|
||||
Map<String, Object> createOrder(String jsonObject) throws Exception;
|
||||
JSONObject createOrder(JSONObject jsonObject) throws Exception;
|
||||
|
||||
/**
|
||||
* 修改设置有无货属性
|
||||
|
||||
@@ -31,6 +31,9 @@ import org.nl.acs.device_driver.lnsh.lnsh_split_manipulator.LnshSplitManipulator
|
||||
import org.nl.acs.device_driver.lnsh.lnsh_station.LnshStationDeviceDriver;
|
||||
import org.nl.acs.device_driver.standard_autodoor.StandardAutodoorDeviceDriver;
|
||||
import org.nl.acs.ext.wms.data.AcsToWmsData.grab_place_station.GrabPlaceStationResponse;
|
||||
import org.nl.acs.ext.wms.data.WmstoAcsData.createOrder.CreateOrderRequest;
|
||||
import org.nl.acs.ext.wms.data.WmstoAcsData.createOrder.CreateOrderResponse;
|
||||
import org.nl.acs.ext.wms.data.WmstoAcsData.createOrder.OrderDto;
|
||||
import org.nl.acs.ext.wms.data.WmstoAcsData.createTask.CreateTaskRequest;
|
||||
import org.nl.acs.ext.wms.data.WmstoAcsData.createTask.CreateTaskResponse;
|
||||
import org.nl.acs.ext.wms.data.WmstoAcsData.putAction.PutActionRequest;
|
||||
@@ -191,12 +194,17 @@ public class WmsToAcsServiceImpl implements WmsToAcsService {
|
||||
continue;
|
||||
}
|
||||
|
||||
// if (!StrUtil.isEmpty(vehicle_code) && !"0000".equals(vehicle_code)) {
|
||||
// TaskDto vehicle_dto = TaskService.findByContainer(vehicle_code);
|
||||
// if (vehicle_dto != null) {
|
||||
// throw new WDKException("已存在该载具号的任务!");
|
||||
// }
|
||||
// }
|
||||
if (!StrUtil.isEmpty(vehicle_code)) {
|
||||
TaskDto vehicle_dto = TaskService.findByContainer(vehicle_code);
|
||||
if (vehicle_dto != null) {
|
||||
JSONObject json = new JSONObject();
|
||||
json.put("task_code", task_code);
|
||||
json.put("ext_task_id", ext_task_uuid);
|
||||
json.put("message", "已存在该载具号的任务");
|
||||
errArr.add(json);
|
||||
continue;
|
||||
}
|
||||
}
|
||||
JSONObject jo = new JSONObject();
|
||||
jo.put("task_code", task_code);
|
||||
jo.put("ext_task_uuid", ext_task_uuid);
|
||||
@@ -316,31 +324,58 @@ public class WmsToAcsServiceImpl implements WmsToAcsService {
|
||||
}
|
||||
|
||||
@Override
|
||||
public Map<String, Object> createOrder(String param) throws Exception {
|
||||
JSONArray orders = JSONArray.parseArray(param);
|
||||
log.info("createOrder - 请求参数 {}", orders.toString());
|
||||
public JSONObject createOrder(JSONObject param) throws Exception {
|
||||
try{
|
||||
MDC.put(log_file_type, log_type);
|
||||
CreateOrderRequest orders = JSON.toJavaObject(param, CreateOrderRequest.class);
|
||||
CreateOrderResponse resp = new CreateOrderResponse();
|
||||
String request_no = orders.getRequestNo();
|
||||
JSONArray errArr = new JSONArray();
|
||||
log.info("CreateOrderRequest - 请求参数 {}", orders.toString());
|
||||
|
||||
for (int i = 0; i < orders.size(); i++) {
|
||||
for (int i = 0; i < orders.getList().size(); i++) {
|
||||
Boolean is_flag = false;
|
||||
|
||||
JSONObject json = orders.getJSONObject(i);
|
||||
String producetask_code = json.getString("workorder_code");
|
||||
String device_code = json.getString("device_code");
|
||||
String material_code = json.getString("material_code");
|
||||
String qty = json.getString("plan_qty");
|
||||
String product_code = json.getString("product_code");
|
||||
String AlongSide = json.getString("a");
|
||||
String BshortSide = json.getString("b");
|
||||
String Htrapezoidal = json.getString("h");
|
||||
String Wthickness = json.getString("w");
|
||||
OrderDto orderDto = orders.getList().get(i);
|
||||
String produce_code = orderDto.getProduct_code();
|
||||
String device_code = orderDto.getDevice_code();
|
||||
String material_code = orderDto.getMaterial_code();
|
||||
String qty = orderDto.getPlan_qty();
|
||||
String product_code = orderDto.getProduct_code();
|
||||
String AlongSide = orderDto.getA();
|
||||
String BshortSide = orderDto.getB();
|
||||
String Htrapezoidal = orderDto.getH();
|
||||
String Wthickness = orderDto.getW();
|
||||
String formula = orderDto.getFormula();
|
||||
String brick_code = orderDto.getBrick_code();
|
||||
String size_error = orderDto.getSize_error();
|
||||
String single_weight = orderDto.getSingle_weight();
|
||||
String drawing_address = orderDto.getDrawing_address();
|
||||
String standard_size_height1 = orderDto.getStandard_size_height1();
|
||||
String standard_size_height2 = orderDto.getStandard_size_height2();
|
||||
String standard_size_height3 = orderDto.getStandard_size_height3();
|
||||
String standard_size_height4 = orderDto.getStandard_size_height4();
|
||||
String standard_weight = orderDto.getStandard_weight();
|
||||
String detection_error = orderDto.getDetection_error();
|
||||
|
||||
if (StrUtil.isEmpty(producetask_code)) {
|
||||
throw new BadRequestException("工单编码不能为空!");
|
||||
|
||||
if (StrUtil.isEmpty(produce_code)) {
|
||||
JSONObject json = new JSONObject();
|
||||
json.put("produce_code", produce_code);
|
||||
json.put("devicie_code", device_code);
|
||||
json.put("message","工单编码不能为空");
|
||||
errArr.add(json);
|
||||
continue;
|
||||
}
|
||||
|
||||
Device device = DeviceAppService.findDeviceByCode(device_code);
|
||||
if (ObjectUtil.isEmpty(device)) {
|
||||
throw new Exception("未找到对应设备:" + device_code);
|
||||
JSONObject json = new JSONObject();
|
||||
json.put("produce_code", produce_code);
|
||||
json.put("devicie_code", device_code);
|
||||
json.put("message","未找到对应设备");
|
||||
errArr.add(json);
|
||||
continue;
|
||||
}
|
||||
|
||||
LnshMixingMillDeviceDriver lnshMixingMillDeviceDriver;
|
||||
@@ -350,36 +385,62 @@ public class WmsToAcsServiceImpl implements WmsToAcsService {
|
||||
if (device.getDeviceDriver() instanceof LnshMixingMillDeviceDriver) {
|
||||
lnshMixingMillDeviceDriver = (LnshMixingMillDeviceDriver) device.getDeviceDriver();
|
||||
if (lnshMixingMillDeviceDriver.getMode() == 0) {
|
||||
throw new BadRequestException("设备未联机,下发失败!");
|
||||
JSONObject json = new JSONObject();
|
||||
json.put("produce_code", produce_code);
|
||||
json.put("devicie_code", device_code);
|
||||
json.put("message","设备未联机");
|
||||
errArr.add(json);
|
||||
continue;
|
||||
}
|
||||
if (StrUtil.isEmpty(qty)) {
|
||||
throw new BadRequestException("重量不能为空!");
|
||||
JSONObject json = new JSONObject();
|
||||
json.put("produce_code", produce_code);
|
||||
json.put("devicie_code", device_code);
|
||||
json.put("message","重量不能为空");
|
||||
errArr.add(json);
|
||||
continue;
|
||||
}
|
||||
if (StrUtil.isEmpty(material_code)) {
|
||||
throw new BadRequestException("物料编码不能为空!");
|
||||
JSONObject json = new JSONObject();
|
||||
json.put("produce_code", produce_code);
|
||||
json.put("devicie_code", device_code);
|
||||
json.put("message","物料编号不能为空");
|
||||
errArr.add(json);
|
||||
continue;
|
||||
}
|
||||
lnshMixingMillDeviceDriver.writing("to_order_No", producetask_code);
|
||||
lnshMixingMillDeviceDriver.writing("to_order_No", produce_code);
|
||||
lnshMixingMillDeviceDriver.writing("to_weight", qty);
|
||||
lnshMixingMillDeviceDriver.writing("to_material_code", material_code);
|
||||
lnshMixingMillDeviceDriver.writing("to_order_No", producetask_code);
|
||||
lnshMixingMillDeviceDriver.writing("to_weight", qty);
|
||||
lnshMixingMillDeviceDriver.writing("to_material_code", material_code);
|
||||
lnshMixingMillDeviceDriver.writing(100);
|
||||
lnshMixingMillDeviceDriver.writing(100);
|
||||
is_flag = true;
|
||||
}
|
||||
if (device.getDeviceDriver() instanceof LnshPressDeviceDriver) {
|
||||
lnshPressDeviceDriver = (LnshPressDeviceDriver) device.getDeviceDriver();
|
||||
if (lnshPressDeviceDriver.getMode() == 0) {
|
||||
throw new BadRequestException("设备未联机,下发失败!");
|
||||
JSONObject json = new JSONObject();
|
||||
json.put("produce_code", produce_code);
|
||||
json.put("devicie_code", device_code);
|
||||
json.put("message","设备未联机");
|
||||
errArr.add(json);
|
||||
continue;
|
||||
}
|
||||
if (StrUtil.isEmpty(qty)) {
|
||||
throw new BadRequestException("数量不能为空!");
|
||||
JSONObject json = new JSONObject();
|
||||
json.put("produce_code", produce_code);
|
||||
json.put("devicie_code", device_code);
|
||||
json.put("message","重量不能为空");
|
||||
errArr.add(json);
|
||||
continue;
|
||||
}
|
||||
if (StrUtil.isEmpty(material_code)) {
|
||||
throw new BadRequestException("物料编码不能为空!");
|
||||
JSONObject json = new JSONObject();
|
||||
json.put("produce_code", produce_code);
|
||||
json.put("devicie_code", device_code);
|
||||
json.put("message","物料编号不能为空");
|
||||
errArr.add(json);
|
||||
continue;
|
||||
}
|
||||
lnshPressDeviceDriver.writing("to_order_No", producetask_code);
|
||||
lnshPressDeviceDriver.writing("to_order_No", produce_code);
|
||||
lnshPressDeviceDriver.writing("to_qty", qty);
|
||||
lnshPressDeviceDriver.writing("to_material_code", material_code);
|
||||
lnshPressDeviceDriver.writing("to_product_code", product_code);
|
||||
@@ -387,59 +448,83 @@ public class WmsToAcsServiceImpl implements WmsToAcsService {
|
||||
lnshPressDeviceDriver.writing("to_BshortSide", BshortSide);
|
||||
lnshPressDeviceDriver.writing("to_Htrapezoidal", Htrapezoidal);
|
||||
lnshPressDeviceDriver.writing("to_Wthickness", Wthickness);
|
||||
lnshPressDeviceDriver.writing("to_order_No", producetask_code);
|
||||
lnshPressDeviceDriver.writing("to_qty", qty);
|
||||
lnshPressDeviceDriver.writing("to_material_code", material_code);
|
||||
lnshPressDeviceDriver.writing("to_product_code", product_code);
|
||||
lnshPressDeviceDriver.writing("to_AlongSide", AlongSide);
|
||||
lnshPressDeviceDriver.writing("to_BshortSide", BshortSide);
|
||||
lnshPressDeviceDriver.writing("to_Htrapezoidal", Htrapezoidal);
|
||||
lnshPressDeviceDriver.writing("to_Wthickness", Wthickness);
|
||||
lnshPressDeviceDriver.writing(100);
|
||||
lnshPressDeviceDriver.writing("to_brick_code", brick_code);
|
||||
lnshPressDeviceDriver.writing("to_formula", formula);
|
||||
lnshPressDeviceDriver.writing("to_size_error", size_error);
|
||||
lnshPressDeviceDriver.writing("to_single_weight", single_weight);
|
||||
lnshPressDeviceDriver.writing("to_drawing_address", drawing_address);
|
||||
lnshPressDeviceDriver.writing("to_standard_weight", standard_weight);
|
||||
lnshPressDeviceDriver.writing("to_detection_error", detection_error);
|
||||
lnshPressDeviceDriver.writing("to_standard_size_height1", standard_size_height1);
|
||||
lnshPressDeviceDriver.writing("to_standard_size_height2", standard_size_height2);
|
||||
lnshPressDeviceDriver.writing("to_standard_size_height3", standard_size_height3);
|
||||
lnshPressDeviceDriver.writing("to_standard_size_height4", standard_size_height4);
|
||||
lnshPressDeviceDriver.writing(100);
|
||||
is_flag = true;
|
||||
}
|
||||
if (device.getDeviceDriver() instanceof LnshPackagePalletManipulatorDeviceDriver) {
|
||||
lnshPackagePalletManipulatorDeviceDriver = (LnshPackagePalletManipulatorDeviceDriver) device.getDeviceDriver();
|
||||
if (lnshPackagePalletManipulatorDeviceDriver.getMode() == 0) {
|
||||
throw new BadRequestException("设备未联机,下发失败!");
|
||||
JSONObject json = new JSONObject();
|
||||
json.put("produce_code", produce_code);
|
||||
json.put("devicie_code", device_code);
|
||||
json.put("message","设备未联机");
|
||||
errArr.add(json);
|
||||
continue;
|
||||
}
|
||||
if (StrUtil.isEmpty(qty)) {
|
||||
throw new BadRequestException("数量不能为空");
|
||||
JSONObject json = new JSONObject();
|
||||
json.put("produce_code", produce_code);
|
||||
json.put("devicie_code", device_code);
|
||||
json.put("message","重量不能为空");
|
||||
errArr.add(json);
|
||||
continue;
|
||||
}
|
||||
if (StrUtil.isEmpty(material_code)) {
|
||||
throw new BadRequestException("物料编号不能为空!");
|
||||
JSONObject json = new JSONObject();
|
||||
json.put("produce_code", produce_code);
|
||||
json.put("devicie_code", device_code);
|
||||
json.put("message","物料编号不能为空");
|
||||
errArr.add(json);
|
||||
continue;
|
||||
}
|
||||
lnshPackagePalletManipulatorDeviceDriver.writing("to_order_No", producetask_code);
|
||||
lnshPackagePalletManipulatorDeviceDriver.writing("to_order_No", produce_code);
|
||||
lnshPackagePalletManipulatorDeviceDriver.writing("to_material", material_code);
|
||||
lnshPackagePalletManipulatorDeviceDriver.writing("to_product_code", product_code);
|
||||
lnshPackagePalletManipulatorDeviceDriver.writing("to_AlongSide", AlongSide);
|
||||
lnshPackagePalletManipulatorDeviceDriver.writing("to_BshortSide", BshortSide);
|
||||
lnshPackagePalletManipulatorDeviceDriver.writing("to_Htrapezoidal", Htrapezoidal);
|
||||
lnshPackagePalletManipulatorDeviceDriver.writing("to_Wthickness", Wthickness);
|
||||
lnshPackagePalletManipulatorDeviceDriver.writing("to_order_No", producetask_code);
|
||||
lnshPackagePalletManipulatorDeviceDriver.writing("to_material", material_code);
|
||||
lnshPackagePalletManipulatorDeviceDriver.writing("to_product_code", product_code);
|
||||
lnshPackagePalletManipulatorDeviceDriver.writing("to_AlongSide", AlongSide);
|
||||
lnshPackagePalletManipulatorDeviceDriver.writing("to_BshortSide", BshortSide);
|
||||
lnshPackagePalletManipulatorDeviceDriver.writing("to_Htrapezoidal", Htrapezoidal);
|
||||
lnshPackagePalletManipulatorDeviceDriver.writing("to_Wthickness", Wthickness);
|
||||
lnshPackagePalletManipulatorDeviceDriver.writing(100);
|
||||
lnshPackagePalletManipulatorDeviceDriver.writing(100);
|
||||
is_flag = true;
|
||||
}
|
||||
if (device.getDeviceDriver() instanceof LnshSplitManipulatorDeviceDriver) {
|
||||
lnshSplitManipulatorDeviceDriver = (LnshSplitManipulatorDeviceDriver) device.getDeviceDriver();
|
||||
if (lnshSplitManipulatorDeviceDriver.getMode() == 0) {
|
||||
throw new BadRequestException("设备未联机,下发失败!");
|
||||
JSONObject json = new JSONObject();
|
||||
json.put("produce_code", produce_code);
|
||||
json.put("devicie_code", device_code);
|
||||
json.put("message","设备未联机");
|
||||
errArr.add(json);
|
||||
continue;
|
||||
}
|
||||
if (StrUtil.isEmpty(qty)) {
|
||||
throw new BadRequestException("数量不能为空");
|
||||
JSONObject json = new JSONObject();
|
||||
json.put("produce_code", produce_code);
|
||||
json.put("devicie_code", device_code);
|
||||
json.put("message","重量不能为空");
|
||||
errArr.add(json);
|
||||
continue;
|
||||
}
|
||||
if (StrUtil.isEmpty(material_code)) {
|
||||
throw new BadRequestException("物料编号不能为空!");
|
||||
JSONObject json = new JSONObject();
|
||||
json.put("produce_code", produce_code);
|
||||
json.put("devicie_code", device_code);
|
||||
json.put("message","物料编号不能为空");
|
||||
errArr.add(json);
|
||||
continue;
|
||||
}
|
||||
lnshSplitManipulatorDeviceDriver.writing("to_order_No", producetask_code);
|
||||
lnshSplitManipulatorDeviceDriver.writing("to_order_No", produce_code);
|
||||
lnshSplitManipulatorDeviceDriver.writing("to_material_qty", qty);
|
||||
lnshSplitManipulatorDeviceDriver.writing("to_material_code", material_code);
|
||||
lnshSplitManipulatorDeviceDriver.writing("to_product_code", product_code);
|
||||
@@ -447,15 +532,6 @@ public class WmsToAcsServiceImpl implements WmsToAcsService {
|
||||
lnshSplitManipulatorDeviceDriver.writing("to_BshortSide", BshortSide);
|
||||
lnshSplitManipulatorDeviceDriver.writing("to_Htrapezoidal", Htrapezoidal);
|
||||
lnshSplitManipulatorDeviceDriver.writing("to_Wthickness", Wthickness);
|
||||
lnshSplitManipulatorDeviceDriver.writing("to_order_No", producetask_code);
|
||||
lnshSplitManipulatorDeviceDriver.writing("to_material_qty", qty);
|
||||
lnshSplitManipulatorDeviceDriver.writing("to_material_code", material_code);
|
||||
lnshSplitManipulatorDeviceDriver.writing("to_product_code", product_code);
|
||||
lnshSplitManipulatorDeviceDriver.writing("to_AlongSide", AlongSide);
|
||||
lnshSplitManipulatorDeviceDriver.writing("to_BshortSide", BshortSide);
|
||||
lnshSplitManipulatorDeviceDriver.writing("to_Htrapezoidal", Htrapezoidal);
|
||||
lnshSplitManipulatorDeviceDriver.writing("to_Wthickness", Wthickness);
|
||||
lnshSplitManipulatorDeviceDriver.writing(100);
|
||||
lnshSplitManipulatorDeviceDriver.writing(100);
|
||||
is_flag = true;
|
||||
}
|
||||
@@ -478,12 +554,21 @@ public class WmsToAcsServiceImpl implements WmsToAcsService {
|
||||
|
||||
}
|
||||
|
||||
JSONObject resultJson = new JSONObject();
|
||||
resultJson.put("status", HttpStatus.OK.value());
|
||||
resultJson.put("message", "操作成功");
|
||||
resultJson.put("data", new JSONObject());
|
||||
log.info("createOrder - 返回参数 {}", resultJson.toString());
|
||||
return resultJson;
|
||||
if(errArr.size()>0){
|
||||
resp.setErrArr(errArr);
|
||||
resp.setCode(HttpStatus.BAD_REQUEST.value());
|
||||
} else {
|
||||
resp.setCode(HttpStatus.OK.value());
|
||||
}
|
||||
resp.setRequestNo(request_no);
|
||||
resp.setResponseDate(AgvUtil.getDate());
|
||||
resp.setMessage("请求成功");
|
||||
log.info("createOrder - 返回参数 {}", JSON.toJSON(resp));
|
||||
return (JSONObject) JSON.toJSON(resp);
|
||||
|
||||
} finally {
|
||||
MDC.remove(log_file_type);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user