mirror of
https://github.com/GSA/notifications-api.git
synced 2026-02-01 15:46:07 -05:00
[WIP]
This commit is contained in:
@@ -54,7 +54,8 @@ def persist_notification(
|
||||
notification_id=None,
|
||||
simulated=False,
|
||||
created_by_id=None,
|
||||
status=NOTIFICATION_CREATED
|
||||
status=NOTIFICATION_CREATED,
|
||||
reply_to_text=None
|
||||
):
|
||||
notification_created_at = created_at or datetime.utcnow()
|
||||
if not notification_id:
|
||||
@@ -76,7 +77,8 @@ def persist_notification(
|
||||
client_reference=client_reference,
|
||||
reference=reference,
|
||||
created_by_id=created_by_id,
|
||||
status=status
|
||||
status=status,
|
||||
reply_to_text=reply_to_text,
|
||||
)
|
||||
|
||||
if notification_type == SMS_TYPE:
|
||||
|
||||
@@ -142,7 +142,7 @@ def check_service_email_reply_to_id(service_id, reply_to_id, notification_type):
|
||||
message = 'email_reply_to_id is not a valid option for {} notification'.format(notification_type)
|
||||
raise BadRequestError(message=message)
|
||||
try:
|
||||
dao_get_reply_to_by_id(service_id, reply_to_id)
|
||||
return dao_get_reply_to_by_id(service_id, reply_to_id).email_address
|
||||
except NoResultFound:
|
||||
message = 'email_reply_to_id {} does not exist in database for service id {}'\
|
||||
.format(reply_to_id, service_id)
|
||||
|
||||
Reference in New Issue
Block a user