|
|
|
|
@ -276,26 +276,18 @@
|
|
|
|
|
>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
<el-table-column
|
|
|
|
|
label="申请数量"
|
|
|
|
|
prop="planAmount"
|
|
|
|
|
label="标准数量"
|
|
|
|
|
prop="standardAmount"
|
|
|
|
|
width="100"
|
|
|
|
|
>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
<el-table-column
|
|
|
|
|
label="已领数量"
|
|
|
|
|
prop="outstockAmount"
|
|
|
|
|
prop="realOutstockAmount"
|
|
|
|
|
width="100"
|
|
|
|
|
>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
<el-table-column
|
|
|
|
|
label="状态"
|
|
|
|
|
prop="auditStatus"
|
|
|
|
|
width="100"
|
|
|
|
|
>
|
|
|
|
|
<template slot-scope="scope">
|
|
|
|
|
<dict-tag :options="dict.type.wms_audit_status" :value="scope.row.auditStatus"/>
|
|
|
|
|
</template>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
|
|
|
|
|
</el-table>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
@ -379,7 +371,7 @@ import {
|
|
|
|
|
} from "@/api/board";
|
|
|
|
|
|
|
|
|
|
import {monitorSerialData} from "@/utils/serial"
|
|
|
|
|
import {addWmslocation, updateWmslocation} from "@/api/wms/wmslocation";
|
|
|
|
|
import {getBomsWithApply} from "@/api/board/laserLight";
|
|
|
|
|
import WorkshopNotice from "@/components/workshopNotice/index.vue";
|
|
|
|
|
import {noticeData} from "@/utils/notice"
|
|
|
|
|
import ViewFile from "@/components/viewFile/index.vue";
|
|
|
|
|
@ -473,7 +465,7 @@ export default {
|
|
|
|
|
|
|
|
|
|
submitLoading: false,
|
|
|
|
|
// 存储选中的行
|
|
|
|
|
selectedRows: {},
|
|
|
|
|
selectedRow: {},
|
|
|
|
|
//显示预览文件
|
|
|
|
|
showFileDialog: false,
|
|
|
|
|
//显示预览文件标题
|
|
|
|
|
@ -483,7 +475,8 @@ export default {
|
|
|
|
|
rawOutstockData:[],
|
|
|
|
|
purchaseOrderData:[],
|
|
|
|
|
IS_SHOW_FINISH: "1",
|
|
|
|
|
showTitle: "显示"
|
|
|
|
|
showTitle: "显示",
|
|
|
|
|
pageSize:5
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
async mounted() {
|
|
|
|
|
@ -497,23 +490,11 @@ export default {
|
|
|
|
|
// duration: 0
|
|
|
|
|
// });
|
|
|
|
|
// }, 60 * 1000)
|
|
|
|
|
const data = await getProductPlans({pageNum: 1, pageSize: 5, incompleteFlag: this.IS_SHOW_FINISH}).then(e => {
|
|
|
|
|
const data = await getProductPlans({pageNum: 1, pageSize: this.pageSize, incompleteFlag: this.IS_SHOW_FINISH}).then(e => {
|
|
|
|
|
this.tableData = e.rows
|
|
|
|
|
this.totalNum1 = Math.ceil(e.total / 5)
|
|
|
|
|
this.$refs.table1.setCurrentRow(e.rows[0]);
|
|
|
|
|
this.getInfo(e.rows[0])
|
|
|
|
|
getNewestProductPlanDetailJoinAttach({planId: e.rows[0].planId}).then(val => {
|
|
|
|
|
this.form = val.data || {}
|
|
|
|
|
this.form.materialId = e.rows[0]?.materialId
|
|
|
|
|
this.form.materialCode = e.rows[0]?.materialCode
|
|
|
|
|
this.form.materialName = e.rows[0]?.materialName
|
|
|
|
|
this.form.saleOrderId = e.rows[0]?.saleOrderId
|
|
|
|
|
if (val.data) {
|
|
|
|
|
this.form.planDetailStatus = setState(val.data.planDetailStatus)
|
|
|
|
|
}
|
|
|
|
|
this.selectBindPurchaseOrders();
|
|
|
|
|
this.selectRawOutstocks();
|
|
|
|
|
})
|
|
|
|
|
this.totalNum1 = Math.ceil(e.total / this.pageSize)
|
|
|
|
|
this.selectedRow = e.rows[0];
|
|
|
|
|
this.getProductPlanDetailByProductPlan();
|
|
|
|
|
})
|
|
|
|
|
this.$refs.chart2.setData({
|
|
|
|
|
tooltip: {
|
|
|
|
|
@ -680,6 +661,25 @@ export default {
|
|
|
|
|
},
|
|
|
|
|
methods: {
|
|
|
|
|
|
|
|
|
|
getProductPlanDetailByProductPlan(){
|
|
|
|
|
if(this.selectedRow) {
|
|
|
|
|
this.$refs.table1.setCurrentRow(this.selectedRow);
|
|
|
|
|
this.getInfo(this.selectedRow)
|
|
|
|
|
getNewestProductPlanDetailJoinAttach({planId: this.selectedRow.planId}).then(val => {
|
|
|
|
|
this.form = val.data || {}
|
|
|
|
|
this.form.materialId = this.selectedRow?.materialId
|
|
|
|
|
this.form.materialCode = this.selectedRow?.materialCode
|
|
|
|
|
this.form.materialName = this.selectedRow?.materialName
|
|
|
|
|
this.form.saleOrderId = this.selectedRow?.saleOrderId
|
|
|
|
|
if (val.data) {
|
|
|
|
|
this.form.planDetailStatus = setState(val.data.planDetailStatus)
|
|
|
|
|
}
|
|
|
|
|
this.selectBindPurchaseOrders();
|
|
|
|
|
this.selectRawOutstocks();
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
async logout() {
|
|
|
|
|
this.$confirm('确定退出系统吗?', '提示', {
|
|
|
|
|
confirmButtonText: '确定',
|
|
|
|
|
@ -694,22 +694,27 @@ export default {
|
|
|
|
|
},
|
|
|
|
|
next1() {
|
|
|
|
|
this.nowNum1 += 1
|
|
|
|
|
getProductPlans({pageNum: this.nowNum1, pageSize: 5, incompleteFlag: this.IS_SHOW_FINISH}).then(e => {
|
|
|
|
|
getProductPlans({pageNum: this.nowNum1, pageSize: this.pageSize, incompleteFlag: this.IS_SHOW_FINISH}).then(e => {
|
|
|
|
|
this.tableData = e.rows
|
|
|
|
|
this.totalNum1 = Math.ceil(e.total / 5)
|
|
|
|
|
this.totalNum1 = Math.ceil(e.total / this.pageSize)
|
|
|
|
|
this.selectedRow = e.rows[0];
|
|
|
|
|
this.getProductPlanDetailByProductPlan();
|
|
|
|
|
})
|
|
|
|
|
},
|
|
|
|
|
pre1() {
|
|
|
|
|
this.nowNum1 -= 1
|
|
|
|
|
getProductPlans({pageNum: this.nowNum1, pageSize: 5, incompleteFlag: this.IS_SHOW_FINISH}).then(e => {
|
|
|
|
|
getProductPlans({pageNum: this.nowNum1, pageSize: this.pageSize, incompleteFlag: this.IS_SHOW_FINISH}).then(e => {
|
|
|
|
|
this.tableData = e.rows
|
|
|
|
|
this.totalNum1 = Math.ceil(e.total / 5)
|
|
|
|
|
this.totalNum1 = Math.ceil(e.total / this.pageSize)
|
|
|
|
|
this.selectedRow = e.rows[0];
|
|
|
|
|
this.getProductPlanDetailByProductPlan();
|
|
|
|
|
})
|
|
|
|
|
},
|
|
|
|
|
getOrderInfo(e) {
|
|
|
|
|
console.log("当前选择行:", e)
|
|
|
|
|
this.selectedRows = e;
|
|
|
|
|
this.selectedRow = e;
|
|
|
|
|
this.getInfo(e)
|
|
|
|
|
this.selectRawOutstocks();
|
|
|
|
|
getNewestProductPlanDetailJoinAttach({planId: e.planId}).then(val => {
|
|
|
|
|
if (val.data) {
|
|
|
|
|
this.form = val.data
|
|
|
|
|
@ -720,7 +725,7 @@ export default {
|
|
|
|
|
this.form.planDetailStatus = setState(val.data.planDetailStatus)
|
|
|
|
|
|
|
|
|
|
this.selectBindPurchaseOrders();
|
|
|
|
|
this.selectRawOutstocks();
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
})
|
|
|
|
|
@ -1103,9 +1108,9 @@ export default {
|
|
|
|
|
message: '已完成'
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
getProductPlans({pageNum: this.nowNum1, pageSize: 5, incompleteFlag: this.IS_SHOW_FINISH}).then(e => {
|
|
|
|
|
getProductPlans({pageNum: this.nowNum1, pageSize: this.pageSize, incompleteFlag: this.IS_SHOW_FINISH}).then(e => {
|
|
|
|
|
this.tableData = e.rows
|
|
|
|
|
this.totalNum1 = Math.ceil(e.total / 5)
|
|
|
|
|
this.totalNum1 = Math.ceil(e.total / this.pageSize)
|
|
|
|
|
let data = e.rows.find(v => v.planCode === this.form.planCode) || null
|
|
|
|
|
this.$refs.table1.setCurrentRow(data || e.rows[0]);
|
|
|
|
|
this.getInfo(data || e.rows[0])
|
|
|
|
|
@ -1346,7 +1351,7 @@ export default {
|
|
|
|
|
/** SOP预览*/
|
|
|
|
|
handleViewSOP(){
|
|
|
|
|
this.fileListData = [];
|
|
|
|
|
getDispatchAttachByPlanIdList("2", this.selectedRows.planId).then(res => {
|
|
|
|
|
getDispatchAttachByPlanIdList("2", this.selectedRow.planId).then(res => {
|
|
|
|
|
let attachList = res.data;
|
|
|
|
|
let thisFileList = [];
|
|
|
|
|
attachList.forEach(e => {
|
|
|
|
|
@ -1414,9 +1419,15 @@ export default {
|
|
|
|
|
|
|
|
|
|
selectRawOutstocks(){
|
|
|
|
|
this.rawOutstockData = [];
|
|
|
|
|
if(this.form.planDetailCode && this.form.planDetailCode!='') {
|
|
|
|
|
getRawOutstocks({planDetailCode: this.form.planDetailCode}).then(response => {
|
|
|
|
|
this.rawOutstockData = response.rows;
|
|
|
|
|
// alert(JSON.stringify(this.form));
|
|
|
|
|
// alert(JSON.stringify(this.selectedRow));
|
|
|
|
|
if(this.selectedRow && this.selectedRow.planCode && this.selectedRow.planCode!='') {
|
|
|
|
|
let query = {
|
|
|
|
|
planCode:this.selectedRow.planCode,
|
|
|
|
|
parentId:this.selectedRow.materialBomId
|
|
|
|
|
}
|
|
|
|
|
getBomsWithApply(query).then(response => {
|
|
|
|
|
this.rawOutstockData = response.data;
|
|
|
|
|
// this.detailTotal = response.total;
|
|
|
|
|
// this.loading = false;
|
|
|
|
|
});
|
|
|
|
|
@ -1431,9 +1442,9 @@ export default {
|
|
|
|
|
this.showTitle = "显示";
|
|
|
|
|
this.IS_SHOW_FINISH = "1";
|
|
|
|
|
}
|
|
|
|
|
getProductPlans({pageNum: this.nowNum1, pageSize: 5, incompleteFlag: this.IS_SHOW_FINISH}).then(e => {
|
|
|
|
|
getProductPlans({pageNum: this.nowNum1, pageSize: this.pageSize, incompleteFlag: this.IS_SHOW_FINISH}).then(e => {
|
|
|
|
|
this.tableData = e.rows
|
|
|
|
|
this.totalNum1 = Math.ceil(e.total / 5)
|
|
|
|
|
this.totalNum1 = Math.ceil(e.total / this.pageSize)
|
|
|
|
|
})
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|