rev:调式更新

This commit is contained in:
2024-03-13 17:07:29 +08:00
parent b5efde54cc
commit 2a9cd7b3d0
8 changed files with 28 additions and 5 deletions

View File

@@ -2016,6 +2016,11 @@ public class AcsToWmsServiceImpl implements AcsToWmsService {
point_code = inBussManageService.taskExceptional(whereJson);
}
}
if (ObjectUtil.isEmpty(point_code)) {
throw new BadRequestException("点位为空!");
}
result.put("status", HttpStatus.OK.value());
result.put("message", "下发成功!");
result.put("point_code", point_code);

View File

@@ -108,7 +108,7 @@ public class AcsTaskDto {
/**
* 任务扩展字段
*/
private String interaction_json;
private JSONObject interaction_json;
/**
* 空点位
*/

View File

@@ -32,6 +32,7 @@ import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
import java.util.HashMap;
import java.util.Map;
import java.util.Objects;
import java.util.concurrent.TimeUnit;
/**
@@ -139,8 +140,15 @@ public class TaskServiceImpl implements TaskService {
// 任务处理类
String processing_class = taskObj.getString("handle_class");
String message = "";
try {
Object obj = SpringContextHolder.getBean(Class.forName(processing_class));
Object obj = new Object();
try {
obj = SpringContextHolder.getBean(Class.forName(processing_class));
} catch (Exception e) {
Class<?> clz = Class.forName(processing_class);
obj = clz.newInstance();
}
// 调用每个任务类的method_name()强制结束方法
Method m = obj.getClass().getMethod(method_name, String.class);
JSONObject result = (JSONObject) m.invoke(obj, task_id);

View File

@@ -1,5 +1,6 @@
package org.nl.wms.st.outbill.rest;
import cn.dev33.satoken.annotation.SaIgnore;
import com.alibaba.fastjson.JSONObject;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
@@ -403,6 +404,7 @@ public class CheckOutBillController {
@PostMapping("/testBoxLash")
@Log("木箱捆扎测试")
@SaIgnore
public ResponseEntity<Object> testBoxLash(@RequestBody JSONObject whereJson) {
lashManageService.createLashTask(whereJson);
return new ResponseEntity<>(HttpStatus.OK);