Exemplo n.º 1
0
 def save(self):
     created = not hasattr(self, "id")
     if created:
         self.timestamp = datetime.now()
     self.put()
     if created:
         notification_created.send(sender=self.__class__, instance=self)
Exemplo n.º 2
0
 def save(self):
     created = not hasattr(self, "id")
     if created:
         self.timestamp = datetime.now()
     self.put()
     if created:
         notification_created.send(sender=self.__class__, instance=self)
Exemplo n.º 3
0
 def save(self, *args, **kw):
     created = not getattr(self, "id", None)
     super(Notification, self).save(*args, **kw)
     if created:
         notification_created.send(sender=self.__class__, instance=self)
Exemplo n.º 4
0
 def save(self, *args, **kw):
     created = not getattr(self, "id", None)
     super(Notification, self).save(*args, **kw)
     if created:
         notification_created.send(sender=self.__class__, instance=self)