-
Notifications
You must be signed in to change notification settings - Fork 307
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
Entry format extension has no effect on a date item #1623
Comments
@f-odhiambo Kindly take a look. |
Is this because the device date format overrides the extension? what do you think @jingtang10? |
@PallaviGanorkar can you please take a look at this? |
Sure @jingtang10 |
@jingtang10 As per discussion in issue #1418 and current implementation, Date entry format hint is displayed from locale date format, entry format defined in Questionnaire is not considered. Please confirm, what is expected behavior? |
Thanks @KhumboLihonga for creating this issue. @PallaviGanorkar yes that's right - we do not consider the entry format extension right now. The issue with the entry format extension, however, is that it's not really "computable". In the spec (https://build.fhir.org/ig/HL7/sdc/rendering.html#entryFormat) it says this:
The keyword here is "guide". the entry format extension is guiding the user to input. But not necessarily used as validation. The FHIR questionnaire is a standard for all platforms. My question is how can we interpret this string in Android and be consistent with other langauges / APIs people might use to interpret entry format? Is this guaranteed to be universally consistent? Someone might use the same questionnaire in a .NET environment, or in Python, or in other langauges with other date libraries. Do we know that the entry format string is going to be generating the same validation result? If we have confidence here, we can probably use entry format extension. But otherwise I'm not so sure. |
@jingtang10 Thanks for clarifying this. I assumed it was being used because it is included in the catalog app date picker questionnaire. I think it would be good to remove the extension from there to avoid further confusion. Well, the reason I shared this issue is that when using the catalog app, the date format is automatically set to dd/MM/y as shown in the screenshot above (and is the preferred format for us). However, when using questionnaires in our app on the same phone, the date format is automatically set to M/d/yy as shown below. So I figured the entry extension may be responsible for this but now I have no idea. Any thoughts? |
@KhumboLihonga Have you changed your device locale by any chance? |
@PallaviGanorkar No, I haven't. These two screenshots is me switching from the catalog app to our app. Also, the language of the phone is set to English (United Kingdom) so I expect the catalog app format i.e. |
@KhumboLihonga Could you please confirm few things
|
@f-odhiambo @Gental-Giant could this issue be FHIR Core related? |
As Discussed @KhumboLihonga , Both date Picker and Input box hint show same date format i.e. US locale format though device Setting has UK locale which is incorrect. On other hand catalog app shows correct UK local date format. |
@PallaviGanorkar Thank you for your assistance. Yes, it's being set at the application level. I'll close this issue. |
Describe the bug
Setting the entry format on a date item has no effect.
Component
SDC library
To Reproduce
Steps to reproduce the behavior:
Expected behavior
I expect when I select a date using the date picker, it should appear in the format set in the entry format extension.
Screenshots

Below is what the date item looks like with the entry format set to 'yyyy-mm-dd':
Smartphone (please complete the following information):
Additional context
N/A
The text was updated successfully, but these errors were encountered: