fix: 修改表格分页多选框,最后一页数量统计错误的缺陷

修改表格分页多选框,最后一页数量统计错误的缺陷
This commit is contained in:
song-tianyang 2021-06-07 15:02:16 +08:00 committed by 刘瑞斌
parent 7dc83a4591
commit db39402603
12 changed files with 18 additions and 11 deletions

View File

@ -19,6 +19,7 @@
<ms-table-header-select-popover v-if="enableSelection && showSelectAll" ref="selectPopover"
:page-size="pageSize > total ? total : pageSize"
:table-data-count-in-page="data.length"
:total="total"
@selectPageAll="isSelectDataAll(false)"
@selectAll="isSelectDataAll(true)"/>
@ -189,8 +190,6 @@ export default {
mounted() {
getLabel(this, TEST_CASE_LIST);
},
created() {
},
watch: {
selectNodeIds() {
this.selectDataCounts = 0;

View File

@ -17,7 +17,7 @@
@click.native.stop="click('selectPageAll')"
ref="selectPageAllLink">
<span :style="selectPageFontColor">
{{ $t('api_test.batch_menus.select_show_data', [pageSize]) }}
{{ $t('api_test.batch_menus.select_show_data', [tableDataCountInPage]) }}
</span>
</el-link>
@ -43,6 +43,12 @@
return 10;
}
},
tableDataCountInPage: {
type: Number,
default() {
return 10;
}
},
selectDataCounts: {
type: Number,
default() {
@ -63,14 +69,6 @@
};
},
watch: {
// selectDataCounts() {
// this.reload();
// },
// total() {
// this.reload();
// }
},
methods: {
click(even) {
if (even === 'selectPageAll') {

View File

@ -15,6 +15,7 @@
:page-size="pageSize>total?total:pageSize"
:total="total"
:select-data-counts="selectDataCounts"
:table-data-count-in-page="tableData.length"
@selectPageAll="isSelectDataAll(false)"
@selectAll="isSelectDataAll(true)"/>
<el-table-column v-if="!referenced" width="30" min-width="30" :resizable="false" align="center">

View File

@ -18,6 +18,7 @@
:page-size="pageSize>total?total:pageSize"
:total="total"
:select-data-counts="selectDataCounts"
:table-data-count-in-page="tableData.length"
@selectPageAll="isSelectDataAll(false)"
@selectAll="isSelectDataAll(true)"/>
<el-table-column v-if="!referenced" width="30" min-width="30" :resizable="false" align="center">

View File

@ -16,6 +16,7 @@
:page-size="pageSize>total?total:pageSize"
:total="total"
:select-data-counts="selectDataCounts"
:table-data-count-in-page="tableData.length"
@selectPageAll="isSelectDataAll(false)"
@selectAll="isSelectDataAll(true)"/>
<el-table-column v-if="!referenced" width="30" min-width="30" :resizable="false" align="center">

View File

@ -25,6 +25,7 @@
:page-size="pageSize > total ? total : pageSize"
:total="total"
:select-data-counts="selectDataCounts"
:table-data-count-in-page="tableData.length"
@selectPageAll="isSelectDataAll(false)"
@selectAll="isSelectDataAll(true)"/>

View File

@ -23,6 +23,7 @@
<ms-table-header-select-popover v-show="total>0"
:page-size="pageSize > total ? total : pageSize"
:total="total"
:table-data-count-in-page="tableData.length"
@selectPageAll="isSelectDataAll(false)"
@selectAll="isSelectDataAll(true)"/>
<el-table-column width="40" :resizable="false" align="center">

View File

@ -18,6 +18,7 @@
<ms-table-header-select-popover v-show="total>0"
:page-size="pageSize > total ? total : pageSize"
:total="total"
:table-data-count-in-page="tableData.length"
@selectPageAll="isSelectDataAll(false)"
@selectAll="isSelectDataAll(true)"/>
<el-table-column width="40" :resizable="false" align="center">

View File

@ -44,6 +44,7 @@
<ms-table-header-select-popover v-show="total>0"
:page-size="pageSize > total ? total : pageSize"
:total="total"
:table-data-count-in-page="tableData.length"
@selectPageAll="isSelectDataAll(false)"
@selectAll="isSelectDataAll(true)"/>
<el-table-column width="30" :resizable="false" align="center">

View File

@ -21,6 +21,7 @@
<ms-table-header-select-popover v-show="total>0"
:page-size="pageSize > total ? total : pageSize"
:total="total"
:table-data-count-in-page="tableData.length"
@selectPageAll="isSelectDataAll(false)"
@selectAll="isSelectDataAll(true)"/>
<el-table-column min-width="40" :resizable="false" align="center">

View File

@ -20,6 +20,7 @@
:page-size="pageSize > total ? total : pageSize"
:total="total"
:select-data-counts="selectDataCounts"
:table-data-count-in-page="tableData.length"
@selectPageAll="isSelectDataAll(false)"
@selectAll="isSelectDataAll(true)"/>

View File

@ -35,6 +35,7 @@
<ms-table-header-select-popover v-show="total>0"
:page-size="pageSize > total ? total : pageSize"
:total="total"
:table-data-count-in-page="tableData.length"
@selectPageAll="isSelectDataAll(false)"
@selectAll="isSelectDataAll(true)"/>