diff --git a/src/api/05_command/api.command.ts b/src/api/05_command/api.command.ts index d9c4e897..9857f070 100644 --- a/src/api/05_command/api.command.ts +++ b/src/api/05_command/api.command.ts @@ -13,6 +13,6 @@ export default { commandSysId: string, search: string ) => - `${commandSalary}/admin?page=${page}&pageSize=${pageSize}&isActive=${isActive}&commandSysId=${commandSysId}&search=${search}`, + `${commandSalary}/admin?page=${page}&pageSize=${pageSize}&isActive=${isActive}&commandSysId=${commandSysId}&searchKeyword=${search}`, commandSalaryById: (id: string) => `${commandSalary}/${id}`, }; diff --git a/src/modules/05_command/views/salaryLists.vue b/src/modules/05_command/views/salaryLists.vue index 6d11fd44..26b1748e 100644 --- a/src/modules/05_command/views/salaryLists.vue +++ b/src/modules/05_command/views/salaryLists.vue @@ -174,6 +174,8 @@ function onSubmit() { function selectInbox(data: CommandSysType) { activeOrderId.value = data.id; pagination.value.page = 1; + filter.value = ""; + fetchSalaryList(); } diff --git a/src/views/MainLayout.vue b/src/views/MainLayout.vue index 8f887f18..23f8570d 100644 --- a/src/views/MainLayout.vue +++ b/src/views/MainLayout.vue @@ -97,7 +97,7 @@ async function getDataNotification(index: number, type: string) { minute: "2-digit", }; await http - .get(config.API.msgNotificate + `?page=${index}&pageSize=${10}`) + .get(config.API.msgNotificate + `?page=${index}&pageSize=${15}`) .then((res) => { const response = res.data.result.data; totalInbox.value = res.data.result.total; @@ -286,9 +286,9 @@ function onLoad(index: any, done: Function) { (notiList.value.length === 0 && totalInbox.value === 0) ) { page.value++; - setTimeout(() => { + setTimeout(async () => { + await getDataNotification(page.value, "NOMAL"); done(); - getDataNotification(page.value, "NOMAL"); }, 1500); } } @@ -443,7 +443,11 @@ onUnmounted(() => { v-if="totalNoti !== 0" >{{ totalNoti }} - +
การแจ้งเตือน