Merge pull request #160 from dderbentsov/UC-64
WIP Исправила баг пагинации при поиске
This commit is contained in:
@@ -6,8 +6,8 @@
|
||||
)
|
||||
.icon-down-arrow.arrow-left
|
||||
button.item.flex.items-center.justify-center(
|
||||
v-for="page in pageCount",
|
||||
:key="page",
|
||||
v-for="page, index in pageCount",
|
||||
:key="index",
|
||||
:id="page",
|
||||
:class="currentPageStyle(page)",
|
||||
:disabled="disabledMissingPages(page)"
|
||||
@@ -33,12 +33,12 @@ export default {
|
||||
},
|
||||
computed: {
|
||||
pageCount() {
|
||||
let countArray = [],
|
||||
incompleteCountArray = [];
|
||||
let countArray = [];
|
||||
for (let i = 1; i <= this.length; i++) {
|
||||
countArray.push(i);
|
||||
}
|
||||
if (this.length <= this.totalVisible) return countArray;
|
||||
let incompleteCountArray = [];
|
||||
if (
|
||||
this.currentPage <= 2 ||
|
||||
this.currentPage >= countArray[this.length - 2]
|
||||
|
||||
@@ -79,7 +79,6 @@ export default {
|
||||
else this.textSearch = "";
|
||||
if (this.currentTablePage !== 1) this.currentTablePage = 1;
|
||||
else {
|
||||
this.currentTablePage = 1;
|
||||
this.fetchDataClients();
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user