diff --git a/src/components/ui/VnFilterPanel.vue b/src/components/ui/VnFilterPanel.vue index 726956772..f09fa7858 100644 --- a/src/components/ui/VnFilterPanel.vue +++ b/src/components/ui/VnFilterPanel.vue @@ -2,6 +2,7 @@ import { onMounted, ref, computed } from 'vue'; import { useI18n } from 'vue-i18n'; import { useArrayData } from 'composables/useArrayData'; +import toDate from 'filters/toDate'; const { t } = useI18n(); const props = defineProps({ @@ -78,6 +79,18 @@ async function remove(key) { delete store.userParams[key]; await search(); } + +function formatValue(value) { + if (typeof value === 'boolean') { + return value ? t('Yes') : t('No'); + } + + if (isNaN(value) && !isNaN(Date.parse(value))) { + return toDate(value); + } + + return `"${value}"`; +}