Skip to content
Snippets Groups Projects
Commit dfd2bcd3 authored by nicrausaz's avatar nicrausaz
Browse files

clear

parent 56ff7a5f
No related branches found
No related tags found
No related merge requests found
......@@ -11,7 +11,6 @@ $(document).ready(function () {
}
if (location.pathname.split("/").slice(-1)[0] == "viewpostulation.php") {
initPostulationChange();
initEdits();
}
});
......@@ -97,6 +96,14 @@ function initButtonsAction() {
$('#viewPostB').click(function () {
document.location.href = "viewpostulation.php";
});
$('#delPostB').click(function () {
if (confirm("Voulez-vous vraiment supprimer cette postulation ? \rCette action est irréversible !")) {
document.location.href = "viewpostulation.php?delete";
}
});
$('#editPost').click(function () {
document.location.href = "form.php?edit";
});
$('#infoFilieres').click(function () {
window.open("https://www.ict-berufsbildung.ch/fr/formation-professionnelle/formation-initiale-ict/", '_blank');
});
......@@ -254,69 +261,6 @@ function initPostulationChange() {
});
}
function initEdits() {
// init buttons
$('#delPostB').click(function () {
if (confirm("Voulez-vous vraiment supprimer cette postulation ? \rCette action est irréversible !")) {
document.location.href = "viewpostulation.php?delete";
}
});
// $.datepicker.setDefaults($.datepicker.regional["fr"]);
// $("#applicant_birthdate").datepicker({ minDate: '-60y', maxDate: '-13y', dateFormat: "dd/mm/yy" });
$('#editPost').click(function () {
document.location.href = "form.php?edit";
// $('#editPost').prop('disabled', true);
// $('#confirmEditPost').show();
// $('#cancelEditPost').show();
// // set inputs
// $('.postulationDataSpans').each(function () {
// $(this).hide();
// })
// $('.editPostInputs').each(function () {
// $(this).show();
// })
// if ($("#applicant_already_applicant_year").val() == '') {
// $("#applicant_already_applicant_year").hide();
// }
});
// $('#confirmEditPost').click(function () {
// });
// $('#cancelEditPost').click(function () {
// $('#editPost').prop('disabled', false);
// $('#confirmEditPost').hide();
// $('#cancelEditPost').hide();
// $('.postulationDataSpans').each(function () {
// $(this).show();
// })
// $('.editPostInputs').each(function () {
// $(this).hide();
// })
// });
// // deja cand switch
// $("#applicant_already_applicant1").click(function () {
// $("#applicant_already_applicant_year").val(null);
// $("#applicant_already_applicant_year").hide();
// })
// $("#applicant_already_applicant2").click(function () {
// $("#applicant_already_applicant_year").show();
// })
// hide default
// $('#confirmEditPost').hide();
// $('#cancelEditPost').hide();
// $('.editPostInputs').each(function () {
// $(this).hide();
// })
}
function checkRequired() {
$("form").submit(function (e) {
let errsNumber = 0;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment