From f41e95921f5adff22bb9bc1231d13c508746914f Mon Sep 17 00:00:00 2001 From: Soroosh Date: Sun, 26 Sep 2021 18:50:12 +0330 Subject: [PATCH] Enable localization for pagination --- src/pages/DashboardHome.vue | 12 ++++++++++++ src/pages/Details.vue | 12 ++++++++++++ 2 files changed, 24 insertions(+) diff --git a/src/pages/DashboardHome.vue b/src/pages/DashboardHome.vue index 186184e..9a9e2a8 100644 --- a/src/pages/DashboardHome.vue +++ b/src/pages/DashboardHome.vue @@ -57,6 +57,7 @@ v-model="page" :records="importantHeartBeatList.length" :per-page="perPage" + :options="paginationConfig" /> @@ -81,6 +82,17 @@ export default { page: 1, perPage: 25, heartBeatList: [], + paginationConfig: { + texts:{ + count:`${this.$t("Showing {from} to {to} of {count} records")}|{count} ${this.$t("records")}|${this.$t("One record")}`, + first:this.$t("First"), + last:this.$t("Last"), + nextPage:'>', + nextChunk:'>>', + prevPage:'<', + prevChunk:'<<' + } + } } }, computed: { diff --git a/src/pages/Details.vue b/src/pages/Details.vue index c93e47d..e4aeb28 100644 --- a/src/pages/Details.vue +++ b/src/pages/Details.vue @@ -181,6 +181,7 @@ v-model="page" :records="importantHeartBeatList.length" :per-page="perPage" + :options="paginationConfig" /> @@ -237,6 +238,17 @@ export default { heartBeatList: [], toggleCertInfoBox: false, showPingChartBox: true, + paginationConfig: { + texts:{ + count:`${this.$t("Showing {from} to {to} of {count} records")}|{count} ${this.$t("records")}|${this.$t("One record")}`, + first:this.$t("First"), + last:this.$t("Last"), + nextPage:'>', + nextChunk:'>>', + prevPage:'<', + prevChunk:'<<' + } + } } }, computed: {