From dbeb9f4116be2964387a23c5039f15a2f687363d Mon Sep 17 00:00:00 2001 From: jedi Date: Wed, 26 Jun 2024 21:22:34 +0200 Subject: [PATCH] stash --- web/src/components/Timeline.vue | 6 +----- web/src/views/Ticket.vue | 5 +++-- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/web/src/components/Timeline.vue b/web/src/components/Timeline.vue index 97c8463..6130656 100644 --- a/web/src/components/Timeline.vue +++ b/web/src/components/Timeline.vue @@ -73,7 +73,7 @@ import TimelineMail from "@/components/TimelineMail.vue"; import TimelineComment from "@/components/TimelineComment.vue"; import TimelineStateChange from "@/components/TimelineStateChange.vue"; -import {mapActions, mapGetters} from "vuex"; +import {mapGetters} from "vuex"; import TimelineAssignment from "@/components/TimelineAssignment.vue"; import TimelineRelatedItem from "@/components/TimelineRelatedItem.vue"; import TimelineShippingVoucher from "@/components/TimelineShippingVoucher.vue"; @@ -103,7 +103,6 @@ export default { }, }, methods: { - ...mapActions(['fetchShippingVouchers']), sendMailAndClear: function () { this.$emit('sendMail', this.newMail); this.newMail = ""; @@ -112,9 +111,6 @@ export default { this.$emit('addComment', this.newComment); this.newComment = ""; } - }, - mounted() { - this.fetchShippingVouchers(); } }; diff --git a/web/src/views/Ticket.vue b/web/src/views/Ticket.vue index e92fb8e..7ca27b1 100644 --- a/web/src/views/Ticket.vue +++ b/web/src/views/Ticket.vue @@ -83,7 +83,7 @@ export default { methods: { ...mapActions(['deleteItem', 'markItemReturned', 'sendMail', 'updateTicketPartial', 'postComment']), ...mapActions(['loadTickets', 'fetchTicketStates', 'loadUsers', 'scheduleAfterInit']), - ...mapActions(['claimShippingVoucher']), + ...mapActions(['claimShippingVoucher', 'fetchShippingVouchers']), handleMail(mail) { this.sendMail({ id: this.ticket.id, @@ -110,7 +110,8 @@ export default { }, }, mounted() { - this.scheduleAfterInit(() => [this.fetchTicketStates(), this.loadTickets(), this.loadUsers()]); + this.scheduleAfterInit(() => [this.fetchTicketStates(), this.loadTickets(), this.loadUsers(), + this.fetchShippingVouchers()]); } };