Make sure the “commencer” link uses the proper test path

This commit is contained in:
Nicolas Bouilleaud 2019-08-13 15:43:23 +02:00
parent c26a701a17
commit 543f9894c1
3 changed files with 8 additions and 2 deletions

View file

@ -40,6 +40,11 @@ class Admin::ProceduresController < AdminController
end
def show
if @procedure.brouillon?
@procedure_lien = commencer_test_url(path: @procedure.path)
else
@procedure_lien = commencer_url(path: @procedure.path)
end
@procedure.path = @procedure.suggested_path(current_administrateur)
@current_administrateur = current_administrateur
end