Revert "Update iframe-script.js"

This reverts commit 1426bc2634.
pull/297/head
Johan Girod 2018-08-10 10:35:29 +02:00
parent 1426bc2634
commit 64bb6259c7
1 changed files with 1 additions and 1 deletions

View File

@ -2,7 +2,7 @@
// Get the "couleur" parameter passed to this script
let script = document.getElementById('script-simulateur-embauche'),
couleur = script.dataset.couleur,
baseUrl = 'https://embauche.beta.gouv.fr/',
baseUrl = script.dataset.iframeUrl || script.getAttribute('src').split('dist')[0],
integratorUrl = encodeURIComponent(window.location.href.toString()),
lang = script.dataset.lang,
src = baseUrl + `?couleur=${couleur}&iframe&integratorUrl=${integratorUrl}&lang=${lang}`