@johnnyicon wrote:
The scenario is a user clicks a button on a template which takes them to another route/template.
For clarity, let’s call the page with the button the
index
route/template, and let’s call the page that the user is sent to after clicking the button theedit
route/template.Before presenting the
edit
route/template, there should be a new record created that will be themodel
of theedit
route/template.Would it best practice to:
- implement the logic of creating a new data record and redirect in the
index
controller; or- implement all the logic in the
edit
route handler?
Posts: 3
Participants: 3