diff --git a/src/components/DataTable/compenents/el-data-table/el-data-table.vue b/src/components/DataTable/compenents/el-data-table/el-data-table.vue index 63dadc190..5cefbfa6a 100644 --- a/src/components/DataTable/compenents/el-data-table/el-data-table.vue +++ b/src/components/DataTable/compenents/el-data-table/el-data-table.vue @@ -8,12 +8,12 @@ @@ -91,28 +91,28 @@ @@ -166,6 +166,7 @@ import getLocatedSlotKeys from './utils/extract-keys' import transformSearchImmediatelyItem from './utils/search-immediately-item' import isFalsey from './utils/is-falsey' import merge from 'deepmerge' + const defaultFirstPage = 1 const noPaginationDataPath = 'payload' @@ -267,7 +268,8 @@ export default { */ beforeSearch: { type: Function, - default() {} + default() { + } }, /** * 单选, 适用场景: 不可以批量删除 @@ -706,7 +708,8 @@ export default { }, extraPaginationAttrs: { type: Object, - default: () => {} + default: () => { + } }, hasSelection: { type: Boolean, @@ -1036,6 +1039,7 @@ export default { } else { this.innerQuery = merge(this.innerQuery, attrs) } + this.selected.splice(0, this.selected.length) return this.getList() }, searchDate(attrs) { @@ -1198,7 +1202,9 @@ export default { remain === 0 && this.page === lastPage && this.page > defaultFirstPage - ) { this.page-- } + ) { + this.page-- + } }, // 树形table相关 diff --git a/src/components/ListTable/TableAction/LeftSide.vue b/src/components/ListTable/TableAction/LeftSide.vue index 598d81f3a..5f2050959 100644 --- a/src/components/ListTable/TableAction/LeftSide.vue +++ b/src/components/ListTable/TableAction/LeftSide.vue @@ -2,8 +2,8 @@ @@ -44,7 +44,8 @@ export default { canBulkUpdate: defaultTrue, handleBulkUpdate: { type: Function, - default: () => {} + default: () => { + } }, hasMoreActions: defaultTrue, tableUrl: { @@ -53,7 +54,8 @@ export default { }, reloadTable: { type: Function, - default: () => {} + default: () => { + } }, performBulkDelete: { type: Function, diff --git a/src/components/ListTable/TableAction/index.vue b/src/components/ListTable/TableAction/index.vue index 6219fcad3..930e0cc07 100644 --- a/src/components/ListTable/TableAction/index.vue +++ b/src/components/ListTable/TableAction/index.vue @@ -1,23 +1,23 @@