You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The template view should have the same access to episode and patient id as the api, however at the moment only the api views receive the patient id and episode id.
Then when we call get_steps we should do this in the view and pass episode_id and patient_id, then pass steps to the wizard/page pathways which should then use the new template context variable.
Make sure other calls to get_steps also have the patient_id and episode_id in them.
The text was updated successfully, but these errors were encountered:
I'm not sure I understand this at all ? get_steps is only called in places that have access to a patient/episode object if they exist?
This ticket doesn't explain why that's related to template views?
I don't think you've explained the problem benefit here?
I definitely couldn't pick this up and implement it :(
The template view should have the same access to episode and patient id as the api, however at the moment only the api views receive the patient id and episode id.
The template view url
https://github.com/openhealthcare/opal/blob/v0.11.0/opal/core/pathway/urls.py#L15
Whereas their are options to pass patient and episode to the pathway
https://github.com/openhealthcare/opal/blob/v0.11.0/opal/core/pathway/urls.py#L35
pathway.get_steps. Takes in optional arguments for patient and episode
https://github.com/openhealthcare/opal/blob/v0.11.0/opal/core/pathway/pathways.py#L124
but when we call it, these arguments are not always passed in. https://github.com/openhealthcare/opal/blob/v0.11.0/opal/core/pathway/pathways.py#L64
https://github.com/openhealthcare/opal/blob/v0.11.0/opal/core/pathway/templates/pathway/templates/page_pathway.html#L4
https://github.com/openhealthcare/opal/blob/v0.11.0/opal/core/pathway/templates/pathway/templates/wizard_pathway.html#L13
yet in some cases they are passed in
https://github.com/openhealthcare/opal/blob/v0.11.0/opal/core/pathway/pathways.py#L144
Then when we call get_steps we should do this in the view and pass episode_id and patient_id, then pass steps to the wizard/page pathways which should then use the new template context variable.
Make sure other calls to get_steps also have the patient_id and episode_id in them.
The text was updated successfully, but these errors were encountered: