Merge pull request 'fix(date-picker): minor fixes to components due to components refactor.' (#6) from dev/nicolas/timesheet-approvals/date-picker into main

Reviewed-on: Targo/targo_frontend#6
This commit is contained in:
Nicolas 2025-08-22 11:36:09 -04:00
commit 8c42235851
2 changed files with 5 additions and 12 deletions

View File

@ -25,11 +25,11 @@ const emit = defineEmits<{
dense dense
rounded rounded
debounce="300" debounce="300"
v-model="props.searchModel"
:label="$t('shared.searchBar')" :label="$t('shared.searchBar')"
label-color="primary" label-color="primary"
bg-color="white" bg-color="white"
color="primary" color="primary"
:model-value="props.searchModel"
@update:model-value="value => emit('onSearchValueUpdated', value)" @update:model-value="value => emit('onSearchValueUpdated', value)"
> >
<template v-slot:append> <template v-slot:append>

View File

@ -1,6 +1,5 @@
<script setup lang="ts"> <script setup lang="ts">
import TimesheetApprovalEmployeeOverviewList from '/src/modules/timesheet-approval/\ import TimesheetApprovalEmployeeOverviewList from '../components/timesheet-approval-employee-overview-list.vue';
components/timesheet-approval-employee-overview-list.vue';
import { computed } from 'vue'; import { computed } from 'vue';
import { useI18n } from 'vue-i18n'; import { useI18n } from 'vue-i18n';
import { useTimesheetStore } from 'src/stores/timesheet-store'; import { useTimesheetStore } from 'src/stores/timesheet-store';
@ -17,16 +16,10 @@
const pay_period_label = computed(() => { const pay_period_label = computed(() => {
const dates = timesheet_store.current_pay_period.label.split('.'); const dates = timesheet_store.current_pay_period.label.split('.');
const start_date = new Intl.DateTimeFormat(locale.value, date_options); const start_date = new Intl.DateTimeFormat(locale.value, date_options).format(date.extractDate(dates[0] as string, 'YYYY-MM-DD'));
const end_date = new Intl.DateTimeFormat(locale.value, date_options); const end_date = new Intl.DateTimeFormat(locale.value, date_options).format(date.extractDate(dates[1] as string, 'YYYY-MM-DD'));
start_date.format(date.extractDate(dates[0] as string, 'YYYY-MM-DD'));
end_date.format(date.extractDate(dates[1] as string, 'YYYY-MM-DD'));
return { return { start_date, end_date };
start_date: start_date,
end_date: end_date,
};
}); });
</script> </script>