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
In the main parler package there is a hide_untranslated option for settings that can be turned off to allow untranslated fields to show in the admin. I'd like to be able to show all of the untranslated fields in an admin form that works via REST API, so I'd like to be able to incorporate this setting into the serializer.
If you have any tips please let me know but I'm working on it now and I'll submit a PR if I come up with anything...
Currently have something like this in fields.py just before return result:
This is not a great option though since there are no fields included in the resulting serialized data. Ideally there would be blank fields ready to fill in, the same way as they would appear in the django admin.
The text was updated successfully, but these errors were encountered:
I think the best way to represent those empty translations, is by offering them as an empty dict {}.
Note that hide_untranslated and PARLER_REST_SHOW_EXCLUDED_LANGUAGE_TABS are two separate things.
The hide untranslated makes any object disappear in the listing if there is no translation. Some of my sites use that to hide untranslated pages (instead of showing them as english).
The PARLER_REST_SHOW_EXCLUDED_LANGUAGE_TABS tests if there are languages in the database which are not exposed in LANGUAGES / PARLER_LANGUAGES.
How difficult would this be to implement?
In the main parler package there is a hide_untranslated option for settings that can be turned off to allow untranslated fields to show in the admin. I'd like to be able to show all of the untranslated fields in an admin form that works via REST API, so I'd like to be able to incorporate this setting into the serializer.
If you have any tips please let me know but I'm working on it now and I'll submit a PR if I come up with anything...
Currently have something like this in fields.py just before
return result
:Fork
This is not a great option though since there are no fields included in the resulting serialized data. Ideally there would be blank fields ready to fill in, the same way as they would appear in the django admin.
The text was updated successfully, but these errors were encountered: