From a3b253c9eba0464e233086fb9ada4356154e195e Mon Sep 17 00:00:00 2001 From: robert Date: Mon, 2 Sep 2024 11:14:46 +0200 Subject: [PATCH 1/4] feat: refs #211153 businessDataLinkGrafana --- src/pages/Customer/Card/CustomerSummary.vue | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/pages/Customer/Card/CustomerSummary.vue b/src/pages/Customer/Card/CustomerSummary.vue index 15bf19b48..da50ba239 100644 --- a/src/pages/Customer/Card/CustomerSummary.vue +++ b/src/pages/Customer/Card/CustomerSummary.vue @@ -217,7 +217,11 @@ const creditWarning = computed(() => { /> - + Date: Tue, 3 Sep 2024 10:31:01 +0200 Subject: [PATCH 2/4] perf: improve mainShrotcutMixin --- src/boot/mainShortcutMixin.js | 23 +++++++++++++++++++---- 1 file changed, 19 insertions(+), 4 deletions(-) diff --git a/src/boot/mainShortcutMixin.js b/src/boot/mainShortcutMixin.js index c4d37fd73..3b5c604b7 100644 --- a/src/boot/mainShortcutMixin.js +++ b/src/boot/mainShortcutMixin.js @@ -1,8 +1,10 @@ import routes from 'src/router/modules'; - import { useRouter } from 'vue-router'; + +let isNotified = false; + export default { - mounted: function () { + created: function () { const router = useRouter(); const keyBindingMap = routes .filter((route) => route.meta.keyBinding) @@ -10,14 +12,27 @@ export default { map[route.meta.keyBinding.toLowerCase()] = route.path; return map; }, {}); + const handleKeyDown = (event) => { const { ctrlKey, altKey, key } = event; - event.preventDefault(); - if (ctrlKey && altKey && keyBindingMap[key]) { + + if (ctrlKey && altKey && keyBindingMap[key] && !isNotified) { + event.preventDefault(); router.push(keyBindingMap[key]); + isNotified = true; + } + }; + + const handleKeyUp = (event) => { + const { ctrlKey, altKey } = event; + + // Resetea la bandera cuando se sueltan las teclas ctrl o alt + if (!ctrlKey || !altKey) { + isNotified = false; } }; window.addEventListener('keydown', handleKeyDown); + window.addEventListener('keyup', handleKeyUp); }, }; From 4e73e74c2c5c7be8545b1be9a845227cb8bd5998 Mon Sep 17 00:00:00 2001 From: Javier Segarra Date: Tue, 3 Sep 2024 10:31:24 +0200 Subject: [PATCH 3/4] fix: add border-top --- src/css/app.scss | 1 + 1 file changed, 1 insertion(+) diff --git a/src/css/app.scss b/src/css/app.scss index 41d3df795..357c9ecdb 100644 --- a/src/css/app.scss +++ b/src/css/app.scss @@ -253,6 +253,7 @@ input::-webkit-inner-spin-button { } td { font-size: 11pt; + border-top: 1px solid var(--vn-page-color); border-collapse: collapse; } } From 397a2606f16065f8c8ee95548c89cd186c3faf0d Mon Sep 17 00:00:00 2001 From: Javier Segarra Date: Tue, 3 Sep 2024 10:31:37 +0200 Subject: [PATCH 4/4] fix: cli warnings --- src/pages/Claim/Card/ClaimSummary.vue | 3 +-- src/pages/Entry/EntryList.vue | 3 --- src/pages/InvoiceOut/InvoiceOutList.vue | 1 - src/pages/Item/Card/ItemBotanical.vue | 2 -- src/pages/Item/ItemRequest.vue | 1 - src/pages/Worker/Card/WorkerSummary.vue | 1 - src/pages/Zone/Card/ZoneCard.vue | 12 +----------- 7 files changed, 2 insertions(+), 21 deletions(-) diff --git a/src/pages/Claim/Card/ClaimSummary.vue b/src/pages/Claim/Card/ClaimSummary.vue index 9538e753f..244eb5936 100644 --- a/src/pages/Claim/Card/ClaimSummary.vue +++ b/src/pages/Claim/Card/ClaimSummary.vue @@ -1,11 +1,10 @@