From b05c5025c02234bca7de19dbb0fbb7919d8aaf90 Mon Sep 17 00:00:00 2001 From: philipp lang Date: Thu, 12 Dec 2024 21:26:51 +0100 Subject: [PATCH] Add button to mark invoice as paid --- resources/js/views/invoice/Index.vue | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/resources/js/views/invoice/Index.vue b/resources/js/views/invoice/Index.vue index 4e9fd0b7..1419b5d3 100644 --- a/resources/js/views/invoice/Index.vue +++ b/resources/js/views/invoice/Index.vue @@ -114,6 +114,7 @@
+
@@ -143,4 +144,9 @@ async function sendMassstore() { await axios.post(meta.value.links['mass-store'], massstore.value); massstore.value = null; } + +async function markAsPaid(invoice) { + await axios.patch(invoice.links.update, {...invoice, status: 'Rechnung beglichen'}); + await reloadPage(); +}