Compare commits

..

No commits in common. "19f81128ec51777622f9dfb6b3b3dc5d398edc4e" and "689eab3a08797bc2d5f8334167d9b3109f2430fd" have entirely different histories.

3 changed files with 2 additions and 16 deletions

View File

@ -997,8 +997,6 @@ func HandleEditInvoiceAction(w http.ResponseWriter, r *http.Request, params http
slug := params[0].Value
actionUri := fmt.Sprintf("/invoices/%s/edit", slug)
handleInvoiceAction(w, r, actionUri, func(w http.ResponseWriter, r *http.Request, form *invoiceForm) {
conn := getConn(r)
form.Number = conn.MustGetText(r.Context(), "", "select invoice_number from invoice where slug = $1", slug)
mustRenderEditInvoiceForm(w, r, slug, form)
})
}

View File

@ -569,13 +569,6 @@ main > nav {
.new-invoice-product {
display: grid;
grid-template-columns: repeat(4, 1fr);
position: relative;
}
.new-invoice-product .delete-product {
position: absolute;
right: 0;
top: .75rem;
}
.new-invoice-product .input:nth-of-type(5) {

View File

@ -145,15 +145,10 @@
{{ define "invoice-product-form" -}}
{{- /*gotype: dev.tandem.ws/tandem/numerus/pkg.invoiceProductForm*/ -}}
<fieldset class="new-invoice-product"
x-data="{removeProduct() { $el.remove(); document.getElementById('recompute-button').click(); }}"
data-hx-select="unset"
data-hx-vals='{"index": {{ .Index }}}'
data-hx-include="[name='product.quantity.{{ .Index }}']"
>
<button x-cloak type="button" class="icon delete-product"
@click="removeProduct()"
aria-label="{{( gettext "Delete product from invoice" )}}"
><i class="ri-delete-back-2-line"></i></button>
{{ template "hidden-field" .InvoiceProductId }}
{{ template "hidden-field" .ProductId }}
{{ template "input-field" .Name }}