diff --git a/src/pages/Worker/Card/WorkerTimeControl.vue b/src/pages/Worker/Card/WorkerTimeControl.vue index f4c81102f..c480d5bd8 100644 --- a/src/pages/Worker/Card/WorkerTimeControl.vue +++ b/src/pages/Worker/Card/WorkerTimeControl.vue @@ -100,23 +100,15 @@ const formattedWeekTotalHours = computed(() => secondsToHoursMinutes(weekTotalHours.value) ); -// const onInputChange = async (date) => { -// if (!date) return; - -// const { timestamp, outside } = date.scope; -// const { year, month, day } = timestamp; -// const _date = new Date(year, month - 1, day); -// setDate(_date); - -// if (outside) getMailStates(_date); -// }; - const onInputChange = async (date) => { if (!date) return; - const { year, month, day } = date.scope.timestamp; + const { timestamp, outside } = date.scope; + const { year, month, day } = timestamp; const _date = new Date(year, month - 1, day); setDate(_date); + + if (outside) getMailStates(_date); }; const setDate = async (date) => {