-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
feat(lab): link visit to labs #2479
feat(lab): link visit to labs #2479
Conversation
Add functionality to link visit to lab, and updated the schema to have a visitId in the Lab model. fix HospitalRun#2184
This pull request is being automatically deployed with Vercel (learn more). 🔍 Inspect: https://vercel.com/hospitalrun/hospitalrun-frontend/9yvjywvup |
In #2243, @jackcmeyer mentioned "updating the pouchdb schema" to describe the relationship between appointments and labs. We have since switched to associating visits with labs. Does updating the schema still apply here? I do not see any inclusion of "visits" in the schema already. |
const onCancel = () => { | ||
history.push('/labs') | ||
} | ||
|
||
const defaultSelectedVisitsOption = () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe a good idea to add a test for this functionality
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great idea. I added a test that chooses a patient in the Typeahead, makes sure the option isn't selected yet, and then tests selecting the option, which all leverages this defaultSelectedVisitsOption
function.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Add functionality to link visit to lab, and updated the schema to have a visitId in the Lab model.
fix #2184
Fixes #2184.
Changes proposed in this pull request:
visitId