10月22日现场最新版本
This commit is contained in:
parent
204bda118b
commit
7e201dd001
|
|
@ -1,8 +1,8 @@
|
|||
import axios from 'axios'
|
||||
|
||||
const request = axios.create({
|
||||
//baseURL: 'http://172.18.222.253:12315/wms',
|
||||
baseURL: 'http://localhost:12315/wms',
|
||||
baseURL: 'http://172.18.222.253:12315/wms',
|
||||
//baseURL: 'http://localhost:12315/wms',
|
||||
timeout: 5000
|
||||
})
|
||||
// 172.18.222.253
|
||||
|
|
|
|||
|
|
@ -2,59 +2,59 @@
|
|||
<el-config-provider :locale="zhCn">
|
||||
<el-container class="content">
|
||||
<div class="work-area">
|
||||
<fieldset class="search-area">
|
||||
<el-form ref="outTaskRef" :model="outTaskEntity" :label-position="labelPosition" label-width="158px"
|
||||
style="max-width: 100%" :rules="requestRules" status-icon>
|
||||
<div style="display: flex; justify-content: space-between;">
|
||||
<el-row>
|
||||
<!-- <el-form-item label="出库类型" prop="outType">
|
||||
<el-select-v2 style="width: 196px" v-model="outTaskEntity.outType" placeholder="请选择入库类型"
|
||||
:options="outTypeOptions"></el-select-v2>
|
||||
</el-form-item> -->
|
||||
<el-form-item label="料号" prop="goodsId">
|
||||
<el-input v-model="outTaskEntity.goodsId" @blur="getLackQty()" clearable/>
|
||||
</el-form-item>
|
||||
<!-- <fieldset class="search-area">-->
|
||||
<!-- <el-form ref="outTaskRef" :model="outTaskEntity" :label-position="labelPosition" label-width="158px"-->
|
||||
<!-- style="max-width: 100%" :rules="requestRules" status-icon>-->
|
||||
<!-- <div style="display: flex; justify-content: space-between;">-->
|
||||
<!-- <el-row>-->
|
||||
<!-- <!– <el-form-item label="出库类型" prop="outType">-->
|
||||
<!-- <el-select-v2 style="width: 196px" v-model="outTaskEntity.outType" placeholder="请选择入库类型"-->
|
||||
<!-- :options="outTypeOptions"></el-select-v2>-->
|
||||
<!-- </el-form-item> –>-->
|
||||
<!-- <el-form-item label="料号" prop="goodsId">-->
|
||||
<!-- <el-input v-model="outTaskEntity.goodsId" @blur="getLackQty()" clearable/>-->
|
||||
<!-- </el-form-item>-->
|
||||
|
||||
<el-form-item label="数量" prop="needNum">
|
||||
<el-input-number style="width: 196px" v-model.number="outTaskEntity.needNum"
|
||||
controls-position="right" :min="1" clearable/>
|
||||
</el-form-item>
|
||||
<el-form-item label="箱号" prop="vehicleId">
|
||||
<el-input v-model="outTaskEntity.vehicleId" clearable/>
|
||||
</el-form-item>
|
||||
<el-form-item label="特殊库存" prop="specialStock">
|
||||
<el-input v-model="outTaskEntity.specialStock" ref="specialStock" clearable/>
|
||||
</el-form-item>
|
||||
<el-form-item label="特殊库存号" prop="specialStockNo">
|
||||
<el-input v-model="outTaskEntity.specialStockNo" ref="specialStockNo" clearable/>
|
||||
</el-form-item>
|
||||
<el-form-item label="特殊库存item号" prop="specialStockItemNo">
|
||||
<el-input v-model="outTaskEntity.specialStockItemNo" ref="specialStockItemNo" clearable/>
|
||||
</el-form-item>
|
||||
<el-form-item label="批次号" prop="batchNo">
|
||||
<el-input v-model="outTaskEntity.batchNo" ref="batchNo" clearable/>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="原因" prop="reason" v-if="outTaskEntity.outType === 9">
|
||||
<el-select-v2 style="width: 196px" v-model="outTaskEntity.reason" placeholder="请选择紧急出库原因"
|
||||
:options="reasonOptions"></el-select-v2>
|
||||
</el-form-item> -->
|
||||
<el-form-item label="工单" prop="workOrder" v-if="outTaskEntity.reason === '缺料'">
|
||||
<el-input v-model="outTaskEntity.workOrder" @blur="getLackQty()" clearable/>
|
||||
</el-form-item>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-button type="primary"
|
||||
style="height: 50px; width: 100px; margin: auto 5px auto 5px; font-size: large; color: black;"
|
||||
@click="confirmOut()">确认出库
|
||||
</el-button>
|
||||
<el-button type="warning"
|
||||
style="height: 50px; width: 100px; margin: auto 5px auto 5px; font-size: large; color: black;"
|
||||
@click="clearInput()">清除输入
|
||||
</el-button>
|
||||
</el-row>
|
||||
</div>
|
||||
</el-form>
|
||||
</fieldset>
|
||||
<!-- <el-form-item label="数量" prop="needNum">-->
|
||||
<!-- <el-input-number style="width: 196px" v-model.number="outTaskEntity.needNum"-->
|
||||
<!-- controls-position="right" :min="1" clearable/>-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- <el-form-item label="箱号" prop="vehicleId">-->
|
||||
<!-- <el-input v-model="outTaskEntity.vehicleId" clearable/>-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- <el-form-item label="特殊库存" prop="specialStock">-->
|
||||
<!-- <el-input v-model="outTaskEntity.specialStock" ref="specialStock" clearable/>-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- <el-form-item label="特殊库存号" prop="specialStockNo">-->
|
||||
<!-- <el-input v-model="outTaskEntity.specialStockNo" ref="specialStockNo" clearable/>-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- <el-form-item label="特殊库存item号" prop="specialStockItemNo">-->
|
||||
<!-- <el-input v-model="outTaskEntity.specialStockItemNo" ref="specialStockItemNo" clearable/>-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- <el-form-item label="批次号" prop="batchNo">-->
|
||||
<!-- <el-input v-model="outTaskEntity.batchNo" ref="batchNo" clearable/>-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- <!– <el-form-item label="原因" prop="reason" v-if="outTaskEntity.outType === 9">-->
|
||||
<!-- <el-select-v2 style="width: 196px" v-model="outTaskEntity.reason" placeholder="请选择紧急出库原因"-->
|
||||
<!-- :options="reasonOptions"></el-select-v2>-->
|
||||
<!-- </el-form-item> –>-->
|
||||
<!-- <el-form-item label="工单" prop="workOrder" v-if="outTaskEntity.reason === '缺料'">-->
|
||||
<!-- <el-input v-model="outTaskEntity.workOrder" @blur="getLackQty()" clearable/>-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- </el-row>-->
|
||||
<!-- <el-row>-->
|
||||
<!-- <el-button type="primary"-->
|
||||
<!-- style="height: 50px; width: 100px; margin: auto 5px auto 5px; font-size: large; color: black;"-->
|
||||
<!-- @click="confirmOut()">确认出库-->
|
||||
<!-- </el-button>-->
|
||||
<!-- <el-button type="warning"-->
|
||||
<!-- style="height: 50px; width: 100px; margin: auto 5px auto 5px; font-size: large; color: black;"-->
|
||||
<!-- @click="clearInput()">清除输入-->
|
||||
<!-- </el-button>-->
|
||||
<!-- </el-row>-->
|
||||
<!-- </div>-->
|
||||
<!-- </el-form>-->
|
||||
<!-- </fieldset>-->
|
||||
<!-- 修改confirm-area为竖直布局,表单项两两一排 -->
|
||||
<!-- 修改confirm-area为竖直布局,表单项两两一排 -->
|
||||
<div style="display: flex; margin-top: 10px;">
|
||||
|
|
|
|||
|
|
@ -17,6 +17,11 @@
|
|||
<el-input class="form-input large-center-input" v-model="bindingData.goodsId" clearable readonly/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="22" :offset="1">
|
||||
<el-form-item label="跟单信息:" required>
|
||||
<el-input class="form-input large-center-input" v-model="bindingData.remark" clearable readonly/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="22" :offset="1">
|
||||
<el-form-item label="本次实际拣选:" required>
|
||||
<el-input class="form-input large-center-input" v-model="bindingData.planPickQty" clearable/>
|
||||
|
|
@ -110,7 +115,8 @@ export default {
|
|||
putArea: '',
|
||||
warningQty: null,
|
||||
containerNo: '',
|
||||
standId: ''
|
||||
standId: '',
|
||||
remark: ''
|
||||
},
|
||||
transferList: [],
|
||||
inventoryList: [],
|
||||
|
|
@ -210,7 +216,7 @@ export default {
|
|||
const responseData = res.data;
|
||||
if (responseData.code === 0) {
|
||||
if (responseData.message === "继续拣选"){
|
||||
ElMessageBox.alert('请继续拣选操作', '提示', {
|
||||
ElMessageBox.alert('该料箱还有任务,请继续拣选!', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
type: 'info'
|
||||
});
|
||||
|
|
@ -249,7 +255,7 @@ export default {
|
|||
this.bindingData.planPickQty = '';
|
||||
this.bindingData.realRemainQty = '';
|
||||
this.bindingData.containerNo = '';
|
||||
|
||||
this.bindingData.remark = '';
|
||||
// 重置完成后聚焦到箱号输入框
|
||||
this.$nextTick(() => {
|
||||
this.$refs.sourceBoxInput.focus();
|
||||
|
|
@ -299,6 +305,7 @@ export default {
|
|||
this.bindingData.isOut = result.stockConfirm.isOut
|
||||
this.bindingData.putArea = result.stockConfirm.putArea || ''
|
||||
this.bindingData.warningQty = result.stockConfirm.warningQty
|
||||
this.bindingData.remark = result.stockConfirm.remark
|
||||
}
|
||||
console.log(this.bindingData)
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ public class ExcelController {
|
|||
* @return 导入结果
|
||||
* @throws Exception 异常
|
||||
*/
|
||||
@PostMapping("/importBaseGoods")
|
||||
//@PostMapping("/importBaseGoods")
|
||||
public BaseWmsApiResponse importBaseGoods(@RequestPart("file") MultipartFile file, @RequestPart("fileVo") FileVo fileVo) throws Exception {
|
||||
return importExcelEasyPoi.doImportBaseGoods(file, fileVo);
|
||||
}
|
||||
|
|
@ -49,7 +49,7 @@ public class ExcelController {
|
|||
* @return 导入结果
|
||||
* @throws Exception 异常
|
||||
*/
|
||||
@PostMapping("/importInventoryRequest")
|
||||
//@PostMapping("/importInventoryRequest")
|
||||
public BaseWmsApiResponse importInventoryRequest(@RequestPart("file") MultipartFile file, @RequestPart("fileVo") FileVo fileVo) throws Exception {
|
||||
return importExcelEasyPoi.doImportInventoryRequest(file, fileVo);
|
||||
}
|
||||
|
|
@ -61,7 +61,7 @@ public class ExcelController {
|
|||
* @return 导入结果
|
||||
* @throws Exception 异常
|
||||
*/
|
||||
@PostMapping("/importKanban")
|
||||
//@PostMapping("/importKanban")
|
||||
public BaseWmsApiResponse importKanban(@RequestPart("file") MultipartFile file, @RequestPart("fileVo") FileVo fileVo) throws Exception {
|
||||
return importExcelEasyPoi.doImportKanban(file, fileVo);
|
||||
}
|
||||
|
|
@ -73,7 +73,7 @@ public class ExcelController {
|
|||
* @return 导入结果
|
||||
* @throws Exception 异常
|
||||
*/
|
||||
@PostMapping("/importDbs")
|
||||
//@PostMapping("/importDbs")
|
||||
public BaseWmsApiResponse importDbs(@RequestPart("file") MultipartFile file, @RequestPart("fileVo") FileVo fileVo) throws Exception {
|
||||
return importExcelEasyPoi.doImportDbs(file, fileVo);
|
||||
}
|
||||
|
|
@ -85,7 +85,7 @@ public class ExcelController {
|
|||
* @return 导入结果
|
||||
* @throws Exception 异常
|
||||
*/
|
||||
@PostMapping("/importProduct")
|
||||
//@PostMapping("/importProduct")
|
||||
public BaseWmsApiResponse importProduct(@RequestPart("file") MultipartFile file, @RequestPart("fileVo") FileVo fileVo) throws Exception {
|
||||
return importExcelEasyPoi.doImportProduct(file, fileVo);
|
||||
}
|
||||
|
|
@ -97,7 +97,7 @@ public class ExcelController {
|
|||
* @return 导入结果
|
||||
* @throws Exception 异常
|
||||
*/
|
||||
@PostMapping("/importServiceProduct")
|
||||
//@PostMapping("/importServiceProduct")
|
||||
public BaseWmsApiResponse importServiceProduct(@RequestPart("file") MultipartFile file, @RequestPart("fileVo") FileVo fileVo) throws Exception {
|
||||
return importExcelEasyPoi.doImportServiceProduct(file, fileVo);
|
||||
}
|
||||
|
|
@ -109,7 +109,7 @@ public class ExcelController {
|
|||
* @return 导入结果
|
||||
* @throws Exception 异常
|
||||
*/
|
||||
@PostMapping("/importProductExtend")
|
||||
//@PostMapping("/importProductExtend")
|
||||
public BaseWmsApiResponse importProductExtend(@RequestPart("file") MultipartFile file, @RequestPart("fileVo") FileVo fileVo) throws Exception {
|
||||
return importExcelEasyPoi.doImportProductExtend(file, fileVo);
|
||||
}
|
||||
|
|
@ -118,7 +118,7 @@ public class ExcelController {
|
|||
* 导出DBS
|
||||
* @param dbsQuery 请求
|
||||
*/
|
||||
@PostMapping("/exportDbsWithExcel")
|
||||
//@PostMapping("/exportDbsWithExcel")
|
||||
public void exportDbsWithExcel(@RequestBody DbsQuery dbsQuery, HttpServletResponse response) throws IOException {
|
||||
exportExcelEasyPoi.doExportDbs(dbsQuery, response);
|
||||
}
|
||||
|
|
@ -127,7 +127,7 @@ public class ExcelController {
|
|||
* 导出配料单
|
||||
* @param kittingBomQuery 请求
|
||||
*/
|
||||
@PostMapping("/exportKittingBomWithExcel")
|
||||
//@PostMapping("/exportKittingBomWithExcel")
|
||||
public void exportKittingBomWithExcel(@RequestBody KittingBomQuery kittingBomQuery, HttpServletResponse response) throws IOException {
|
||||
exportExcelEasyPoi.doExportKittingBom(kittingBomQuery, response);
|
||||
}
|
||||
|
|
@ -136,7 +136,7 @@ public class ExcelController {
|
|||
* 导出配对关系
|
||||
* @param kittingBomRelationQuery 请求
|
||||
*/
|
||||
@PostMapping("/exportKittingBomRelationWithExcel")
|
||||
//@PostMapping("/exportKittingBomRelationWithExcel")
|
||||
public void exportKittingBomRelationWithExcel(@RequestBody KittingBomRelationQuery kittingBomRelationQuery, HttpServletResponse response) throws IOException {
|
||||
exportExcelEasyPoi.doExportKittingBomRelations(kittingBomRelationQuery, response);
|
||||
}
|
||||
|
|
@ -154,7 +154,7 @@ public class ExcelController {
|
|||
* 导出物料基础信息
|
||||
* @param goodsQuery 请求
|
||||
*/
|
||||
@PostMapping("/exportGoodsExcel")
|
||||
//@PostMapping("/exportGoodsExcel")
|
||||
public void exportGoodsExcel(@RequestBody GoodsQuery goodsQuery, HttpServletResponse response) throws IOException {
|
||||
exportExcelEasyPoi.doExportGoods(goodsQuery, response);
|
||||
}
|
||||
|
|
@ -172,7 +172,7 @@ public class ExcelController {
|
|||
* 导出工作详情信息
|
||||
* @param workSummaryQuery 请求
|
||||
*/
|
||||
@PostMapping("/exportWorkSummaryExcel")
|
||||
//@PostMapping("/exportWorkSummaryExcel")
|
||||
public void exportWorkSummaryExcel(@RequestBody WorkSummaryQuery workSummaryQuery, HttpServletResponse response) throws IOException {
|
||||
exportExcelEasyPoi.doExportWorkSummaryExcel(workSummaryQuery, response);
|
||||
}
|
||||
|
|
@ -181,7 +181,7 @@ public class ExcelController {
|
|||
* 导出看板需求
|
||||
* @param kanbanQuery 请求
|
||||
*/
|
||||
@PostMapping("/exportKanbanExcel")
|
||||
//@PostMapping("/exportKanbanExcel")
|
||||
public void exportKanbanExcel(@RequestBody KanbanQuery kanbanQuery, HttpServletResponse response) throws IOException {
|
||||
exportExcelEasyPoi.doExportKanbanExcel(kanbanQuery, response);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ public class TaskController {
|
|||
* @param stockInRequest 请求信息
|
||||
* @return 处理结果
|
||||
*/
|
||||
@PostMapping("/requireStockIn")
|
||||
//@PostMapping("/requireStockIn")
|
||||
public BaseWmsApiResponse requireStockIn(@RequestBody StockInRequest stockInRequest) {
|
||||
return taskControllerService.requireStockIn(stockInRequest);
|
||||
}
|
||||
|
|
@ -58,7 +58,7 @@ public class TaskController {
|
|||
* @param stockOutRequest 请求信息
|
||||
* @return 处理结果
|
||||
*/
|
||||
@PostMapping("/requireStockOut")
|
||||
//@PostMapping("/requireStockOut")
|
||||
public BaseWmsApiResponse requireStockOut(@RequestBody StockOutRequest stockOutRequest) {
|
||||
return taskControllerService.requireStockOut(stockOutRequest);
|
||||
}
|
||||
|
|
@ -103,10 +103,10 @@ public class TaskController {
|
|||
* @param voiRequest 请求信息
|
||||
* @return 处理结果
|
||||
*/
|
||||
@PostMapping("/requireVehiclesForIn")
|
||||
public BaseWmsApiResponse requireVehiclesForIn(@RequestBody VehicleOutForInRequest voiRequest) {
|
||||
return taskControllerService.requireVehiclesForIn(voiRequest);
|
||||
}
|
||||
// @PostMapping("/requireVehiclesForIn")
|
||||
// public BaseWmsApiResponse requireVehiclesForIn(@RequestBody VehicleOutForInRequest voiRequest) {
|
||||
// return taskControllerService.requireVehiclesForIn(voiRequest);
|
||||
// }
|
||||
|
||||
/**
|
||||
* 接收wcs反馈任务状态
|
||||
|
|
|
|||
|
|
@ -52,7 +52,7 @@ public class ImportExcelEasyPoi extends BaseImportExcelEasyPoi implements IImpor
|
|||
* @throws Exception 异常
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
//@Transactional(rollbackFor = Exception.class)
|
||||
public BaseWmsApiResponse doImportDbs(MultipartFile file, FileVo fileVo) throws Exception {
|
||||
// 设置解析条件
|
||||
ImportParams dbsImportparams = new ImportParams();
|
||||
|
|
@ -129,7 +129,7 @@ public class ImportExcelEasyPoi extends BaseImportExcelEasyPoi implements IImpor
|
|||
* @throws Exception 异常
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
//@Transactional(rollbackFor = Exception.class)
|
||||
public BaseWmsApiResponse doImportProduct(MultipartFile file, FileVo fileVo) throws Exception {
|
||||
// 设置解析条件
|
||||
ImportParams productImportparams = new ImportParams();
|
||||
|
|
@ -208,7 +208,7 @@ public class ImportExcelEasyPoi extends BaseImportExcelEasyPoi implements IImpor
|
|||
* @throws Exception 异常
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
//@Transactional(rollbackFor = Exception.class)
|
||||
public BaseWmsApiResponse doImportServiceProduct(MultipartFile file, FileVo fileVo) throws Exception {
|
||||
// 设置解析条件
|
||||
ImportParams productImportparams = new ImportParams();
|
||||
|
|
@ -311,7 +311,7 @@ public class ImportExcelEasyPoi extends BaseImportExcelEasyPoi implements IImpor
|
|||
* @throws Exception 异常
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
//@Transactional(rollbackFor = Exception.class)
|
||||
public BaseWmsApiResponse doImportProductExtend(MultipartFile file, FileVo fileVo) throws Exception {
|
||||
// 设置解析条件
|
||||
ImportParams productImportparams = new ImportParams();
|
||||
|
|
@ -358,7 +358,7 @@ public class ImportExcelEasyPoi extends BaseImportExcelEasyPoi implements IImpor
|
|||
* @return 导入结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
//@Transactional(rollbackFor = Exception.class)
|
||||
public BaseWmsApiResponse doImportBaseGoods(MultipartFile file, FileVo fileVo) throws Exception {
|
||||
// 设置解析条件
|
||||
ImportParams baseGoodsImportparams = new ImportParams();
|
||||
|
|
@ -422,7 +422,7 @@ public class ImportExcelEasyPoi extends BaseImportExcelEasyPoi implements IImpor
|
|||
* @throws Exception 异常
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
//@Transactional(rollbackFor = Exception.class)
|
||||
public BaseWmsApiResponse doImportKanban(MultipartFile file, FileVo fileVo) throws Exception {
|
||||
// 设置解析条件
|
||||
ImportParams kanbanImportparams = new ImportParams();
|
||||
|
|
@ -474,7 +474,7 @@ public class ImportExcelEasyPoi extends BaseImportExcelEasyPoi implements IImpor
|
|||
* @throws Exception 异常
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
//@Transactional(rollbackFor = Exception.class)
|
||||
public BaseWmsApiResponse doImportInventoryRequest(MultipartFile file, FileVo fileVo) throws Exception {
|
||||
// 设置解析条件
|
||||
ImportParams inventoryRequestImportparams = new ImportParams();
|
||||
|
|
|
|||
|
|
@ -53,6 +53,12 @@ public class StockConfirmEntity {
|
|||
@JsonProperty("warningQty")
|
||||
private Integer warningQty;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
@JsonProperty("remark")
|
||||
private String remark;
|
||||
|
||||
// /**
|
||||
// * 库存总剩余数量
|
||||
// */
|
||||
|
|
|
|||
|
|
@ -417,7 +417,7 @@ public class ConveyTaskServiceImpl implements IConveyTaskService {
|
|||
null,
|
||||
null,
|
||||
null,
|
||||
null
|
||||
null,null
|
||||
);
|
||||
resultVo = new WorkConfirmVo(orderConfirmVo, stockConfirmVo);
|
||||
break;
|
||||
|
|
@ -509,11 +509,13 @@ public class ConveyTaskServiceImpl implements IConveyTaskService {
|
|||
0,
|
||||
"ASRS",
|
||||
stockDataService.getWarningQty(),
|
||||
thisOuts.getWorkOrder(),
|
||||
thisOuts.getSpecialStock() ,
|
||||
thisOuts.getBatchNo(),
|
||||
thisOuts.getSpecialStockNo(),
|
||||
thisOuts.getSpecialStockItemNo()
|
||||
|
||||
|
||||
);
|
||||
resultVo = new TaskConfirmVo(thisPickTask.getPickStand(),false,taskConfirmVo, stockConfirmVo);
|
||||
break;
|
||||
|
|
|
|||
|
|
@ -567,6 +567,27 @@ public class StackerTaskServiceImpl implements IStackerTaskService {
|
|||
EwmApiBackResponse ewmApiBackResponse = ewmApiService.sendWarehouseInCompleted(request);
|
||||
if (!Objects.equals(ewmApiBackResponse.getState(), "successfully")) {
|
||||
log.error("调用EWM系统接口异常,请求参数: {}", request);
|
||||
// 需要将料箱下架,生成一个出库任务
|
||||
// 生成出库任务
|
||||
TAppTask outTask = new TAppTask(
|
||||
UUIDUtils.getNewUUID(),
|
||||
WmsTaskTypeEnums.OUT.getCode(),
|
||||
0,
|
||||
9,
|
||||
vehicleId,
|
||||
emptyVehicle.getLocationId(),
|
||||
null,
|
||||
null,
|
||||
LocalDateTime.now(),
|
||||
null,
|
||||
AppConstant.EMPTY_GOODS_ID,
|
||||
0,
|
||||
0,
|
||||
appOuts.getUserName(),
|
||||
"",
|
||||
appOuts.getDestination(),
|
||||
""
|
||||
);
|
||||
}else {
|
||||
log.info("调用EWM系统接口成功,请求参数: {}", request);
|
||||
}
|
||||
|
|
@ -581,7 +602,7 @@ public class StackerTaskServiceImpl implements IStackerTaskService {
|
|||
* @param stackerInTasks 已完成的入库任务
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
//@Transactional(rollbackFor = Exception.class)
|
||||
public void finishStackerInTasksMergeSameGoods(List<TAppTask> stackerInTasks) {
|
||||
// 入库任务完成需要做以下几件事情:
|
||||
// 1. 生成库存,如果是已有库存则更新库存状态、数量、库位这些信息。
|
||||
|
|
|
|||
|
|
@ -122,12 +122,12 @@ public class StockDataServiceImpl implements IStockDataService {
|
|||
// 回告EWM系统
|
||||
SendEwmVehicleForInRequest request = new SendEwmVehicleForInRequest();
|
||||
request.setContainerNo(stockConfirm.getVehicleId());
|
||||
// EwmApiBackResponse ewmApiBackResponse = ewmApiService.sendContainerEmpty(request);
|
||||
// if (!Objects.equals(ewmApiBackResponse.getState(), "successful")) {
|
||||
// log.error("容器置空调用EWM系统接口异常,请求参数: {}", request);
|
||||
// }else {
|
||||
// log.info("容器置空调用EWM系统接口成功,请求参数: {}", request);
|
||||
// }
|
||||
EwmApiBackResponse ewmApiBackResponse = ewmApiService.sendContainerEmpty(request);
|
||||
if (!Objects.equals(ewmApiBackResponse.getState(), "successful")) {
|
||||
log.error("容器置空调用EWM系统接口异常,请求参数: {}", request);
|
||||
}else {
|
||||
log.info("容器置空调用EWM系统接口成功,请求参数: {}", request);
|
||||
}
|
||||
}
|
||||
// 更新库存数量
|
||||
if (!updateStocks.isEmpty()) {
|
||||
|
|
|
|||
|
|
@ -120,7 +120,7 @@ public class KateWorkControllerServiceImpl implements IKateWorkControllerService
|
|||
* @return 初始化任务响应信息
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
//@Transactional(rollbackFor = Exception.class)
|
||||
public BaseWmsApiResponse initWorks(InitKateWorkRequest initKateWorkRequest) {
|
||||
if (initKateWorkRequest == null) {
|
||||
return BaseWmsApiResponse.error("请求信息为空,无法创建工作。");
|
||||
|
|
@ -281,7 +281,7 @@ public class KateWorkControllerServiceImpl implements IKateWorkControllerService
|
|||
* @return 查询结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
//@Transactional(rollbackFor = Exception.class)
|
||||
public WmsApiResponse<WorkConfirmVo> getCurrentWorks(KateWorksQuery kateWorksQuery) {
|
||||
if (kateWorksQuery == null || StringUtils.isEmpty(kateWorksQuery.getStandId())) {
|
||||
return WmsApiResponse.error("请求缺少信息,请输入站台号。", null);
|
||||
|
|
@ -318,7 +318,7 @@ public class KateWorkControllerServiceImpl implements IKateWorkControllerService
|
|||
stockDataService.getWarningQty(),null,
|
||||
null,
|
||||
null,
|
||||
null)
|
||||
null,null)
|
||||
|
||||
));
|
||||
}
|
||||
|
|
@ -377,7 +377,7 @@ public class KateWorkControllerServiceImpl implements IKateWorkControllerService
|
|||
* @return 确认结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
//@Transactional(rollbackFor = Exception.class)
|
||||
public BaseWmsApiResponse confirmCurrentWork(ConfirmWorkRequest confirmWorkRequest) {
|
||||
if (confirmWorkRequest == null || StringUtils.isEmpty(confirmWorkRequest.getStandId())) {
|
||||
return BaseWmsApiResponse.error("请求缺少信息,请输入站台号。");
|
||||
|
|
@ -505,7 +505,7 @@ public class KateWorkControllerServiceImpl implements IKateWorkControllerService
|
|||
* @return 显示信息
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
//@Transactional(rollbackFor = Exception.class)
|
||||
public WmsApiResponse<BoxDetailVo> getBoxesAndLacks(BaseWmsRequest request) {
|
||||
if (StringUtils.isEmpty(request.getStandId())) {
|
||||
// 站台号不能为空
|
||||
|
|
@ -680,7 +680,7 @@ public class KateWorkControllerServiceImpl implements IKateWorkControllerService
|
|||
* @return 生成结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
//@Transactional(rollbackFor = Exception.class)
|
||||
public WmsApiResponse<List<KanbanLackDetail>> genClcKanbanRequirement(GenKanbanRequirementRequest genRequest) {
|
||||
// 判断工单列表是否为空
|
||||
if (genRequest == null) {
|
||||
|
|
@ -1316,7 +1316,7 @@ public class KateWorkControllerServiceImpl implements IKateWorkControllerService
|
|||
* @return 删除结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
//@Transactional(rollbackFor = Exception.class)
|
||||
public BaseWmsApiResponse deleteDbsPlan(DbsRequest dbsRequest) {
|
||||
if (dbsRequest == null) {
|
||||
// 请求为空
|
||||
|
|
@ -1348,7 +1348,7 @@ public class KateWorkControllerServiceImpl implements IKateWorkControllerService
|
|||
* @return 删除结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
//@Transactional(rollbackFor = Exception.class)
|
||||
public BaseWmsApiResponse deleteKittingBom(KittingBomRequest kittingBomRequest) {
|
||||
if (kittingBomRequest == null) {
|
||||
// 请求为NULL
|
||||
|
|
@ -1579,7 +1579,7 @@ public class KateWorkControllerServiceImpl implements IKateWorkControllerService
|
|||
null,
|
||||
null,
|
||||
null,
|
||||
null
|
||||
null,null
|
||||
);
|
||||
return new WorkConfirmVo(orderConfirmVo, stockConfirmVo);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ public class LocationControllerServiceImpl implements ILocationControllerService
|
|||
* @return 处理结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
//@Transactional(rollbackFor = Exception.class)
|
||||
public BaseWmsApiResponse genLocations(LocationQuery locationQuery) {
|
||||
List<TAppLocation> locationList = appLocationService.list();
|
||||
List<TAppLocation> newLocationList = new ArrayList<>();
|
||||
|
|
|
|||
|
|
@ -90,7 +90,7 @@ public class TaskControllerServiceImpl implements ITaskControllerService {
|
|||
* @return 响应结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
//@Transactional(rollbackFor = Exception.class)
|
||||
public BaseWmsApiResponse requireStockIn(StockInRequest stockInRequest) {
|
||||
// 判断请求信息的正确性。
|
||||
if (stockInRequest == null || StringUtils.isEmpty(stockInRequest.getVehicleId())) {
|
||||
|
|
@ -250,7 +250,7 @@ public class TaskControllerServiceImpl implements ITaskControllerService {
|
|||
* @return 处理结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
//@Transactional(rollbackFor = Exception.class)
|
||||
public BaseWmsApiResponse requireStockOut(StockOutRequest stockOutRequest) {
|
||||
// 保存
|
||||
if (stockOutRequest == null || stockOutRequest.getNeedNum() == null
|
||||
|
|
@ -561,7 +561,7 @@ public class TaskControllerServiceImpl implements ITaskControllerService {
|
|||
"EWM",
|
||||
"SYSTEM",
|
||||
LocalDateTime.now(),
|
||||
null,
|
||||
task.getRemark(),
|
||||
task.getOrderNo(),
|
||||
task.getSpecialStock(),
|
||||
task.getSpecialStockNo(),
|
||||
|
|
@ -821,7 +821,7 @@ public class TaskControllerServiceImpl implements ITaskControllerService {
|
|||
* @return 处理结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
//@Transactional(rollbackFor = Exception.class)
|
||||
public BaseWmsApiResponse requireVehiclesForIn(VehicleOutForInRequest voiRequest) {
|
||||
// 验证请求正确性
|
||||
if (voiRequest == null || voiRequest.getGoodsIds() == null || voiRequest.getGoodsIds().isEmpty()) {
|
||||
|
|
@ -1316,6 +1316,16 @@ public class TaskControllerServiceImpl implements ITaskControllerService {
|
|||
}
|
||||
}
|
||||
|
||||
// 无事务的查询方法
|
||||
public TAppPickTask findPickTask(String vehicleNo) {
|
||||
return appPickTaskService.getOne(new LambdaQueryWrapper<TAppPickTask>()
|
||||
.eq(TAppPickTask::getVehicleId, vehicleNo)
|
||||
.eq(TAppPickTask::getPickStatus, WmsPickTaskStatusEnum.SEND.getCode())
|
||||
.orderByDesc(TAppPickTask::getCreateTime)
|
||||
.last("LIMIT 1"));
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 实现
|
||||
*
|
||||
|
|
@ -1331,11 +1341,7 @@ public class TaskControllerServiceImpl implements ITaskControllerService {
|
|||
|| StringUtils.isEmpty(boxArriveRequest.getLocation())) {
|
||||
return BaseWcsApiResponse.error("请求信息不完整,缺少载具号或者点位。");
|
||||
}
|
||||
TAppPickTask pickTask = appPickTaskService.getOne(new LambdaQueryWrapper<TAppPickTask>()
|
||||
.eq(TAppPickTask::getVehicleId, boxArriveRequest.getVehicleNo())
|
||||
.eq(TAppPickTask::getPickStatus, WmsPickTaskStatusEnum.SEND.getCode())
|
||||
.orderByDesc(TAppPickTask::getCreateTime) // 按创建时间倒序
|
||||
.last("LIMIT 1")); // 限制只返回一条记录
|
||||
TAppPickTask pickTask = findPickTask(boxArriveRequest.getVehicleNo());
|
||||
|
||||
if (pickTask == null) {
|
||||
return BaseWcsApiResponse.error("没有找到当前载具的拣选任务。");
|
||||
|
|
@ -1366,14 +1372,14 @@ public class TaskControllerServiceImpl implements ITaskControllerService {
|
|||
.gt(TAppPickTask::getPickStatus, WmsPickTaskStatusEnum.WAIT.getCode())
|
||||
.ne(TAppPickTask::getPickStatus, WmsPickTaskStatusEnum.FOR_IN.getCode()));
|
||||
|
||||
// // 更新拣选PLAN
|
||||
// boolean isUpdatePlanSuccess = appPickPlanService.update(new LambdaUpdateWrapper<TAppPickPlan>()
|
||||
// .set(TAppPickPlan::getStandId, boxArriveRequest.getLocation())
|
||||
// .eq(TAppPickPlan::getVehicleId, boxArriveRequest.getVehicleNo())
|
||||
// .eq(TAppPickPlan::getStandId, pickStand)
|
||||
// .last("LIMIT 1"));
|
||||
// 更新拣选PLAN
|
||||
boolean isUpdatePlanSuccess = appPickPlanService.update(new LambdaUpdateWrapper<TAppPickPlan>()
|
||||
.set(TAppPickPlan::getStandId, boxArriveRequest.getLocation())
|
||||
.eq(TAppPickPlan::getVehicleId, boxArriveRequest.getVehicleNo())
|
||||
.eq(TAppPickPlan::getStandId, pickStand)
|
||||
.last("LIMIT 1"));
|
||||
|
||||
boolean isUpdatePlanSuccess = updatePickPlanInNewTransaction(boxArriveRequest, pickStand);
|
||||
//boolean isUpdatePlanSuccess = updatePickPlanInNewTransaction(boxArriveRequest, pickStand);
|
||||
|
||||
if (isUpdateSuccess && isUpdatePlanSuccess) {
|
||||
// 更新成功,返回成功
|
||||
|
|
@ -1384,15 +1390,6 @@ public class TaskControllerServiceImpl implements ITaskControllerService {
|
|||
}
|
||||
}
|
||||
|
||||
@Transactional(propagation = Propagation.REQUIRES_NEW, rollbackFor = Exception.class)
|
||||
public boolean updatePickPlanInNewTransaction(WcsBoxArriveRequest boxArriveRequest, String pickStand) {
|
||||
return appPickPlanService.update(new LambdaUpdateWrapper<TAppPickPlan>()
|
||||
.set(TAppPickPlan::getStandId, boxArriveRequest.getLocation())
|
||||
.eq(TAppPickPlan::getVehicleId, boxArriveRequest.getVehicleNo())
|
||||
.eq(TAppPickPlan::getStandId, pickStand)
|
||||
.last("LIMIT 1"));
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 取消拣选任务实现
|
||||
|
|
@ -1431,7 +1428,7 @@ public class TaskControllerServiceImpl implements ITaskControllerService {
|
|||
* @return 获取结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
//@Transactional(rollbackFor = Exception.class)
|
||||
public WmsApiResponse<List<TaskConfirmVo>> getCurrentTask(BaseWmsRequest wmsRequest) {
|
||||
if (wmsRequest == null || StringUtils.isEmpty(wmsRequest.getStandId())) {
|
||||
// 缺少站台号
|
||||
|
|
@ -1556,26 +1553,26 @@ public class TaskControllerServiceImpl implements ITaskControllerService {
|
|||
return BaseWmsApiResponse.error("当前任务不存在或已经拣选完毕,请刷新后重试。");
|
||||
}
|
||||
|
||||
// // 调用EWM系统检验箱子
|
||||
// SendEwmCheckContainerNo request = new SendEwmCheckContainerNo();
|
||||
// request.setContainerNo(confirmTaskRequest.getTaskConfirm().getContainerNo());
|
||||
// request.setType(thisOut.getPickingType());
|
||||
// request.setFirstOrSecond(false);
|
||||
// request.setCheckKey(thisOut.getSecondPickingCode());
|
||||
// EwmApiBackResponse ewmResponse = ewmApiService.sendEwmCheckContainerNo(request);
|
||||
// // 检查 EWM 系统返回结果
|
||||
// if (ewmResponse == null) {
|
||||
// return BaseWmsApiResponse.error("EWM系统无响应,请检查网络连接。");
|
||||
// }
|
||||
// // 检查返回内容是否为空
|
||||
// if (ewmResponse.getContent() == null) {
|
||||
// // 根据 state 状态处理
|
||||
// if ("successfully".equals(ewmResponse.getState())) {
|
||||
// return BaseWmsApiResponse.success("操作成功,但无返回内容。");
|
||||
// } else {
|
||||
// return BaseWmsApiResponse.error("EWM系统返回异常:" + (ewmResponse.getMessage() != null ? ewmResponse.getMessage() : "未知错误"));
|
||||
// }
|
||||
// }
|
||||
// 调用EWM系统检验箱子
|
||||
SendEwmCheckContainerNo request = new SendEwmCheckContainerNo();
|
||||
request.setContainerNo(confirmTaskRequest.getTaskConfirm().getContainerNo());
|
||||
request.setType(thisOut.getPickingType());
|
||||
request.setFirstOrSecond(false);
|
||||
request.setCheckKey(thisOut.getSecondPickingCode());
|
||||
EwmApiBackResponse ewmResponse = ewmApiService.sendEwmCheckContainerNo(request);
|
||||
// 检查 EWM 系统返回结果
|
||||
if (ewmResponse == null) {
|
||||
return BaseWmsApiResponse.error("EWM系统无响应,请检查网络连接。");
|
||||
}
|
||||
// 检查返回内容是否为空
|
||||
if (ewmResponse.getContent() == null) {
|
||||
// 根据 state 状态处理
|
||||
if ("successfully".equals(ewmResponse.getState())) {
|
||||
return BaseWmsApiResponse.success("操作成功,但无返回内容。");
|
||||
} else {
|
||||
return BaseWmsApiResponse.error("EWM系统返回异常:" + (ewmResponse.getMessage() != null ? ewmResponse.getMessage() : "未知错误"));
|
||||
}
|
||||
}
|
||||
|
||||
// 检测目标箱号是否存在别的物料,以颗粒度为第一优先级,如果颗粒度为空,则使用工单号
|
||||
List<TAppOutsCheck> thisOutsChecks = appOutsCheckService.list(new LambdaQueryWrapper<TAppOutsCheck>()
|
||||
|
|
@ -2140,19 +2137,20 @@ public class TaskControllerServiceImpl implements ITaskControllerService {
|
|||
request.setPickingDetail(pickingDetails);
|
||||
request.setWaveNo(outs.getWaveNo());
|
||||
request.setPickingType(outs.getPickingType());
|
||||
// EwmApiBackResponse ewmApiBackResponse = ewmApiService.sendWarehouseOutCompleted(request);
|
||||
// if (Objects.equals(ewmApiBackResponse.getState(), "successfully")) {
|
||||
// log.info("调用EWM系统接口成功,请求参数: {}", request);
|
||||
// appOutsCheckService.remove(new LambdaQueryWrapper<TAppOutsCheck>()
|
||||
// .eq(TAppOutsCheck::getTaskNo, taskConfirm.getTaskId()));
|
||||
// }else {
|
||||
// log.error("调用EWM系统接口异常,请求参数: {}", request);
|
||||
// // 触发事务回滚
|
||||
// TransactionAspectSupport.currentTransactionStatus().setRollbackOnly();
|
||||
// // 返回错误信息
|
||||
// return ewmApiBackResponse.toString();
|
||||
//
|
||||
// }
|
||||
EwmApiBackResponse ewmApiBackResponse = ewmApiService.sendWarehouseOutCompleted(request);
|
||||
if (Objects.equals(ewmApiBackResponse.getState(), "successfully")) {
|
||||
log.info("调用EWM系统接口成功,请求参数: {}", request);
|
||||
appOutsCheckService.remove(new LambdaQueryWrapper<TAppOutsCheck>()
|
||||
.eq(TAppOutsCheck::getTaskNo, taskConfirm.getTaskId())
|
||||
);
|
||||
}else {
|
||||
log.error("调用EWM系统接口异常,请求参数: {}", request);
|
||||
// 触发事务回滚
|
||||
TransactionAspectSupport.currentTransactionStatus().setRollbackOnly();
|
||||
// 返回错误信息
|
||||
return ewmApiBackResponse.toString();
|
||||
|
||||
}
|
||||
|
||||
// 生成记录
|
||||
TAppOutsRecord record = new TAppOutsRecord(
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@ package com.wms_main.service.quartz_job.serviceImpl;
|
|||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.wms_main.app.AppCommon;
|
||||
import com.wms_main.constant.AppConstant;
|
||||
import com.wms_main.constant.enums.wms.*;
|
||||
|
|
@ -43,6 +44,7 @@ public class OutsExecutorServiceImpl implements IOutsExecutorService {
|
|||
private final ITAppInventoryService appInventoryService;// 盘点任务服务
|
||||
private final AppCommon appCommon;// 应用共通数据
|
||||
|
||||
|
||||
/**
|
||||
* 解析出库单 实现
|
||||
*/
|
||||
|
|
@ -53,15 +55,22 @@ public class OutsExecutorServiceImpl implements IOutsExecutorService {
|
|||
// 查询到对应的出库单
|
||||
// List<TAppOuts> appOutsList = appOutsService.list(
|
||||
// new LambdaQueryWrapper<TAppOuts>().orderByDesc(TAppOuts::getOutType)
|
||||
// );
|
||||
// List<TAppOuts> appOutsList = appOutsService.list(
|
||||
// new LambdaQueryWrapper<TAppOuts>()
|
||||
// .le(TAppOuts::getPickingDate, LocalDate.now())
|
||||
// .orderByDesc(TAppOuts::getOutType)
|
||||
// );
|
||||
List<TAppOuts> appOutsList = appOutsService.list(
|
||||
new LambdaQueryWrapper<TAppOuts>()
|
||||
.le(TAppOuts::getPickingDate, LocalDate.now())
|
||||
// .orderByDesc(TAppOuts::getOutType)
|
||||
);
|
||||
new LambdaQueryWrapper<TAppOuts>()
|
||||
.le(TAppOuts::getPickingDate, LocalDate.now())
|
||||
.orderByDesc(TAppOuts::getOutType)
|
||||
.last("LIMIT 15") // 限制只查询15条记录
|
||||
).stream()
|
||||
.filter(appOuts -> appOuts.getDistributeNum() < appOuts.getNeedNum())
|
||||
.toList();
|
||||
|
||||
|
||||
if (appOutsList == null || appOutsList.isEmpty()) {
|
||||
if (appOutsList.isEmpty()) {
|
||||
return;
|
||||
}
|
||||
// 需要保存的信息
|
||||
|
|
@ -72,15 +81,30 @@ public class OutsExecutorServiceImpl implements IOutsExecutorService {
|
|||
// 拣选任务
|
||||
List<TAppPickTask> pickTasks = appPickTaskService.list();
|
||||
// 查询库存,条件:剩余数量>0,回库中、锁定以外的库存状态。
|
||||
List<TAppStock> allStocks = appStockService.list(new LambdaQueryWrapper<TAppStock>()
|
||||
.le(TAppStock::getStockStatus, WmsStockStatusEnums.OUTED.getCode())
|
||||
.gt(TAppStock::getRemainNum, 0)
|
||||
.orderByAsc(TAppStock::getFirstInTime));
|
||||
List<TAppVehicle> emptyVehicles = appVehicleService.list(new LambdaQueryWrapper<TAppVehicle>()
|
||||
.eq(TAppVehicle::getIsEmpty, 1)
|
||||
.eq(TAppVehicle::getVehicleStatus, WmsVehicleStatusEnums.ON.getCode())
|
||||
.orderByAsc(TAppVehicle::getLastInTime)); // 先进先出
|
||||
// 获取可用堆垛机
|
||||
// List<TAppStock> allStocks = appStockService.list(new LambdaQueryWrapper<TAppStock>()
|
||||
// .le(TAppStock::getStockStatus, WmsStockStatusEnums.OUTED.getCode())
|
||||
// .gt(TAppStock::getRemainNum, 0)
|
||||
// .orderByAsc(TAppStock::getFirstInTime));
|
||||
|
||||
Set<String> requiredGoodsIds = appOutsList.stream()
|
||||
.map(TAppOuts::getGoodsId)
|
||||
.filter(StringUtils::isNotEmpty)
|
||||
.collect(Collectors.toSet());
|
||||
|
||||
List<TAppStock> allStocks = new ArrayList<>();
|
||||
if (!requiredGoodsIds.isEmpty()) {
|
||||
allStocks = appStockService.list(new LambdaQueryWrapper<TAppStock>()
|
||||
.in(TAppStock::getGoodsId, requiredGoodsIds)
|
||||
.le(TAppStock::getStockStatus, WmsStockStatusEnums.OUTED.getCode())
|
||||
.gt(TAppStock::getRemainNum, 0)
|
||||
.orderByAsc(TAppStock::getFirstInTime));
|
||||
}
|
||||
|
||||
// List<TAppVehicle> emptyVehicles = appVehicleService.list(new LambdaQueryWrapper<TAppVehicle>()
|
||||
// .eq(TAppVehicle::getIsEmpty, 1)
|
||||
// .eq(TAppVehicle::getVehicleStatus, WmsVehicleStatusEnums.ON.getCode())
|
||||
// .orderByAsc(TAppVehicle::getLastInTime)); // 先进先出
|
||||
// // 获取可用堆垛机
|
||||
List<TAppEquipment> usableStackers = appEquipmentService.list(new LambdaQueryWrapper<TAppEquipment>()
|
||||
.eq(TAppEquipment::getEquipmentType, 1)
|
||||
.eq(TAppEquipment::getEquipmentStatus, WmsUsableStatusEnums.USABLE.getCode()));
|
||||
|
|
@ -90,15 +114,15 @@ public class OutsExecutorServiceImpl implements IOutsExecutorService {
|
|||
if (appOuts.getDistributeNum() >= appOuts.getNeedNum()) {
|
||||
continue;
|
||||
}
|
||||
// 判断目前是否是空箱任务
|
||||
if (Objects.equals(appOuts.getOutType(), WmsOutTypeEnums.EMPTY.getCode())) {
|
||||
solveEmpty(appOuts, emptyVehicles, equipVehicleMap, newOutWmsTasks, thisTimeOutVehicleIds);
|
||||
} else if (Objects.equals(appOuts.getOutType(), WmsOutTypeEnums.FOR_IN.getCode())) {
|
||||
solveOutForIn(equipVehicleMap, appOuts, allStocks, pickTasks, newOutWmsTasks, newPickTasks, thisTimeOutVehicleIds);
|
||||
} else if (Objects.equals(appOuts.getOutType(), WmsOutTypeEnums.EMERGE.getCode())) {
|
||||
// // 判断目前是否是空箱任务
|
||||
// if (Objects.equals(appOuts.getOutType(), WmsOutTypeEnums.EMPTY.getCode())) {
|
||||
// solveEmpty(appOuts, emptyVehicles, equipVehicleMap, newOutWmsTasks, thisTimeOutVehicleIds);
|
||||
// } else if (Objects.equals(appOuts.getOutType(), WmsOutTypeEnums.FOR_IN.getCode())) {
|
||||
// solveOutForIn(equipVehicleMap, appOuts, allStocks, pickTasks, newOutWmsTasks, newPickTasks, thisTimeOutVehicleIds);
|
||||
// } else if (Objects.equals(appOuts.getOutType(), WmsOutTypeEnums.EMERGE.getCode())) {
|
||||
// 紧急出库
|
||||
solveEmerge(equipVehicleMap, appOuts, allStocks, pickTasks, newOutWmsTasks, newPickTasks, thisTimeOutVehicleIds, newPickPlans);
|
||||
}
|
||||
solveEmerge(equipVehicleMap, appOuts, allStocks, pickTasks, newOutWmsTasks, newPickTasks, thisTimeOutVehicleIds, newPickPlans);
|
||||
//}
|
||||
}
|
||||
// 保存出库单---只更新分配数量
|
||||
List<TAppOuts> onlyDistributeNumOuts = appOutsList.stream().map(outs -> {
|
||||
|
|
|
|||
|
|
@ -10,6 +10,8 @@ spring:
|
|||
# password: developer
|
||||
# 本地
|
||||
url: jdbc:mysql://localhost:3306/wms_fengshang_yangzhou?characterEncoding=utf8&serverTimezone=Asia/Shanghai&allowMultiQueries=true&rewriteBatchedStatements=true
|
||||
# username: wms
|
||||
# password: Admin123
|
||||
username: root
|
||||
password: 123456
|
||||
#在线
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user