summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorManel Clos <manelclos@gmail.com>2015-04-15 12:34:57 (GMT)
committerManel Clos <manelclos@gmail.com>2015-04-15 12:34:57 (GMT)
commitdb4b71dd30524ba90ff850241c17fa321b1c22ea (patch)
treeefcfc7e99b22025bc17a22d75665d115913f72d1
parent8a7d97e2697baf512a88e7d2c428f5d627e1f5d4 (diff)
downloaddjango-import-export-db4b71dd30524ba90ff850241c17fa321b1c22ea.zip
django-import-export-db4b71dd30524ba90ff850241c17fa321b1c22ea.tar.gz
django-import-export-db4b71dd30524ba90ff850241c17fa321b1c22ea.tar.bz2
make 'fields' option more explicit
-rw-r--r--docs/getting_started.rst11
1 files changed, 9 insertions, 2 deletions
diff --git a/docs/getting_started.rst b/docs/getting_started.rst
index b3c453f..c440ff8 100644
--- a/docs/getting_started.rst
+++ b/docs/getting_started.rst
@@ -71,8 +71,15 @@ By default ``ModelResource`` introspects model fields and creates
for each field.
To affect which model fields will be included in an import-export
-resource, use the ``fields`` option to whitelist fields or ``exclude``
-option to blacklist fields::
+resource, use the ``fields`` option to whitelist fields::
+
+ class BookResource(resources.ModelResource):
+
+ class Meta:
+ model = Book
+ fields = ('id', 'name', 'price',)
+
+Or the ``exclude`` option to blacklist fields::
class BookResource(resources.ModelResource):