修复了分页

This commit is contained in:
luyuan 2020-11-25 14:50:26 +08:00
parent c1c2a8a3f9
commit 468682172f
Signed by: theluyuan
GPG Key ID: A7972FD973317FF3

View File

@ -175,7 +175,7 @@
}
</style>
<script lang="ts">
import { defineComponent, onMounted, ref } from "vue";
import { defineComponent, onMounted, ref, watch } from "vue";
import LiveItem from "@/components/LiveItem.vue";
import { getlivelist } from "@/api";
import { LivelistInfo } from "@/types";
@ -216,6 +216,14 @@ export default defineComponent({
console.log(input.value);
livelist.value = await getlivelist({title: input.value});
}
async function naxtpage(){
console.log(input.value);
livelist.value = await getlivelist({title: input.value, page: page.value});
}
watch(page,()=>{
console.log(page.value)
naxtpage()
})
return {
page,