代码更新
This commit is contained in:
@@ -293,7 +293,7 @@ public class RawFoilServiceImpl implements RawFoilService {
|
||||
|
||||
JSONObject raw_jo = whereJson.getJSONObject("raw_jo");
|
||||
|
||||
JSONObject jsonCool = coolTab.query("mfg_order_name = '" + raw_jo.getString("mfg_order_name") + "'").uniqueResult(0);
|
||||
JSONObject jsonCool = coolTab.query("workorder_id = '" + raw_jo.getString("workorder_id") + "'").uniqueResult(0);
|
||||
|
||||
jsonCool.put("status", "09");
|
||||
jsonCool.put("realend_time", DateUtil.now());
|
||||
|
||||
@@ -3,6 +3,8 @@ package org.nl.wms.sch.tasks;
|
||||
import cn.hutool.core.date.DateUnit;
|
||||
import cn.hutool.core.date.DateUtil;
|
||||
import cn.hutool.core.util.IdUtil;
|
||||
import cn.hutool.core.util.NumberUtil;
|
||||
import cn.hutool.core.util.ObjectUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
@@ -85,6 +87,16 @@ public class OutTask extends AbstractAcsTask {
|
||||
Long currentUserId = SecurityUtils.getCurrentUserId();
|
||||
String currentUsername = SecurityUtils.getCurrentUsername();
|
||||
|
||||
// 判断此任务是否有任务组
|
||||
String task_group_id = jsonTask.getString("task_group_id");
|
||||
if (ObjectUtil.isNotEmpty(task_group_id)) {
|
||||
// 上一个任务组顺序号
|
||||
String sort_seq_last = NumberUtil.sub(jsonTask.getString("sort_seq"), "1").toString();
|
||||
|
||||
JSONObject jsonTaskLast = taskTab.query("task_group_id = '" + task_group_id + "' and sort_seq = '" + sort_seq_last + "' and task_status <> '07'").uniqueResult(0);
|
||||
if (ObjectUtil.isNotEmpty(jsonTaskLast)) throw new BadRequestException("请先完成"+jsonTaskLast.getString("task_code")+"的任务!");
|
||||
}
|
||||
|
||||
// 更改任务状态为完成
|
||||
// jsonTask.put("task_status", TaskStatusEnum.FINISHED.getCode());
|
||||
jsonTask.put("update_optid", currentUserId);
|
||||
|
||||
@@ -200,13 +200,15 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
Long currentUserId = SecurityUtils.getCurrentUserId();
|
||||
String nickName = SecurityUtils.getCurrentNickName();
|
||||
String user = map.getString("user");
|
||||
if (user.equals("mes")) {
|
||||
currentUserId = Long.parseLong(2 + "");
|
||||
nickName = "mes用户";
|
||||
}
|
||||
if (user.equals("sap")) {
|
||||
currentUserId = Long.parseLong(3 + "");
|
||||
nickName = "sap用户";
|
||||
if (ObjectUtil.isNotEmpty(user)) {
|
||||
if (user.equals("mes")) {
|
||||
currentUserId = Long.parseLong(2 + "");
|
||||
nickName = "mes用户";
|
||||
}
|
||||
if (user.equals("sap")) {
|
||||
currentUserId = Long.parseLong(3 + "");
|
||||
nickName = "sap用户";
|
||||
}
|
||||
}
|
||||
String now = DateUtil.now();
|
||||
String iostorinv_id = IdUtil.getSnowflake(1, 1).nextId() + "";
|
||||
@@ -231,12 +233,13 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
map.put("update_time", now);
|
||||
map.put("is_delete", "0");
|
||||
map.put("is_upload", "0");
|
||||
if (!user.equals("mes") || user.equals("sap")) {
|
||||
Long deptId = SecurityUtils.getDeptId();
|
||||
map.put("sysdeptid", deptId);
|
||||
map.put("syscompanyid", deptId);
|
||||
if (ObjectUtil.isNotEmpty(user)) {
|
||||
if (!user.equals("mes") || user.equals("sap")) {
|
||||
Long deptId = SecurityUtils.getDeptId();
|
||||
map.put("sysdeptid", deptId);
|
||||
map.put("syscompanyid", deptId);
|
||||
}
|
||||
}
|
||||
|
||||
double qty = 0.0; // 主表重量
|
||||
int num = rows.size(); // 明细数
|
||||
for (int i = 0; i < rows.size(); i++) {
|
||||
|
||||
Reference in New Issue
Block a user