tomchristie/django-rest-framework — pull request #1479 by nemesisdesign (2014-03-20 13:27:13+00:00)
Title: non_native_fields feature request, related to #951

This pull request is related to discussion #951.

We think this ModelSerializer feature is needed to handle cases in which extra fields that do not correspond to any particular model field are needed to be shown on the browsable API form and OPTIONS http response.

The extra fields are shown in the list of fields but DRF won't try to save them in the database, nor display them in the JSON/XML/whatever response. The developer can access the fields and can do custom processing according to his needs.

I think it's similar to write_only_fields, with the difference that it does not have to correspond to any field on the model.