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

EntryForm DateWidge not working good with internationalization #4

Open
kevin-sgcib opened this issue Jun 25, 2021 · 1 comment
Open

Comments

@kevin-sgcib
Copy link

I am in Japan and the date widget is not happy with my regional settings. I can pick a date, but when I try to validate the form (through clicking in 'save'), it says 'input a valid date'. I didn't have much time to look into it so I just added a line to your datewidget initialization :

        'date': DateWidget(
            bootstrap_version=3,
            options=DATE_WIDGET_OPTIONS,
        ),

became

        'date': DateWidget(
            bootstrap_version=3,
            options=DATE_WIDGET_OPTIONS,
            usel10n = True,
        ),

Now the date are not displayed using my local preferences, but it works.

@BobBowles
Copy link
Owner

Thanks for the feedback. I did not spend much time looking at internationalisation issues when I wrote this. Hopefully when I have time I will incorporate your suggestion.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants