django-parler / django-parler

Easily translate "cheese omelet" into "omelette au fromage".
Apache License 2.0
689 stars 155 forks source link

Saving data to all the languages at the same? #177

Open sunjoomoon opened 7 years ago

sunjoomoon commented 7 years ago

Any way to save data to all the languages upon saving default data?

Say, I have three languages with en as default plus ko, ja, then when I save English data, I need to save the same data saved to the other two -ko and ja as well.

That will help translaters save big time and confusion as well.

TeddyBear06 commented 7 years ago

By default, fields that aren't in translations = TranslatedFields() in your models.py file will share its content between all the languages.

So if you set 'price' field to 15 in english, this value will be available in all the others languages.

This avoid data duplication.

Probably that you need something like hidding non-translatable fields into other languages than the PARLER_DEFAULT_LANGUAGE_CODE.

This will avoid translaters confusion.

What do you think about it ?

sunjoomoon commented 7 years ago

.Yes, agree and it makes sense. Documentation says so too. Translatable and non translatable can be in different fieldsets in admin that can tell translators which fields are to be translatd

Data duplication is okay for my requirements. So, any language input, whether default language or not, is savd in all the other languages too. Something like if new record, fill in all the language fields as well.

Fluent contents have copying language data function already, which is great.

Hope things make sense, anybody has achieved anything similar?