mirror of
https://github.com/Hopiu/django-modeltranslation.git
synced 2026-04-13 01:40:58 +00:00
Fixed occasional "This field is required" error for the original field. Resolves issue 5.
This commit is contained in:
parent
5fd7306b7e
commit
5eb60f06f5
1 changed files with 2 additions and 0 deletions
|
|
@ -29,7 +29,9 @@ class TranslationAdminBase(object):
|
|||
# translation field required instead.
|
||||
if db_field.language == settings.LANGUAGES[0][0] and orig_formfield.required:
|
||||
orig_formfield.required = False
|
||||
orig_formfield.blank = True
|
||||
field.required = True
|
||||
field.blank = False
|
||||
|
||||
field.widget = deepcopy(orig_formfield.widget)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue