OpenConceptLab / ocl_issues

Issues for all OCL repos. NOTE: Install ZenHub Browser Extension and request access to the OCL Roadmap board to view all issues and to contribute
4 stars 2 forks source link

$cascade for OpenMRS - Automatically add sets (answers, labsets, etc) when parent concept is added to my collection #1057

Closed gracepotma closed 8 months ago

gracepotma commented 3 years ago

As a user assembling a collection using the OCL Online UI, I want it to be fast to add sets of things into my collection (e.g. a Question with many connected answers; a LabSet ("panel") with many connected labs), so that I can "Add to Collection" a panel concept like CBC (Complete Blood Count #1019) and automatically have all the relevant labs in that panel also added to my collection (e.g. Hematocrit, Platelets, Hemoglobin, etc).

I actually expected this was already the case because when I click "Add to Collection" I see the modal that confirms that it will "Automatically add associated mappings": image

(e.g. see 5 min clip of user testing adding a LabSet to a collection here: https://www.loom.com/share/d841edce17b547f8a5a922ed423ce1cd)

paynejd commented 3 years ago

Thanks for creating this ticket @gracepotma!

OCL has a feature (that the Dictionary Mgr uses) to "cascade source mappings", which means that when you add a concept, you have the option to also add any mappings from the same source where the concept you're adding is the fromConcept -- but it doesn't actually add any of the toConcepts. That said, this is an important feature to support, and we'll use this ticket to compile requirements.

Examples

Questions

cc @snyaggarwal

snyaggarwal commented 3 years ago

@paynejd sourceToConcepts is available on QA via UI and API both. Please check it out and provide feedback

snyaggarwal commented 3 years ago

Test to describe/document the behaviour

jamlung-ri commented 3 years ago

This is working pretty well, and we have a discussion topic on this for tomorrow's Arch call.

jamlung-ri commented 3 years ago

We had a Cascading discussion in today's Arch call, which lays out some more specific functionality for $cascade.

Highlight:

Proposed method: Implement a new $cascade operation that returns mixed resource types based on the parameters used

/orgs/CIEL/sources/CIEL/concepts/1234/$cascade?method=sourceToConcepts&cascadeMapTypes=SAME-AS&resourceTypes=concepts,mappings

Need to consider recursion and hierarchy, and how this aligns with FHIR $subsumes Would maintain backwards compatibility until we retire the old-style cascade

jamlung-ri commented 3 years ago

@snyaggarwal I am going to put this back to In Dev for these changes. We also need to get feedback on the UI piece of this.

Since this is becoming a series of features, we probably need to create a specific epic for this and continue to track the features there.

jamlung-ri commented 3 years ago

Turning this into an epic and adding tickets to it

jamlung-ri commented 8 months ago

Closing this out since this functionality has been implemented in OCL for some time. Note that there will be an additional set of work for OCLv3, which will be documented here: https://docs.google.com/document/d/1nkSEU4qizs3fk6y8DZ_p_ZP3-8MA2ovgup3b22L5Bn4/edit#heading=h.zbg0nbu53vfv