From c2159cc65ceec7126247a86ad3aa6ef5c6561fd6 Mon Sep 17 00:00:00 2001 From: Bing Sun Date: Mon, 27 Apr 2020 19:29:14 +0800 Subject: [PATCH] Table: fix pages calculation --- src/components/Table.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/Table.js b/src/components/Table.js index 3b4cab8..138f148 100644 --- a/src/components/Table.js +++ b/src/components/Table.js @@ -30,7 +30,7 @@ export default initial_vnode => { if (limit > 0 && limit < Infinity && model.cache().count) { let active_page = offset / limit - pages = Array.from(Array(Math.floor(model.cache().count / limit) + 1)) + pages = Array.from(Array(Math.ceil(model.cache().count / limit))) .map((_,i) => active_page == i ? {active: true} : {active: false}) if (pages.length <= 10) {