From a476af0ad96ec966ba8a08328d7aecdcb851b650 Mon Sep 17 00:00:00 2001 From: "DESKTOP-1R2VSQH\\Lenovo ThinkPad E490" Date: Thu, 30 Nov 2023 17:24:21 +0700 Subject: [PATCH] =?UTF-8?q?=E0=B8=9B=E0=B8=A3=E0=B8=B1=E0=B8=9A=20rowIndex?= =?UTF-8?q?=20table?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/modules/09_leave/components/1_Work/TableList.vue | 8 +++++++- src/modules/09_leave/components/2_Leave/TableList.vue | 7 ++++++- 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/src/modules/09_leave/components/1_Work/TableList.vue b/src/modules/09_leave/components/1_Work/TableList.vue index e72e5e330..b23e09053 100644 --- a/src/modules/09_leave/components/1_Work/TableList.vue +++ b/src/modules/09_leave/components/1_Work/TableList.vue @@ -122,7 +122,13 @@ function updateRowsPerPagen(newPagination: any) { @click.prevent="clickDetail(props.row)" >
- {{ props.rowIndex + 1 }} + + + {{ + (currentPage - 1) * Number(pagination.rowsPerPage) + + props.rowIndex + + 1 + }}
diff --git a/src/modules/09_leave/components/2_Leave/TableList.vue b/src/modules/09_leave/components/2_Leave/TableList.vue index ad3a1298c..8874d03ff 100644 --- a/src/modules/09_leave/components/2_Leave/TableList.vue +++ b/src/modules/09_leave/components/2_Leave/TableList.vue @@ -197,6 +197,7 @@ onMounted(() => { :paging="true" dense class="custom-header-table" + :rows-per-page-options="[10, 25, 50, 100]" :visible-columns="leaveStore.visibleColumns" :pagination="pagination" @update:pagination="updatedPagination" @@ -217,7 +218,11 @@ onMounted(() => { @click.prevent="redirectToDetail(props.row.id)" >
- {{ props.rowIndex + 1 }} + {{ + (currentPage - 1) * Number(pagination.rowsPerPage) + + props.rowIndex + + 1 + }}