Currently, since our "view encounter" is a model on the encounters list page, we do not link directly to an encounter. This means that on the dashboard view, clicking a encounter summary card directs you to the encounter list page instead of a specific encounter.
We would like it to still direct to the encounter list page, but if there is an id in the route path the encounter list page should load with the model open for the relevant encounter.
basically:
/encounters -> still goes to the encounters list page
/encounters/:id -> goes to the encounters list page, but has the model open for that encounter.
When this is set up, clicking on a summary card in the dashboard view should direct you to /encounters/:id.
Acceptance Criteria
[x] Clicking on a encounter summary card in the home view leads you to the encounters list page and shows you the encounter in an open model
[x] /encounters/:id evokes this behaviour
Implementation details
You can look at the edit/create person and the person view page to see how they extract information from the route.
Testing notes
Will need to figure out what the behaviour should be for an invalid encounter id.
Description
Currently, since our "view encounter" is a model on the encounters list page, we do not link directly to an encounter. This means that on the dashboard view, clicking a encounter summary card directs you to the encounter list page instead of a specific encounter.
We would like it to still direct to the encounter list page, but if there is an id in the route path the encounter list page should load with the model open for the relevant encounter.
basically: /encounters -> still goes to the encounters list page /encounters/:id -> goes to the encounters list page, but has the model open for that encounter.
When this is set up, clicking on a summary card in the dashboard view should direct you to /encounters/:id.
Acceptance Criteria
Implementation details
You can look at the edit/create person and the person view page to see how they extract information from the route.
Testing notes
Will need to figure out what the behaviour should be for an invalid encounter id.