Reload price on keyup too

This commit is contained in:
Gabriel Augendre 2023-03-27 17:48:10 +02:00
parent 755d896f1c
commit f8e7647af1

View file

@ -28,7 +28,7 @@ class BasketForm(forms.ModelForm):
self.helper.add_input(Submit("submit", _("Save")))
self.helper.attrs = {
"hx_post": reverse("purchase:price_preview"),
"hx_trigger": "change",
"hx_trigger": "keyup,change",
"hx_target": "#price_preview",
"hx_swap": "innerHTML",
}