From 493e51833955b79906b46ca552c7074e0af419c6 Mon Sep 17 00:00:00 2001 From: Jon Date: Tue, 29 Oct 2024 12:15:40 +0100 Subject: [PATCH 01/18] feat: refs #6999 added search when user tabs on a filter with value --- src/pages/Entry/EntryLatestBuys.vue | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/src/pages/Entry/EntryLatestBuys.vue b/src/pages/Entry/EntryLatestBuys.vue index 119808176..50a4ccc7f 100644 --- a/src/pages/Entry/EntryLatestBuys.vue +++ b/src/pages/Entry/EntryLatestBuys.vue @@ -4,6 +4,7 @@ import { useI18n } from 'vue-i18n'; import { useStateStore } from 'stores/useStateStore'; import { toDate } from 'src/filters'; +import { useArrayData } from 'composables/useArrayData'; import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue'; import RightMenu from 'src/components/common/RightMenu.vue'; import EntryLatestBuysFilter from './EntryLatestBuysFilter.vue'; @@ -12,6 +13,9 @@ import VnImg from 'src/components/ui/VnImg.vue'; const stateStore = useStateStore(); const { t } = useI18n(); +const tableRef = ref(); +const arrayData = useArrayData('LatestBuys', { searchUrl: 'Buys/latestBuysFilter' }); +const lastParams = {}; const columns = [ { align: 'center', @@ -234,13 +238,26 @@ const columns = [ format: (row, dashIfEmpty) => dashIfEmpty(toDate(row.landing)), }, ]; -const tableRef = ref(); onMounted(async () => { stateStore.rightDrawer = true; }); onUnmounted(() => (stateStore.rightDrawer = false)); + +const onTabPressed = async () => { + let params = tableRef.value.params; + + if ( + Object.keys(params).length > 0 && + JSON.stringify(params) !== JSON.stringify(lastParams) + ) { + Object.assign(lastParams, params); + + await arrayData.addFilter({ filter: { where: params } }); + } + params = {}; +}; From 7f4a73fd56451c83fad6a932270eb968345c2917 Mon Sep 17 00:00:00 2001 From: Jon Date: Thu, 14 Nov 2024 08:30:55 +0100 Subject: [PATCH 02/18] feat: refs #6999 added tab to search in VnTable filter --- src/components/VnTable/VnFilter.vue | 5 +++++ src/pages/Entry/EntryLatestBuys.vue | 18 ------------------ 2 files changed, 5 insertions(+), 18 deletions(-) diff --git a/src/components/VnTable/VnFilter.vue b/src/components/VnTable/VnFilter.vue index 9da0b26a4..c9c81f5a7 100644 --- a/src/components/VnTable/VnFilter.vue +++ b/src/components/VnTable/VnFilter.vue @@ -143,6 +143,10 @@ function alignRow() { const showFilter = computed( () => $props.column?.columnFilter !== false && $props.column.name != 'tableActions' ); + +const onTabPressed = async () => { + if (model.value) enterEvent['keyup.enter'](); +}; diff --git a/src/pages/Entry/EntryLatestBuys.vue b/src/pages/Entry/EntryLatestBuys.vue index 50a4ccc7f..bc10ac1ca 100644 --- a/src/pages/Entry/EntryLatestBuys.vue +++ b/src/pages/Entry/EntryLatestBuys.vue @@ -4,7 +4,6 @@ import { useI18n } from 'vue-i18n'; import { useStateStore } from 'stores/useStateStore'; import { toDate } from 'src/filters'; -import { useArrayData } from 'composables/useArrayData'; import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue'; import RightMenu from 'src/components/common/RightMenu.vue'; import EntryLatestBuysFilter from './EntryLatestBuysFilter.vue'; @@ -14,8 +13,6 @@ import VnImg from 'src/components/ui/VnImg.vue'; const stateStore = useStateStore(); const { t } = useI18n(); const tableRef = ref(); -const arrayData = useArrayData('LatestBuys', { searchUrl: 'Buys/latestBuysFilter' }); -const lastParams = {}; const columns = [ { align: 'center', @@ -244,20 +241,6 @@ onMounted(async () => { }); onUnmounted(() => (stateStore.rightDrawer = false)); - -const onTabPressed = async () => { - let params = tableRef.value.params; - - if ( - Object.keys(params).length > 0 && - JSON.stringify(params) !== JSON.stringify(lastParams) - ) { - Object.assign(lastParams, params); - - await arrayData.addFilter({ filter: { where: params } }); - } - params = {}; -}; From e119bf5bfc0ab05ecfa700db976812f035b16d82 Mon Sep 17 00:00:00 2001 From: pablone Date: Tue, 19 Nov 2024 07:59:14 +0100 Subject: [PATCH 03/18] feat: refs #8138 add component ticket problems --- src/pages/Monitor/Ticket/MonitorTickets.vue | 57 +------------------ src/pages/Ticket/TicketList.vue | 62 +-------------------- 2 files changed, 4 insertions(+), 115 deletions(-) diff --git a/src/pages/Monitor/Ticket/MonitorTickets.vue b/src/pages/Monitor/Ticket/MonitorTickets.vue index 406bf5f29..f08402d69 100644 --- a/src/pages/Monitor/Ticket/MonitorTickets.vue +++ b/src/pages/Monitor/Ticket/MonitorTickets.vue @@ -15,6 +15,7 @@ import { toCurrency, dateRange, dashIfEmpty } from 'src/filters'; import RightMenu from 'src/components/common/RightMenu.vue'; import MonitorTicketSearchbar from './MonitorTicketSearchbar.vue'; import MonitorTicketFilter from './MonitorTicketFilter.vue'; +import TicketProblems from 'src/components/ui/TicketProblems.vue'; const DEFAULT_AUTO_REFRESH = 2 * 60 * 1000; // 2min in ms const { t } = useI18n(); @@ -366,61 +367,7 @@ const openTab = (id) =>