<template>
  <n-space vertical>
    <n-pagination v-model:page="pageNum" :page-count="pageSize" />
  </n-space>
</template>

<script lang="ts">
import { reactive } from 'vue';
import { defineComponent, ref } from 'vue';
import type { QueryParams } from '~/src/service/api/user';

export default defineComponent({
  setup() {
    const pageNum = ref(2);
    const pageSize = ref<any>(10);
    const queryData = reactive<QueryParams>({});
    function queryList() {
      console.log(1);

      // query(1, 10, queryData).then(r => {
      // 	console.log(r);
      // });
    }

    return {
      // 每页条数， 可自定义 page-size
      pageNum,
      // page-count
      pageSize,
      queryList,
      queryData
      // page: ref(2),
      // pageSize: ref(20),
      // queryData:reactive({})
    };
  }
});
</script>
