mirror of
https://github.com/GSA/notifications-api.git
synced 2026-08-18 21:48:49 -04:00
ensure created_by_id is being persisted correctly
(also make sure it's well tested 🎉 )
This commit is contained in:
@@ -1007,6 +1007,9 @@ class NotificationHistory(db.Model, HistoryModel):
|
||||
phone_prefix = db.Column(db.String, nullable=True)
|
||||
rate_multiplier = db.Column(db.Float(asdecimal=False), nullable=True)
|
||||
|
||||
created_by = db.relationship('User')
|
||||
created_by_id = db.Column(UUID(as_uuid=True), db.ForeignKey('users.id'), nullable=True)
|
||||
|
||||
@classmethod
|
||||
def from_original(cls, notification):
|
||||
history = super().from_original(notification)
|
||||
|
||||
Reference in New Issue
Block a user