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

added referred_to_external field PatientConsultationDischargeSerializer #1430

Merged
merged 15 commits into from
Jul 21, 2023

Conversation

sachdevavaibhav
Copy link
Contributor

@sachdevavaibhav sachdevavaibhav commented Jul 4, 2023

added referred_to_external field PatientConsultationDischargeSerializer

Associated Issue

Merge Checklist

  • Tests added/fixed
  • Update docs in /docs
  • Linting Complete
  • Any other necessary step

@coronasafe/care-backend-maintainers @coronasafe/care-backend-admins @rithviknishad

@sachdevavaibhav
Copy link
Contributor Author

@rithviknishad Kindly review it.

Copy link
Member

@rithviknishad rithviknishad left a comment

Choose a reason for hiding this comment

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

@sachdevavaibhav lint CI is failing, make sure pre-commit is installed and ensure lints passes.

https://care-be-docs.coronasafe.network/local-setup/configuration.html#setting-up-pre-commit

@sachdevavaibhav
Copy link
Contributor Author

@rithviknishad Done with formatting.

@sainak
Copy link
Member

sainak commented Jul 4, 2023

@sainak
Copy link
Member

sainak commented Jul 5, 2023

@sachdevavaibhav can you add some tests to validate whether this field is accepting correct inputs

@sachdevavaibhav
Copy link
Contributor Author

@sachdevavaibhav can you add some tests to validate whether this field is accepting correct inputs

ya sure!

@vigneshhari
Copy link
Member

@vigneshhari this is a good time to migrate and remove referred_to foreign key

https://github.com/coronasafe/care/blob/b0eefd152511a390f759b41dac0cb7e27c9ee117/care/facility/models/patient_consultation.py#L92-L98

This is more of an ops question @gigincg

@gigincg
Copy link
Member

gigincg commented Jul 5, 2023

@sainak @vigneshhari And why is reffered_to deprecated?

@sainak
Copy link
Member

sainak commented Jul 5, 2023

@sainak @vigneshhari And why is reffered_to deprecated?

it was changed in #715, but I couldn't find the reference of the issue that requested the change

@sachdevavaibhav
Copy link
Contributor Author

@sachdevavaibhav can you add some tests to validate whether this field is accepting correct inputs

ya sure!

@sainak I have a couple of questions:

  • referred_to_external should accept only strings/null values right? And not integer etc.
  • Should I create separate branch for tests or push them here only?

@sainak
Copy link
Member

sainak commented Jul 6, 2023

@sainak I have a couple of questions:

  • referred_to_external should accept only strings/null values right? And not integer etc.

Yes

  • Should I create separate branch for tests or push them here only?

You can include them in this pr

@sachdevavaibhav
Copy link
Contributor Author

@sainak I have a couple of questions:

  • referred_to_external should accept only strings/null values right? And not integer etc.

Yes

  • Should I create separate branch for tests or push them here only?

You can include them in this pr

@sainak I have written a few test and found that its also accepting integers (may be its converting it to string values). Kindly review the test and should I also add some validation to the input?

@sachdevavaibhav
Copy link
Contributor Author

@sainak I have a couple of questions:

  • referred_to_external should accept only strings/null values right? And not integer etc.

Yes

  • Should I create separate branch for tests or push them here only?

You can include them in this pr

@sainak I have written a few test and found that its also accepting integers (may be its converting it to string values). Kindly review the test and should I also add some validation to the input?

@sainak

@vigneshhari vigneshhari merged commit 80a2ce1 into ohcnetwork:master Jul 21, 2023
2 checks passed
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.

PatientConsultationDischargeSerializer is not having referred_to_external field.
5 participants