|
|
|
@ -2304,52 +2304,55 @@ export default { |
|
|
|
}) |
|
|
|
}, |
|
|
|
created() { |
|
|
|
|
|
|
|
this.handleRouteQuery(); |
|
|
|
}, |
|
|
|
activated() { |
|
|
|
if (this.$route.params.type === 'tokenLogin'){ |
|
|
|
let params = { |
|
|
|
site: this.$route.params.site, |
|
|
|
proofingNo: this.$route.params.docNo, |
|
|
|
limit: this.pageSize, |
|
|
|
createBy: this.$store.state.user.name, |
|
|
|
page : 1, |
|
|
|
} |
|
|
|
this.dataListLoading = true |
|
|
|
proofingInformationSearch(params).then(({data}) => { |
|
|
|
if (data && data.code === 0) { |
|
|
|
this.dataList = data.page.list |
|
|
|
this.totalPage = data.page.totalCount |
|
|
|
this.$refs.selectDiv.setLengthAll(this.dataList.length) |
|
|
|
// 判断是否全部存在数据 |
|
|
|
if (this.totalPage > 0) { |
|
|
|
//设置选中行 |
|
|
|
this.$refs.proofingTable.setCurrentRow(this.dataList[0]) |
|
|
|
//加载当前的页签的table |
|
|
|
this.refreshCurrentTabTable() |
|
|
|
this.proofingClickRow(this.dataList[0]) |
|
|
|
this.updateModal(this.dataList[0]) |
|
|
|
} else { |
|
|
|
//设置选中行 |
|
|
|
this.$refs.proofingTable.setCurrentRow({}) |
|
|
|
// 加载当前的页签的table |
|
|
|
this.refreshCurrentTabTable() |
|
|
|
this.testClickRow({}) |
|
|
|
} |
|
|
|
} |
|
|
|
this.dataListLoading = false |
|
|
|
}) |
|
|
|
}else if (this.$route.params.proofingNo){ |
|
|
|
this.searchData.proofingNo = this.$route.params.proofingNo |
|
|
|
this.getDataList(); |
|
|
|
setTimeout(()=>{ |
|
|
|
this.searchData.proofingNo = '' |
|
|
|
},200) |
|
|
|
}else { |
|
|
|
this.getDataList(); |
|
|
|
} |
|
|
|
this.handleRouteQuery(); |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
handleRouteQuery(){ |
|
|
|
if (this.$route.params.type === 'tokenLogin'){ |
|
|
|
let params = { |
|
|
|
site: this.$route.params.site, |
|
|
|
proofingNo: this.$route.params.docNo, |
|
|
|
limit: this.pageSize, |
|
|
|
createBy: this.$store.state.user.name, |
|
|
|
page : 1, |
|
|
|
} |
|
|
|
this.dataListLoading = true |
|
|
|
proofingInformationSearch(params).then(({data}) => { |
|
|
|
if (data && data.code === 0) { |
|
|
|
this.dataList = data.page.list |
|
|
|
this.totalPage = data.page.totalCount |
|
|
|
this.$refs.selectDiv.setLengthAll(this.dataList.length) |
|
|
|
// 判断是否全部存在数据 |
|
|
|
if (this.totalPage > 0) { |
|
|
|
//设置选中行 |
|
|
|
this.$refs.proofingTable.setCurrentRow(this.dataList[0]) |
|
|
|
//加载当前的页签的table |
|
|
|
this.refreshCurrentTabTable() |
|
|
|
this.proofingClickRow(this.dataList[0]) |
|
|
|
this.updateModal(this.dataList[0]) |
|
|
|
} else { |
|
|
|
//设置选中行 |
|
|
|
this.$refs.proofingTable.setCurrentRow({}) |
|
|
|
// 加载当前的页签的table |
|
|
|
this.refreshCurrentTabTable() |
|
|
|
this.testClickRow({}) |
|
|
|
} |
|
|
|
} |
|
|
|
this.dataListLoading = false |
|
|
|
}) |
|
|
|
}else if (this.$route.params.proofingNo){ |
|
|
|
this.searchData.proofingNo = this.$route.params.proofingNo |
|
|
|
this.getDataList(); |
|
|
|
setTimeout(()=>{ |
|
|
|
this.searchData.proofingNo = '' |
|
|
|
},200) |
|
|
|
}else { |
|
|
|
this.getDataList(); |
|
|
|
} |
|
|
|
}, |
|
|
|
// ======== 分页相关方法 ======== |
|
|
|
/** |
|
|
|
* 每页数 |
|
|
|
|