|
|
|
@ -1654,6 +1654,9 @@ function cloneDefaultTrackingColumns () { |
|
|
|
return DEFAULT_TRACKING_COLUMNS.map(item => Object.assign({}, item)) |
|
|
|
} |
|
|
|
|
|
|
|
// 动态列保存会重建页面;只临时传递本页 BU,不持久化或改变其他页面的刷新行为。 |
|
|
|
let pendingRefreshBu = null |
|
|
|
|
|
|
|
export default { |
|
|
|
name: 'ProjectProofTracking', |
|
|
|
directives: { |
|
|
|
@ -1895,6 +1898,14 @@ export default { |
|
|
|
} |
|
|
|
} |
|
|
|
}, |
|
|
|
created () { |
|
|
|
const savedBu = pendingRefreshBu |
|
|
|
pendingRefreshBu = null |
|
|
|
// 必须在 activated 加载 BU/工序/列表前恢复;用户或工厂切换时不沿用旧选择。 |
|
|
|
if (savedBu && savedBu.userName === this.searchData.userName && savedBu.site === this.searchData.site) { |
|
|
|
this.searchData.buNo = savedBu.buNo |
|
|
|
} |
|
|
|
}, |
|
|
|
mounted () { |
|
|
|
this.bindTrackingTableResize() |
|
|
|
this.scheduleTrackingTableHeightUpdate() |
|
|
|
@ -1918,6 +1929,13 @@ export default { |
|
|
|
this.destroyDefaultProcessConfigSortable() |
|
|
|
}, |
|
|
|
beforeDestroy () { |
|
|
|
if (this.$store.state.common.contentIsNeedRefresh) { |
|
|
|
pendingRefreshBu = { |
|
|
|
userName: this.searchData.userName, |
|
|
|
site: this.searchData.site, |
|
|
|
buNo: this.searchData.buNo |
|
|
|
} |
|
|
|
} |
|
|
|
this.unbindTrackingTableResize() |
|
|
|
}, |
|
|
|
watch: { |
|
|
|
|