|
|
|
@ -590,24 +590,63 @@ export default {
|
|
|
|
|
RecentlyCarrierData: []
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
beforeRouteLeave (to, from, next) {
|
|
|
|
|
// console.log('路由离开')
|
|
|
|
|
this.gridOptions = {
|
|
|
|
|
border: false,
|
|
|
|
|
resizable: true,
|
|
|
|
|
showOverflow: true,
|
|
|
|
|
loading: true,
|
|
|
|
|
stripe: true,
|
|
|
|
|
round: true,
|
|
|
|
|
autoResize: true,
|
|
|
|
|
align: 'center',
|
|
|
|
|
columnConfig: { resizable: true },
|
|
|
|
|
importConfig: {},
|
|
|
|
|
exportConfig: {},
|
|
|
|
|
pagerConfig: {
|
|
|
|
|
total: 0,
|
|
|
|
|
currentPage: 1,
|
|
|
|
|
pageSize: 10,
|
|
|
|
|
pageSizes: [10, 20, 50, 100, 200, 500]
|
|
|
|
|
},
|
|
|
|
|
columns: JSON.parse(JSON.stringify(initData.columns)),
|
|
|
|
|
data: []
|
|
|
|
|
}
|
|
|
|
|
next()
|
|
|
|
|
},
|
|
|
|
|
beforeRouteEnter (to, from, next) {
|
|
|
|
|
// console.log('路由进入')
|
|
|
|
|
next(vm => {
|
|
|
|
|
console.log('== 进入路由 - beforeRouteEnter ==', vm.inAddSave)
|
|
|
|
|
vm.createdInit()
|
|
|
|
|
vm.onresize()
|
|
|
|
|
})
|
|
|
|
|
},
|
|
|
|
|
created() {
|
|
|
|
|
this.showColumns = JSON.parse(JSON.stringify(initData.columns))
|
|
|
|
|
this.formAllData = JSON.parse(JSON.stringify(initData.condAllData))
|
|
|
|
|
this.fromTableAllData = JSON.parse(JSON.stringify(initData.columnsAllData))
|
|
|
|
|
this.tableHeight = document.body.clientHeight - 300
|
|
|
|
|
console.log('=== 列表创建 ===')
|
|
|
|
|
this.getFormData()
|
|
|
|
|
this.getTableList()
|
|
|
|
|
this.getPageSize()
|
|
|
|
|
this.getCarrier()
|
|
|
|
|
// this.createdInit()
|
|
|
|
|
},
|
|
|
|
|
mounted() {
|
|
|
|
|
console.log('=== 列表 mounted ===')
|
|
|
|
|
window.onresize = () => {
|
|
|
|
|
this.screenWidth = document.body.clientWidth
|
|
|
|
|
}
|
|
|
|
|
// this.onresize()
|
|
|
|
|
},
|
|
|
|
|
methods: {
|
|
|
|
|
createdInit () {
|
|
|
|
|
this.showColumns = JSON.parse(JSON.stringify(initData.columns))
|
|
|
|
|
this.formAllData = JSON.parse(JSON.stringify(initData.condAllData))
|
|
|
|
|
this.fromTableAllData = JSON.parse(JSON.stringify(initData.columnsAllData))
|
|
|
|
|
this.tableHeight = document.body.clientHeight - 300
|
|
|
|
|
// console.log('=== 列表创建 ===')
|
|
|
|
|
this.getFormData()
|
|
|
|
|
this.getTableList()
|
|
|
|
|
this.getPageSize()
|
|
|
|
|
this.getCarrier()
|
|
|
|
|
},
|
|
|
|
|
onresize () {
|
|
|
|
|
// console.log('=== 列表加载完成 ===')
|
|
|
|
|
window.onresize = () => {
|
|
|
|
|
this.screenWidth = document.body.clientWidth
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
// 批量编辑
|
|
|
|
|
editingHandleOk() {
|
|
|
|
|
const {
|
|
|
|
|