numerus/pkg
jordi fita mas c453715ee1 Remove the number field from new invoice form
Initially, this field was meant to be left almost always blank, except
for when we deleted invoiced and had to “replace” its number with a new
invoice; using the automatic numbering in this cas would not “fill in”
the missing number in the sequence.

However, we decide to not allow removing invoicer not edit their
numbers, therefore, if everything goes as planned, there should not be
any gap in the sequence, and that field is rendered useless.

Oriol suggested making it a read-only field, both for new and edit
forms, but i do not think it makes sense to have a field if you can not
edit it at all, specially in the new invoice dialog, where it would
always be blank.  In the edit form we already show the number in the
title and breadcrumbs, thus no need for the read-only field as
reference.

I still keep a Number member to the form struct, but is now a string
(kind of “a read-only field”, in a way) and just to be written in the
title or breadcrumbs.  I did not like the idea of adding a new SQL
query just for that value.
2023-04-01 15:57:56 +02:00
..
company.go Show the tax details form in a dialog using HTMx 2023-03-21 11:58:54 +01:00
contacts.go Add tags for contacts too 2023-03-26 01:32:53 +01:00
db.go Properly register array and composite PostgreSQL types with pgtype 2023-02-20 11:42:21 +01:00
form.go Add filters form for invoices 2023-03-29 16:16:31 +02:00
invoices.go Remove the number field from new invoice form 2023-04-01 15:57:56 +02:00
locale.go Add currency_pattern to language relation 2023-02-23 12:12:33 +01:00
logger.go Move source file to the root of pkg 2023-01-17 10:40:22 +01:00
login.go Replace default router with github.com/julienschmidt/httprouter 2023-02-03 12:30:56 +01:00
pgtypes.go Add the edit form for invoices 2023-03-13 15:00:35 +01:00
products.go Boost the products’ section links and forms 2023-03-27 09:44:04 +02:00
profile.go Show the profile form in a dialog using HTMx 2023-03-20 13:09:52 +01:00
recover.go Gofmt recover.go 2023-01-22 20:37:34 +01:00
router.go Boost the main navigation links with HTMx 2023-03-23 10:55:02 +01:00
template.go Boost the main navigation links with HTMx 2023-03-23 10:55:02 +01:00