Make update notification status transcational.

Refactor methods for reusability.
This commit is contained in:
Rebecca Law
2016-05-27 12:09:36 +01:00
parent 25a1b7f31c
commit 885abcaf16
4 changed files with 30 additions and 27 deletions

View File

@@ -345,7 +345,7 @@ class Notification(db.Model):
nullable=True,
onupdate=datetime.datetime.utcnow)
status = db.Column(
db.Enum(*NOTIFICATION_STATUS_TYPES, name='notification_status_type'), nullable=False, default='sending')
db.Enum(*NOTIFICATION_STATUS_TYPES, name='notify_status_types'), nullable=False, default='sending')
reference = db.Column(db.String, nullable=True, index=True)