You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If my current language is different from default language, and I create an object, it doesn't populate the default field value.
For example, I have below in my settings:
LANGUAGES = (
('en', gettext_noop('English')),
('ar', gettext_noop('Arabic')),
)
If I go the create page, and select "ar" as my current language. Create the model object. I then change my language to default language "en". The en field doesn't get populated. Whereas, if its the other way round, and I create an object with "en" selected, then it populates "ar" field properly. Is this how it is designed? Or am I missing something with auto-populate function?
The text was updated successfully, but these errors were encountered:
Take a look at modeltranslation/translator.py and try to find a bug.
last-partizan
changed the title
MODELTRANSLATION_AUTO_POPULATE = True has no effect
MODELTRANSLATION_AUTO_POPULATE = True has no effect with non-default language
Jun 9, 2020
In my case, I'm not set MODELTRANSLATION_AUTO_POPULATE but it still auto copy all translated field to default field although I have provided value for default fields.
Django==2.2.13
django-modeltranslation==0.15
MODELTRANSLATION_AUTO_POPULATE = True
If my current language is different from default language, and I create an object, it doesn't populate the default field value.
For example, I have below in my settings:
LANGUAGES = (
('en', gettext_noop('English')),
('ar', gettext_noop('Arabic')),
)
If I go the create page, and select "ar" as my current language. Create the model object. I then change my language to default language "en". The en field doesn't get populated. Whereas, if its the other way round, and I create an object with "en" selected, then it populates "ar" field properly. Is this how it is designed? Or am I missing something with auto-populate function?
The text was updated successfully, but these errors were encountered: