mirror of
https://github.com/GSA/notifications-api.git
synced 2026-08-25 00:33:41 -04:00
Update upload_letters_pdf to use config setting for letter processing deadline
This commit is contained in:
@@ -1,4 +1,4 @@
|
|||||||
from datetime import datetime, timedelta, time
|
from datetime import datetime, timedelta
|
||||||
|
|
||||||
from flask import current_app
|
from flask import current_app
|
||||||
|
|
||||||
@@ -85,7 +85,7 @@ def upload_letters_pdf(reference, crown, filedata):
|
|||||||
now = datetime.utcnow()
|
now = datetime.utcnow()
|
||||||
|
|
||||||
print_datetime = now
|
print_datetime = now
|
||||||
if now.time() > time(17, 30):
|
if now.time() > current_app.config.get('LETTER_PROCESSING_DEADLINE'):
|
||||||
print_datetime = now + timedelta(days=1)
|
print_datetime = now + timedelta(days=1)
|
||||||
|
|
||||||
upload_file_name = LETTERS_PDF_FILE_LOCATION_STRUCTURE.format(
|
upload_file_name = LETTERS_PDF_FILE_LOCATION_STRUCTURE.format(
|
||||||
|
|||||||
Reference in New Issue
Block a user