diff --git a/app/main/views/send.py b/app/main/views/send.py index c3a0fcb2f..faeb3acf4 100644 --- a/app/main/views/send.py +++ b/app/main/views/send.py @@ -242,11 +242,16 @@ def check_messages(service_id, template_type, upload_id): ) if current_service['restricted'] else None ) - if request.args.get('from_test') and len(template.placeholders): + if request.args.get('from_test'): extra_args = {'help': 1} if request.args.get('help', '0') != '0' else {} - back_link = url_for( - '.send_test', service_id=service_id, template_id=template.id, **extra_args - ) + if len(template.placeholders): + back_link = url_for( + '.send_test', service_id=service_id, template_id=template.id, **extra_args + ) + else: + back_link = url_for( + '.choose_template', service_id=service_id, template_type=template.template_type, **extra_args + ) else: back_link = url_for('.send_messages', service_id=service_id, template_id=template.id) diff --git a/app/templates/views/send-test.html b/app/templates/views/send-test.html index 95f298c30..600a3d2b4 100644 --- a/app/templates/views/send-test.html +++ b/app/templates/views/send-test.html @@ -14,7 +14,7 @@ {% if request.args['help'] %}