From 760da25c6018eff02b3aab33dc6fea7c93881d9f Mon Sep 17 00:00:00 2001 From: Tom Christie Date: Wed, 17 Dec 2014 16:23:42 +0000 Subject: Update documentation --- api-guide/relations/index.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'api-guide/relations/index.html') diff --git a/api-guide/relations/index.html b/api-guide/relations/index.html index 03e88565..2c4fe9b6 100644 --- a/api-guide/relations/index.html +++ b/api-guide/relations/index.html @@ -792,7 +792,7 @@ class Note(models.Model): return 'Note: ' + value.text raise Exception('Unexpected type of tagged object') -
If you need the target of the relationship to have a nested representation, you can use the required serializers inside the .to_native() method:
If you need the target of the relationship to have a nested representation, you can use the required serializers inside the .to_representation() method:
def to_representation(self, value):
"""
Serialize bookmark instances using a bookmark serializer,
--
cgit v1.2.3