浏览代码

Merge branch 'master' of https://github.com/macav/django-rest-framework-bulk into macav-master

Conflicts:
	README.rst
Miroslav Shubernetskiy 10 年之前
父节点
当前提交
eee87db4ce
共有 2 个文件被更改,包括 2 次插入1 次删除
  1. 1 0
      README.rst
  2. 1 1
      rest_framework_bulk/mixins.py

+ 1 - 0
README.rst

@@ -138,3 +138,4 @@ Maintainers/contributors:
 * Miroslav Shubernetskiy - `GitHub <https://github.com/miki725>`_
 * Arien Tolner - `GitHub <https://github.com/Bounder>`_
 * Kevin Brown - `GitHub <https://github.com/kevin-brown>`_
+* Martin Cavoj - `GitHub <https://github.com/macav>`_

+ 1 - 1
rest_framework_bulk/mixins.py

@@ -30,7 +30,7 @@ class BulkCreateModelMixin(CreateModelMixin):
             if serializer.is_valid():
                 [self.pre_save(obj) for obj in serializer.object]
                 self.object = serializer.save(force_insert=True)
-                [self.post_save(obj) for obj in self.object]
+                [self.post_save(obj, created=True) for obj in self.object]
                 return Response(serializer.data, status=status.HTTP_201_CREATED)
 
         return Response(serializer.errors, status=status.HTTP_400_BAD_REQUEST)