【修改】修复筛选列头后,操作列不见的问题
This commit is contained in:
@@ -128,10 +128,9 @@ export default {
|
|||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
// 存储当前列表的用户存储信息
|
key: "customer_cloumns_" + this.$route.path, // 存储当前列表的用户存储信息
|
||||||
key: "customer_cloumns_" + this.$route.path,
|
defaultOperationKey: "action", // 操作列dataIndex=action不作相关处理,默认去除
|
||||||
// 内部使用的 slots ,不再处理
|
usedSlots: [], // 内部使用的 slots ,不再处理
|
||||||
usedSlots: [],
|
|
||||||
needTotalList: [],
|
needTotalList: [],
|
||||||
selectedRows: [],
|
selectedRows: [],
|
||||||
selectedRowKeys: [],
|
selectedRowKeys: [],
|
||||||
@@ -217,7 +216,6 @@ export default {
|
|||||||
methods: {
|
methods: {
|
||||||
// 用户可自行筛选列头显示的字段
|
// 用户可自行筛选列头显示的字段
|
||||||
onChange(e) {
|
onChange(e) {
|
||||||
debugger
|
|
||||||
// 只剩一个时候,最后一个多选按钮禁用
|
// 只剩一个时候,最后一个多选按钮禁用
|
||||||
if (this.checkedList.length === 1) {
|
if (this.checkedList.length === 1) {
|
||||||
this.plainOptions.forEach((item) => {
|
this.plainOptions.forEach((item) => {
|
||||||
@@ -263,8 +261,13 @@ export default {
|
|||||||
},
|
},
|
||||||
// 比较两个数组之间的不同,生成新数组
|
// 比较两个数组之间的不同,生成新数组
|
||||||
getArrDifference(arr1, arr2) {
|
getArrDifference(arr1, arr2) {
|
||||||
|
let that = this;
|
||||||
return arr1.concat(arr2).filter(function (v, i, arr) {
|
return arr1.concat(arr2).filter(function (v, i, arr) {
|
||||||
return arr.indexOf(v) === arr.lastIndexOf(v)
|
if (v !== that.defaultOperationKey){
|
||||||
|
return arr.indexOf(v) === arr.lastIndexOf(v)
|
||||||
|
} else {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
fixedChange(e, dataIndex) {
|
fixedChange(e, dataIndex) {
|
||||||
|
|||||||
@@ -31,7 +31,6 @@
|
|||||||
ref="jTable"
|
ref="jTable"
|
||||||
size="default"
|
size="default"
|
||||||
:columns="columns"
|
:columns="columns"
|
||||||
:isCheck="false"
|
|
||||||
:dataSource="dataSource"
|
:dataSource="dataSource"
|
||||||
>
|
>
|
||||||
<div
|
<div
|
||||||
@@ -134,9 +133,6 @@
|
|||||||
width: '150px',
|
width: '150px',
|
||||||
dataIndex: 'action',
|
dataIndex: 'action',
|
||||||
scopedSlots: { customRender: 'action' },
|
scopedSlots: { customRender: 'action' },
|
||||||
slots: {
|
|
||||||
fixedValue: 2,
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
dataSource:[],
|
dataSource:[],
|
||||||
|
|||||||
Reference in New Issue
Block a user