Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/idorobots/invoice.py
A spartan invoice generator.
https://github.com/idorobots/invoice.py
invoice python spartan
Last synced: 8 days ago
JSON representation
A spartan invoice generator.
- Host: GitHub
- URL: https://github.com/idorobots/invoice.py
- Owner: Idorobots
- License: mit
- Created: 2016-05-10T19:49:49.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2023-11-02T08:38:43.000Z (about 1 year ago)
- Last Synced: 2024-10-11T01:18:55.205Z (25 days ago)
- Topics: invoice, python, spartan
- Language: Python
- Size: 20.5 KB
- Stars: 0
- Watchers: 2
- Forks: 2
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# invoice.py
A spartan invoice generator based on LaTeX and Pystache conforming to the Polish VAT invoice policy.# Usage
```bash
/src/invoice.py --template "templates/basic.tex" \
--number "1001" \
--issuer $ISSUER \
--recipient $RECIPIENT \
$ITEM1 $ITEM2 $ITEM3
```Where `$ISSUER` and `$RECIPIENT` take the following form:
```json
{
"name" : "string, a name of a company",
"address" : "string, an address of a company",
"id" : "string, tax ID numbers of a company",
"bank" : "optional string, the bank account number of a company",
"extra" : "optional string, any extra info like phone numbers or URLs"
}
```Each `$ITEM*` takes the following form:
```json
{
"name" : "string, the name of an item or service",
"net_price" : "number, the net price of an item or service",
"quantity" : "number, quantity of the items/services",
"quantity_unit" : "number, quantity unit",
"vat" : "number, the VAT fee of an item or service[0-100]"
}
```Additional values such as `item.amount`, `item.vat_amount` and `taxes` will be computed automatically and added to the mustache engine parameters before templating. You can supply any custom keys and values to any JSON object and use them in your templates.