  
  Preprocessing values before saving
  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  
  .. method:: pre_save(self, model_instance, add)
  
  This method is called just prior to :meth:`get_db_prep_save` and should return
  the value of the appropriate attribute from ``model_instance`` for this field.
  The attribute name is in ``self.attname`` (this is set up by
  :class:`~django.db.models.Field`). If the model is being saved to the database
 
</s> remove This method is called just prior to :meth:`get_db_prep_save` and should return
 </s> add This method is called just prior to :meth:`.get_db_prep_save` and should return </s> remove parameters (which is implemented by ``get_db_prep_value``).
 </s> add parameters (which is implemented by :meth:`.get_db_prep_value`). </s> remove ``get_db_prep_value``, you shouldn't need to implement this method
 </s> add :meth:`.get_db_prep_value`, you shouldn't need to implement this method </s> remove This is the reverse of :meth:`to_python` when working with the
 </s> add This is the reverse of :meth:`.to_python` when working with the </s> remove ``datetime``. The simplest way to handle this in a ``db_type()`` method is to
check the ``connection.settings_dict['ENGINE']`` attribute.
 </s> add ``datetime``. The simplest way to handle this in a :meth:`.db_type`
method is to check the ``connection.settings_dict['ENGINE']`` attribute.
.. method:: Field.pre_save(self, model_instance, add)
  
  Preprocessing values before saving
  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  
.. method:: Field.pre_save(self, model_instance, add)
  
  This method is called just prior to :meth:`get_db_prep_save` and should return
  the value of the appropriate attribute from ``model_instance`` for this field.
  The attribute name is in ``self.attname`` (this is set up by
  :class:`~django.db.models.Field`). If the model is being saved to the database
keep keep keep keep replace keep keep keep keep keep
 Fixed #15308 -- Sphinx/reST fixes for the Custom Model Fields docs.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@15547 bcc190cf-cafb-0310-a4f2-bffc1f526a37 
docs/howto/custom-model-fields.txt