Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
added reference to qr code
  • Loading branch information
Andreas Müller committed Jul 26, 2022
commit 4ae5f6ef3f868b314be3ad26de333cbb15b0a1c0
2 changes: 1 addition & 1 deletion documentation.md
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,7 @@ Defaults to `table`. `csv` and `markdown` can be printed to stdout, `pdf` and `x
There are additional options for the invoice output as given in the following example:

```shell
gtt report --output=invoice --file=invoice.md --from 2021-02-01 --to 2021-02-28 --closed --invoiceCurrencyMaxUnit 1 --invoiceTitle "Rechnung" --invoiceAddress "Firma" "Mr. X" "Strasse" "10000 Ort" "Land" --invoiceCurrency "EUR" --invoiceCurrencyPerHour "50" --invoiceVAT "0.15" --invoiceDate "1.03.2021" --invoicePositionText "Position Text"
gtt report --output=invoice --file=invoice.md --from 2021-02-01 --to 2021-02-28 --closed --invoiceCurrencyMaxUnit 1 --invoiceTitle "Rechnung" --invoiceReference "Reference" --invoiceAddress "Firma" "Mr. X" "Strasse" "10000 Ort" "Land" --invoiceCurrency "EUR" --invoiceCurrencyPerHour "50" --invoiceVAT "0.15" --invoiceDate "1.03.2021" --invoicePositionText "Position Text"
```

For paper invoice, further process the output with a css, see the folder preview (styles.css, invoice.pdf)
Expand Down
2 changes: 2 additions & 0 deletions src/gtt-report.js
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ program
.option('--show_without_times', 'show issues/merge requests without time records')
.option('--from_dump <file>', 'instead of querying gitlab, use data from the given dump file')
.option('--invoiceTitle <title>', 'title on invoice')
.option('--invoiceReference <reference>', 'payment reference on invoice')
.option('--invoiceAddress [address...]', 'address')
.option('--invoiceCurrency <currency>', 'currecnty on invoice')
.option('--invoiceCurrencyPerHour <number>', 'hourly wage rate on invoice')
Expand Down Expand Up @@ -133,6 +134,7 @@ config
.set('subgroups', program.opts().subgroups)
.set('_verbose', program.opts().verbose)
.set('invoiceTitle', program.opts().invoiceTitle)
.set('invoiceReference', program.opts().invoiceReference)
.set('invoiceAddress', program.opts().invoiceAddress)
.set('invoiceCurrency', program.opts().invoiceCurrency)
.set('invoiceCurrencyPerHour', program.opts().invoiceCurrencyPerHour)
Expand Down
2 changes: 1 addition & 1 deletion src/output/invoice.js
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ class invoice extends Base {
const data = {
currency: "CHF",
amount: this.totalForInvoice,
reference: this.config.get('invoiceTitle'),
reference: this.config.get('invoiceReference'),
creditor: {
name: this.config.get('invoiceSettings').from [0],
address: this.config.get('invoiceSettings').from [2],
Expand Down