fix:关闭弹窗后列表刷新

This commit is contained in:
shijing 2025-02-25 17:37:55 +08:00
parent 9fbc9eb002
commit d59116cc31
1 changed files with 16 additions and 11 deletions

View File

@ -2,7 +2,7 @@
<el-drawer <el-drawer
v-model="visible" v-model="visible"
title="出入库记录" title="出入库记录"
:size="'90%'" :size="'95%'"
destroy-on-close destroy-on-close
@closed="$emit('closed')" @closed="$emit('closed')"
> >
@ -228,7 +228,7 @@
:type="type" :type="type"
:objitem="objitem" :objitem="objitem"
@success="handleCheckSuccess" @success="handleCheckSuccess"
@closed="dialog.check = false" @closed="checkDialogClose"
> >
</check-dialog> </check-dialog>
<el-dialog v-model="printVisible" width="1200px"> <el-dialog v-model="printVisible" width="1200px">
@ -301,6 +301,7 @@ export default {
// cate: "", // cate: "",
objitem: {}, objitem: {},
mtype:10, mtype:10,
mioType:'',
project_code:'', project_code:'',
setNameVisible:false, setNameVisible:false,
printer_name:localStorage.getItem("printer_name") printer_name:localStorage.getItem("printer_name")
@ -330,16 +331,20 @@ export default {
this.visible = true; this.visible = true;
}, },
getMio() { getMio() {
this.$API.inm.mio.item.req(this.mioId).then((res) => { let that = this;
this.mioObj = res; that.$API.inm.mio.item.req(that.mioId).then((res) => {
this.belongDeptId = res.belong_dept; that.mioObj = res;
that.mioType = res.type;
that.belongDeptId = res.belong_dept;
}); });
}, },
// //
table_add() { table_add() {
let that = this;
console.log(this.mioType);
this.dialog.save = true; this.dialog.save = true;
this.$nextTick(() => { this.$nextTick(() => {
this.$refs.saveDialog.open("add", this.mioObj.type); this.$refs.saveDialog.open("add", that.mioType);
}); });
}, },
@ -419,17 +424,17 @@ export default {
this.mioObj = res; this.mioObj = res;
}); });
}, },
checkDialogClose(){
let that = this;
that.dialog.check = false;
that.$refs.table.refresh();
},
handlePrint(){ handlePrint(){
let that = this; let that = this;
let params = { let params = {
mio: that.mioId, mio: that.mioId,
page:0 page:0
} }
// if(){
// that.mtype = 10
// }else{
// }
that.$API.inm.mioitem.list.req(params).then((res) => { that.$API.inm.mioitem.list.req(params).then((res) => {
that.tableData = res; that.tableData = res;
that.printVisible = true; that.printVisible = true;