skolo-online / invoice3

Final Instalment in the Invoice App, the complete code.
55 stars 39 forks source link

Empty invoices created when form is not submitted #4

Closed aalexmrt closed 1 year ago

aalexmrt commented 1 year ago

I'm building a project similar that yours following a similar idea when building the invoice. And I'm finding a case where for example if you click to create an Invoice you will call the function createInvoice and a new one will be created and redirected to the view createBuildInvoice with the new id of the created invoice. But if the user close the windows or doesn't submit the form, an empty invoice will be created. I will like to manage this case and delete the invoice if the form is not submitted. How will you approach this situation? Thanks

aalexmrt commented 1 year ago

Sorry, I'm gonna close the issue I just realized that you can manage this case deleting the invoice by yourself wiht a delete button for each invoice.