Quick Start

InvoGen is easy to use! In the command prompt or in a file type:

from invogen import *

foobar_inc = Customer("test", name="Foobar Inc.")
invoice = Invoice(foobar_inc)
invoice.add_entry(
    InvoiceEntry(id_code="Test01", description="Some entry item", rate=5, quantity=1)
)
invoice.shipping = 3
print(invoice)

You should see a printout of your invoice like this:

Invoice for Foobar Inc. (test)
|   ID   |     Description      |   Rate   | Quantity |  Amount  |
+--------+----------------------+----------+----------+----------+
| Test01 | Some entry item      |     5.00 |        1 |     5.00 |
+--------+----------------------+----------+----------+----------+
                                             Sub-total:     5.00
                                              Shipping:     3.00
                                              Discount:    -0.00
                                           +---------------------+
                                                 Total:     8.00

To generate a PDF invoice using LaTeX, use

template = LatexTemplate("default.tex")
template.to_pdf(invoice)

Note

To use LaTeX templates, you will have to have LaTeX installed. You can find out how to install LaTeX for your system here.