Compare commits

..

No commits in common. "689eab3a08797bc2d5f8334167d9b3109f2430fd" and "992bbf32a9fb3b7807cca4967e78214c003ddb27" have entirely different histories.

10 changed files with 234 additions and 245 deletions

View File

@ -234,12 +234,14 @@ func ServeInvoice(w http.ResponseWriter, r *http.Request, params httprouter.Para
w.WriteHeader(http.StatusOK)
mustRenderNewInvoiceForm(w, r, form)
case "product-form":
company := mustGetCompany(r)
query := r.URL.Query()
index, _ := strconv.Atoi(query.Get("index"))
conn := getConn(r)
form := newInvoiceProductForm(index, company, getLocale(r), mustGetTaxOptions(r.Context(), conn, company))
productSlug := query.Get("slug")
if len(productSlug) > 0 {
if !form.MustFillFromDatabase(r.Context(), conn, productSlug) {
slug := query.Get("slug")
if len(slug) > 0 {
if !form.MustFillFromDatabase(r.Context(), conn, slug) {
http.NotFound(w, r)
return
}
@ -413,9 +415,6 @@ func newNewInvoicePage(form *invoiceForm, r *http.Request) *newInvoicePage {
if err != nil {
panic(err)
}
if len(form.Products) == 0 {
form.Products = append(form.Products, newInvoiceProductForm(0, company, getLocale(r), mustGetTaxOptions(r.Context(), conn, company)))
}
return page
}

227
po/ca.po
View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: numerus\n"
"Report-Msgid-Bugs-To: jordi@tandem.blog\n"
"POT-Creation-Date: 2023-05-26 13:35+0200\n"
"POT-Creation-Date: 2023-05-23 14:16+0200\n"
"PO-Revision-Date: 2023-01-18 17:08+0100\n"
"Last-Translator: jordi fita mas <jordi@tandem.blog>\n"
"Language-Team: Catalan <ca@dodds.net>\n"
@ -54,135 +54,127 @@ msgid "All"
msgstr "Tots"
#: web/template/invoices/products.gohtml:49
#: web/template/products/index.gohtml:40
#: web/template/products/index.gohtml:38
msgctxt "title"
msgid "Name"
msgstr "Nom"
#: web/template/invoices/products.gohtml:50
#: web/template/invoices/view.gohtml:62 web/template/products/index.gohtml:42
#: web/template/invoices/view.gohtml:62 web/template/products/index.gohtml:40
msgctxt "title"
msgid "Price"
msgstr "Preu"
#: web/template/invoices/products.gohtml:64
#: web/template/products/index.gohtml:82
#: web/template/products/index.gohtml:79
msgid "No products added yet."
msgstr "No hi ha cap producte."
#: web/template/invoices/products.gohtml:72 web/template/invoices/new.gohtml:63
#: web/template/invoices/edit.gohtml:64
#: web/template/invoices/products.gohtml:72 web/template/invoices/new.gohtml:62
#: web/template/invoices/edit.gohtml:62
msgctxt "action"
msgid "Add products"
msgstr "Afegeix productes"
#: web/template/invoices/new.gohtml:40 web/template/invoices/view.gohtml:67
#: web/template/invoices/edit.gohtml:41
#: web/template/invoices/new.gohtml:39 web/template/invoices/view.gohtml:67
#: web/template/invoices/edit.gohtml:39
msgctxt "title"
msgid "Subtotal"
msgstr "Subtotal"
#: web/template/invoices/new.gohtml:50 web/template/invoices/view.gohtml:71
#: web/template/invoices/view.gohtml:111 web/template/invoices/edit.gohtml:51
#: web/template/invoices/new.gohtml:49 web/template/invoices/view.gohtml:71
#: web/template/invoices/view.gohtml:111 web/template/invoices/edit.gohtml:49
msgctxt "title"
msgid "Total"
msgstr "Total"
#: web/template/invoices/new.gohtml:67 web/template/invoices/edit.gohtml:68
#: web/template/invoices/new.gohtml:66 web/template/invoices/edit.gohtml:66
msgctxt "action"
msgid "Update"
msgstr "Actualitza"
#: web/template/invoices/new.gohtml:69 web/template/invoices/edit.gohtml:70
#: web/template/contacts/new.gohtml:39 web/template/contacts/edit.gohtml:43
#: web/template/expenses/new.gohtml:33 web/template/expenses/edit.gohtml:38
#: web/template/products/new.gohtml:30 web/template/products/edit.gohtml:36
msgctxt "action"
msgid "Save"
msgstr "Desa"
#: web/template/invoices/index.gohtml:19
msgctxt "action"
msgid "Download invoices"
msgstr "Descarrega factures"
#: web/template/invoices/index.gohtml:21
#: web/template/invoices/new.gohtml:68 web/template/invoices/index.gohtml:20
msgctxt "action"
msgid "New invoice"
msgstr "Nova factura"
#: web/template/invoices/index.gohtml:43 web/template/dashboard.gohtml:23
#: web/template/contacts/index.gohtml:34 web/template/expenses/index.gohtml:36
#: web/template/products/index.gohtml:34
#: web/template/invoices/index.gohtml:18
msgctxt "action"
msgid "Download invoices"
msgstr "Descarrega factures"
#: web/template/invoices/index.gohtml:40 web/template/dashboard.gohtml:22
#: web/template/contacts/index.gohtml:32 web/template/expenses/index.gohtml:34
#: web/template/products/index.gohtml:32
msgctxt "action"
msgid "Filter"
msgstr "Filtra"
#: web/template/invoices/index.gohtml:49
#: web/template/invoices/index.gohtml:46
msgctxt "invoice"
msgid "All"
msgstr "Totes"
#: web/template/invoices/index.gohtml:50 web/template/invoices/view.gohtml:34
#: web/template/invoices/index.gohtml:47 web/template/invoices/view.gohtml:34
msgctxt "title"
msgid "Date"
msgstr "Data"
#: web/template/invoices/index.gohtml:51
#: web/template/invoices/index.gohtml:48
msgctxt "title"
msgid "Invoice Num."
msgstr "Núm. factura"
#: web/template/invoices/index.gohtml:52 web/template/contacts/index.gohtml:40
#: web/template/invoices/index.gohtml:49 web/template/contacts/index.gohtml:38
msgctxt "title"
msgid "Customer"
msgstr "Client"
#: web/template/invoices/index.gohtml:53
#: web/template/invoices/index.gohtml:50
msgctxt "title"
msgid "Status"
msgstr "Estat"
#: web/template/invoices/index.gohtml:54 web/template/contacts/index.gohtml:43
#: web/template/expenses/index.gohtml:46 web/template/products/index.gohtml:41
#: web/template/invoices/index.gohtml:51 web/template/contacts/index.gohtml:41
#: web/template/expenses/index.gohtml:44 web/template/products/index.gohtml:39
msgctxt "title"
msgid "Tags"
msgstr "Etiquetes"
#: web/template/invoices/index.gohtml:55 web/template/expenses/index.gohtml:47
#: web/template/invoices/index.gohtml:52 web/template/expenses/index.gohtml:45
msgctxt "title"
msgid "Amount"
msgstr "Import"
#: web/template/invoices/index.gohtml:56 web/template/expenses/index.gohtml:48
#: web/template/invoices/index.gohtml:53 web/template/expenses/index.gohtml:46
msgctxt "title"
msgid "Download"
msgstr "Descàrrega"
#: web/template/invoices/index.gohtml:57 web/template/contacts/index.gohtml:44
#: web/template/expenses/index.gohtml:49 web/template/products/index.gohtml:43
#: web/template/invoices/index.gohtml:54 web/template/contacts/index.gohtml:42
#: web/template/expenses/index.gohtml:47 web/template/products/index.gohtml:41
msgctxt "title"
msgid "Actions"
msgstr "Accions"
#: web/template/invoices/index.gohtml:64
#: web/template/invoices/index.gohtml:61
msgctxt "action"
msgid "Select invoice %v"
msgstr "Selecciona factura %v"
#: web/template/invoices/index.gohtml:119 web/template/invoices/view.gohtml:19
#: web/template/contacts/index.gohtml:74 web/template/expenses/index.gohtml:88
#: web/template/products/index.gohtml:72
#: web/template/invoices/index.gohtml:116 web/template/invoices/view.gohtml:19
#: web/template/contacts/index.gohtml:71 web/template/expenses/index.gohtml:86
#: web/template/products/index.gohtml:69
msgctxt "action"
msgid "Edit"
msgstr "Edita"
#: web/template/invoices/index.gohtml:127 web/template/invoices/view.gohtml:16
#: web/template/invoices/index.gohtml:124 web/template/invoices/view.gohtml:16
msgctxt "action"
msgid "Duplicate"
msgstr "Duplica"
#: web/template/invoices/index.gohtml:137
#: web/template/invoices/index.gohtml:134
msgid "No invoices added yet."
msgstr "No hi ha cap factura."
@ -221,47 +213,47 @@ msgctxt "title"
msgid "Edit Invoice “%s”"
msgstr "Edició de la factura «%s»"
#: web/template/invoices/edit.gohtml:68
msgctxt "action"
msgid "Save"
msgstr "Desa"
#: web/template/form.gohtml:36
msgctxt "input"
msgid "(Max. %s)"
msgstr "(Màx. %s)"
#: web/template/form.gohtml:167
msgctxt "action"
msgid "Filters"
msgstr "Filtra"
#: web/template/dashboard.gohtml:3
msgctxt "title"
msgid "Dashboard"
msgstr "Tauler"
#: web/template/dashboard.gohtml:29
#: web/template/dashboard.gohtml:27
msgctxt "term"
msgid "Sales"
msgstr "Vendes"
#: web/template/dashboard.gohtml:33
#: web/template/dashboard.gohtml:31
msgctxt "term"
msgid "Income"
msgstr "Ingressos"
#: web/template/dashboard.gohtml:37
#: web/template/dashboard.gohtml:35
msgctxt "term"
msgid "Expenses"
msgstr "Despeses"
#: web/template/dashboard.gohtml:41
#: web/template/dashboard.gohtml:39
msgctxt "term"
msgid "VAT"
msgstr "IVA"
#: web/template/dashboard.gohtml:45
#: web/template/dashboard.gohtml:43
msgctxt "term"
msgid "IRPF"
msgstr "IRPF"
#: web/template/dashboard.gohtml:49
#: web/template/dashboard.gohtml:47
msgctxt "term"
msgid "Net Income"
msgstr "Ingressos nets"
@ -318,22 +310,22 @@ msgctxt "title"
msgid "Contacts"
msgstr "Contactes"
#: web/template/contacts/index.gohtml:15
#: web/template/contacts/new.gohtml:36 web/template/contacts/index.gohtml:14
msgctxt "action"
msgid "New contact"
msgstr "Nou contacte"
#: web/template/contacts/index.gohtml:41
#: web/template/contacts/index.gohtml:39
msgctxt "title"
msgid "Email"
msgstr "Correu-e"
#: web/template/contacts/index.gohtml:42
#: web/template/contacts/index.gohtml:40
msgctxt "title"
msgid "Phone"
msgstr "Telèfon"
#: web/template/contacts/index.gohtml:84
#: web/template/contacts/index.gohtml:81
msgid "No contacts added yet."
msgstr "No hi ha cap contacte."
@ -342,6 +334,11 @@ msgctxt "title"
msgid "Edit Contact “%s”"
msgstr "Edició del contacte «%s»"
#: web/template/contacts/edit.gohtml:41
msgctxt "action"
msgid "Update contact"
msgstr "Actualitza contacte"
#: web/template/login.gohtml:2 web/template/login.gohtml:15
msgctxt "title"
msgid "Login"
@ -390,32 +387,32 @@ msgctxt "title"
msgid "Expenses"
msgstr "Despeses"
#: web/template/expenses/index.gohtml:16
#: web/template/expenses/new.gohtml:33 web/template/expenses/index.gohtml:15
msgctxt "action"
msgid "New expense"
msgstr "Nova despesa"
#: web/template/expenses/index.gohtml:42
#: web/template/expenses/index.gohtml:40
msgctxt "expense"
msgid "All"
msgstr "Totes"
#: web/template/expenses/index.gohtml:43
#: web/template/expenses/index.gohtml:41
msgctxt "title"
msgid "Contact"
msgstr "Contacte"
#: web/template/expenses/index.gohtml:44
#: web/template/expenses/index.gohtml:42
msgctxt "title"
msgid "Invoice Date"
msgstr "Data de factura"
#: web/template/expenses/index.gohtml:45
#: web/template/expenses/index.gohtml:43
msgctxt "title"
msgid "Invoice Number"
msgstr "Número de factura"
#: web/template/expenses/index.gohtml:98
#: web/template/expenses/index.gohtml:96
msgid "No expenses added yet."
msgstr "No hi ha cap despesa."
@ -424,6 +421,11 @@ msgctxt "title"
msgid "Edit Expense “%s”"
msgstr "Edició de la despesa «%s»"
#: web/template/expenses/edit.gohtml:36
msgctxt "action"
msgid "Update expense"
msgstr "Actualitza despesa"
#: web/template/tax-details.gohtml:2 web/template/tax-details.gohtml:10
#: web/template/tax-details.gohtml:18
msgctxt "title"
@ -504,20 +506,25 @@ msgctxt "title"
msgid "Products"
msgstr "Productes"
#: web/template/products/search.gohtml:12
msgid "No products found."
msgstr "No sha trobat cap producte."
#: web/template/products/index.gohtml:15
#: web/template/products/new.gohtml:30 web/template/products/index.gohtml:14
msgctxt "action"
msgid "New product"
msgstr "Nou producte"
#: web/template/products/search.gohtml:12
msgid "No products found."
msgstr "No sha trobat cap producte."
#: web/template/products/edit.gohtml:3 web/template/products/edit.gohtml:20
msgctxt "title"
msgid "Edit Product “%s”"
msgstr "Edició del producte «%s»"
#: web/template/products/edit.gohtml:34
msgctxt "action"
msgid "Update product"
msgstr "Actualitza producte"
#: pkg/login.go:36 pkg/profile.go:40 pkg/contacts.go:268
msgctxt "input"
msgid "Email"
@ -544,15 +551,15 @@ msgstr "No podeu deixar la contrasenya en blanc."
msgid "Invalid user or password."
msgstr "Nom dusuari o contrasenya incorrectes."
#: pkg/products.go:164 pkg/products.go:263 pkg/invoices.go:777
#: pkg/products.go:164 pkg/products.go:263 pkg/invoices.go:776
#: pkg/contacts.go:135
msgctxt "input"
msgid "Name"
msgstr "Nom"
#: pkg/products.go:169 pkg/products.go:290 pkg/expenses.go:202
#: pkg/expenses.go:361 pkg/invoices.go:187 pkg/invoices.go:598
#: pkg/invoices.go:1048 pkg/contacts.go:140 pkg/contacts.go:325
#: pkg/expenses.go:361 pkg/invoices.go:187 pkg/invoices.go:597
#: pkg/invoices.go:1047 pkg/contacts.go:140 pkg/contacts.go:325
msgctxt "input"
msgid "Tags"
msgstr "Etiquetes"
@ -585,40 +592,40 @@ msgstr "Qualsevol"
msgid "Invoices must have at least one of the specified labels."
msgstr "Les factures han de tenir com a mínim una de les etiquetes."
#: pkg/products.go:269 pkg/invoices.go:791
#: pkg/products.go:269 pkg/invoices.go:790
msgctxt "input"
msgid "Description"
msgstr "Descripció"
#: pkg/products.go:274 pkg/invoices.go:795
#: pkg/products.go:274 pkg/invoices.go:794
msgctxt "input"
msgid "Price"
msgstr "Preu"
#: pkg/products.go:284 pkg/expenses.go:181 pkg/invoices.go:824
#: pkg/products.go:284 pkg/expenses.go:181 pkg/invoices.go:823
msgctxt "input"
msgid "Taxes"
msgstr "Imposts"
#: pkg/products.go:309 pkg/profile.go:92 pkg/invoices.go:871
#: pkg/products.go:309 pkg/profile.go:92 pkg/invoices.go:870
msgid "Name can not be empty."
msgstr "No podeu deixar el nom en blanc."
#: pkg/products.go:310 pkg/invoices.go:872
#: pkg/products.go:310 pkg/invoices.go:871
msgid "Price can not be empty."
msgstr "No podeu deixar el preu en blanc."
#: pkg/products.go:311 pkg/invoices.go:873
#: pkg/products.go:311 pkg/invoices.go:872
msgid "Price must be a number greater than zero."
msgstr "El preu ha de ser un número major a zero."
#: pkg/products.go:313 pkg/expenses.go:227 pkg/expenses.go:232
#: pkg/invoices.go:881
#: pkg/invoices.go:880
msgid "Selected tax is not valid."
msgstr "Heu seleccionat un impost que no és vàlid."
#: pkg/products.go:314 pkg/expenses.go:228 pkg/expenses.go:233
#: pkg/invoices.go:882
#: pkg/invoices.go:881
msgid "You can only select a tax of each class."
msgstr "Només podeu seleccionar un impost de cada classe."
@ -775,7 +782,7 @@ msgctxt "input"
msgid "Invoice number"
msgstr "Número de factura"
#: pkg/expenses.go:175 pkg/invoices.go:587
#: pkg/expenses.go:175 pkg/invoices.go:586
msgctxt "input"
msgid "Invoice Date"
msgstr "Data de factura"
@ -794,7 +801,7 @@ msgstr "Fitxer"
msgid "Selected contact is not valid."
msgstr "Heu seleccionat un contacte que no és vàlid."
#: pkg/expenses.go:226 pkg/invoices.go:642
#: pkg/expenses.go:226 pkg/invoices.go:641
msgid "Invoice date must be a valid date."
msgstr "La data de facturació ha de ser vàlida."
@ -806,7 +813,7 @@ msgstr "No podeu deixar limport en blanc."
msgid "Amount must be a number greater than zero."
msgstr "Limport ha de ser un número major a zero."
#: pkg/expenses.go:340 pkg/invoices.go:160 pkg/invoices.go:581
#: pkg/expenses.go:340 pkg/invoices.go:160 pkg/invoices.go:580
msgctxt "input"
msgid "Customer"
msgstr "Client"
@ -830,7 +837,7 @@ msgctxt "input"
msgid "To Date"
msgstr "Fins la data"
#: pkg/invoices.go:166 pkg/invoices.go:575
#: pkg/invoices.go:166 pkg/invoices.go:574
msgctxt "input"
msgid "Invoice Status"
msgstr "Estat de la factura"
@ -839,80 +846,80 @@ msgstr "Estat de la factura"
msgid "All status"
msgstr "Tots els estats"
#: pkg/invoices.go:424
#: pkg/invoices.go:423
msgid "Select a customer to bill."
msgstr "Escolliu un client a facturar."
#: pkg/invoices.go:525
#: pkg/invoices.go:524
msgid "invoices.zip"
msgstr "factures.zip"
#: pkg/invoices.go:531 pkg/invoices.go:1032
#: pkg/invoices.go:530 pkg/invoices.go:1031
msgid "Invalid action"
msgstr "Acció invàlida."
#: pkg/invoices.go:593
#: pkg/invoices.go:592
msgctxt "input"
msgid "Notes"
msgstr "Notes"
#: pkg/invoices.go:603
#: pkg/invoices.go:602
msgctxt "input"
msgid "Payment Method"
msgstr "Mètode de pagament"
#: pkg/invoices.go:639
#: pkg/invoices.go:638
msgid "Selected invoice status is not valid."
msgstr "Heu seleccionat un estat de factura que no és vàlid."
#: pkg/invoices.go:640
#: pkg/invoices.go:639
msgid "Selected customer is not valid."
msgstr "Heu seleccionat un client que no és vàlid."
#: pkg/invoices.go:641
#: pkg/invoices.go:640
msgid "Invoice date can not be empty."
msgstr "No podeu deixar la data de la factura en blanc."
#: pkg/invoices.go:644
#: pkg/invoices.go:643
msgid "Selected payment method is not valid."
msgstr "Heu seleccionat un mètode de pagament que no és vàlid."
#: pkg/invoices.go:767 pkg/invoices.go:772
#: pkg/invoices.go:766 pkg/invoices.go:771
msgctxt "input"
msgid "Id"
msgstr "Identificador"
#: pkg/invoices.go:805
#: pkg/invoices.go:804
msgctxt "input"
msgid "Quantity"
msgstr "Quantitat"
#: pkg/invoices.go:814
#: pkg/invoices.go:813
msgctxt "input"
msgid "Discount (%)"
msgstr "Descompte (%)"
#: pkg/invoices.go:866
#: pkg/invoices.go:865
msgid "Invoice product ID must be a number greater than zero."
msgstr "LID del producte de factura ha de ser un número major a zero."
#: pkg/invoices.go:869
#: pkg/invoices.go:868
msgid "Product ID must be a positive number or zero."
msgstr "LID del producte ha de ser un número positiu o zero."
#: pkg/invoices.go:875
#: pkg/invoices.go:874
msgid "Quantity can not be empty."
msgstr "No podeu deixar la quantitat en blanc."
#: pkg/invoices.go:876
#: pkg/invoices.go:875
msgid "Quantity must be a number greater than zero."
msgstr "La quantitat ha de ser un número major a zero."
#: pkg/invoices.go:878
#: pkg/invoices.go:877
msgid "Discount can not be empty."
msgstr "No podeu deixar el descompte en blanc."
#: pkg/invoices.go:879
#: pkg/invoices.go:878
msgid "Discount must be a percentage between 0 and 100."
msgstr "El descompte ha de ser un percentatge entre 0 i 100."
@ -1018,18 +1025,6 @@ msgstr "No podeu deixar el codi postal en blanc."
msgid "This value is not a valid postal code."
msgstr "Aquest valor no és un codi postal vàlid."
#~ msgctxt "action"
#~ msgid "Update contact"
#~ msgstr "Actualitza contacte"
#~ msgctxt "action"
#~ msgid "Update expense"
#~ msgstr "Actualitza despesa"
#~ msgctxt "action"
#~ msgid "Update product"
#~ msgstr "Actualitza producte"
#~ msgctxt "action"
#~ msgid "Edit invoice"
#~ msgstr "Edita factura"

227
po/es.po
View File

@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: numerus\n"
"Report-Msgid-Bugs-To: jordi@tandem.blog\n"
"POT-Creation-Date: 2023-05-26 13:35+0200\n"
"POT-Creation-Date: 2023-05-23 14:16+0200\n"
"PO-Revision-Date: 2023-01-18 17:45+0100\n"
"Last-Translator: jordi fita mas <jordi@tandem.blog>\n"
"Language-Team: Spanish <es@tp.org.es>\n"
@ -54,135 +54,127 @@ msgid "All"
msgstr "Todos"
#: web/template/invoices/products.gohtml:49
#: web/template/products/index.gohtml:40
#: web/template/products/index.gohtml:38
msgctxt "title"
msgid "Name"
msgstr "Nombre"
#: web/template/invoices/products.gohtml:50
#: web/template/invoices/view.gohtml:62 web/template/products/index.gohtml:42
#: web/template/invoices/view.gohtml:62 web/template/products/index.gohtml:40
msgctxt "title"
msgid "Price"
msgstr "Precio"
#: web/template/invoices/products.gohtml:64
#: web/template/products/index.gohtml:82
#: web/template/products/index.gohtml:79
msgid "No products added yet."
msgstr "No hay productos."
#: web/template/invoices/products.gohtml:72 web/template/invoices/new.gohtml:63
#: web/template/invoices/edit.gohtml:64
#: web/template/invoices/products.gohtml:72 web/template/invoices/new.gohtml:62
#: web/template/invoices/edit.gohtml:62
msgctxt "action"
msgid "Add products"
msgstr "Añadir productos"
#: web/template/invoices/new.gohtml:40 web/template/invoices/view.gohtml:67
#: web/template/invoices/edit.gohtml:41
#: web/template/invoices/new.gohtml:39 web/template/invoices/view.gohtml:67
#: web/template/invoices/edit.gohtml:39
msgctxt "title"
msgid "Subtotal"
msgstr "Subtotal"
#: web/template/invoices/new.gohtml:50 web/template/invoices/view.gohtml:71
#: web/template/invoices/view.gohtml:111 web/template/invoices/edit.gohtml:51
#: web/template/invoices/new.gohtml:49 web/template/invoices/view.gohtml:71
#: web/template/invoices/view.gohtml:111 web/template/invoices/edit.gohtml:49
msgctxt "title"
msgid "Total"
msgstr "Total"
#: web/template/invoices/new.gohtml:67 web/template/invoices/edit.gohtml:68
#: web/template/invoices/new.gohtml:66 web/template/invoices/edit.gohtml:66
msgctxt "action"
msgid "Update"
msgstr "Actualizar"
#: web/template/invoices/new.gohtml:69 web/template/invoices/edit.gohtml:70
#: web/template/contacts/new.gohtml:39 web/template/contacts/edit.gohtml:43
#: web/template/expenses/new.gohtml:33 web/template/expenses/edit.gohtml:38
#: web/template/products/new.gohtml:30 web/template/products/edit.gohtml:36
msgctxt "action"
msgid "Save"
msgstr "Guardad"
#: web/template/invoices/index.gohtml:19
msgctxt "action"
msgid "Download invoices"
msgstr "Descargar facturas"
#: web/template/invoices/index.gohtml:21
#: web/template/invoices/new.gohtml:68 web/template/invoices/index.gohtml:20
msgctxt "action"
msgid "New invoice"
msgstr "Nueva factura"
#: web/template/invoices/index.gohtml:43 web/template/dashboard.gohtml:23
#: web/template/contacts/index.gohtml:34 web/template/expenses/index.gohtml:36
#: web/template/products/index.gohtml:34
#: web/template/invoices/index.gohtml:18
msgctxt "action"
msgid "Download invoices"
msgstr "Descargar facturas"
#: web/template/invoices/index.gohtml:40 web/template/dashboard.gohtml:22
#: web/template/contacts/index.gohtml:32 web/template/expenses/index.gohtml:34
#: web/template/products/index.gohtml:32
msgctxt "action"
msgid "Filter"
msgstr "Filtrar"
#: web/template/invoices/index.gohtml:49
#: web/template/invoices/index.gohtml:46
msgctxt "invoice"
msgid "All"
msgstr "Todas"
#: web/template/invoices/index.gohtml:50 web/template/invoices/view.gohtml:34
#: web/template/invoices/index.gohtml:47 web/template/invoices/view.gohtml:34
msgctxt "title"
msgid "Date"
msgstr "Fecha"
#: web/template/invoices/index.gohtml:51
#: web/template/invoices/index.gohtml:48
msgctxt "title"
msgid "Invoice Num."
msgstr "Nº factura"
#: web/template/invoices/index.gohtml:52 web/template/contacts/index.gohtml:40
#: web/template/invoices/index.gohtml:49 web/template/contacts/index.gohtml:38
msgctxt "title"
msgid "Customer"
msgstr "Cliente"
#: web/template/invoices/index.gohtml:53
#: web/template/invoices/index.gohtml:50
msgctxt "title"
msgid "Status"
msgstr "Estado"
#: web/template/invoices/index.gohtml:54 web/template/contacts/index.gohtml:43
#: web/template/expenses/index.gohtml:46 web/template/products/index.gohtml:41
#: web/template/invoices/index.gohtml:51 web/template/contacts/index.gohtml:41
#: web/template/expenses/index.gohtml:44 web/template/products/index.gohtml:39
msgctxt "title"
msgid "Tags"
msgstr "Etiquetes"
#: web/template/invoices/index.gohtml:55 web/template/expenses/index.gohtml:47
#: web/template/invoices/index.gohtml:52 web/template/expenses/index.gohtml:45
msgctxt "title"
msgid "Amount"
msgstr "Importe"
#: web/template/invoices/index.gohtml:56 web/template/expenses/index.gohtml:48
#: web/template/invoices/index.gohtml:53 web/template/expenses/index.gohtml:46
msgctxt "title"
msgid "Download"
msgstr "Descargar"
#: web/template/invoices/index.gohtml:57 web/template/contacts/index.gohtml:44
#: web/template/expenses/index.gohtml:49 web/template/products/index.gohtml:43
#: web/template/invoices/index.gohtml:54 web/template/contacts/index.gohtml:42
#: web/template/expenses/index.gohtml:47 web/template/products/index.gohtml:41
msgctxt "title"
msgid "Actions"
msgstr "Acciones"
#: web/template/invoices/index.gohtml:64
#: web/template/invoices/index.gohtml:61
msgctxt "action"
msgid "Select invoice %v"
msgstr "Seleccionar factura %v"
#: web/template/invoices/index.gohtml:119 web/template/invoices/view.gohtml:19
#: web/template/contacts/index.gohtml:74 web/template/expenses/index.gohtml:88
#: web/template/products/index.gohtml:72
#: web/template/invoices/index.gohtml:116 web/template/invoices/view.gohtml:19
#: web/template/contacts/index.gohtml:71 web/template/expenses/index.gohtml:86
#: web/template/products/index.gohtml:69
msgctxt "action"
msgid "Edit"
msgstr "Editar"
#: web/template/invoices/index.gohtml:127 web/template/invoices/view.gohtml:16
#: web/template/invoices/index.gohtml:124 web/template/invoices/view.gohtml:16
msgctxt "action"
msgid "Duplicate"
msgstr "Duplicar"
#: web/template/invoices/index.gohtml:137
#: web/template/invoices/index.gohtml:134
msgid "No invoices added yet."
msgstr "No hay facturas."
@ -221,47 +213,47 @@ msgctxt "title"
msgid "Edit Invoice “%s”"
msgstr "Edición de la factura «%s»"
#: web/template/invoices/edit.gohtml:68
msgctxt "action"
msgid "Save"
msgstr "Guardad"
#: web/template/form.gohtml:36
msgctxt "input"
msgid "(Max. %s)"
msgstr "(Máx. %s)"
#: web/template/form.gohtml:167
msgctxt "action"
msgid "Filters"
msgstr "Filtrar"
#: web/template/dashboard.gohtml:3
msgctxt "title"
msgid "Dashboard"
msgstr "Panel"
#: web/template/dashboard.gohtml:29
#: web/template/dashboard.gohtml:27
msgctxt "term"
msgid "Sales"
msgstr "Ventas"
#: web/template/dashboard.gohtml:33
#: web/template/dashboard.gohtml:31
msgctxt "term"
msgid "Income"
msgstr "Ingresos"
#: web/template/dashboard.gohtml:37
#: web/template/dashboard.gohtml:35
msgctxt "term"
msgid "Expenses"
msgstr "Gastos"
#: web/template/dashboard.gohtml:41
#: web/template/dashboard.gohtml:39
msgctxt "term"
msgid "VAT"
msgstr "IVA"
#: web/template/dashboard.gohtml:45
#: web/template/dashboard.gohtml:43
msgctxt "term"
msgid "IRPF"
msgstr "IRPF"
#: web/template/dashboard.gohtml:49
#: web/template/dashboard.gohtml:47
msgctxt "term"
msgid "Net Income"
msgstr "Ingresos netos"
@ -318,22 +310,22 @@ msgctxt "title"
msgid "Contacts"
msgstr "Contactos"
#: web/template/contacts/index.gohtml:15
#: web/template/contacts/new.gohtml:36 web/template/contacts/index.gohtml:14
msgctxt "action"
msgid "New contact"
msgstr "Nuevo contacto"
#: web/template/contacts/index.gohtml:41
#: web/template/contacts/index.gohtml:39
msgctxt "title"
msgid "Email"
msgstr "Correo-e"
#: web/template/contacts/index.gohtml:42
#: web/template/contacts/index.gohtml:40
msgctxt "title"
msgid "Phone"
msgstr "Teléfono"
#: web/template/contacts/index.gohtml:84
#: web/template/contacts/index.gohtml:81
msgid "No contacts added yet."
msgstr "No hay contactos."
@ -342,6 +334,11 @@ msgctxt "title"
msgid "Edit Contact “%s”"
msgstr "Edición del contacto «%s»"
#: web/template/contacts/edit.gohtml:41
msgctxt "action"
msgid "Update contact"
msgstr "Actualizar contacto"
#: web/template/login.gohtml:2 web/template/login.gohtml:15
msgctxt "title"
msgid "Login"
@ -390,32 +387,32 @@ msgctxt "title"
msgid "Expenses"
msgstr "Gastos"
#: web/template/expenses/index.gohtml:16
#: web/template/expenses/new.gohtml:33 web/template/expenses/index.gohtml:15
msgctxt "action"
msgid "New expense"
msgstr "Nuevo gasto"
#: web/template/expenses/index.gohtml:42
#: web/template/expenses/index.gohtml:40
msgctxt "expense"
msgid "All"
msgstr "Todos"
#: web/template/expenses/index.gohtml:43
#: web/template/expenses/index.gohtml:41
msgctxt "title"
msgid "Contact"
msgstr "Contacto"
#: web/template/expenses/index.gohtml:44
#: web/template/expenses/index.gohtml:42
msgctxt "title"
msgid "Invoice Date"
msgstr "Fecha de factura"
#: web/template/expenses/index.gohtml:45
#: web/template/expenses/index.gohtml:43
msgctxt "title"
msgid "Invoice Number"
msgstr "Número de factura"
#: web/template/expenses/index.gohtml:98
#: web/template/expenses/index.gohtml:96
msgid "No expenses added yet."
msgstr "No hay gastos."
@ -424,6 +421,11 @@ msgctxt "title"
msgid "Edit Expense “%s”"
msgstr "Edición del gasto «%s»"
#: web/template/expenses/edit.gohtml:36
msgctxt "action"
msgid "Update expense"
msgstr "Actualizar gasto"
#: web/template/tax-details.gohtml:2 web/template/tax-details.gohtml:10
#: web/template/tax-details.gohtml:18
msgctxt "title"
@ -504,20 +506,25 @@ msgctxt "title"
msgid "Products"
msgstr "Productos"
#: web/template/products/search.gohtml:12
msgid "No products found."
msgstr "No se ha encontrado ningún producto."
#: web/template/products/index.gohtml:15
#: web/template/products/new.gohtml:30 web/template/products/index.gohtml:14
msgctxt "action"
msgid "New product"
msgstr "Nuevo producto"
#: web/template/products/search.gohtml:12
msgid "No products found."
msgstr "No se ha encontrado ningún producto."
#: web/template/products/edit.gohtml:3 web/template/products/edit.gohtml:20
msgctxt "title"
msgid "Edit Product “%s”"
msgstr "Edición del producto «%s»"
#: web/template/products/edit.gohtml:34
msgctxt "action"
msgid "Update product"
msgstr "Actualizar producto"
#: pkg/login.go:36 pkg/profile.go:40 pkg/contacts.go:268
msgctxt "input"
msgid "Email"
@ -544,15 +551,15 @@ msgstr "No podéis dejar la contraseña en blanco."
msgid "Invalid user or password."
msgstr "Nombre de usuario o contraseña inválido."
#: pkg/products.go:164 pkg/products.go:263 pkg/invoices.go:777
#: pkg/products.go:164 pkg/products.go:263 pkg/invoices.go:776
#: pkg/contacts.go:135
msgctxt "input"
msgid "Name"
msgstr "Nombre"
#: pkg/products.go:169 pkg/products.go:290 pkg/expenses.go:202
#: pkg/expenses.go:361 pkg/invoices.go:187 pkg/invoices.go:598
#: pkg/invoices.go:1048 pkg/contacts.go:140 pkg/contacts.go:325
#: pkg/expenses.go:361 pkg/invoices.go:187 pkg/invoices.go:597
#: pkg/invoices.go:1047 pkg/contacts.go:140 pkg/contacts.go:325
msgctxt "input"
msgid "Tags"
msgstr "Etiquetes"
@ -585,40 +592,40 @@ msgstr "Cualquiera"
msgid "Invoices must have at least one of the specified labels."
msgstr "Las facturas debent tener como mínimo una de las etiquetas."
#: pkg/products.go:269 pkg/invoices.go:791
#: pkg/products.go:269 pkg/invoices.go:790
msgctxt "input"
msgid "Description"
msgstr "Descripción"
#: pkg/products.go:274 pkg/invoices.go:795
#: pkg/products.go:274 pkg/invoices.go:794
msgctxt "input"
msgid "Price"
msgstr "Precio"
#: pkg/products.go:284 pkg/expenses.go:181 pkg/invoices.go:824
#: pkg/products.go:284 pkg/expenses.go:181 pkg/invoices.go:823
msgctxt "input"
msgid "Taxes"
msgstr "Impuestos"
#: pkg/products.go:309 pkg/profile.go:92 pkg/invoices.go:871
#: pkg/products.go:309 pkg/profile.go:92 pkg/invoices.go:870
msgid "Name can not be empty."
msgstr "No podéis dejar el nombre en blanco."
#: pkg/products.go:310 pkg/invoices.go:872
#: pkg/products.go:310 pkg/invoices.go:871
msgid "Price can not be empty."
msgstr "No podéis dejar el precio en blanco."
#: pkg/products.go:311 pkg/invoices.go:873
#: pkg/products.go:311 pkg/invoices.go:872
msgid "Price must be a number greater than zero."
msgstr "El precio tiene que ser un número mayor a cero."
#: pkg/products.go:313 pkg/expenses.go:227 pkg/expenses.go:232
#: pkg/invoices.go:881
#: pkg/invoices.go:880
msgid "Selected tax is not valid."
msgstr "Habéis escogido un impuesto que no es válido."
#: pkg/products.go:314 pkg/expenses.go:228 pkg/expenses.go:233
#: pkg/invoices.go:882
#: pkg/invoices.go:881
msgid "You can only select a tax of each class."
msgstr "Solo podéis escoger un impuesto de cada clase."
@ -775,7 +782,7 @@ msgctxt "input"
msgid "Invoice number"
msgstr "Número de factura"
#: pkg/expenses.go:175 pkg/invoices.go:587
#: pkg/expenses.go:175 pkg/invoices.go:586
msgctxt "input"
msgid "Invoice Date"
msgstr "Fecha de factura"
@ -794,7 +801,7 @@ msgstr "Archivo"
msgid "Selected contact is not valid."
msgstr "Habéis escogido un contacto que no es válido."
#: pkg/expenses.go:226 pkg/invoices.go:642
#: pkg/expenses.go:226 pkg/invoices.go:641
msgid "Invoice date must be a valid date."
msgstr "La fecha de factura debe ser válida."
@ -806,7 +813,7 @@ msgstr "No podéis dejar el importe en blanco."
msgid "Amount must be a number greater than zero."
msgstr "El importe tiene que ser un número mayor a cero."
#: pkg/expenses.go:340 pkg/invoices.go:160 pkg/invoices.go:581
#: pkg/expenses.go:340 pkg/invoices.go:160 pkg/invoices.go:580
msgctxt "input"
msgid "Customer"
msgstr "Cliente"
@ -830,7 +837,7 @@ msgctxt "input"
msgid "To Date"
msgstr "Hasta la fecha"
#: pkg/invoices.go:166 pkg/invoices.go:575
#: pkg/invoices.go:166 pkg/invoices.go:574
msgctxt "input"
msgid "Invoice Status"
msgstr "Estado de la factura"
@ -839,80 +846,80 @@ msgstr "Estado de la factura"
msgid "All status"
msgstr "Todos los estados"
#: pkg/invoices.go:424
#: pkg/invoices.go:423
msgid "Select a customer to bill."
msgstr "Escoged un cliente a facturar."
#: pkg/invoices.go:525
#: pkg/invoices.go:524
msgid "invoices.zip"
msgstr "facturas.zip"
#: pkg/invoices.go:531 pkg/invoices.go:1032
#: pkg/invoices.go:530 pkg/invoices.go:1031
msgid "Invalid action"
msgstr "Acción inválida."
#: pkg/invoices.go:593
#: pkg/invoices.go:592
msgctxt "input"
msgid "Notes"
msgstr "Notas"
#: pkg/invoices.go:603
#: pkg/invoices.go:602
msgctxt "input"
msgid "Payment Method"
msgstr "Método de pago"
#: pkg/invoices.go:639
#: pkg/invoices.go:638
msgid "Selected invoice status is not valid."
msgstr "Habéis escogido un estado de factura que no es válido."
#: pkg/invoices.go:640
#: pkg/invoices.go:639
msgid "Selected customer is not valid."
msgstr "Habéis escogido un cliente que no es válido."
#: pkg/invoices.go:641
#: pkg/invoices.go:640
msgid "Invoice date can not be empty."
msgstr "No podéis dejar la fecha de la factura en blanco."
#: pkg/invoices.go:644
#: pkg/invoices.go:643
msgid "Selected payment method is not valid."
msgstr "Habéis escogido un método de pago que no es válido."
#: pkg/invoices.go:767 pkg/invoices.go:772
#: pkg/invoices.go:766 pkg/invoices.go:771
msgctxt "input"
msgid "Id"
msgstr "Identificador"
#: pkg/invoices.go:805
#: pkg/invoices.go:804
msgctxt "input"
msgid "Quantity"
msgstr "Cantidad"
#: pkg/invoices.go:814
#: pkg/invoices.go:813
msgctxt "input"
msgid "Discount (%)"
msgstr "Descuento (%)"
#: pkg/invoices.go:866
#: pkg/invoices.go:865
msgid "Invoice product ID must be a number greater than zero."
msgstr "El ID de producto de factura tiene que ser un número mayor a cero."
#: pkg/invoices.go:869
#: pkg/invoices.go:868
msgid "Product ID must be a positive number or zero."
msgstr "El ID de producto tiene que ser un número positivo o cero."
#: pkg/invoices.go:875
#: pkg/invoices.go:874
msgid "Quantity can not be empty."
msgstr "No podéis dejar la cantidad en blanco."
#: pkg/invoices.go:876
#: pkg/invoices.go:875
msgid "Quantity must be a number greater than zero."
msgstr "La cantidad tiene que ser un número mayor a cero."
#: pkg/invoices.go:878
#: pkg/invoices.go:877
msgid "Discount can not be empty."
msgstr "No podéis dejar el descuento en blanco."
#: pkg/invoices.go:879
#: pkg/invoices.go:878
msgid "Discount must be a percentage between 0 and 100."
msgstr "El descuento tiene que ser un porcentaje entre 0 y 100."
@ -1018,18 +1025,6 @@ msgstr "No podéis dejar el código postal en blanco."
msgid "This value is not a valid postal code."
msgstr "Este valor no es un código postal válido válido."
#~ msgctxt "action"
#~ msgid "Update contact"
#~ msgstr "Actualizar contacto"
#~ msgctxt "action"
#~ msgid "Update expense"
#~ msgstr "Actualizar gasto"
#~ msgctxt "action"
#~ msgid "Update product"
#~ msgstr "Actualizar producto"
#~ msgctxt "action"
#~ msgid "Edit invoice"
#~ msgstr "Editar factura"

View File

@ -40,7 +40,7 @@
{{ end }}
<fieldset>
<button class="primary" type="submit">{{( pgettext "Save" "action" )}}</button>
<button class="primary" type="submit">{{( pgettext "Update contact" "action" )}}</button>
</fieldset>
</form>
</section>

View File

@ -36,7 +36,7 @@
</div>
<fieldset>
<button class="primary" type="submit">{{( pgettext "Save" "action" )}}</button>
<button class="primary" type="submit">{{( pgettext "New contact" "action" )}}</button>
</fieldset>
</form>

View File

@ -35,7 +35,7 @@
{{- end }}
<fieldset>
<button class="primary" type="submit">{{( pgettext "Save" "action" )}}</button>
<button class="primary" type="submit">{{( pgettext "Update expense" "action" )}}</button>
</fieldset>
</form>
</section>

View File

@ -30,7 +30,7 @@
{{ template "file-field" .File }}
</div>
<fieldset>
<button class="primary" type="submit">{{( pgettext "Save" "action" )}}</button>
<button class="primary" type="submit">{{( pgettext "New expense" "action" )}}</button>
</fieldset>
</form>
</section>

View File

@ -66,7 +66,7 @@
name="action" value="update"
type="submit">{{( pgettext "Update" "action" )}}</button>
<button class="primary" name="action" value="add"
type="submit">{{( pgettext "Save" "action" )}}</button>
type="submit">{{( pgettext "New invoice" "action" )}}</button>
</fieldset>
</form>
</section>

View File

@ -33,7 +33,7 @@
{{ end }}
<fieldset>
<button class="primary" type="submit">{{( pgettext "Save" "action" )}}</button>
<button class="primary" type="submit">{{( pgettext "Update product" "action" )}}</button>
</fieldset>
</form>
</section>

View File

@ -27,7 +27,7 @@
{{ template "input-field" .Description }}
</div>
<fieldset>
<button class="primary" type="submit">{{( pgettext "Save" "action" )}}</button>
<button class="primary" type="submit">{{( pgettext "New product" "action" )}}</button>
</fieldset>
</form>