blob: 61837ed6884fbb423c04a9335909f5d2eebe3de8 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
|
<script setup lang="ts">
import Converter from "number-to-words"
const props = defineProps(["invoice", "total"])
</script>
<template>
<div class="print-preview-footer">
<div class="footer--col1">
<div class="footer--col1--row1">
<p class="total-words">
<strong>Total (in words):</strong>
{{ Number.isFinite(props.total.TotalWithGST.value) && `${Converter.toWords(props.total.TotalWithGST.value)} only` }}
</p>
</div>
<div class="footer--col1--row2">
</div>
<div class="footer--col1--row3">
<div>
<strong>Note:</strong>
</div>
<div>
{{ props.invoice.Note }}
</div>
</div>
</div>
<div class="footer--col2">
<div class="total-summary">
<span class="total-summary-row">
<span><strong>Total Before Tax</strong></span>
<span>{{props.total.TotalWithoutGST}}</span>
</span>
<span class="total-summary-row">
<span><strong>Total Tax Amount</strong></span>
<span>{{props.total.TotalGSTValue}}</span>
</span>
<span class="total-summary-row">
<span><strong>Total Amount</strong></span>
<span>{{props.total.TotalWithGST}}</span>
</span>
</div>
<div class="firm-signature-wrapper">
<img src="../assets/placeholdersignature.png"/>
</div>
</div>
</div>
</template>
<style>
.total-words {
text-transform: capitalize;
}
.footer--col1--row1 {
border-bottom: 1px solid gray;
padding: 0.1em 0.3em;
}
.print-preview-footer {
border: 1px solid gray;
display: grid;
grid-template-columns: 4fr 3fr;
width: 100%;
}
.footer--col1 {
border-right: 1pt solid gray;
display: grid;
grid-template-rows: 2fr 4fr 6fr;
}
.firm-signature-wrapper {
display: flex;
justify-content: center;
align-items: center;
max-width: 1.7in;
}
.firm-signature-wrapper img {
max-width: 100%;
max-height: 100%;
}
.total-summary {
display: grid;
grid-template-columns: 1fr;
padding: 0.1em 0.3em;
}
.total-summary-row {
display: grid;
grid-template-columns: 1fr 1fr;
}
.footer--col1--row3 {
display: grid;
grid-template-rows: 1.3em 1fr;
white-space: pre-wrap;
line-height: 1.3;
padding: 0.1em 0.3em;
border-top: 1px solid gray;
}
</style>
|