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

Moves the antifungal logic out of a signal into update_from_dict #1459

Open
wants to merge 25 commits into
base: v0.108
Choose a base branch
from

Conversation

fredkingham
Copy link
Contributor

We do not want this logic to be called by merge_patient

This will conflict with #1456 but probs best kept seperate and the conflict handled

We do not want this logic to be called by merge_patient
fredkingham added 2 commits April 26, 2023 15:30
At the moment there is a bug if a patient is created who has TB tests
prior to 3 days ago, they are not added to the MDT list. We may as well
run for all time.
@davidmiller
Copy link
Member

as discussed, conflicts...

fredkingham and others added 19 commits May 23, 2023 14:51
Adds a human readable representation to BedStatus
This line was commented out when the method had not been pushed live.

That method should now be live.
the css class 'text-strong' in elcid is the same as 'bold' in opal so
lets just use that.
We don't need to hoist the patient id onto the scope so lets not.
Changes create_tb_observations to always run for all time
Removes the text-strong class which is the same as the bold class
Removes an old function call that is no longer used in opal that was
returning false.
Changes the text to be more in keeping with the format of our other
modals
Adds in a management command that takes in MRNs and reloads the
associated patients. It errors if the patient does not exist.
Needs to be the previous Wed
…mand

Adds the reload_patients management command
…cations

Makes the patients name appear in tb medications and other medications
elcid/models.py Outdated
@@ -427,6 +427,12 @@ def update_from_dict(self, data, *args, **kwargs):
).first()
if micro_input:
micro_input.delete_self()

if data.get("reason_for_interaction") == self.ANTIFUNGAL_STEWARDSHIP_ROUND:
omodels.Episode.objects.get(id=data['episode_id']).patient.chronicantifungal_set.create(
Copy link
Member

Choose a reason for hiding this comment

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

Use self.episode?

@davidmiller davidmiller removed their assignment May 25, 2023
fredkingham added 2 commits May 25, 2023 20:06
Changes the ANTIFUNGAL_STEWARDSHIP_ROUND logic to use self.episode
rather than the episode id in the dict.
@fredkingham fredkingham removed their assignment May 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants