有一个带有post_create捕手的父类:
class ParentClass(SomeParentModel):
# parent's code
@receiver(post_save, sender=ParentClass):
# some code after catching the signal
还有一个儿童班:
class ChildClass(ParentClass):
# child's code
由于某种原因,post_save
在初始化ChildClass
时永远不会被触发。这里做错了什么?
修改:可能必须在post_save()
实施ChildNode
并致电super()
?