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

(UPDATE) prevent of using i18n field as form field #53

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

dfirst
Copy link
Contributor

@dfirst dfirst commented May 5, 2019

Why i did it.

  1. We have this line https://github.com/zostera/django-modeltrans/blob/master/modeltrans/translator.py#L138, currently flag (editable=False) did nothing because it isnt set to TranslatedVirtualField.
  2. I think in case if we need active language model form we need to force user to use solution like ActiveLanguageMixin.
  3. Also i18n virtual form field can be unpredictable in case of (required=False) because its always (blank | null = True).

Alternative of this solution can be using some kind of lazy form field.

What do you think?

@coveralls
Copy link

coveralls commented May 5, 2019

Coverage Status

Coverage remained the same at ?% when pulling 8a629ab on dfirst:UPDATE_prevent_using_i18n_virt_field_as_form_field into 862d4f5 on zostera:master.

@dfirst dfirst force-pushed the UPDATE_prevent_using_i18n_virt_field_as_form_field branch from e3199cd to 8a629ab Compare May 17, 2019 01:16
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

Successfully merging this pull request may close these issues.

2 participants