501流程测试修改,作废流程添加
This commit is contained in:
@@ -12,12 +12,32 @@ import java.util.HashMap;
|
||||
*/
|
||||
public interface IToWcsService {
|
||||
|
||||
|
||||
/**
|
||||
* 推送CTU出库任务
|
||||
*/
|
||||
void pushOutMydoJob();
|
||||
|
||||
/**
|
||||
* 推送agv搬运作业
|
||||
* @return
|
||||
*/
|
||||
AjaxResult pushAgvMoveJob(GenAgvSchedulingTaskRequest genAgvSchedulingTaskRequest);
|
||||
|
||||
/**
|
||||
* 推送流利架入库任务
|
||||
*/
|
||||
void pushInMydoJob();
|
||||
|
||||
/**
|
||||
* 出库作业确认
|
||||
* @param outMydojobMakeSureParam
|
||||
* @return
|
||||
*/
|
||||
AjaxResult outMydojobMakeSure(HashMap<String, String> outMydojobMakeSureParam);
|
||||
|
||||
/**
|
||||
* 取消任务
|
||||
* @param taskNo
|
||||
* @return
|
||||
*/
|
||||
AjaxResult cancelTaskByTaskNo(String taskNo);
|
||||
}
|
||||
|
||||
@@ -30,6 +30,7 @@ import org.springframework.stereotype.Service;
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 作业统计 Service 实现
|
||||
@@ -45,6 +46,7 @@ public class ToWcsServiceImpl implements IToWcsService {
|
||||
public static final String PUSH_IN_MYDO_JOB = "http://localhost:8081/agv/wcs2Wms/api/receiveInMydoJob";
|
||||
public static final String PUSH_AGV_MOVE_JOB = "http://localhost:8081/api/receiveAgvMoveJob";
|
||||
public static final String OUT_MYDOJOB_MS = "http://localhost:8081/wcs2Wms/api/outMydojobMakesure";
|
||||
public static final String CANCEL_MYDOJOB = "http://localhost:8081/wcs2Wms/api/cancelMydoJob";
|
||||
|
||||
|
||||
@Override
|
||||
@@ -104,4 +106,15 @@ public class ToWcsServiceImpl implements IToWcsService {
|
||||
}
|
||||
return AjaxResult.error(requestLog.getDuration());
|
||||
}
|
||||
|
||||
@Override
|
||||
public AjaxResult cancelTaskByTaskNo(String taskNo) {
|
||||
Map<String,String> map = new HashMap<>();
|
||||
map.put("taskNo", taskNo);
|
||||
RequestLog requestLog = requestLogService.getRequestLog(CANCEL_MYDOJOB, JSONUtil.toJsonStr(map), "取消任务");
|
||||
if ("1".equals(requestLog.getIsSuccessful())){
|
||||
return AjaxResult.success();
|
||||
}
|
||||
return AjaxResult.error();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -150,6 +150,8 @@ public class ToWmsServiceImpl implements IToWmsService {
|
||||
return AjaxResult.error(MessageUtils.message("warn.message"));
|
||||
}
|
||||
MydoJob outJob = outMydoJobs.get(0);
|
||||
//料箱出库 需同步电子标签
|
||||
if("23".equals(outJob.getInOut())){
|
||||
//查询拣选工位绑定的电子标签
|
||||
BasTag tagParam = new BasTag();
|
||||
tagParam.setPickAdd(wmsJobRequest.getPickSsj());
|
||||
@@ -176,6 +178,7 @@ public class ToWmsServiceImpl implements IToWmsService {
|
||||
tagTask.setFloor("0");
|
||||
tagTaskService.insertTagTask(tagTask);
|
||||
}
|
||||
}
|
||||
break;
|
||||
case "3":
|
||||
if (StrUtil.isEmpty(wmsJobRequest.getContainerCode())){
|
||||
|
||||
@@ -2,6 +2,8 @@ package com.ruoyi.check.DifferenceRecordFinish.controller;
|
||||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import com.ruoyi.check.difference.domain.CheckDifferenceRecord;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
@@ -37,12 +39,12 @@ public class CheckDifferenceRecordFinishController extends BaseController
|
||||
/**
|
||||
* 查询盘点差异历史列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('check:DifferenceRecordFinish:list')")
|
||||
@PreAuthorize("@ss.hasPermi('check:difference:list')")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(CheckDifferenceRecordFinish checkDifferenceRecordFinish)
|
||||
{
|
||||
startPage();
|
||||
List<CheckDifferenceRecordFinish> list = checkDifferenceRecordFinishService.selectCheckDifferenceRecordFinishList(checkDifferenceRecordFinish);
|
||||
List<CheckDifferenceRecord> list = checkDifferenceRecordFinishService.selectCheckDifferenceRecordFinishList(checkDifferenceRecordFinish);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
@@ -54,8 +56,8 @@ public class CheckDifferenceRecordFinishController extends BaseController
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, CheckDifferenceRecordFinish checkDifferenceRecordFinish)
|
||||
{
|
||||
List<CheckDifferenceRecordFinish> list = checkDifferenceRecordFinishService.selectCheckDifferenceRecordFinishList(checkDifferenceRecordFinish);
|
||||
ExcelUtil<CheckDifferenceRecordFinish> util = new ExcelUtil<CheckDifferenceRecordFinish>(CheckDifferenceRecordFinish.class);
|
||||
List<CheckDifferenceRecord> list = checkDifferenceRecordFinishService.selectCheckDifferenceRecordFinishList(checkDifferenceRecordFinish);
|
||||
ExcelUtil<CheckDifferenceRecord> util = new ExcelUtil<CheckDifferenceRecord>(CheckDifferenceRecord.class);
|
||||
util.exportExcel(response, list, "盘点差异历史数据");
|
||||
}
|
||||
|
||||
|
||||
@@ -70,6 +70,25 @@ public class CheckDifferenceRecordFinish extends BaseEntity
|
||||
@Excel(name = "审核状态")
|
||||
private String status;
|
||||
|
||||
private String warehouseId;
|
||||
private String warehouseName;
|
||||
|
||||
public String getWarehouseId() {
|
||||
return warehouseId;
|
||||
}
|
||||
|
||||
public void setWarehouseId(String warehouseId) {
|
||||
this.warehouseId = warehouseId;
|
||||
}
|
||||
|
||||
public String getWarehouseName() {
|
||||
return warehouseName;
|
||||
}
|
||||
|
||||
public void setWarehouseName(String warehouseName) {
|
||||
this.warehouseName = warehouseName;
|
||||
}
|
||||
|
||||
public void setCheckGuid(String checkGuid)
|
||||
{
|
||||
this.checkGuid = checkGuid;
|
||||
|
||||
@@ -2,6 +2,7 @@ package com.ruoyi.check.DifferenceRecordFinish.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.check.DifferenceRecordFinish.domain.CheckDifferenceRecordFinish;
|
||||
import com.ruoyi.check.difference.domain.CheckDifferenceRecord;
|
||||
|
||||
/**
|
||||
* 盘点差异历史Mapper接口
|
||||
@@ -17,7 +18,7 @@ public interface CheckDifferenceRecordFinishMapper
|
||||
* @param checkGuid 盘点差异历史主键
|
||||
* @return 盘点差异历史
|
||||
*/
|
||||
public CheckDifferenceRecordFinish selectCheckDifferenceRecordFinishByCheckGuid(String checkGuid);
|
||||
public CheckDifferenceRecord selectCheckDifferenceRecordFinishByCheckGuid(String checkGuid);
|
||||
|
||||
/**
|
||||
* 查询盘点差异历史列表
|
||||
@@ -25,7 +26,7 @@ public interface CheckDifferenceRecordFinishMapper
|
||||
* @param checkDifferenceRecordFinish 盘点差异历史
|
||||
* @return 盘点差异历史集合
|
||||
*/
|
||||
public List<CheckDifferenceRecordFinish> selectCheckDifferenceRecordFinishList(CheckDifferenceRecordFinish checkDifferenceRecordFinish);
|
||||
public List<CheckDifferenceRecord> selectCheckDifferenceRecordFinishList(CheckDifferenceRecordFinish checkDifferenceRecordFinish);
|
||||
|
||||
/**
|
||||
* 新增盘点差异历史
|
||||
|
||||
@@ -2,6 +2,7 @@ package com.ruoyi.check.DifferenceRecordFinish.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.check.DifferenceRecordFinish.domain.CheckDifferenceRecordFinish;
|
||||
import com.ruoyi.check.difference.domain.CheckDifferenceRecord;
|
||||
|
||||
/**
|
||||
* 盘点差异历史Service接口
|
||||
@@ -17,7 +18,7 @@ public interface ICheckDifferenceRecordFinishService
|
||||
* @param checkGuid 盘点差异历史主键
|
||||
* @return 盘点差异历史
|
||||
*/
|
||||
public CheckDifferenceRecordFinish selectCheckDifferenceRecordFinishByCheckGuid(String checkGuid);
|
||||
public CheckDifferenceRecord selectCheckDifferenceRecordFinishByCheckGuid(String checkGuid);
|
||||
|
||||
/**
|
||||
* 查询盘点差异历史列表
|
||||
@@ -25,7 +26,7 @@ public interface ICheckDifferenceRecordFinishService
|
||||
* @param checkDifferenceRecordFinish 盘点差异历史
|
||||
* @return 盘点差异历史集合
|
||||
*/
|
||||
public List<CheckDifferenceRecordFinish> selectCheckDifferenceRecordFinishList(CheckDifferenceRecordFinish checkDifferenceRecordFinish);
|
||||
public List<CheckDifferenceRecord> selectCheckDifferenceRecordFinishList(CheckDifferenceRecordFinish checkDifferenceRecordFinish);
|
||||
|
||||
/**
|
||||
* 新增盘点差异历史
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
package com.ruoyi.check.DifferenceRecordFinish.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.ruoyi.check.difference.domain.CheckDifferenceRecord;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
@@ -27,7 +29,7 @@ public class CheckDifferenceRecordFinishServiceImpl implements ICheckDifferenceR
|
||||
* @return 盘点差异历史
|
||||
*/
|
||||
@Override
|
||||
public CheckDifferenceRecordFinish selectCheckDifferenceRecordFinishByCheckGuid(String checkGuid)
|
||||
public CheckDifferenceRecord selectCheckDifferenceRecordFinishByCheckGuid(String checkGuid)
|
||||
{
|
||||
return checkDifferenceRecordFinishMapper.selectCheckDifferenceRecordFinishByCheckGuid(checkGuid);
|
||||
}
|
||||
@@ -39,7 +41,7 @@ public class CheckDifferenceRecordFinishServiceImpl implements ICheckDifferenceR
|
||||
* @return 盘点差异历史
|
||||
*/
|
||||
@Override
|
||||
public List<CheckDifferenceRecordFinish> selectCheckDifferenceRecordFinishList(CheckDifferenceRecordFinish checkDifferenceRecordFinish)
|
||||
public List<CheckDifferenceRecord> selectCheckDifferenceRecordFinishList(CheckDifferenceRecordFinish checkDifferenceRecordFinish)
|
||||
{
|
||||
return checkDifferenceRecordFinishMapper.selectCheckDifferenceRecordFinishList(checkDifferenceRecordFinish);
|
||||
}
|
||||
|
||||
@@ -12,6 +12,7 @@ import cn.hutool.core.collection.CollUtil;
|
||||
import cn.hutool.core.convert.Convert;
|
||||
import cn.hutool.core.date.DateTime;
|
||||
import cn.hutool.core.date.DateUtil;
|
||||
import com.ruoyi.api.service.IToWcsService;
|
||||
import com.ruoyi.bas.basJobId.service.IBasJobIdService;
|
||||
import com.ruoyi.bas.cargoSpace.domain.BasCargoSpace;
|
||||
import com.ruoyi.bas.cargoSpace.service.IBasCargoSpaceService;
|
||||
@@ -78,6 +79,8 @@ public class MydoJobServiceImpl implements IMydoJobService {
|
||||
private PdaService pdaService;
|
||||
@Autowired
|
||||
private IBasWarehouseService basWarehouseService;
|
||||
@Autowired
|
||||
private IToWcsService iToWcsService;
|
||||
|
||||
|
||||
/**
|
||||
@@ -181,7 +184,7 @@ public class MydoJobServiceImpl implements IMydoJobService {
|
||||
//插入历史表
|
||||
insertHistory(mydoJob.getJobId());
|
||||
|
||||
return AjaxResult.success();
|
||||
|
||||
} else {
|
||||
MydoJobDetail param = new MydoJobDetail();
|
||||
param.setJobId(jobId);
|
||||
@@ -200,9 +203,14 @@ public class MydoJobServiceImpl implements IMydoJobService {
|
||||
updateMydoJob(mydoJob);
|
||||
//插入历史表
|
||||
insertHistory(mydoJob.getJobId());
|
||||
return AjaxResult.success();
|
||||
}
|
||||
|
||||
//通知wcs
|
||||
AjaxResult ajaxResult = iToWcsService.cancelTaskByTaskNo(job.getTaskNo());
|
||||
if (!ajaxResult.isSuccess()){
|
||||
return AjaxResult.success();
|
||||
}else {
|
||||
throw new RuntimeException(Convert.toStr(ajaxResult.get("msg")));
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -418,7 +426,7 @@ public class MydoJobServiceImpl implements IMydoJobService {
|
||||
MydoJob job = selectMydoJobByJobId(jobId);
|
||||
BasWarehouse basWarehouse = basWarehouseService.selectBasWarehouseByWarehouseId(job.getWarehouseId());
|
||||
|
||||
if("1".equals(basWarehouse.getWarehouseType()) && Integer.parseInt(job.getStatus())<3){
|
||||
if("2".equals(basWarehouse.getWarehouseType()) && Integer.parseInt(job.getStatus())<3){
|
||||
log.error("只能完成正执行的作业");
|
||||
return AjaxResult.error();
|
||||
}
|
||||
@@ -470,14 +478,21 @@ public class MydoJobServiceImpl implements IMydoJobService {
|
||||
job.setFinishTime(DateUtil.formatDateTime(DateUtil.date()));
|
||||
updateMydoJob(job);
|
||||
insertHistory(jobId);
|
||||
}
|
||||
//通知wcs
|
||||
AjaxResult ajaxResult = iToWcsService.cancelTaskByTaskNo(job.getTaskNo());
|
||||
if (!ajaxResult.isSuccess()){
|
||||
return AjaxResult.success();
|
||||
}else {
|
||||
throw new RuntimeException(Convert.toStr(ajaxResult.get("msg")));
|
||||
}
|
||||
}
|
||||
|
||||
} catch (Exception e) {
|
||||
TransactionAspectSupport.currentTransactionStatus().setRollbackOnly();
|
||||
log.error("任务处理异常", e);
|
||||
return AjaxResult.error();
|
||||
}
|
||||
return AjaxResult.error();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -182,7 +182,7 @@ public class OutStockoutServiceImpl implements IOutStockoutService
|
||||
}
|
||||
}
|
||||
}
|
||||
if (stringBuilder.length()>0){
|
||||
if (!stringBuilder.isEmpty()){
|
||||
return AjaxResult.warn(stringBuilder.toString());
|
||||
}
|
||||
return AjaxResult.success();
|
||||
|
||||
@@ -124,7 +124,7 @@ public class PdaServiceImp implements PdaService {
|
||||
if ("10".equals(result)) {
|
||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||
} else {
|
||||
return AjaxResult.error(map.get("v_resultmsg").toString());
|
||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||
}
|
||||
|
||||
}
|
||||
@@ -146,7 +146,7 @@ public class PdaServiceImp implements PdaService {
|
||||
if ("10".equals(result)) {
|
||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||
} else {
|
||||
return AjaxResult.error(map.get("v_resultmsg").toString());
|
||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||
}
|
||||
|
||||
}
|
||||
@@ -162,7 +162,7 @@ public class PdaServiceImp implements PdaService {
|
||||
if ("10".equals(result)) {
|
||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||
} else {
|
||||
return AjaxResult.warn(map.get("v_resultmsg").toString());
|
||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -177,7 +177,7 @@ public class PdaServiceImp implements PdaService {
|
||||
if ("10".equals(result)) {
|
||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||
} else {
|
||||
return AjaxResult.warn(map.get("v_resultmsg").toString());
|
||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -211,7 +211,7 @@ public class PdaServiceImp implements PdaService {
|
||||
if ("10".equals(result)) {
|
||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||
} else {
|
||||
return AjaxResult.warn(map.get("v_resultmsg").toString());
|
||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -227,7 +227,7 @@ public class PdaServiceImp implements PdaService {
|
||||
if ("10".equals(result)) {
|
||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||
} else {
|
||||
return AjaxResult.warn(map.get("v_resultmsg").toString());
|
||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||
}
|
||||
|
||||
}
|
||||
@@ -296,12 +296,17 @@ public class PdaServiceImp implements PdaService {
|
||||
//修改拣选数量
|
||||
for (MydoJobDetail mydoJobDetail : mydoJobDetailList) {
|
||||
//修改拣选数量
|
||||
//MydoJobDetail mydoJobDetailOld = mydoJobDetailService.selectMydoJobDetailByJobDetailId(mydoJobDetail.getJobDetailId());
|
||||
/*BigDecimal oldPickQuantity = Convert.toBigDecimal(mydoJobDetailOld.getPickQuantity());
|
||||
BigDecimal newPickQuantity = Convert.toBigDecimal(mydoJobDetail.getOutQuantity());*/
|
||||
mydoJobDetail.setPickQuantity(mydoJobDetail.getOutQuantity());
|
||||
mydoJobDetailService.updateMydoJobDetail(mydoJobDetail);
|
||||
updateTagTaskStatus(mydoJobDetail,basWarehouse);
|
||||
|
||||
//修改单据实际数量
|
||||
String inOrOutDId = mydoJobDetail.getInOrOutDId();
|
||||
OutStockoutDetail outStockoutDetail = outStockoutDetailService.selectOutStockoutDetailByStockoutDetailId(inOrOutDId);
|
||||
outStockoutDetail.setAssignNum(outStockoutDetail.getAssignNum().add(Convert.toBigDecimal(mydoJobDetail.getPickQuantity())));
|
||||
outStockoutDetailService.updateOutStockoutDetail(outStockoutDetail);
|
||||
//修改电子标签
|
||||
updateTagTaskStatus(mydoJobDetail, basWarehouse);
|
||||
}
|
||||
//判断拣选数量是否等于出库数量
|
||||
MydoJobDetail mydoJobDetailParam = new MydoJobDetail();
|
||||
@@ -316,10 +321,10 @@ public class PdaServiceImp implements PdaService {
|
||||
String result = map.get("v_result").toString();
|
||||
if ("10".equals(result)) {
|
||||
//通知wcs 出库确认
|
||||
deleteTagTask(trayCodeMakeSure, basWarehouse);
|
||||
deleteTagTask(trayCodeMakeSure, basWarehouse,mydoJob);
|
||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||
} else {
|
||||
return AjaxResult.warn(map.get("v_resultmsg").toString());
|
||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||
}
|
||||
} else {
|
||||
return AjaxResult.success();
|
||||
@@ -394,10 +399,10 @@ public class PdaServiceImp implements PdaService {
|
||||
pdaMapper.outMakeSure(map);
|
||||
String result = map.get("v_result").toString();
|
||||
if ("10".equals(result)) {
|
||||
deleteTagTask(trayCodeMakeSure, basWarehouse);
|
||||
deleteTagTask(trayCodeMakeSure, basWarehouse,mydoJob);
|
||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||
} else {
|
||||
return AjaxResult.warn(map.get("v_resultmsg").toString());
|
||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||
}
|
||||
} else {
|
||||
return AjaxResult.success();
|
||||
@@ -443,10 +448,9 @@ public class PdaServiceImp implements PdaService {
|
||||
pdaMapper.checkMakeSure(map);
|
||||
String result = map.get("v_result").toString();
|
||||
if ("10".equals(result)) {
|
||||
deleteTagTask(trayCodeMakeSure, basWarehouse);
|
||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||
} else {
|
||||
return AjaxResult.warn(map.get("v_resultmsg").toString());
|
||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||
}
|
||||
}
|
||||
return AjaxResult.success();
|
||||
@@ -477,8 +481,8 @@ public class PdaServiceImp implements PdaService {
|
||||
* @param trayCodeMakeSure
|
||||
* @param basWarehouse
|
||||
*/
|
||||
private void deleteTagTask(TrayCodeMakeSure trayCodeMakeSure, BasWarehouse basWarehouse) {
|
||||
if ("2".equals(basWarehouse.getWarehouseType())) {
|
||||
private void deleteTagTask(TrayCodeMakeSure trayCodeMakeSure, BasWarehouse basWarehouse,MydoJob mydoJob) {
|
||||
if ("2".equals(basWarehouse.getWarehouseType())&&"23".equals(mydoJob.getInOrOut())) {
|
||||
BasTag basTag = basTagService.selectBasTagByTrayCode(trayCodeMakeSure.getTrayCode());
|
||||
basTag.setTrayCode("");
|
||||
basTagService.updateBasTag(basTag);
|
||||
@@ -491,6 +495,7 @@ public class PdaServiceImp implements PdaService {
|
||||
.map(TagTask::getId)
|
||||
.toArray(Long[]::new));
|
||||
}
|
||||
if (mydoJob.getExitId().startsWith("fluent")){
|
||||
//通知wcs出库确认成功
|
||||
HashMap<String, String> outMydojobMakeSureParam = new HashMap<>();
|
||||
outMydojobMakeSureParam.put("trayCode", trayCodeMakeSure.getTrayCode());
|
||||
@@ -499,9 +504,12 @@ public class PdaServiceImp implements PdaService {
|
||||
throw new RuntimeException(ajaxResult.toString());
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public AjaxResult outException(TrayCodeMakeSure trayCodeMakeSure) {
|
||||
//判断任务是否存在
|
||||
MydoJob mydoJobParam = new MydoJob();
|
||||
@@ -559,7 +567,8 @@ public class PdaServiceImp implements PdaService {
|
||||
if ("10".equals(result)) {
|
||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||
} else {
|
||||
return AjaxResult.warn(map.get("v_resultmsg").toString());
|
||||
//return AjaxResult.warn(map.get("v_resultmsg").toString());
|
||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||
}
|
||||
|
||||
}
|
||||
@@ -574,7 +583,7 @@ public class PdaServiceImp implements PdaService {
|
||||
if ("10".equals(result)) {
|
||||
return AjaxResult.success(map.get("v_resultmsg").toString());
|
||||
} else {
|
||||
return AjaxResult.warn(map.get("v_resultmsg").toString());
|
||||
throw new RuntimeException(map.get("v_resultmsg").toString());
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -4,11 +4,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.check.DifferenceRecordFinish.mapper.CheckDifferenceRecordFinishMapper">
|
||||
|
||||
<resultMap type="CheckDifferenceRecordFinish" id="CheckDifferenceRecordFinishResult">
|
||||
<resultMap type="CheckDifferenceRecord" id="CheckDifferenceRecordResult">
|
||||
<result property="checkGuid" column="check_guid"/>
|
||||
<result property="checkStockDetailId" column="check_stock_detail_id"/>
|
||||
<result property="stockId" column="stock_id"/>
|
||||
<result property="trayCode" column="tray_code"/>
|
||||
<result property="cargoSpaceId" column="cargo_space_id"/>
|
||||
<result property="cargoSpaceName" column="cargo_space_name"/>
|
||||
<result property="productId" column="product_id"/>
|
||||
<result property="lotNo" column="lot_no"/>
|
||||
<result property="supplier" column="supplier"/>
|
||||
@@ -18,34 +20,73 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<result property="recordType" column="record_type"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
<result property="productGuid" column="product_guid"/>
|
||||
<result property="checkStockDetailId" column="check_stock_detail_id" />
|
||||
<result property="status" column="status"/>
|
||||
<result property="warehouseId" column="warehouse_id"/>
|
||||
<result property="warehouseName" column="warehouse_name"/>
|
||||
<association property="extraField" javaType="ExtraField">
|
||||
<result property="productId" column="product_id"/>
|
||||
<result property="materialDesc" column="product_name"/>
|
||||
<result property="englishDesc" column="englishDesc"/>
|
||||
<result property="length" column="length"/>
|
||||
<result property="width" column="width"/>
|
||||
<result property="height" column="height"/>
|
||||
<result property="volume" column="volume"/>
|
||||
<result property="netWeight" column="netWeight"/>
|
||||
</association>
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectCheckDifferenceRecordFinishVo">
|
||||
select check_guid, stock_id, tray_code, cargo_space_id, product_id, lot_no, supplier, customer, old_quantity, new_quantity, record_type, create_time, product_guid, check_stock_detail_id, status from check_difference_record_finish
|
||||
select r.check_guid,
|
||||
r.check_stock_detail_id,
|
||||
r.stock_id,
|
||||
r.tray_code,
|
||||
r.cargo_space_id,
|
||||
r.product_id,
|
||||
r.lot_no,
|
||||
r.supplier,
|
||||
r.customer,
|
||||
r.old_quantity,
|
||||
r.new_quantity,
|
||||
r.record_type,
|
||||
r.create_time,
|
||||
r.product_guid,
|
||||
r.status,
|
||||
r.warehouse_id,
|
||||
w.warehouse_name,
|
||||
bp.product_name,
|
||||
bp.spare1 as englishDesc,
|
||||
bp.spare2 as netWeight,
|
||||
bp.spare5 as length,
|
||||
bp.spare6 as width,
|
||||
bp.spare7 as height,
|
||||
bp.spare8 as volume,
|
||||
bcs.cargo_space_name
|
||||
from check_difference_record_finish r
|
||||
left join bas_warehouse w on r.warehouse_id = w.warehouse_id
|
||||
left join bas_product bp on r.product_id = bp.product_id
|
||||
left join bas_cargo_space bcs on r.cargo_space_id = bcs.cargo_space_id
|
||||
</sql>
|
||||
|
||||
<select id="selectCheckDifferenceRecordFinishList" parameterType="CheckDifferenceRecordFinish" resultMap="CheckDifferenceRecordFinishResult">
|
||||
<select id="selectCheckDifferenceRecordFinishList" parameterType="CheckDifferenceRecordFinish" resultMap="CheckDifferenceRecordResult">
|
||||
<include refid="selectCheckDifferenceRecordFinishVo"/>
|
||||
<where>
|
||||
<if test="stockId != null and stockId != ''"> and stock_id = #{stockId}</if>
|
||||
<if test="trayCode != null and trayCode != ''"> and tray_code = #{trayCode}</if>
|
||||
<if test="cargoSpaceId != null and cargoSpaceId != ''"> and cargo_space_id = #{cargoSpaceId}</if>
|
||||
<if test="productId != null and productId != ''"> and product_id = #{productId}</if>
|
||||
<if test="lotNo != null and lotNo != ''"> and lot_no = #{lotNo}</if>
|
||||
<if test="supplier != null and supplier != ''"> and supplier = #{supplier}</if>
|
||||
<if test="customer != null and customer != ''"> and customer = #{customer}</if>
|
||||
<if test="oldQuantity != null and oldQuantity != ''"> and old_quantity = #{oldQuantity}</if>
|
||||
<if test="newQuantity != null and newQuantity != ''"> and new_quantity = #{newQuantity}</if>
|
||||
<if test="recordType != null "> and record_type = #{recordType}</if>
|
||||
<if test="productGuid != null and productGuid != ''"> and product_guid = #{productGuid}</if>
|
||||
<if test="checkStockDetailId != null and checkStockDetailId != ''"> and check_stock_detail_id = #{checkStockDetailId}</if>
|
||||
<if test="status != null and status != ''"> and status = #{status}</if>
|
||||
<if test="stockId != null and stockId != ''"> and r.stock_id = #{stockId}</if>
|
||||
<if test="trayCode != null and trayCode != ''"> and r.tray_code = #{trayCode}</if>
|
||||
<if test="cargoSpaceId != null and cargoSpaceId != ''"> and r.cargo_space_id = #{cargoSpaceId}</if>
|
||||
<if test="productId != null and productId != ''"> and r.product_id = #{productId}</if>
|
||||
<if test="lotNo != null and lotNo != ''"> and r.lot_no = #{lotNo}</if>
|
||||
<if test="supplier != null and supplier != ''"> and r.supplier = #{supplier}</if>
|
||||
<if test="customer != null and customer != ''"> and r.customer = #{customer}</if>
|
||||
<if test="oldQuantity != null and oldQuantity != ''"> and r.old_quantity = #{oldQuantity}</if>
|
||||
<if test="newQuantity != null and newQuantity != ''"> and r.new_quantity = #{newQuantity}</if>
|
||||
<if test="recordType != null "> and r.record_type = #{recordType}</if>
|
||||
<if test="productGuid != null and productGuid != ''"> and r.product_guid = #{productGuid}</if>
|
||||
<if test="checkStockDetailId != null and checkStockDetailId != ''"> and r.check_stock_detail_id = #{checkStockDetailId}</if>
|
||||
<if test="status != null and status != ''"> and r.status = #{status}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectCheckDifferenceRecordFinishByCheckGuid" parameterType="String" resultMap="CheckDifferenceRecordFinishResult">
|
||||
<select id="selectCheckDifferenceRecordFinishByCheckGuid" parameterType="String" resultMap="CheckDifferenceRecordResult">
|
||||
<include refid="selectCheckDifferenceRecordFinishVo"/>
|
||||
where check_guid = #{checkGuid}
|
||||
</select>
|
||||
|
||||
@@ -379,7 +379,7 @@ export default {
|
||||
alreadyAudited: '单据已审核,请勿重复审核',
|
||||
alreadyCancelFail: '单据已审核,无法作废',
|
||||
onlyOneCanAutoAllocation: '请选择一条数据',
|
||||
auditStockOut:'"请选择审核状态为审核通过单据"',
|
||||
auditStockOut: '请选择审核状态为审核通过单据',
|
||||
alreadyAuditStockOut: '"单据已审核"',
|
||||
confirmExit: '提交',
|
||||
cancelExit: '取消',
|
||||
@@ -740,6 +740,7 @@ export default {
|
||||
confirmNPass: '是否确认通过盘点差异编号为',
|
||||
deleteSuccess: '审核不通过成功',
|
||||
auditSuccess: '审核成功',
|
||||
confirmPass: '是否确认通过盘点差异编号为'
|
||||
},
|
||||
// ********************库存信息*************
|
||||
stockManagement: {
|
||||
@@ -822,7 +823,6 @@ export default {
|
||||
},
|
||||
|
||||
|
||||
|
||||
searchViewStockSecure: {
|
||||
stockId: '库存ID',
|
||||
cargoSpaceId: '货位ID',
|
||||
|
||||
@@ -374,7 +374,7 @@ export default {
|
||||
/** 审核按钮操作 */
|
||||
handleAudit() {
|
||||
const checkGuids = this.ids
|
||||
this.$modal.confirm(this.$t('checkDifference.confirmPass') + checkGuids.length).then(function() {
|
||||
this.$modal.confirm(this.$t('checkDifference.confirmPass') + checkGuids).then(function() {
|
||||
return auditDifference(checkGuids)
|
||||
}).then(() => {
|
||||
this.getList()
|
||||
|
||||
@@ -377,7 +377,7 @@ export default {
|
||||
}
|
||||
|
||||
// 如果是审核操作(status=2),显示弹窗选择出口
|
||||
if (status === 2) {
|
||||
if (status === 2 || status === 3) {
|
||||
this.currentAuditStatus = status
|
||||
// 根据选中单据的仓库ID设置出口选项
|
||||
this.setExitOptionsByWarehouse()
|
||||
@@ -412,7 +412,9 @@ export default {
|
||||
}
|
||||
const stockoutIds = this.selectedRows.map(row => row.stockoutId)
|
||||
let outstock = this.selectedRows[0]
|
||||
if (outstock.status !== "2") {
|
||||
console.log(outstock.status !== "2")
|
||||
console.log(outstock.status !== "3")
|
||||
if (outstock.status !== "2" && outstock.status !== "3") {
|
||||
this.$modal.msgError(this.$t('outStockoutManage.auditStockOut'))
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user