diff --git a/django/db/models/base.py b/django/db/models/base.py
index ebd67be..82db914 100644
a
|
b
|
class Model(object):
|
553 | 553 | |
554 | 554 | if update_pk: |
555 | 555 | setattr(self, meta.pk.attname, result) |
556 | | transaction.commit_unless_managed(using=using) |
557 | 556 | |
558 | 557 | # Store the database on which the object was saved |
559 | 558 | self._state.db = using |
560 | 559 | # Once saved, this is no longer a to-be-added instance. |
561 | 560 | self._state.adding = False |
562 | 561 | |
563 | | # Signal that the save is complete |
564 | | if origin and not meta.auto_created: |
565 | | signals.post_save.send(sender=origin, instance=self, |
566 | | created=(not record_exists), raw=raw, using=using) |
| 562 | # All tables saved, signal and commit. |
| 563 | if origin: |
| 564 | transaction.commit_unless_managed(using=using) |
| 565 | if not meta.auto_created: |
| 566 | signals.post_save.send(sender=origin, instance=self, |
| 567 | created=(not record_exists), raw=raw, using=using) |
567 | 568 | |
568 | 569 | |
569 | 570 | save_base.alters_data = True |