diff --git a/src/views/Dashboard.vue b/src/views/Dashboard.vue
index 212404cf1..ce5834086 100644
--- a/src/views/Dashboard.vue
+++ b/src/views/Dashboard.vue
@@ -157,7 +157,7 @@ const thaiOptions: Intl.DateTimeFormatOptions = {
กล่องข้อความ
-
ทั้งหมด {{ totalInbox }} ข้อความ
+
ทั้งหมด {{ totalInbox }} ข้อความ
diff --git a/src/views/MainLayout.vue b/src/views/MainLayout.vue
index 83a56c48b..d43318725 100644
--- a/src/views/MainLayout.vue
+++ b/src/views/MainLayout.vue
@@ -451,14 +451,14 @@ const clickDelete = async (id: string, index: number) => {
const totalInbox = ref(0);
const totalNoti = ref(0);
const round = ref(0);
+const page = ref(0);
function onLoad(index: any, done: any) {
- if (notiList.value.length < totalInbox.value && isLoad) {
- setTimeout(() => {
- done();
- getDataNotification(index + 1, "NOMAL");
- }, 3000);
- }
+ page.value++;
+ setTimeout(() => {
+ done();
+ getDataNotification(page.value, "NOMAL");
+ }, 1500);
}
watch(
@@ -471,9 +471,6 @@ watch(
}));
notiList.value = updatedNotifications;
fetchmsgNoread();
- } else {
- round.value++;
- round.value === 1 && getDataNotification(round.value, "NOMAL");
}
}
);
@@ -534,27 +531,21 @@ watch(
v-if="totalNoti !== 0"
>{{ totalNoti }}
-
-
+
+
การแจ้งเตือน
-
ทั้งหมด {{ totalInbox }} ข้อความ
+
+ ทั้งหมด {{ totalInbox }} ข้อความ
+
-
-
+
+
@@ -582,9 +573,11 @@ watch(
@click="clickDelete(n.id, index)"
>
-
-
-
+
+
+
+
+