Add back links to all steps of tour

This commit is contained in:
Chris Hill-Scott
2019-06-06 11:14:42 +01:00
parent 7b3d522070
commit 62fb71966b
2 changed files with 58 additions and 1 deletions

View File

@@ -800,7 +800,20 @@ def get_back_link(service_id, template, step_index):
help=get_help_argument()
)
else:
return None
if step_index == 0:
return url_for(
'main.start_tour',
service_id=service_id,
template_id=template.id,
)
elif step_index > 0:
return url_for(
'main.send_test_step',
service_id=service_id,
template_id=template.id,
step_index=step_index - 1,
help=2,
)
elif step_index == 0:
if should_skip_template_page(template.template_type):
return url_for(