mirror of
https://github.com/encode/django-rest-framework.git
synced 2025-03-03 19:00:17 +03:00
Merge pull request #3650 from silviogutierrez/master
Documentation fix for list serializers.
This commit is contained in:
commit
f3de2146ea
|
@ -800,6 +800,10 @@ Here's an example of how you might choose to implement multiple updates:
|
|||
return ret
|
||||
|
||||
class BookSerializer(serializers.Serializer):
|
||||
# We need to identify elements in the list using their primary key,
|
||||
# so use a writable field here, rather than the default which would be read-only.
|
||||
id = serializers.IntegerField()
|
||||
|
||||
...
|
||||
class Meta:
|
||||
list_serializer_class = BookListSerializer
|
||||
|
|
Loading…
Reference in New Issue
Block a user