Merge remote-tracking branch 'origin/master'
This commit is contained in:
@@ -183,28 +183,44 @@ public class MydoJobServiceImpl implements IMydoJobService {
|
||||
if (job == null) {
|
||||
return AjaxResult.warn("任务不存在");
|
||||
}
|
||||
MydoJobDetail param = new MydoJobDetail();
|
||||
param.setJobId(jobId);
|
||||
List<MydoJobDetail> mydoJobDetails = mydoJobDetailService.selectMydoJobDetailList(param);
|
||||
if (CollUtil.isNotEmpty(mydoJobDetails)) {
|
||||
List<BasStock> list = new ArrayList<>();
|
||||
for (MydoJobDetail mydoJobDetail : mydoJobDetails) {
|
||||
list.add(getStockByInStockinDetail(mydoJobDetail, job));
|
||||
}
|
||||
basStockService.insertBasStockList(list);
|
||||
mydoJob.setStatus("4");
|
||||
updateMydoJob(mydoJob);
|
||||
if (job.getInOrOut().equals("5")){
|
||||
//料箱盘点入库作业
|
||||
|
||||
//修改货位
|
||||
BasCargoSpace basCargoSpace = new BasCargoSpace();
|
||||
basCargoSpace.setStatus("2");
|
||||
basCargoSpace.setStatus("5");
|
||||
basCargoSpace.setTrayCode(job.getTrayCode());
|
||||
basCargoSpace.setCargoSpaceId(job.getCargoSpaceId());
|
||||
basCargoSpaceService.updateBasCargoSpace(basCargoSpace);
|
||||
//插入历史表
|
||||
insertHistory(mydoJob.getJobId());
|
||||
|
||||
return AjaxResult.success();
|
||||
|
||||
}else {
|
||||
//正常入库作业
|
||||
|
||||
MydoJobDetail param = new MydoJobDetail();
|
||||
param.setJobId(jobId);
|
||||
List<MydoJobDetail> mydoJobDetails = mydoJobDetailService.selectMydoJobDetailList(param);
|
||||
if (CollUtil.isNotEmpty(mydoJobDetails)) {
|
||||
List<BasStock> list = new ArrayList<>();
|
||||
for (MydoJobDetail mydoJobDetail : mydoJobDetails) {
|
||||
list.add(getStockByInStockinDetail(mydoJobDetail, job));
|
||||
}
|
||||
basStockService.insertBasStockList(list);
|
||||
mydoJob.setStatus("4");
|
||||
updateMydoJob(mydoJob);
|
||||
//修改货位
|
||||
BasCargoSpace basCargoSpace = new BasCargoSpace();
|
||||
basCargoSpace.setStatus("2");
|
||||
basCargoSpace.setTrayCode(job.getTrayCode());
|
||||
basCargoSpace.setCargoSpaceId(job.getCargoSpaceId());
|
||||
basCargoSpaceService.updateBasCargoSpace(basCargoSpace);
|
||||
//插入历史表
|
||||
insertHistory(mydoJob.getJobId());
|
||||
}
|
||||
return AjaxResult.success();
|
||||
}
|
||||
|
||||
return AjaxResult.success();
|
||||
}
|
||||
|
||||
private BasStock getStockByInStockinDetail(MydoJobDetail mydoJobDetail, MydoJob mydoJob) {
|
||||
|
||||
@@ -237,6 +237,7 @@ public class PdaController extends BaseController {
|
||||
* @param trayCodeMakeSure 托盘信息
|
||||
* @return
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('pda:out:outMakeSure')")
|
||||
@PostMapping("/outMakeSure")
|
||||
@ResponseBody
|
||||
public AjaxResult outMakeSure(@RequestBody TrayCodeMakeSure trayCodeMakeSure) {
|
||||
@@ -248,6 +249,7 @@ public class PdaController extends BaseController {
|
||||
* @param trayCodeMakeSure 托盘信息
|
||||
* @return
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('pda:check:checkMakeSure')")
|
||||
@PostMapping("/checkMakeSure")
|
||||
@ResponseBody
|
||||
public AjaxResult checkMakeSure(@RequestBody TrayCodeMakeSure trayCodeMakeSure) {
|
||||
|
||||
@@ -252,12 +252,17 @@ public class PdaServiceImp implements PdaService {
|
||||
public AjaxResult checkMakeSure(TrayCodeMakeSure trayCodeMakeSure) {
|
||||
List<MydoJobDetail> mydoJobDetailList = trayCodeMakeSure.getMydoJobDetailList();
|
||||
if(CollUtil.isNotEmpty(mydoJobDetailList)){
|
||||
boolean flag = mydoJobDetailList.stream().anyMatch(x -> StrUtil.isEmpty(x.getStockId()) && "0".equals(x.getInQuantity()));
|
||||
if (flag){
|
||||
return AjaxResult.warn("新增库存,存在为0的数量");
|
||||
}
|
||||
for (MydoJobDetail mydoJobDetail : mydoJobDetailList) {
|
||||
CheckCommitRecord checkCommitRecord = new CheckCommitRecord();
|
||||
checkCommitRecord.setQuantity(mydoJobDetail.getInQuantity());
|
||||
checkCommitRecord.setTrayCode(trayCodeMakeSure.getTrayCode());
|
||||
checkCommitRecord.setStockId(mydoJobDetail.getStockId());
|
||||
checkCommitRecord.setSpare1(mydoJobDetail.getInOrOutDId());
|
||||
checkCommitRecord.setSpare2(mydoJobDetail.getProductId());
|
||||
checkCommitRecordService.insertCheckCommitRecord(checkCommitRecord);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -93,8 +93,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<if test="classId != null and classId != ''"> and class_id = #{classId}</if>
|
||||
<if test="warehouseId != null and warehouseId != ''"> and warehouse_id = #{warehouseId}</if>
|
||||
<if test="faultFlag != null and faultFlag != ''"> and fault_flag = #{faultFlag}</if>
|
||||
<if test="inOut != null and inOut != '' and inOut =='2'.toString "> and mj.in_or_out >=20</if>
|
||||
<if test="inOut != null and inOut != '' and inOut =='1'.toString "> and mj.in_or_out < 20</if>
|
||||
<if test="inOut != null and inOut != '' and inOut =='2'.toString "> and in_or_out >=20</if>
|
||||
<if test="inOut != null and inOut != '' and inOut =='1'.toString "> and in_or_out < 20</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
|
||||
@@ -514,7 +514,7 @@ export default {
|
||||
|
||||
// 手动完成/作废
|
||||
handleCompletedManually(row) {
|
||||
console.log("1111")
|
||||
//console.log("1111")
|
||||
const jobIds = this.ids;
|
||||
if (jobIds.length === 0) {
|
||||
this.$modal.msgError("请选择要操作的数据");
|
||||
@@ -531,11 +531,13 @@ export default {
|
||||
//手动作废
|
||||
manualInvalidation(data).then(response => {
|
||||
this.$modal.msgSuccess("操作成功");
|
||||
this.getList();
|
||||
})
|
||||
}else if (row.type === 'completed'){
|
||||
//手动完成
|
||||
manualCompleted(data).then(response => {
|
||||
this.$modal.msgSuccess("操作成功");
|
||||
this.getList();
|
||||
})
|
||||
}
|
||||
},
|
||||
|
||||
@@ -320,7 +320,8 @@
|
||||
<!-- </template>-->
|
||||
<!-- </el-table-column>-->
|
||||
<el-table-column :label="$t('checkJobOut.billId')" align="center" prop="inOrOutId" /> <!-- 单据ID -->
|
||||
<el-table-column :label="$t('checkJobOut.subBillId')" align="center" prop="productId" /> <!-- 子单据ID -->
|
||||
<el-table-column :label="$t('checkJobOut.subBillId')" align="center" prop="inOrOutDId" /> <!-- 单据ID -->
|
||||
<el-table-column :label="$t('checkJobOut.productId')" align="center" prop="productId" /> <!-- 物料id -->
|
||||
<el-table-column :label="$t('checkJobOut.materialDesc')" align="center" prop="extraField.materialDesc" /> <!-- 物料编码 -->
|
||||
<el-table-column :label="$t('checkJobOut.englishDesc')" align="center" prop="extraField.englishDesc" /> // 英文描述
|
||||
<!-- <el-table-column :label="$t('checkJobOut.cartonNo')" align="center" prop="extraField.cartonNo" /> // 箱号-->
|
||||
|
||||
@@ -17,8 +17,8 @@
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item :label="$t('stockManagement.stockStatus')" prop="stockStatus"><!-- 库存状态 -->
|
||||
<el-select v-model="queryParams.stockStatus" :placeholder="$t('stockManagement.selectStockStatus')" clearable>
|
||||
<el-form-item :label="$t('stockManagement.stockStatus')" prop="cargoSpaceStockStatus"><!-- 库存状态 -->
|
||||
<el-select v-model="queryParams.cargoSpaceStockStatus" :placeholder="$t('stockManagement.selectStockStatus')" clearable>
|
||||
<el-option
|
||||
v-for="dict in dict.type.stock_status"
|
||||
:key="dict.value"
|
||||
@@ -250,9 +250,9 @@
|
||||
<el-table-column :label="$t('stockManagement.stockId')" align="center" prop="stockId" /> <!-- 库存id -->
|
||||
<el-table-column :label="$t('stockManagement.cargoSpaceId')" align="center" prop="cargoSpaceId" /> <!-- 货位id -->
|
||||
<el-table-column :label="$t('stockManagement.cargoSpaceName')" align="center" prop="cargoSpaceName" /> <!-- 货位id -->
|
||||
<el-table-column :label="$t('stockManagement.stockStatus')" align="center" prop="stockStatus"> <!-- 库存状态 -->
|
||||
<el-table-column :label="$t('stockManagement.stockStatus')" align="center" prop="cargoSpaceStockStatus"> <!-- 库存状态 -->
|
||||
<template slot-scope="scope">
|
||||
<dict-tag :options="dict.type.stock_status" :value="scope.row.stockStatus"/>
|
||||
<dict-tag :options="dict.type.stock_status" :value="scope.row.cargoSpaceStockStatus"/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column :label="$t('stockManagement.cargoSpaceStatus')" align="center" prop="cargoSpaceStatus" >
|
||||
@@ -323,8 +323,8 @@
|
||||
<el-form-item :label="$t('stockManagement.cargoSpaceId')" prop="cargoSpaceId"> <!-- 货位id -->
|
||||
<el-input v-model="form.cargoSpaceId" :placeholder="$t('stockManagement.inputCargoSpaceId')" />
|
||||
</el-form-item>
|
||||
<el-form-item :label="$t('stockManagement.stockStatus')" prop="stockStatus"> <!-- 库存状态 -->
|
||||
<el-select v-model="form.stockStatus" :placeholder="$t('stockManagement.selectStockStatus')">
|
||||
<el-form-item :label="$t('stockManagement.stockStatus')" prop="cargoSpaceStockStatus"> <!-- 库存状态 -->
|
||||
<el-select v-model="form.cargoSpaceStockStatus" :placeholder="$t('stockManagement.selectStockStatus')">
|
||||
<el-option
|
||||
v-for="dict in dict.type.stock_status"
|
||||
:key="dict.value"
|
||||
|
||||
Reference in New Issue
Block a user