Merge pull request 'fix: expense form reset incorrectly after top-up submission' (#4) from fix/expense-form into main

Reviewed-on: #4
This commit is contained in:
juancwu 2026-02-07 19:50:32 +00:00
commit f0a8c95ee6

View file

@ -24,7 +24,7 @@ type AddExpenseFormProps struct {
} }
func (p AddExpenseFormProps) formAttrs() templ.Attributes { func (p AddExpenseFormProps) formAttrs() templ.Attributes {
closeScript := "on htmx:afterOnLoad if event.detail.xhr.status == 200 then call window.tui.dialog.close('" + p.DialogID + "') then reset() me end" closeScript := "on htmx:afterOnLoad if event.detail.xhr.status == 200 then call window.tui.dialog.close('" + p.DialogID + "') then reset() me then show #item-selector-section end"
if p.FromOverview { if p.FromOverview {
return templ.Attributes{ return templ.Attributes{
"hx-post": "/app/spaces/" + p.Space.ID + "/expenses?from=overview", "hx-post": "/app/spaces/" + p.Space.ID + "/expenses?from=overview",