-
Notifications
You must be signed in to change notification settings - Fork 23
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
unit field limited by precoordinated ucum unit #75
Comments
The unit management in the formbuilder also lead to error in IG publisher QA as the display used in the questionnaire-unit extension is not the one defined in UCUM : and the log :
|
The UCUM standard does not define a display string for "cm". FHIR does here: https://www.hl7.org/fhir/valueset-ucum-units.html, and the display string it lists is "centimeter". So, it looks to me like this error from the IG publisher is itself an error. Do you have a place to report problems with the IG publisher? If not, I could ask on chat.fhir.org. |
My understanding is that the display in the valueset can be specific : while the display in coding (the datatype used in questionnaire-unit extension) is the one from codesystem : We (APHP) use this extension because the unit was hard displayed in the questionnaire. Therefor, there is no use of a display in the extension. We still have to think about, but a solution based on the LHC UCUM validator would resolve our two issues... |
With regard to the original issue here, I think there are two problems. The first is that the UCUM unit selector in the Form Builder does not behave quite like the one on https://ucum.nlm.nih.gov/ucum-lhc/demo.html, in that if you try to compose a second unit string with a first, the first is lost. Secondly, typing in a UCUM unit code without picking from the list does not result in a Coding with the UCUM code system set. |
There is a discrepancy between https://www.hl7.org/fhir/valueset-ucum-units.html (which defines display strings like "centimeter") and https://terminology.hl7.org/UCUM.html, which says the display strings are the unit codes. Apparently the latter page is the authoritative one, so we will adjust the Form Builder to use the codes for the display strings in the Questionnaire output. |
We are currently working on something that :
We will probably have something in one month if you can wait. |
I did create a internal task to work on these issues, but we probably would not start on it for a couple of weeks. My plan was to refactor the unit processing code for the list that appears on https://ucum.nlm.nih.gov/ucum-lhc/demo.html into a shared library to make it re-usable bu the form builder. That code (as you probably know) is currently on the gh-pages branch of the ucum-lhc repository. If you are taking a different approach, I am curious to know how you are using https://ucum.nlm.nih.gov/ucum-lhc/demo.html. |
Nothing revolutionary The idea is to:
May be using the color-code you already use : |
For getting the search autocompleter to work (so that it doesn't replace the full field value), I suggest looking at https://github.com/lhncbc/ucum-lhc/blob/gh-pages/demo/ucumDemo.js. Note that that file is more complicated than is needed here because it is the entire code for the ucum demo, and it is handling both the "convert" and "validate" tabs, but there should be some code that can be re-used (at least as a guide) for the form builder. |
It is not possible to enter valid ucum unit in the unit field if they are not 'precoordinated' in the API used.
For exemple :
In such case, it leads to the following extension :
it is of course possible to :
but we loose some convenient annotation and possibly some users used to one unit
Instead of relying on a limited precoordinated set of unit, it could be possible just to validate the unit filed by the user in the field ?
Or just enriching the list of precoordinated units ?
Or add an option in the formbuilder to fully specify unit (codesystem, code and display) ?
There is probably tons of solution...
The text was updated successfully, but these errors were encountered: