去掉分页页码记录,分页接口调用一次

szh_zidingyibiaoti
lilu 2 years ago
parent 3709cffaee
commit b48913d79b

@ -252,7 +252,8 @@ const initDetail = {
weiTuoFang: '',
ediAttn: '',
ediAttnTel: '',
ediAttnMail: ''
ediAttnMail: '',
sendCode: ''
},
//
hbList: [],
@ -728,7 +729,8 @@ export default {
weiTuoFang: '',
ediAttn: '',
ediAttnTel: '',
ediAttnMail: ''
ediAttnMail: '',
sendCode: ''
}
}
//

@ -284,6 +284,7 @@ export default {
},
computed: {
locaService () {
if (!this.details) { return [] }
return this.details.item.map((item, index) => {
return item.code
})

@ -528,7 +528,7 @@ export default {
pagerConfig: {
total: 0,
currentPage: 1,
pageSize: 10,
pageSize: 50,
pageSizes: [10, 20, 50, 100, 200, 500]
},
columns: JSON.parse(JSON.stringify(initData.columns)),
@ -628,8 +628,9 @@ export default {
this.formAllData = JSON.parse(JSON.stringify(initData.condAllData))
this.fromTableAllData = JSON.parse(JSON.stringify(initData.columnsAllData))
this.tableHeight = document.body.clientHeight - 300
this.getList({}, true)
this.getConfigUser(true)
this.getCarrier()
this.getConfigUser()
},
onresize () {
window.onresize = () => {
@ -758,23 +759,23 @@ export default {
this.getList(queryParam)
},
//
getConfigUser() {
getConfigUser(isInit = false) {
//
const query = {
typeArr: ['booking_list_cond', 'booking_list_column', 'booking_list_page']
typeArr: ['booking_list_cond', 'booking_list_column']
}
DjyUserConfigMulti(this.$qs.stringify(query, { arrayFormat: 'repeat' })).then(res => {
res.data.map((item, index) => {
switch (item.type) {
case 'booking_list_cond':
this.setFormData(item)
this.setFormData(item, false, true)
break
case 'booking_list_column':
this.setTableList(item)
break
case 'booking_list_page':
this.setPageSize(item)
break
// case 'booking_list_page':
// this.setPageSize(item)
// break
}
})
})
@ -839,7 +840,7 @@ export default {
console.log(err)
})
},
setFormData (data, isReset = false) {
setFormData (data, isReset = false, isInit = false) {
if (data && JSON.parse(data.configJson).length) {
const arr = JSON.parse(data.configJson)
const nowData = []
@ -882,8 +883,8 @@ export default {
}
}
})
if (!isReset) {
this.getList(this.formRes, true)
if (!isReset && !isInit) {
this.getList(this.formRes)
}
const len = this.formData.length % 4
if (this.formData.length === 4 || this.formData.length > 4) {
@ -962,24 +963,24 @@ export default {
})
},
handlePageChange({ currentPage, pageSize }) {
if (this.gridOptions.pagerConfig.pageSize !== pageSize) {
this.editPageSizeSave(pageSize)
}
// if (this.gridOptions.pagerConfig.pageSize !== pageSize) {
// this.editPageSizeSave(pageSize)
// }
this.gridOptions.pagerConfig.currentPage = currentPage
this.gridOptions.pagerConfig.pageSize = pageSize
this.getList(this.formRes)
},
editPageSizeSave(pageSize = 10) {
const data = {
pageSize: pageSize
}
DjyUserConfigAdd({
type: 'booking_list_page',
configJson: JSON.stringify(data)
}).then(res => {
console.log('页码设置成功')
})
// const data = {
// pageSize: pageSize
// }
// DjyUserConfigAdd({
// type: 'booking_list_page',
// configJson: JSON.stringify(data)
// }).then(res => {
// console.log('')
// })
},
// form
@ -1159,9 +1160,14 @@ export default {
const arr = this.formRes.MBLNO.split(/|,/)
query.MBLNO = arr.toString()
}
if (isInit) {
console.log('这里新增初始化字段 - 等后台接口修改')
// -
query.firstFlag = true
}
BookingOrderPage(query)
.then(res => {
if (isInit) { this.getList(this.formRes) }
// if (isInit) { this.getList(this.formRes) }
if (res.success) {
let newBookingList = {}
if (query.PageNo !== 1) {

Loading…
Cancel
Save