summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBojan Mihelac <bmihelac@mihelac.org>2015-04-15 12:50:05 (GMT)
committerBojan Mihelac <bmihelac@mihelac.org>2015-04-15 12:50:05 (GMT)
commite974b6bc4ff6e262f63a6fda3c65174dc7230e30 (patch)
tree16462dd03202b4c367a3cb7dab54774bd36bf640
parent0be7cc13e00fffd934def17feaead9171486d57b (diff)
parentdb4b71dd30524ba90ff850241c17fa321b1c22ea (diff)
downloaddjango-import-export-e974b6bc4ff6e262f63a6fda3c65174dc7230e30.zip
django-import-export-e974b6bc4ff6e262f63a6fda3c65174dc7230e30.tar.gz
django-import-export-e974b6bc4ff6e262f63a6fda3c65174dc7230e30.tar.bz2
Merge pull request #241 from manelclos/patch-2
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 aa00898..71fd8a6 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):