修改
This commit is contained in:
@@ -5,7 +5,7 @@ import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.nl.annotation.Log;
|
||||
import org.nl.modules.logging.annotation.Log;
|
||||
import org.nl.wms.st.instor.service.CheckService;
|
||||
import org.springframework.data.domain.Pageable;
|
||||
import org.springframework.http.HttpStatus;
|
||||
|
||||
@@ -9,18 +9,15 @@ import com.alibaba.fastjson.JSONArray;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.nl.exception.BadRequestException;
|
||||
import org.nl.modules.security.service.dto.JwtUserDto;
|
||||
import org.nl.modules.common.exception.BadRequestException;
|
||||
import org.nl.modules.common.utils.SecurityUtils;
|
||||
import org.nl.modules.system.util.CodeUtil;
|
||||
import org.nl.utils.FileUtil;
|
||||
import org.nl.utils.SecurityUtils;
|
||||
import org.nl.wms.common.util.DataAuthUtil;
|
||||
import org.nl.wms.st.core.service.StorPublicService;
|
||||
import org.nl.modules.wql.WQL;
|
||||
import org.nl.modules.wql.core.bean.WQLObject;
|
||||
import org.nl.modules.wql.util.WqlUtil;
|
||||
import org.nl.wms.st.inbill.service.StorPublicService;
|
||||
import org.nl.wms.st.instor.service.CheckService;
|
||||
import org.nl.wms.st.instor.task.HandMoveStorAcsTask;
|
||||
import org.nl.wql.WQL;
|
||||
import org.nl.wql.core.bean.WQLObject;
|
||||
import org.nl.wql.util.WqlUtil;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.data.domain.Pageable;
|
||||
import org.springframework.stereotype.Service;
|
||||
@@ -39,8 +36,6 @@ import java.util.*;
|
||||
public class CheckServiceImpl implements CheckService {
|
||||
@Autowired
|
||||
private StorPublicService storPublicService;
|
||||
@Autowired
|
||||
private MoreOrLessService moreOrLessService;
|
||||
|
||||
@Override
|
||||
public Map<String, Object> pageQuery(Map whereJson, Pageable page) {
|
||||
@@ -49,8 +44,6 @@ public class CheckServiceImpl implements CheckService {
|
||||
if (StrUtil.isNotEmpty(map.get("check_code"))) {
|
||||
map.put("check_code", "%" + map.get("check_code") + "%");
|
||||
}
|
||||
String deptIds = DataAuthUtil.getDeptStr();
|
||||
map.put("deptIds", deptIds);
|
||||
if (StrUtil.isNotEmpty(map.get("buss_type"))) {
|
||||
map.put("buss_type", whereJson.get("buss_type") + "%");
|
||||
}
|
||||
@@ -78,7 +71,7 @@ public class CheckServiceImpl implements CheckService {
|
||||
WQLObject wo_mst = WQLObject.getWQLObject("ST_IVT_CheckMst");
|
||||
|
||||
Long currentUserId = SecurityUtils.getCurrentUserId();
|
||||
String nickName = SecurityUtils.getNickName();
|
||||
String nickName = SecurityUtils.getCurrentNickName();
|
||||
String now = DateUtil.now();
|
||||
HashMap<String, String> map = new HashMap<>();
|
||||
map.put("is_delete", "1");
|
||||
@@ -111,7 +104,7 @@ public class CheckServiceImpl implements CheckService {
|
||||
ArrayList<HashMap> rows = (ArrayList<HashMap>) map.get("tableData");
|
||||
map.remove("tableData");
|
||||
Long currentUserId = SecurityUtils.getCurrentUserId();
|
||||
String nickName = SecurityUtils.getNickName();
|
||||
String nickName = SecurityUtils.getCurrentNickName();
|
||||
String now = DateUtil.now();
|
||||
String check_id = IdUtil.getSnowflake(1, 1).nextId() + "";
|
||||
String check_code = CodeUtil.getNewCode("PD_CODE");
|
||||
@@ -127,8 +120,7 @@ public class CheckServiceImpl implements CheckService {
|
||||
map.put("update_time", now);
|
||||
map.put("is_delete", "0");
|
||||
map.put("is_upload", "0");
|
||||
JwtUserDto currentUser = (JwtUserDto) SecurityUtils.getCurrentUser();
|
||||
Long deptId = currentUser.getDeptId();
|
||||
Long deptId = SecurityUtils.getDeptId();
|
||||
map.put("sysdeptid", deptId);
|
||||
map.put("syscompanyid", deptId);
|
||||
JSONObject jo_mst = JSONObject.parseObject(JSON.toJSONString(map));
|
||||
@@ -212,7 +204,7 @@ public class CheckServiceImpl implements CheckService {
|
||||
WQLObject wo_mst = WQLObject.getWQLObject("ST_IVT_CheckMst");
|
||||
|
||||
Long currentUserId = SecurityUtils.getCurrentUserId();
|
||||
String nickName = SecurityUtils.getNickName();
|
||||
String nickName = SecurityUtils.getCurrentNickName();
|
||||
String now = DateUtil.now();
|
||||
String check_id = (String) whereJson.get("check_id");
|
||||
//查询主表
|
||||
@@ -259,7 +251,7 @@ public class CheckServiceImpl implements CheckService {
|
||||
JSONObject form = whereJson.getJSONObject("row");
|
||||
JSONArray rows = whereJson.getJSONArray("rows");
|
||||
Long currentUserId = SecurityUtils.getCurrentUserId();
|
||||
String nickName = SecurityUtils.getNickName();
|
||||
String nickName = SecurityUtils.getCurrentNickName();
|
||||
String now = DateUtil.now();
|
||||
|
||||
JSONObject jo_mst = wo_mst.query("status in ('10','30') and check_id='" + form.getString("check_id") + "'").uniqueResult(0);
|
||||
@@ -344,7 +336,7 @@ public class CheckServiceImpl implements CheckService {
|
||||
HandMoveStorAcsTask handMoveStorAcsTask = new HandMoveStorAcsTask();
|
||||
|
||||
Long currentUserId = SecurityUtils.getCurrentUserId();
|
||||
String nickName = SecurityUtils.getNickName();
|
||||
String nickName = SecurityUtils.getCurrentNickName();
|
||||
String now = DateUtil.now();
|
||||
|
||||
String moveinv_id = whereJson.getString("moveinv_id");
|
||||
@@ -396,7 +388,7 @@ public class CheckServiceImpl implements CheckService {
|
||||
JSONObject form = whereJson.getJSONObject("row");
|
||||
JSONArray rows = whereJson.getJSONArray("rows");
|
||||
Long currentUserId = SecurityUtils.getCurrentUserId();
|
||||
String nickName = SecurityUtils.getNickName();
|
||||
String nickName = SecurityUtils.getCurrentNickName();
|
||||
String now = DateUtil.now();
|
||||
|
||||
JSONObject jo_mst = wo_mst.query("status in ('10','30') and check_id='" + form.getString("check_id") + "'").uniqueResult(0);
|
||||
@@ -454,7 +446,7 @@ public class CheckServiceImpl implements CheckService {
|
||||
JSONObject form = whereJson.getJSONObject("form");
|
||||
JSONObject row = whereJson.getJSONObject("row");
|
||||
Long currentUserId = SecurityUtils.getCurrentUserId();
|
||||
String nickName = SecurityUtils.getNickName();
|
||||
String nickName = SecurityUtils.getCurrentNickName();
|
||||
String now = DateUtil.now();
|
||||
|
||||
JSONObject jo_mst = wo_mst.query("status <>'99' and check_id='" + form.getString("check_id") + "'").uniqueResult(0);
|
||||
@@ -504,7 +496,7 @@ public class CheckServiceImpl implements CheckService {
|
||||
JSONObject form = whereJson.getJSONObject("row");
|
||||
JSONArray rows = whereJson.getJSONArray("rows");
|
||||
Long currentUserId = SecurityUtils.getCurrentUserId();
|
||||
String nickName = SecurityUtils.getNickName();
|
||||
String nickName = SecurityUtils.getCurrentNickName();
|
||||
String now = DateUtil.now();
|
||||
|
||||
JSONObject jo_mst = wo_mst.query("status <>'99' and check_id='" + form.getString("check_id") + "'").uniqueResult(0);
|
||||
@@ -551,7 +543,7 @@ public class CheckServiceImpl implements CheckService {
|
||||
mapMst.put("struct_name", ja_sun.getJSONObject(0).getString("struct_name"));
|
||||
//List<HashMap> rows_sun = ja_sun.toJavaList(HashMap.class);
|
||||
mapMst.put("tableData", ja_sun);
|
||||
moreOrLessService.insertDtl(mapMst);
|
||||
//moreOrLessService.insertDtl(mapMst);
|
||||
}
|
||||
|
||||
//判断是否要生成溢单
|
||||
@@ -573,7 +565,7 @@ public class CheckServiceImpl implements CheckService {
|
||||
mapMst.put("struct_name", ja_yi.getJSONObject(0).getString("struct_name"));
|
||||
//List<HashMap> rows_yi = ja_yi.toJavaList(HashMap.class);
|
||||
mapMst.put("tableData", ja_yi);
|
||||
moreOrLessService.insertDtl(mapMst);
|
||||
//moreOrLessService.insertDtl(mapMst);
|
||||
}
|
||||
|
||||
JSONArray ja = wo_dtl.query("status in ('99','07') and check_id='" + form.getString("check_id") + "'").getResultJSONArray(0);
|
||||
@@ -603,7 +595,7 @@ public class CheckServiceImpl implements CheckService {
|
||||
.getResultJSONArray(0);
|
||||
for (int i = 0; i < ja_sunyi.size(); i++) {
|
||||
JSONObject jo = ja_sunyi.getJSONObject(i);
|
||||
moreOrLessService.confirm(jo);
|
||||
//moreOrLessService.confirm(jo);
|
||||
}
|
||||
}
|
||||
wo_mst.update(jo_mst);
|
||||
@@ -669,7 +661,7 @@ public class CheckServiceImpl implements CheckService {
|
||||
}
|
||||
list.add(map);
|
||||
}
|
||||
FileUtil.downloadExcel(list, response);
|
||||
//FileUtil.downloadExcel(list, response);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -3,17 +3,24 @@ package org.nl.wms.st.instor.task;
|
||||
import cn.hutool.core.date.DateUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import org.nl.exception.BadRequestException;
|
||||
import org.nl.utils.SecurityUtils;
|
||||
import org.nl.utils.SpringContextHolder;
|
||||
import org.nl.modules.common.exception.BadRequestException;
|
||||
import org.nl.modules.common.utils.SecurityUtils;
|
||||
import org.nl.modules.wql.core.bean.WQLObject;
|
||||
import org.nl.modules.wql.util.SpringContextHolder;
|
||||
import org.nl.wms.sch.AcsTaskDto;
|
||||
import org.nl.wms.sch.manage.AbstractAcsTask;
|
||||
import org.nl.wms.st.instor.service.impl.HandMoveStorServiceImpl;
|
||||
import org.nl.wql.core.bean.WQLObject;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
|
||||
public class HandMoveStorAcsTask extends AbstractAcsTask {
|
||||
@Override
|
||||
public List<AcsTaskDto> addTask() {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* @param taskObj 代表一条任务对象
|
||||
@@ -29,7 +36,7 @@ public class HandMoveStorAcsTask extends AbstractAcsTask {
|
||||
HashMap<String,String> map = new HashMap<>();
|
||||
|
||||
Long currentUserId = SecurityUtils.getCurrentUserId();
|
||||
String nickName = SecurityUtils.getNickName();
|
||||
String nickName = SecurityUtils.getCurrentNickName();
|
||||
String now = DateUtil.now();
|
||||
String taskdtl_id = taskObj.getString("taskdtl_id");
|
||||
if (StrUtil.isEmpty(taskdtl_id)) {
|
||||
@@ -92,14 +99,6 @@ public class HandMoveStorAcsTask extends AbstractAcsTask {
|
||||
handMoveStorService.finishTask(task);
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* @param taskdtl_id
|
||||
*/
|
||||
@Override
|
||||
public void pullBack(String taskdtl_id) {
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user