add qr to invoice
This commit is contained in:
parent
01d7fc4cb7
commit
a16ceaa82e
1 changed files with 22 additions and 0 deletions
22
rechnung.typ
22
rechnung.typ
|
@ -1,5 +1,6 @@
|
|||
#import "templates/tmpl_letter.typ": tmpl_letter
|
||||
#import "templates/common.typ": colors, money
|
||||
#import "@preview/cades:0.3.0": qr-code
|
||||
#let config = yaml("rechnung.yml")
|
||||
|
||||
#show: doc => tmpl_letter(
|
||||
|
@ -73,4 +74,25 @@
|
|||
#pad(x:1em)[
|
||||
*Gesamtbetrag: #money(config.entries.map(e => e.pieces * e.price - e.sale).sum())*
|
||||
]
|
||||
]
|
||||
|
||||
#if config.type == "invoice" [
|
||||
#v(1em)
|
||||
#align(right)[
|
||||
#block(
|
||||
stroke: 1pt,
|
||||
inset: 1em,
|
||||
radius: 1em
|
||||
)[
|
||||
#qr-code("BCD\n002\n1\nSCT\n\nswablab e.V.\nDE12642624080125634005\nEUR" + str(config.entries.map(e => e.pieces * e.price - e.sale).sum()) + "\nGDDS\n\nRechnung " + str(config.invoice_no) + "\nswablab Rechnung", width: 2cm)
|
||||
|
||||
#place(center+bottom, dy: 1.1em)[
|
||||
#block(width: 100%+0.75em, fill: white)[
|
||||
#text(size: 8pt)[
|
||||
Zahlen mit Code
|
||||
]
|
||||
]
|
||||
]
|
||||
]
|
||||
]
|
||||
]
|
Loading…
Add table
Reference in a new issue