Stream: questionnaire
Topic: In progress questionnaire
Milton Mitjans (Dec 07 2021 at 20:27):
Is there a way the UI Client can avoid calling the Questionnaire and QuestionnaireResponse resources to get the questionnaire definition and any in-progress responses?
We are thinking on using the initialSelected in the Questionnaire. The UI Client gets the QuestionnaireResponse ID from the Task Resource.
Lloyd McKenzie (Dec 07 2021 at 20:47):
You should never update the Questionnaire to reflect a particular patient's answers. Remember, the Questionnaire is the same instance for every patient (and every time they fill it out)
Lloyd McKenzie (Dec 07 2021 at 20:49):
We made the decision long ago to manage questions and answers as two separate resources. Authorship responsibilities are different, permissions are different and even how they're organized internally are different. (In a QR, groups and questions can repeat, while in the Q, they don't.)
Milton Mitjans (Dec 07 2021 at 20:53):
That makes sense. Is there a way we could optimize the client? meaning instead of having to call: Task / Questionnaire / QuestionnareResponse to make fewer calls.
Paul Lynch (Dec 07 2021 at 20:55):
You could send a batch request. Also I think you use _include to get the QuestionnaireResponse with the Questionnaire.
Milton Mitjans (Dec 07 2021 at 20:56):
Good Point! Didn't think about it. Thank you all!
Lloyd McKenzie (Dec 07 2021 at 21:04):
There's no standard search parameter for Task.input or Task.output in R4 (planning to fix in R5). However, you could certainly define your own to include both when retrieving the Task.
Lloyd McKenzie (Dec 07 2021 at 21:04):
We've done that for at least one or two implementation guides
Brian Postlethwaite (Dec 08 2021 at 05:28):
that include gets a bit funky as its a canonical, and servers may not have that covered yet (ours doesn't, and not sure if HAPI does either)
Last updated: Apr 12 2022 at 19:14 UTC