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

Fix get resource by id (use rt/id, not search(_id=)) #111

Merged
merged 2 commits into from Aug 15, 2023

Conversation

pavlushkin
Copy link
Member

@pavlushkin pavlushkin commented Aug 14, 2023

Fix a discrepancy between documentation (https://github.com/beda-software/fhir-py#get-resource-by-id) and actual http request that is executed in reference.to_resource()

@@ -190,6 +190,11 @@ def to_reference(self, **kwargs):
"""
return self.client.reference(reference=self.reference, **kwargs)

def _perform_resource(self, data):
Copy link
Member

@ir4y ir4y Aug 15, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

def _dict_to_resource(self, data_dict):
    return self.client.resource(data['resourceType'], **data)

@pavlushkin pavlushkin merged commit 19d636e into master Aug 15, 2023
8 checks passed
@pavlushkin pavlushkin deleted the fix-read-resource-by-id branch August 15, 2023 20:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants