forked from hswaw/hscloud
bgpwtf/invoice: format for non-eu customers
Change-Id: I42ec23d911cd69a310a6de8ffe5dca5ff1b30f00master
parent
8a572cd36a
commit
87ede25bec
|
@ -52,9 +52,13 @@ func renderInvoicePDF(i *pb.Invoice, language string) ([]byte, error) {
|
||||||
}
|
}
|
||||||
if len(parts) > 0 {
|
if len(parts) > 0 {
|
||||||
symbols = strings.Join(parts, ", ") + "."
|
symbols = strings.Join(parts, ", ") + "."
|
||||||
|
} else {
|
||||||
|
if language == "en" {
|
||||||
|
symbols = "<i>brak (none)</i>."
|
||||||
} else {
|
} else {
|
||||||
symbols = "<i>brak</i>."
|
symbols = "<i>brak</i>."
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
data := struct {
|
data := struct {
|
||||||
InvoiceNumber string
|
InvoiceNumber string
|
||||||
|
|
|
@ -143,21 +143,21 @@ div.symbols {
|
||||||
{{ end }}
|
{{ end }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
{{ if .USCustomer }}
|
{{ if .USCustomer }}
|
||||||
<li>EIN: {{ .InvoiceeVAT }}</li>
|
<li>{{ .InvoiceeVAT }}</li>
|
||||||
<li><b>(VAT zero rate)</b></li>
|
<li style="margin-top: 2em;"><b>VAT NP</b> <i>(zero rate)</i></li>
|
||||||
{{ else if .InvoiceeVAT }}
|
{{ else if .InvoiceeVAT }}
|
||||||
<li><b>NIP:</b> {{ .InvoiceeVAT }}</li>
|
<li><b>NIP:</b> {{ .InvoiceeVAT }}</li>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
{{ if .ReverseVAT }}
|
{{ if .ReverseVAT }}
|
||||||
<li><b>(reverse charge / obciążenie odwrotne)</b></li>
|
<li><b>Obciążenie odwrotne</b> <i>(reverse charge)</ii></li>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div style="clear: both; height: 1em;"></div>
|
<div style="clear: both; height: 1em;"></div>
|
||||||
<div class="symbols">
|
<div class="symbols">
|
||||||
<b>Oznaczenia</b>: {{ .Symbols }}
|
<b>Oznaczenia</b> <i>(JPK symbols)</i>: {{ .Symbols }}
|
||||||
</div>
|
</div>
|
||||||
<table class="items">
|
<table class="items">
|
||||||
<tr>
|
<tr>
|
||||||
|
@ -201,8 +201,5 @@ div.symbols {
|
||||||
<td><b>{{ .Total }}</b></td>
|
<td><b>{{ .Total }}</b></td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
<div class="footer">
|
|
||||||
{{ .Footer }}
|
|
||||||
</div>
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|
Loading…
Reference in New Issue