diff options
| author | Tom Christie | 2013-04-04 22:24:30 +0100 | 
|---|---|---|
| committer | Tom Christie | 2013-04-04 22:24:30 +0100 | 
| commit | 371698331c979305b5684f864ee6bf5b6d11a44e (patch) | |
| tree | 9a3943318a7ee40b861caf2f2a2c8a423f3ef316 /rest_framework/mixins.py | |
| parent | fd3f538e9f9ef5d4d929c107b9619e0735e426f1 (diff) | |
| download | django-rest-framework-371698331c979305b5684f864ee6bf5b6d11a44e.tar.bz2 | |
Tweaks
Diffstat (limited to 'rest_framework/mixins.py')
| -rw-r--r-- | rest_framework/mixins.py | 4 | 
1 files changed, 4 insertions, 0 deletions
| diff --git a/rest_framework/mixins.py b/rest_framework/mixins.py index 7d9a6e65..c700602e 100644 --- a/rest_framework/mixins.py +++ b/rest_framework/mixins.py @@ -137,6 +137,10 @@ class UpdateModelMixin(object):          return Response(serializer.errors, status=status.HTTP_400_BAD_REQUEST) +    def partial_update(self, request, *args, **kwargs): +        kwargs['partial'] = True +        return self.update(request, *args, **kwargs) +      def pre_save(self, obj):          """          Set any attributes on the object that are implicit in the request. | 
