|
|
@ -233,6 +233,81 @@ export default {
|
|
|
|
this.init()
|
|
|
|
this.init()
|
|
|
|
},
|
|
|
|
},
|
|
|
|
methods: {
|
|
|
|
methods: {
|
|
|
|
|
|
|
|
init() {
|
|
|
|
|
|
|
|
Object.assign(this.$data, this.$options.data())
|
|
|
|
|
|
|
|
columns.forEach(item => {
|
|
|
|
|
|
|
|
item.checked = true
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
columns.forEach(item => {
|
|
|
|
|
|
|
|
this.ColumnsQuery.push({ ...item, checked: true })
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
DjyCustomerGet({ type: 'customer_column_config' }).then(res => {
|
|
|
|
|
|
|
|
if (res.data && JSON.parse(res.data.configJson).length) {
|
|
|
|
|
|
|
|
columns.forEach(item => {
|
|
|
|
|
|
|
|
item.checked = false
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
let Arr = []
|
|
|
|
|
|
|
|
JSON.parse(res.data.configJson).forEach(item => {
|
|
|
|
|
|
|
|
columns.forEach(item2 => {
|
|
|
|
|
|
|
|
if (item2.dataIndex == item) {
|
|
|
|
|
|
|
|
item2.checked = true
|
|
|
|
|
|
|
|
Arr.push(item2)
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
columns.forEach(item => {
|
|
|
|
|
|
|
|
let type = true
|
|
|
|
|
|
|
|
Arr.forEach(item2 => {
|
|
|
|
|
|
|
|
if (item.dataIndex == item2.dataIndex) {
|
|
|
|
|
|
|
|
type = false
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
if (type) {
|
|
|
|
|
|
|
|
Arr.push(item)
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
this.TableColumns = Arr
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
this.TableColumns = columns
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
this.FnGetData()
|
|
|
|
|
|
|
|
this.$forceUpdate()
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
DjyCustomerGet({ type: 'pai_che' }).then(res => {
|
|
|
|
|
|
|
|
if (res.data) {
|
|
|
|
|
|
|
|
this.ColumnsQueryL = JSON.parse(res.data.configJson).length
|
|
|
|
|
|
|
|
if (JSON.parse(res.data.configJson).length) {
|
|
|
|
|
|
|
|
this.ColumnsQuery = []
|
|
|
|
|
|
|
|
columns.forEach(item => {
|
|
|
|
|
|
|
|
this.ColumnsQuery.push({ ...item, checked: false })
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
let Arr = []
|
|
|
|
|
|
|
|
JSON.parse(res.data.configJson).forEach(item => {
|
|
|
|
|
|
|
|
this.ColumnsQuery.forEach(item2 => {
|
|
|
|
|
|
|
|
if (item == item2.dataIndex) {
|
|
|
|
|
|
|
|
item2.checked = true
|
|
|
|
|
|
|
|
Arr.push(item2)
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
this.ColumnsQuery.forEach(item => {
|
|
|
|
|
|
|
|
let type = true
|
|
|
|
|
|
|
|
Arr.forEach(item2 => {
|
|
|
|
|
|
|
|
if (item.dataIndex == item2.dataIndex) {
|
|
|
|
|
|
|
|
type = false
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
if (type) {
|
|
|
|
|
|
|
|
Arr.push(item)
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
this.ColumnsQuery = Arr
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.$forceUpdate()
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
},
|
|
|
|
FnRpropString(data) {
|
|
|
|
FnRpropString(data) {
|
|
|
|
let propString = ''
|
|
|
|
let propString = ''
|
|
|
|
if (data.propString) {
|
|
|
|
if (data.propString) {
|
|
|
@ -330,81 +405,7 @@ export default {
|
|
|
|
toggleAdvanced() {
|
|
|
|
toggleAdvanced() {
|
|
|
|
this.advanced = !this.advanced
|
|
|
|
this.advanced = !this.advanced
|
|
|
|
},
|
|
|
|
},
|
|
|
|
init() {
|
|
|
|
|
|
|
|
Object.assign(this.$data, this.$options.data())
|
|
|
|
|
|
|
|
columns.forEach(item => {
|
|
|
|
|
|
|
|
item.checked = true
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
columns.forEach(item => {
|
|
|
|
|
|
|
|
this.ColumnsQuery.push({ ...item, checked: true })
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
DjyCustomerGet({ type: 'customer_column_config' }).then(res => {
|
|
|
|
|
|
|
|
if (res.data && JSON.parse(res.data.configJson).length) {
|
|
|
|
|
|
|
|
columns.forEach(item => {
|
|
|
|
|
|
|
|
item.checked = false
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
let Arr = []
|
|
|
|
|
|
|
|
JSON.parse(res.data.configJson).forEach(item => {
|
|
|
|
|
|
|
|
columns.forEach(item2 => {
|
|
|
|
|
|
|
|
if (item2.dataIndex == item) {
|
|
|
|
|
|
|
|
item2.checked = true
|
|
|
|
|
|
|
|
Arr.push(item2)
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
columns.forEach(item => {
|
|
|
|
|
|
|
|
let type = true
|
|
|
|
|
|
|
|
Arr.forEach(item2 => {
|
|
|
|
|
|
|
|
if (item.dataIndex == item2.dataIndex) {
|
|
|
|
|
|
|
|
type = false
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
if (type) {
|
|
|
|
|
|
|
|
Arr.push(item)
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
this.TableColumns = Arr
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
this.TableColumns = columns
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
this.FnGetData()
|
|
|
|
|
|
|
|
this.$forceUpdate()
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
DjyCustomerGet({ type: 'pai_che' }).then(res => {
|
|
|
|
|
|
|
|
if (res.data) {
|
|
|
|
|
|
|
|
this.ColumnsQueryL = JSON.parse(res.data.configJson).length
|
|
|
|
|
|
|
|
if (JSON.parse(res.data.configJson).length) {
|
|
|
|
|
|
|
|
this.ColumnsQuery = []
|
|
|
|
|
|
|
|
columns.forEach(item => {
|
|
|
|
|
|
|
|
this.ColumnsQuery.push({ ...item, checked: false })
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
let Arr = []
|
|
|
|
|
|
|
|
JSON.parse(res.data.configJson).forEach(item => {
|
|
|
|
|
|
|
|
this.ColumnsQuery.forEach(item2 => {
|
|
|
|
|
|
|
|
if (item == item2.dataIndex) {
|
|
|
|
|
|
|
|
item2.checked = true
|
|
|
|
|
|
|
|
Arr.push(item2)
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
this.ColumnsQuery.forEach(item => {
|
|
|
|
|
|
|
|
let type = true
|
|
|
|
|
|
|
|
Arr.forEach(item2 => {
|
|
|
|
|
|
|
|
if (item.dataIndex == item2.dataIndex) {
|
|
|
|
|
|
|
|
type = false
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
if (type) {
|
|
|
|
|
|
|
|
Arr.push(item)
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
this.ColumnsQuery = Arr
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.$forceUpdate()
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
handlePageChange({ currentPage, pageSize }) {
|
|
|
|
handlePageChange({ currentPage, pageSize }) {
|
|
|
|
this.queryParam.pageNo = currentPage
|
|
|
|
this.queryParam.pageNo = currentPage
|
|
|
|
this.queryParam.pageSize = pageSize
|
|
|
|
this.queryParam.pageSize = pageSize
|
|
|
|