localized_fields/fields/file_field.py
def pre_save(self, model_instance, add):
        """Returns field's value just before saving."""
        value = super().pre_save(model_instance, add)
        if isinstance(value, LocalizedValue):
            for file in value.__dict__.values():
                if file and not file._committed:
                    file.save(file.name, file, save=False)
        return value
Returns field's value just before saving.
Returns field's value just before saving.
Returns field ' s value just before saving .
def pre_save(self, model_instance, add):
        value = super().pre_save(model_instance, add)
        if isinstance(value, LocalizedValue):
            for file in value.__dict__.values():
                if file and not file._committed:
                    file.save(file.name, file, save=False)
        return value
def pre_save ( self , model_instance , add ) : value = super ( ) . pre_save ( model_instance , add ) if isinstance ( value , LocalizedValue ) : for file in value . __dict__ . values ( ) : if file and not file . _committed : file . save ( file . name , file , save = False ) return value
Returns field's value just before saving.
Returns field ' s value just before saving .
"""Returns field's value just before saving."""
self
model_instance
add