Sergiusz Bazanski | fb18c99 | 2019-05-01 12:27:03 +0200 | [diff] [blame] | 1 | <!doctype html> |
| 2 | <html lang="en"> |
| 3 | <head> |
| 4 | <meta charset="UTF-8"> |
| 5 | <title>Invoice 0001</title> |
| 6 | <link href="https://fonts.googleapis.com/css?family=Roboto:300,400,700" rel="stylesheet"> |
| 7 | <style type="text/css"> |
| 8 | body { |
| 9 | background-color: #fff; |
| 10 | font-family: 'Roboto', sans-serif; |
| 11 | font-size: 1em; |
| 12 | |
| 13 | padding: 2em; |
| 14 | } |
| 15 | ul { |
| 16 | list-style: none; |
| 17 | padding: 0; |
| 18 | } |
| 19 | ul li { |
| 20 | margin-bottom: 0.2em; |
| 21 | } |
| 22 | |
| 23 | @page { |
| 24 | size: A4; |
| 25 | margin: 0; |
| 26 | } |
| 27 | div.rhs { |
| 28 | float: right; |
| 29 | width: 50%; |
| 30 | text-align: right; |
| 31 | } |
| 32 | div.lhs { |
| 33 | float: left; |
| 34 | text-align: left; |
| 35 | width: 50%; |
| 36 | min-height: 35em; |
| 37 | } |
| 38 | div.metadata { |
| 39 | margin-top: 2em; |
| 40 | } |
| 41 | div.invoicee { |
| 42 | margin-top: 9em; |
| 43 | } |
| 44 | h1 { |
| 45 | font-size: 1.5em; |
| 46 | margin: 0; |
| 47 | text-transform: uppercase; |
| 48 | } |
Sergiusz Bazanski | a103f06 | 2019-05-18 16:23:58 +0200 | [diff] [blame] | 49 | h2 { |
| 50 | font-size: 1.2em; |
| 51 | margin: 0; |
| 52 | } |
Sergiusz Bazanski | fb18c99 | 2019-05-01 12:27:03 +0200 | [diff] [blame] | 53 | table.items { |
| 54 | text-align: right; |
| 55 | border-spacing: 0px; |
| 56 | border-collapse: collapse; |
| 57 | border: 0; |
| 58 | width: 100%; |
| 59 | } |
| 60 | table.items td,th { |
| 61 | border: 1px solid black; |
| 62 | } |
| 63 | table.items tr:first-child { |
| 64 | background-color: #eee; |
| 65 | color: #111; |
| 66 | padding: 0.8em; |
| 67 | text-align: left; |
| 68 | } |
| 69 | table.items td { |
| 70 | background-color: #fff; |
| 71 | } |
| 72 | table.items td,th { |
| 73 | padding: 0.5em 1em 0.5em 1em; |
| 74 | } |
| 75 | td.lhead { |
| 76 | border: 0 !important; |
| 77 | text-align: right; |
| 78 | text-transform: uppercase; |
| 79 | background: rgba(0, 0, 0, 0) !important; |
| 80 | } |
| 81 | div.bgtext { |
| 82 | z-index: -10; |
| 83 | position: absolute; |
| 84 | top: 140mm; |
| 85 | left: 0; |
| 86 | width: 100%; |
| 87 | } |
| 88 | div.bgtext div { |
| 89 | text-align: center; |
| 90 | font-size: 10em; |
| 91 | color: #ddd; |
| 92 | -webkit-transform: rotate(-45deg); |
| 93 | text-transform: uppercase; |
| 94 | } |
| 95 | </style> |
| 96 | </head> |
| 97 | <body> |
| 98 | {{ if .Proforma }} |
| 99 | <div class="bgtext"><div>Proforma</div></div> |
| 100 | {{ end }} |
| 101 | <div class="rhs"> |
| 102 | <div class="invoicer"> |
| 103 | <ul> |
| 104 | {{ range $i, $e := .InvoicerBilling }} |
| 105 | {{ if eq $i 0 }} |
| 106 | <li><b>{{ $e }}</b></li> |
| 107 | {{ else }} |
| 108 | <li>{{ $e }}</li> |
| 109 | {{ end }} |
| 110 | {{ end }} |
| 111 | {{ if .InvoicerCompanyNumber }} |
Sergiusz Bazanski | c2d322c | 2019-05-01 13:14:32 +0200 | [diff] [blame] | 112 | <li>{{ .InvoicerCompanyNumber }}</li> |
Sergiusz Bazanski | fb18c99 | 2019-05-01 12:27:03 +0200 | [diff] [blame] | 113 | {{ end }} |
Sergiusz Bazanski | c2d322c | 2019-05-01 13:14:32 +0200 | [diff] [blame] | 114 | <li><b>NIP:</b> {{ .InvoicerVAT }}</li> |
Sergiusz Bazanski | fb18c99 | 2019-05-01 12:27:03 +0200 | [diff] [blame] | 115 | </ul> |
| 116 | </div> |
| 117 | <div class="metadata"> |
| 118 | <ul> |
Sergiusz Bazanski | c2d322c | 2019-05-01 13:14:32 +0200 | [diff] [blame] | 119 | <li><b>Numer faktury:</b> {{ .InvoiceNumber }}</li> |
| 120 | <li><b>Data wystawienia:</b> {{ .Date.Format "2006/01/02" }}</li> |
| 121 | <li><b>Termin płatności:</b> {{ .DueDate.Format "2006/01/02" }}</li> |
Sergiusz Bazanski | fb18c99 | 2019-05-01 12:27:03 +0200 | [diff] [blame] | 122 | <li><b>IBAN:</b> {{ .IBAN }}</li> |
| 123 | <li><b>SWIFT/BIC:</b> {{ .SWIFT }}</li> |
| 124 | </ul> |
| 125 | </div> |
| 126 | </div> |
| 127 | <div class="lhs"> |
| 128 | <div class="invoicee"> |
| 129 | {{ if .Proforma }} |
Sergiusz Bazanski | a103f06 | 2019-05-18 16:23:58 +0200 | [diff] [blame] | 130 | <h1>Faktura Proforma</h1> |
Sergiusz Bazanski | fb18c99 | 2019-05-01 12:27:03 +0200 | [diff] [blame] | 131 | {{ else }} |
Sergiusz Bazanski | a103f06 | 2019-05-18 16:23:58 +0200 | [diff] [blame] | 132 | <h1>Faktura VAT</h1> |
Sergiusz Bazanski | fb18c99 | 2019-05-01 12:27:03 +0200 | [diff] [blame] | 133 | {{ end }} |
Sergiusz Bazanski | a103f06 | 2019-05-18 16:23:58 +0200 | [diff] [blame] | 134 | <h2>nr. {{ .InvoiceNumber }}</h2> |
Sergiusz Bazanski | fb18c99 | 2019-05-01 12:27:03 +0200 | [diff] [blame] | 135 | <ul> |
| 136 | {{ range $i, $e := .InvoiceeBilling }} |
| 137 | {{ if eq $i 0 }} |
| 138 | <li><b>{{ $e }}</b></li> |
| 139 | {{ else }} |
| 140 | <li>{{ $e }}</li> |
| 141 | {{ end }} |
| 142 | {{ end }} |
| 143 | {{ if .USCustomer }} |
| 144 | <li>EIN: {{ .InvoiceeVAT }}</li> |
| 145 | <li><b>(VAT zero rate)</b></li> |
Sergiusz Bazanski | de3d3fa | 2020-05-31 00:12:11 +0200 | [diff] [blame] | 146 | {{ else if .InvoiceeVAT }} |
Sergiusz Bazanski | c2d322c | 2019-05-01 13:14:32 +0200 | [diff] [blame] | 147 | <li><b>NIP:</b> {{ .InvoiceeVAT }}</li> |
Sergiusz Bazanski | fb18c99 | 2019-05-01 12:27:03 +0200 | [diff] [blame] | 148 | {{ end }} |
| 149 | |
| 150 | {{ if .ReverseVAT }} |
Sergiusz Bazanski | a103f06 | 2019-05-18 16:23:58 +0200 | [diff] [blame] | 151 | <li><b>(nie podlega VAT)</b></li> |
Sergiusz Bazanski | fb18c99 | 2019-05-01 12:27:03 +0200 | [diff] [blame] | 152 | {{ end }} |
| 153 | </ul> |
| 154 | </div> |
| 155 | </div> |
| 156 | <div style="clear: both; height: 1em;"></div> |
| 157 | <table class="items"> |
| 158 | <tr> |
Sergiusz Bazanski | c2d322c | 2019-05-01 13:14:32 +0200 | [diff] [blame] | 159 | <th style="width: 60%;">Nazwa towaru lub usługi</th> |
| 160 | <th>Cena<br />netto</th> |
| 161 | <th>Ilość</th> |
| 162 | <th>VAT (%)</th> |
| 163 | <th>Wartość<br />netto</th> |
| 164 | <th>Wartość<br />brutto</th> |
Sergiusz Bazanski | fb18c99 | 2019-05-01 12:27:03 +0200 | [diff] [blame] | 165 | </tr> |
| 166 | {{ range .Items }} |
| 167 | <tr> |
| 168 | <td style="text-align: left;">{{ .Title }}</td> |
| 169 | <td>{{ .UnitPrice }}</td> |
| 170 | <td>{{ .Qty }}</td> |
| 171 | <td>{{ .VATRate }}</td> |
| 172 | <td>{{ .TotalNet }}</td> |
| 173 | <td>{{ .Total }}</td> |
| 174 | </tr> |
| 175 | {{ end }} |
| 176 | <tr> |
Sergiusz Bazanski | c2d322c | 2019-05-01 13:14:32 +0200 | [diff] [blame] | 177 | <td colspan="5" class="lhead">RAZEM netto</td> |
Sergiusz Bazanski | fb18c99 | 2019-05-01 12:27:03 +0200 | [diff] [blame] | 178 | <td>{{ .TotalNet }}</td> |
| 179 | </tr> |
| 180 | <tr> |
Sergiusz Bazanski | a103f06 | 2019-05-18 16:23:58 +0200 | [diff] [blame] | 181 | <td colspan="5" class="lhead">VAT{{ if .ReverseVAT }} (nie podlega){{ end }} {{ if .USCustomer }}(nie podlega){{ end }}</td> |
Sergiusz Bazanski | fb18c99 | 2019-05-01 12:27:03 +0200 | [diff] [blame] | 182 | <td>{{ .VATTotal }}</td> |
| 183 | </tr> |
| 184 | <tr> |
Sergiusz Bazanski | c2d322c | 2019-05-01 13:14:32 +0200 | [diff] [blame] | 185 | <td colspan="5" class="lhead"><b>RAZEM brutto</b></td> |
| 186 | <td><b>{{ .Total }}</b></td> |
Sergiusz Bazanski | fb18c99 | 2019-05-01 12:27:03 +0200 | [diff] [blame] | 187 | </tr> |
| 188 | </table> |
| 189 | </body> |
| 190 | </html> |