Preview prices at page load

This commit is contained in:
Gabriel Augendre 2023-03-27 18:00:30 +02:00
parent a219eeae84
commit f060df9219

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": "keyup delay:500ms,change delay:500ms",
"hx_trigger": "keyup delay:500ms,change delay:500ms,load",
"hx_target": "#price_preview",
"hx_swap": "innerHTML",
}