Go to file
jordi fita mas 90982b49ff Move the product_id field from invoice_product to a separate table
We are going to allow invoices with products that are not (yet) inserted
into the products table.

We always allowed to have products in invoices with a totally different
name, description, price, and whatnot, but until now we had the product
id in these invoice lines for statistics purposes.

However, Oriol raised the concern that this requires for the products
to be inserted before we can create an invoice with them, and we do not
plan to have a “create product while invoicing” feature, thus it would
mean that people would need to cancel the new invoice, create the new
product, and then start the invoice again from scratch.

The compromise is to allow products in the invoice that do not have a
product_id, meaning that at the time the invoice was created they were
not (yet) in the products table.  Oriol sees this stop-invoice-create-
product issue more important than the accurate statistics of product
sales, as it will probably be only one or two units off, anyway.

I did not want to allow NULL values to the invoice product’s product_id
field, because NULL means “dunno” instead of “no product”, so i had to
split that field to a separate table that relates an invoice product
with a registered product.
2023-04-19 19:30:12 +02:00
cmd/numerus Implement login cookie, its verification, and logout 2023-01-17 20:58:13 +01:00
debian Convert invoices to PDF with WeasyPrint 2023-02-26 17:26:09 +01:00
demo Replace tag relations with array attributes 2023-04-07 21:31:35 +02:00
deploy Move the product_id field from invoice_product to a separate table 2023-04-19 19:30:12 +02:00
pkg Move the product_id field from invoice_product to a separate table 2023-04-19 19:30:12 +02:00
po Add validation for minimum length of contact’s name 2023-04-18 21:01:29 +02:00
revert Move the product_id field from invoice_product to a separate table 2023-04-19 19:30:12 +02:00
test Move the product_id field from invoice_product to a separate table 2023-04-19 19:30:12 +02:00
verify Move the product_id field from invoice_product to a separate table 2023-04-19 19:30:12 +02:00
web Make sure the tag’s condition menu is within the limits of <body> 2023-04-17 11:51:10 +02:00
.gitignore Ignore IntelliJ’s project files 2023-01-30 16:42:15 +01:00
COPYING Rename LICENSE to COPYING 2023-01-15 04:08:35 +01:00
Makefile Rename extension of templates to .gohtml 2023-01-30 16:48:21 +01:00
go.mod Properly register array and composite PostgreSQL types with pgtype 2023-02-20 11:42:21 +01:00
go.sum Fix use of API methods not available in Go 1.16 2023-02-13 10:32:26 +01:00
sqitch.conf Setup authentication schema and user relation 2023-01-13 20:30:21 +01:00
sqitch.plan Move the product_id field from invoice_product to a separate table 2023-04-19 19:30:12 +02:00