Last active
November 3, 2020 08:21
-
-
Save arnaudvalle/f1641592cd8531fbd059f610d1271c32 to your computer and use it in GitHub Desktop.
Attestation de déplacement dérogatoire - Chrome snippet
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// https://developers.google.com/web/tools/chrome-devtools/javascript/snippets | |
const now = new Date(); | |
const hoursWithLeadingZero = `0${now.getHours()}`.slice(-2); | |
const minutesWithLeadingZero = `0${now.getMinutes()}`.slice(-2); | |
document.querySelector('#field-firstname').value = 'PRENOM'; | |
document.querySelector('#field-lastname').value = 'NOM'; | |
document.querySelector('#field-birthday').value = 'DATE DE NAISSANCE (JJ/MM/YYYY)'; | |
document.querySelector('#field-placeofbirth').value = 'LIEU DE NAISSANCE'; | |
document.querySelector('#field-address').value = 'ADRESSE'; | |
document.querySelector('#field-city').value = 'VILLE'; | |
document.querySelector('#field-zipcode').value = 'CODE POSTAL'; | |
document.querySelector('#field-heuresortie').value = `${hoursWithLeadingZero}:${minutesWithLeadingZero}`; | |
document.querySelector('#checkbox-achats').checked = true; | |
document.querySelector('#generate-btn').click(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment