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

This commit is contained in:
STW_TTTY\stwtt 2024-04-29 18:04:55 +07:00
parent bebdfbfce5
commit efb095b37a
4 changed files with 8 additions and 0 deletions

View file

@ -14,6 +14,7 @@ import config from "@/app.config";
import type { FormType } from "@/modules/07_appealComplain/interface/response/mainType";
import type { DataOption } from "@/modules/07_appealComplain/interface/index/main";
const total = ref<number>(0)
const currentPage = ref<number>(1);
const maxPage = ref<number>(1);
const page = ref<number>(1);
@ -174,6 +175,7 @@ const getData = async () => {
)
)
.then((res: any) => {
total.value = res.data.result.total
maxPage.value = Math.ceil(res.data.result.total / rowsPerPage.value);
let data = res.data.result.data;
dataStore.fetchAppealComplain(data);
@ -390,6 +392,7 @@ onMounted(async () => {
:rows-per-page-options="[10, 25, 50, 100]"
>
<template v-slot:pagination="scope">
งหมด {{ total }} รายการ
<q-pagination
v-model="currentPage"
active-color="primary"