Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support fully defining contained resources using caret rules #1404

Open
cmoesel opened this issue Dec 13, 2023 · 0 comments
Open

Support fully defining contained resources using caret rules #1404

cmoesel opened this issue Dec 13, 2023 · 0 comments
Labels
added to backlog Added to the team's Jira backlog bug Something isn't working

Comments

@cmoesel
Copy link
Member

cmoesel commented Dec 13, 2023

It should be possible to fully define a contained resource, element-by-element, using caret rules in a non-Instance FSH definition. E.g.:

ValueSet: ExampleValueset
Id: example-valueset
* ^contained.resourceType = "CodeSystem"
* ^contained.id = "example-codesystem"
* ^contained.url = "http://example.org/codesystem"
* ^contained.version = "1.0.0"
* ^contained.content = #complete
* ^contained.concept[0].code = #example-code-1
* ^contained.concept[0].display = "Example Code 1"
* ^url = "http://example.org/valueset"
* ^version = "1.0.0"
* ^status = #active

Currently this results in an error because SUSHI does not recognize the path ^contained.url since it is not in the Resource datatype. Ideally, SUSHI should look at the assigned resourceType and use that type when resolving paths in the contained resource FSH. Note that this does work correctly when assigning contained resources in an Instance definition.

See: https://chat.fhir.org/#narrow/stream/215610-shorthand/topic/Contained.20code.20system.20in.20the.20value.20set/near/407685349

@cmoesel cmoesel added the bug Something isn't working label Dec 13, 2023
@cmoesel cmoesel added the added to backlog Added to the team's Jira backlog label Dec 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
added to backlog Added to the team's Jira backlog bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant