mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-09-05 16:38:26 -04:00
Reverting as this should be addressed in a future issue
This commit is contained in:
@@ -174,25 +174,12 @@ def send_messages(service_id, template_id):
|
|||||||
flash(error_message)
|
flash(error_message)
|
||||||
column_headings = get_spreadsheet_column_headings_from_template(template)
|
column_headings = get_spreadsheet_column_headings_from_template(template)
|
||||||
|
|
||||||
params = {
|
|
||||||
"href": {
|
|
||||||
"url": url_for(
|
|
||||||
"main.send_one_off",
|
|
||||||
service_id=current_service.id,
|
|
||||||
template_id=template.id,
|
|
||||||
),
|
|
||||||
"text": "Back to Select recipients",
|
|
||||||
},
|
|
||||||
"classes": "usa-link usa-back-link",
|
|
||||||
}
|
|
||||||
|
|
||||||
return render_template(
|
return render_template(
|
||||||
"views/send.html",
|
"views/send.html",
|
||||||
template=template,
|
template=template,
|
||||||
column_headings=list(ascii_uppercase[: len(column_headings)]),
|
column_headings=list(ascii_uppercase[: len(column_headings)]),
|
||||||
example=[column_headings, get_example_csv_rows(template)],
|
example=[column_headings, get_example_csv_rows(template)],
|
||||||
form=form,
|
form=form,
|
||||||
params=params,
|
|
||||||
allowed_file_extensions=Spreadsheet.ALLOWED_FILE_EXTENSIONS,
|
allowed_file_extensions=Spreadsheet.ALLOWED_FILE_EXTENSIONS,
|
||||||
remaining_messages=remaining_messages,
|
remaining_messages=remaining_messages,
|
||||||
)
|
)
|
||||||
@@ -756,46 +743,39 @@ def get_send_test_page_title(template_type, entering_recipient, name=None):
|
|||||||
return "Personalize this message"
|
return "Personalize this message"
|
||||||
|
|
||||||
|
|
||||||
def get_back_link(service_id, template, step_index, placeholders=None, preview=False):
|
def get_back_link(
|
||||||
|
service_id,
|
||||||
|
template,
|
||||||
|
step_index,
|
||||||
|
placeholders=None,
|
||||||
|
preview=False,
|
||||||
|
):
|
||||||
if preview:
|
if preview:
|
||||||
return {
|
return url_for(
|
||||||
"url": url_for(
|
"main.check_notification",
|
||||||
"main.check_notification",
|
service_id=service_id,
|
||||||
service_id=service_id,
|
template_id=template.id,
|
||||||
template_id=template.id,
|
)
|
||||||
),
|
|
||||||
"text": "Back to Select delivery time",
|
|
||||||
}
|
|
||||||
|
|
||||||
if step_index == 0:
|
if step_index == 0:
|
||||||
if should_skip_template_page(template._template):
|
if should_skip_template_page(template._template):
|
||||||
return {
|
return url_for(
|
||||||
"url": url_for(
|
".choose_template",
|
||||||
"main.view_template",
|
service_id=service_id,
|
||||||
service_id=service_id,
|
)
|
||||||
template_id=template.id,
|
|
||||||
),
|
|
||||||
"text": "Back to View Template",
|
|
||||||
}
|
|
||||||
else:
|
else:
|
||||||
return {
|
return url_for(
|
||||||
"url": url_for(
|
".view_template",
|
||||||
".choose_template",
|
service_id=service_id,
|
||||||
service_id=service_id,
|
template_id=template.id,
|
||||||
),
|
)
|
||||||
"text": "Back to Select or create a template",
|
|
||||||
}
|
|
||||||
|
|
||||||
# For all other steps
|
return url_for(
|
||||||
return {
|
"main.send_one_off_step",
|
||||||
"url": url_for(
|
service_id=service_id,
|
||||||
"main.send_one_off_step",
|
template_id=template.id,
|
||||||
service_id=service_id,
|
step_index=step_index - 1,
|
||||||
template_id=template.id,
|
)
|
||||||
step_index=step_index - 1,
|
|
||||||
),
|
|
||||||
"text": "Back to Personalize this message",
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
def get_skip_link(step_index, template):
|
def get_skip_link(step_index, template):
|
||||||
|
|||||||
Reference in New Issue
Block a user