-
Notifications
You must be signed in to change notification settings - Fork 97
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
Table view header generation issue #7
base: master
Are you sure you want to change the base?
Conversation
When there are multiple entries per day, the logic used to merge these observations would work on the first same-day group, but would always put in 2 entries for all subsequent same-day group. This fixes that by stepping back and overwriting a previous same day entry.
We had to make several changes to allow for accurate percentiles for the ultra precise Fenton and Olsen charts.
trunc display precision for weeker to only 2 digits
@vlad-ignatov Does this pull request make sense for the app? Could you please review and merge (if appropriate) when you have a chance? |
js/gc-smart-data.js
Outdated
@@ -406,7 +406,10 @@ window.GC = window.GC || {}; | |||
if ( d.valid() ) { | |||
this.DOB = d; | |||
this.birthdate = d.toString(); | |||
this.gestationAge = this.weeker = Math.round(40 - this.DOB.diffWeeks(this.EDD)); | |||
|
|||
if (this.gestationAge == null) { |
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.
Could you explain why do you want to keep the gestationAge/weeker if DOB or EDD is changed?
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.
Cerner gives us the pre-calculated gest age in their fhir service response.
There is sometimes a discrepancy of 1 day when using the calculation, so this logic is guarding against changing the gest age, if we have already read and populated it elsewhere.
is the DOB or EDD likely to change? and if so, wont restarting the app simply realign all the values?
I just added a new commit with a down syndrome growth chart. please merge into main |
var ptFetch = patient.read(); | ||
|
||
patient.Observation.where. | ||
nameIn(['3141-9', '8302-2', '8287-5', '39156-5', '18185-9', '37362-1', '11884-4']). |
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.
Are you using the DSTU2 May 2015 ballot syntax here? Can you pull in the latest changes from the smart-on-fhir:master branch to use the DSTU2 final syntax?
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.
unfortunately, we are using the Cerner FHIR service, which is not DSTU2 compliant. Once the service is updated, we plan to upgrade all such calls.
When there are multiple entries per day, the logic used to merge these
observations would work on the first same-day group, but would always
put in 2 entries for all subsequent same-day group. This fixes that by
stepping back and overwriting a previous same day entry.