修复分页问题
This commit is contained in:
@@ -57,7 +57,8 @@
|
|||||||
let currentPage = ref(props.page === 0 ? 1 : props.page)
|
let currentPage = ref(props.page === 0 ? 1 : props.page)
|
||||||
|
|
||||||
function returnMaxPage() {
|
function returnMaxPage() {
|
||||||
return Math.ceil(props.totalElements / props.size)
|
const result=Math.ceil(props.totalElements / props.size)
|
||||||
|
return (result-1<=0?1:result-1)
|
||||||
}
|
}
|
||||||
let maxPage=ref(returnMaxPage())
|
let maxPage=ref(returnMaxPage())
|
||||||
const pagesData = computed(() => {
|
const pagesData = computed(() => {
|
||||||
|
|||||||
Reference in New Issue
Block a user