|
|
@ -27,6 +27,10 @@
|
|
|
|
<div style="text-align: center">
|
|
|
|
<div style="text-align: center">
|
|
|
|
<el-button type="success" v-if="(!$route.query || $route.query.id!=='2')" :disabled="form.planDetailStatus === '已完成' || !form.planDetailCode" @click="getMaterials('0')">领料
|
|
|
|
<el-button type="success" v-if="(!$route.query || $route.query.id!=='2')" :disabled="form.planDetailStatus === '已完成' || !form.planDetailCode" @click="getMaterials('0')">领料
|
|
|
|
</el-button>
|
|
|
|
</el-button>
|
|
|
|
|
|
|
|
<el-button type="warning" v-if="(!$route.query || $route.query.id!=='2')" :disabled="form.planDetailStatus === '已完成' || !form.planDetailCode" @click="handleMaterialConfirmForm()">扫描
|
|
|
|
|
|
|
|
</el-button>
|
|
|
|
|
|
|
|
<el-button type="danger" v-if="(!$route.query || $route.query.id!=='2')" :disabled="!form.planDetailCode">退料
|
|
|
|
|
|
|
|
</el-button>
|
|
|
|
<el-button type="primary" v-if="($route.query && $route.query.id) === '2'" :disabled="form.planDetailStatus === '已完成' || !form.planDetailCode" @click="getMaterials('1')">
|
|
|
|
<el-button type="primary" v-if="($route.query && $route.query.id) === '2'" :disabled="form.planDetailStatus === '已完成' || !form.planDetailCode" @click="getMaterials('1')">
|
|
|
|
领柜体
|
|
|
|
领柜体
|
|
|
|
</el-button>
|
|
|
|
</el-button>
|
|
|
@ -368,6 +372,30 @@
|
|
|
|
</el-dialog>
|
|
|
|
</el-dialog>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<el-dialog
|
|
|
|
|
|
|
|
:visible.sync="materialConfirmVisible"
|
|
|
|
|
|
|
|
title="确认物料使用"
|
|
|
|
|
|
|
|
width="40%">
|
|
|
|
|
|
|
|
<el-form ref="materialConfirmForm" :model="materialConfirmForm" :rules="materialConfirmRules" label-width="80px">
|
|
|
|
|
|
|
|
<el-form-item label="计划ID" prop="planId" v-if="false">
|
|
|
|
|
|
|
|
<el-input v-model="materialConfirmForm.planId"></el-input>
|
|
|
|
|
|
|
|
</el-form-item>
|
|
|
|
|
|
|
|
<el-form-item label="明细ID" prop="planDetailId" v-if="false">
|
|
|
|
|
|
|
|
<el-input v-model="materialConfirmForm.planDetailId"></el-input>
|
|
|
|
|
|
|
|
</el-form-item>
|
|
|
|
|
|
|
|
<el-form-item label="物料条码" prop="materialBarcode">
|
|
|
|
|
|
|
|
<el-input v-model="materialConfirmForm.materialBarcode"></el-input>
|
|
|
|
|
|
|
|
</el-form-item>
|
|
|
|
|
|
|
|
<el-form-item label="数量" prop="checkAmount">
|
|
|
|
|
|
|
|
<el-input v-model="materialConfirmForm.checkAmount"></el-input>
|
|
|
|
|
|
|
|
</el-form-item>
|
|
|
|
|
|
|
|
</el-form>
|
|
|
|
|
|
|
|
<div slot="footer" class="dialog-footer">
|
|
|
|
|
|
|
|
<el-button type="primary" @click="submitMaterialConfirm">确 定</el-button>
|
|
|
|
|
|
|
|
<el-button @click="cancelMaterialConfirm">取 消</el-button>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
</el-dialog>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- <el-dialog :visible.sync="assignModel" title="工位选择" width="80%">-->
|
|
|
|
<!-- <el-dialog :visible.sync="assignModel" title="工位选择" width="80%">-->
|
|
|
|
|
|
|
|
|
|
|
|
<!-- <el-table :data="stationData" highlight-current-row-->
|
|
|
|
<!-- <el-table :data="stationData" highlight-current-row-->
|
|
|
@ -418,7 +446,7 @@ import {
|
|
|
|
getWarehouses,
|
|
|
|
getWarehouses,
|
|
|
|
bindBarcode,
|
|
|
|
bindBarcode,
|
|
|
|
applyRawBack,
|
|
|
|
applyRawBack,
|
|
|
|
assignTask
|
|
|
|
assignTask, scanMaterial2Confirm
|
|
|
|
} from "@/api/board";
|
|
|
|
} from "@/api/board";
|
|
|
|
|
|
|
|
|
|
|
|
const setState = (e) => {
|
|
|
|
const setState = (e) => {
|
|
|
@ -469,6 +497,22 @@ export default {
|
|
|
|
},
|
|
|
|
},
|
|
|
|
submitAssignLoading: false,
|
|
|
|
submitAssignLoading: false,
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
materialConfirmVisible: false,
|
|
|
|
|
|
|
|
materialConfirmForm: {
|
|
|
|
|
|
|
|
materialBarcode: null,
|
|
|
|
|
|
|
|
planId: null,
|
|
|
|
|
|
|
|
planDetailId:null,
|
|
|
|
|
|
|
|
checkAmount:null
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
materialConfirmRules: {
|
|
|
|
|
|
|
|
materialBarcode: [
|
|
|
|
|
|
|
|
{ required: true, message: "物料条码不能为空", trigger: "blur" }
|
|
|
|
|
|
|
|
],
|
|
|
|
|
|
|
|
checkAmount: [
|
|
|
|
|
|
|
|
{ required: true, message: "数量不能为空", trigger: "blur" }
|
|
|
|
|
|
|
|
],
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
tableData: [],
|
|
|
|
tableData: [],
|
|
|
|
nowStation: null,
|
|
|
|
nowStation: null,
|
|
|
|
stationData: [
|
|
|
|
stationData: [
|
|
|
@ -1342,6 +1386,47 @@ export default {
|
|
|
|
this.resetRawBack();
|
|
|
|
this.resetRawBack();
|
|
|
|
},
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 表单重置
|
|
|
|
|
|
|
|
resetMaterialConfirm() {
|
|
|
|
|
|
|
|
this.materialConfirmForm = {
|
|
|
|
|
|
|
|
materialBarcode: null,
|
|
|
|
|
|
|
|
planId: null,
|
|
|
|
|
|
|
|
planDetailId:null,
|
|
|
|
|
|
|
|
checkAmount:null
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
this.resetForm("materialConfirmForm");
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/** 扫描物料确认使用按钮操作 */
|
|
|
|
|
|
|
|
handleMaterialConfirmForm() {
|
|
|
|
|
|
|
|
this.materialConfirmForm = {
|
|
|
|
|
|
|
|
materialBarcode: null,
|
|
|
|
|
|
|
|
planId: this.form.planId,
|
|
|
|
|
|
|
|
planDetailId:this.form.planDetailId,
|
|
|
|
|
|
|
|
checkAmount:null
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
this.materialConfirmVisible = true;
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
submitMaterialConfirm(){
|
|
|
|
|
|
|
|
this.$refs["materialConfirmForm"].validate(valid => {
|
|
|
|
|
|
|
|
if (valid) {
|
|
|
|
|
|
|
|
scanMaterial2Confirm(this.materialConfirmForm).then(response => {
|
|
|
|
|
|
|
|
this.$modal.msgSuccess("确认成功");
|
|
|
|
|
|
|
|
this.cancelMaterialConfirm();
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
cancelMaterialConfirm(){
|
|
|
|
|
|
|
|
this.materialConfirmVisible = false;
|
|
|
|
|
|
|
|
this.resetMaterialConfirm();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
</script>
|
|
|
|
</script>
|
|
|
|