领料审核页面增加组件缓存 实现查询或审核后主列表保持之前的查询状态

This commit is contained in:
BianLzhaoMin 2024-06-17 09:37:23 +08:00
parent c03ce8ee88
commit 3181ae6751
4 changed files with 20 additions and 8 deletions

View File

@ -512,7 +512,7 @@ export default {
// this.$tab.closeOpenPage({
// path: '/claimAndRefund/receive/receiveManage',
// })
this.$emit('goBackPage')
this.$emit('goBackPage', 1) // 1
}
// console.log('subAuditLeaseByCompany ==================', res)
},
@ -564,7 +564,7 @@ export default {
// this.$tab.closeOpenPage({
// path: '/claimAndRefund/receive/receiveManage',
// })
this.$emit('goBackPage')
this.$emit('goBackPage', 1)
}
console.log('subAuditLeaseByCompany ==================', res)
},

View File

@ -588,6 +588,11 @@ export default {
// console.log(this.user)
this.getList()
},
/* 刷新列表 */
refreshList() {
this.getList()
},
/** 查询列表 */
async getList() {
this.loading = true

View File

@ -6,8 +6,10 @@
:pageContent="pageContent"
@goBack="goBack"
/>
<keep-alive :include="includeCom">
<!-- 6.17 新增组件缓存 因客户需要查询或审核后返回列表时保留页面状态 -->
<keep-alive>
<component
ref="componentRef"
:is="isShowComponent"
:isView="isView"
:auditingTaskId="auditingTaskId"
@ -41,7 +43,6 @@ export default {
methods: {
/* 审核按钮 */
pickingAuditing(taskId) {
this.includeCom = ''
this.auditingTaskId = taskId
this.isView = false
this.pageContent = '领料任务审批'
@ -49,14 +50,20 @@ export default {
},
/* 查看按钮 */
pickingView(taskId) {
this.includeCom = 'Home'
this.auditingTaskId = taskId
this.isView = true
this.pageContent = '领料审批详情'
this.isShowComponent = 'AuditingPage'
},
goBack() {
goBack(val) {
this.isShowComponent = 'Home'
// val 1
if (val === 1) {
this.$nextTick(() => {
this.$refs.componentRef.refreshList()
})
}
},
},
}

View File

@ -46,8 +46,8 @@ module.exports = {
// target: `http://10.40.92.51:28080`, //超
// target: `http://10.40.92.81:8080`, //韩/
// target: `http://10.40.92.74:8080`,//旭/
// target: `http://10.40.92.138:28080`, //帅
target: `http://10.40.92.253:28080`, //福
target: `http://10.40.92.140:28080`, //帅
// target: `http://10.40.92.253:28080`, //福
//******** 注意事项 ********* */
//1.全局替换qrUrl二维码扫码提供的网址-发布服务器的地址target;