aboutsummaryrefslogtreecommitdiff
path: root/src/components/invoice_summary.vue
diff options
context:
space:
mode:
Diffstat (limited to 'src/components/invoice_summary.vue')
-rw-r--r--src/components/invoice_summary.vue9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/components/invoice_summary.vue b/src/components/invoice_summary.vue
new file mode 100644
index 0000000..6ca7907
--- /dev/null
+++ b/src/components/invoice_summary.vue
@@ -0,0 +1,9 @@
+<script setup lang="js">
+import currency from "currency.js"
+
+const props = defineProps(["items", "isLoading"])
+</script>
+
+<template>
+ Total: {{ props.items.reduce((t, c) => t.add(c.TotalAmount), currency(0)) }}
+</template>