hide loop noti total

This commit is contained in:
Warunee Tamkoo 2025-04-07 18:40:07 +07:00
parent 95c577b647
commit ccb6d1b4eb

View file

@ -233,7 +233,7 @@ const activeBtn = () => {
};
const isSsoToken = ref<boolean>(false);
const interval = ref<any>(null);
// const interval = ref<any>(null);
/**
* เมอเรมตนโปรแกรมให event resize และ function myEventHandler
* set function myEventHandler เพราะ state งไมเซ , state เซทเม หนาจอเร ขยบหนาจอ
@ -259,9 +259,9 @@ onMounted(async () => {
fetchmsgNoread();
// fetch noread noti every 15 seconds
interval.value = setInterval(() => {
fetchmsgNoread();
}, 15000);
// interval.value = setInterval(() => {
// fetchmsgNoread();
// }, 15000);
myEventHandler(null, false);
window.addEventListener("resize", (e: any) => {
@ -276,9 +276,9 @@ onUnmounted(() => {
window.removeEventListener("resize", (e: any) => {
myEventHandler(e, true);
});
if (interval.value) {
clearInterval(interval.value);
}
// if (interval.value) {
// clearInterval(interval.value);
// }
});
/**