|
|
|
@ -3,7 +3,7 @@
|
|
|
|
|
<div class="headTitle">京源环保生产管理系统</div>
|
|
|
|
|
|
|
|
|
|
<div class="chartBox chartBox1">
|
|
|
|
|
<div class="title">工单信息</div>
|
|
|
|
|
<div class="title">生产详细信息</div>
|
|
|
|
|
<div class="chart">
|
|
|
|
|
<div class="form">
|
|
|
|
|
|
|
|
|
@ -26,6 +26,8 @@
|
|
|
|
|
</el-form>
|
|
|
|
|
<div style="text-align: center">
|
|
|
|
|
<el-button type="primary" @click="getMaterials">领料</el-button>
|
|
|
|
|
<el-button v-if="($route.query && $route.query.id) === '2'" type="info" @click="handleBindBarcode">绑定</el-button>
|
|
|
|
|
<el-button v-if="($route.query && $route.query.id) === '2'" type="warning" @click="handleRawBack">返库</el-button>
|
|
|
|
|
<el-button :disabled="form.planDetailStatus === '已完成'" type="primary" @click="finish">完成</el-button>
|
|
|
|
|
<el-popover
|
|
|
|
|
v-if="($route.query && $route.query.id) === '2'"
|
|
|
|
@ -45,6 +47,7 @@
|
|
|
|
|
<el-button slot="reference" type="success">下发
|
|
|
|
|
</el-button>
|
|
|
|
|
</el-popover>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
@ -188,7 +191,7 @@
|
|
|
|
|
<el-button type="primary">首页</el-button>
|
|
|
|
|
<!-- <el-button type="success" @click="getMaterialsModel = true">条码打印</el-button>-->
|
|
|
|
|
<el-button type="info">SOP预览</el-button>
|
|
|
|
|
<el-button type="danger">退出</el-button>
|
|
|
|
|
<el-button type="danger" @click="logout">退出</el-button>
|
|
|
|
|
</el-row>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
@ -230,7 +233,7 @@
|
|
|
|
|
</el-form>
|
|
|
|
|
<el-table
|
|
|
|
|
:cell-style="{textAlign:'center'}"
|
|
|
|
|
:data="form.wmsRawOutstockDetailList"
|
|
|
|
|
:data="form1.wmsRawOutstockDetailList"
|
|
|
|
|
:header-cell-style="{textAlign:'center'}"
|
|
|
|
|
max-height="19.13vw"
|
|
|
|
|
style="width: 100%"
|
|
|
|
@ -297,6 +300,43 @@
|
|
|
|
|
</div>
|
|
|
|
|
</el-dialog>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<el-dialog
|
|
|
|
|
:visible.sync="bindBarcodeVisible"
|
|
|
|
|
title="柜体绑定"
|
|
|
|
|
width="40%">
|
|
|
|
|
<el-form ref="bindBarcodeForm" :model="bindBarcodeForm" :rules="bindBarcodeRules" label-width="80px">
|
|
|
|
|
<el-form-item label="成品条码" prop="productBarcode">
|
|
|
|
|
<el-input v-model="bindBarcodeForm.productBarcode"></el-input>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
<el-form-item label="物料条码" prop="materialBarcode">
|
|
|
|
|
<el-input v-model="bindBarcodeForm.materialBarcode"></el-input>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-form>
|
|
|
|
|
<div slot="footer" class="dialog-footer">
|
|
|
|
|
<el-button type="primary" @click="submitBindBarcode">确 定</el-button>
|
|
|
|
|
<el-button @click="cancelBindBarcode">取 消</el-button>
|
|
|
|
|
</div>
|
|
|
|
|
</el-dialog>
|
|
|
|
|
|
|
|
|
|
<el-dialog
|
|
|
|
|
:visible.sync="rawBackVisible"
|
|
|
|
|
title="柜体返库"
|
|
|
|
|
width="40%">
|
|
|
|
|
<el-form ref="rawBackForm" :model="rawBackForm" :rules="rawBackRules" label-width="80px">
|
|
|
|
|
<el-form-item label="物料条码" prop="materialBarcode">
|
|
|
|
|
<el-input v-model="rawBackForm.materialBarcode"></el-input>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-form>
|
|
|
|
|
<div slot="footer" class="dialog-footer">
|
|
|
|
|
<el-button type="primary" @click="submitRawBack">确 定</el-button>
|
|
|
|
|
<el-button @click="cancelRawBack">取 消</el-button>
|
|
|
|
|
</div>
|
|
|
|
|
</el-dialog>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<!-- <el-dialog :visible.sync="assignModel" title="工位选择" width="80%">-->
|
|
|
|
|
|
|
|
|
|
<!-- <el-table :data="stationData" highlight-current-row-->
|
|
|
|
@ -343,7 +383,9 @@ import {
|
|
|
|
|
startNextProductPlanDetail,
|
|
|
|
|
applyRawOutstock,
|
|
|
|
|
getStockTotal,
|
|
|
|
|
getWarehouses
|
|
|
|
|
getWarehouses,
|
|
|
|
|
bindBarcode,
|
|
|
|
|
applyRawBack
|
|
|
|
|
} from "@/api/board";
|
|
|
|
|
|
|
|
|
|
const setState = (e) => {
|
|
|
|
@ -406,6 +448,30 @@ export default {
|
|
|
|
|
warehouseList: [],
|
|
|
|
|
searchMaterialValue: '',
|
|
|
|
|
vw: (document.documentElement.clientWidth || document.body.clientWidth) / 100,
|
|
|
|
|
|
|
|
|
|
bindBarcodeVisible: false,
|
|
|
|
|
bindBarcodeForm: {
|
|
|
|
|
productBarcode: null,
|
|
|
|
|
materialBarcode: null
|
|
|
|
|
},
|
|
|
|
|
bindBarcodeRules: {
|
|
|
|
|
productBarcode: [
|
|
|
|
|
{ required: true, message: "成品条码不能为空", trigger: "blur" }
|
|
|
|
|
],
|
|
|
|
|
materialBarcode: [
|
|
|
|
|
{ required: true, message: "物料条码不能为空", trigger: "blur" }
|
|
|
|
|
],
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
rawBackVisible: false,
|
|
|
|
|
rawBackForm: {
|
|
|
|
|
materialBarcode: null,
|
|
|
|
|
},
|
|
|
|
|
rawBackRules: {
|
|
|
|
|
materialBarcode: [
|
|
|
|
|
{ required: true, message: "物料条码不能为空", trigger: "blur" }
|
|
|
|
|
]
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
async mounted() {
|
|
|
|
@ -578,6 +644,18 @@ export default {
|
|
|
|
|
})
|
|
|
|
|
},
|
|
|
|
|
methods: {
|
|
|
|
|
|
|
|
|
|
async logout() {
|
|
|
|
|
this.$confirm('确定注销并退出系统吗?', '提示', {
|
|
|
|
|
confirmButtonText: '确定',
|
|
|
|
|
cancelButtonText: '取消',
|
|
|
|
|
type: 'warning'
|
|
|
|
|
}).then(() => {
|
|
|
|
|
this.$store.dispatch('LogOut').then(() => {
|
|
|
|
|
location.href = '/login?isStationId=true';
|
|
|
|
|
})
|
|
|
|
|
}).catch(() => {});
|
|
|
|
|
},
|
|
|
|
|
next1() {
|
|
|
|
|
this.nowNum1 += 1
|
|
|
|
|
getProductPlans({pageNum: this.nowNum1, pageSize: 5}).then(e => {
|
|
|
|
@ -602,6 +680,7 @@ export default {
|
|
|
|
|
}
|
|
|
|
|
this.form = data.data || {}
|
|
|
|
|
this.form.materialId = val.materialId
|
|
|
|
|
this.form.materialCode = val.materialCode
|
|
|
|
|
this.form.materialName = val.materialName
|
|
|
|
|
this.form.planDetailStatus = setState(data.data.planDetailStatus)
|
|
|
|
|
this.getInfo(val)
|
|
|
|
@ -611,6 +690,7 @@ export default {
|
|
|
|
|
const {data} = await getNewestProductPlanDetail({planId: val.planId})
|
|
|
|
|
this.form = data || {}
|
|
|
|
|
this.form.materialId = val.materialId
|
|
|
|
|
this.form.materialCode = val.materialCode
|
|
|
|
|
this.form.materialName = val.materialName
|
|
|
|
|
this.form.planDetailStatus = setState(data.planDetailStatus)
|
|
|
|
|
this.getInfo(val)
|
|
|
|
@ -984,9 +1064,9 @@ export default {
|
|
|
|
|
this.dialogVisible = true
|
|
|
|
|
this.form1 = {
|
|
|
|
|
warehouseId: '',
|
|
|
|
|
planId: this.form.row.planId,
|
|
|
|
|
planCode: this.form.row.planCode,
|
|
|
|
|
planDetailCode: this.form.row.planDetailCode,
|
|
|
|
|
planId: this.form?.planId,
|
|
|
|
|
planCode: this.form?.planCode,
|
|
|
|
|
planDetailCode: this.form?.planDetailCode,
|
|
|
|
|
applyReason: '',
|
|
|
|
|
taskType: '1',
|
|
|
|
|
wmsRawOutstockDetailList: []
|
|
|
|
@ -1023,7 +1103,7 @@ export default {
|
|
|
|
|
warehouseChange(warehouseId) {
|
|
|
|
|
this.form.wmsRawOutstockDetailList = [];
|
|
|
|
|
this.form.warehouseId = warehouseId;
|
|
|
|
|
this.getStockTotal();
|
|
|
|
|
this.searchMaterial('');
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
receiveMaterial() {
|
|
|
|
@ -1044,7 +1124,76 @@ export default {
|
|
|
|
|
},
|
|
|
|
|
assignClick() {
|
|
|
|
|
this.assignModel = true
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 表单重置
|
|
|
|
|
resetBindBarcode() {
|
|
|
|
|
this.bindBarcodeForm = {
|
|
|
|
|
productBarcode: null,
|
|
|
|
|
materialBarcode: null,
|
|
|
|
|
planCode: this.form.planCode,
|
|
|
|
|
planDetailCode: this.form.planDetailCode
|
|
|
|
|
};
|
|
|
|
|
this.resetForm("bindBarcodeForm");
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
/** 柜体绑定按钮操作 */
|
|
|
|
|
handleBindBarcode() {
|
|
|
|
|
this.resetBindBarcode();
|
|
|
|
|
this.bindBarcodeVisible = true;
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
submitBindBarcode(){
|
|
|
|
|
this.$refs["bindBarcodeForm"].validate(valid => {
|
|
|
|
|
if (valid) {
|
|
|
|
|
bindBarcode(this.bindBarcodeForm).then(response => {
|
|
|
|
|
this.$modal.msgSuccess("绑定成功");
|
|
|
|
|
this.cancelBindBarcode();
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
cancelBindBarcode(){
|
|
|
|
|
this.bindBarcodeVisible = false;
|
|
|
|
|
this.resetBindBarcode();
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 表单重置
|
|
|
|
|
resetRawBack() {
|
|
|
|
|
this.rawBackForm = {
|
|
|
|
|
materialBarcode: null,
|
|
|
|
|
};
|
|
|
|
|
this.resetForm("rawBackForm");
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
/** 成品入库按钮操作 */
|
|
|
|
|
handleRawBack(scope) {
|
|
|
|
|
this.resetRawBack();
|
|
|
|
|
this.rawBackVisible = true;
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
submitRawBack(){
|
|
|
|
|
this.$refs["rawBackForm"].validate(valid => {
|
|
|
|
|
if (valid) {
|
|
|
|
|
applyRawBack(this.rawBackForm).then(response => {
|
|
|
|
|
this.$modal.msgSuccess("申请成功");
|
|
|
|
|
this.cancelRawBack();
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
cancelRawBack(){
|
|
|
|
|
this.rawBackVisible = false;
|
|
|
|
|
this.resetRawBack();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
</script>
|
|
|
|
|