ทั้งหมดรายการ

This commit is contained in:
STW_TTTY\stwtt 2024-04-26 10:05:07 +07:00
parent 9f90e4575f
commit b6809d98c2
4 changed files with 12 additions and 0 deletions

View file

@ -15,6 +15,7 @@ import type { ListGroup } from "@/modules/14_KPI/interface/request/Main";
import http from "@/plugins/http";
import config from "@/app.config";
const total = ref<number>()
const id = ref<string>("");
const modal = ref<boolean>(false);
const rows = ref<any>([]);
@ -98,6 +99,7 @@ async function getData() {
`?page=${formQuery.page}&pageSize=${formQuery.pageSize}&keyword=${formQuery.keyword}`
)
.then((res) => {
total.value = res.data.result.total
const data = res.data.result;
totalList.value = Math.ceil(res.data.result.total / formQuery.pageSize);
rows.value = data.data;
@ -460,6 +462,7 @@ onMounted(async () => {
</q-tr>
</template>
<template v-slot:pagination="scope">
งหมด {{ total }} รายการ
<q-pagination
v-model="formQuery.page"
active-color="primary"