summaryrefslogtreecommitdiff
path: root/docs/howto
diff options
context:
space:
mode:
authorAndrew Godwin <andrew@aeracode.org>2014-05-06 23:06:41 -0700
committerAndrew Godwin <andrew@aeracode.org>2014-05-06 23:06:41 -0700
commit827d5dc189fba33ec69d8916be310ff1e76361b1 (patch)
treea180131b0545a09d6d63d18518f78b256be24fd5 /docs/howto
parentf9d7e18dc5fa324ed095c6aafd83a34f3086a3de (diff)
Improve docs around deconstruction/serialisation (refs #22337)
Diffstat (limited to 'docs/howto')
-rw-r--r--docs/howto/custom-file-storage.txt7
1 files changed, 7 insertions, 0 deletions
diff --git a/docs/howto/custom-file-storage.txt b/docs/howto/custom-file-storage.txt
index 090cc089cb..5109986d45 100644
--- a/docs/howto/custom-file-storage.txt
+++ b/docs/howto/custom-file-storage.txt
@@ -34,6 +34,13 @@ You'll need to follow these steps:
In addition, if your class provides local file storage, it must override
the ``path()`` method.
+#. Your storage class must be :ref:`deconstructible <custom-deconstruct-method>`
+ so it can be serialized when it's used on a field in a migration. As long
+ as your field has arguments that are themselves
+ :ref:`serializable <migration-serializing>`, you can use the
+ ``django.utils.deconstruct.deconstructible`` class decorator for this
+ (that's what Django uses on FileSystemStorage).
+
Your custom storage system may override any of the storage methods explained in
:doc:`/ref/files/storage`, but you **must** implement the following methods: