feat(transfer): 新增 showSearch 属性

This commit is contained in:
就眠儀式
2022-03-17 17:08:31 +08:00
parent da1e07a9be
commit 4d0e68448c
6 changed files with 132 additions and 16 deletions

View File

@@ -56,12 +56,7 @@ const maxPage = ref(0);
const totalPage = computed(() => {
maxPage.value = Math.ceil(props.total / props.limit);
let r: number[] = [],
start =
maxPage.value <= props.pages
? 1
: currentPage.value > pages
? currentPage.value - pages
: 1;
start = maxPage.value <= props.pages ? 1 : currentPage.value > pages ? currentPage.value - pages : 1;
for (let i = start; ; i++) {
if (r.length >= props.pages || i > maxPage.value) {
break;
@@ -100,7 +95,6 @@ const jumpPage = function () {
watch(inlimit, function () {
currentPage.value = 1;
// maxPage.value = Math.ceil(props.total / inlimit.value);
});
watch(currentPage, function () {