a
This commit is contained in:
101
Js/fonctions.js
101
Js/fonctions.js
@@ -16233,56 +16233,6 @@ async function valider_selection_examen_cso() {
|
||||
}
|
||||
}
|
||||
|
||||
// Fonction appelée lorsqu’on veut indiquer qu’il n’y a pas de prescription pour un patient
|
||||
function no_presciption()
|
||||
{
|
||||
const facture = $("#facture").val();
|
||||
const contestation = $("#contestation").val();
|
||||
|
||||
// Si la facture est déjà émise, on affiche une alerte et on arrête
|
||||
if (facture == "1") {
|
||||
const v_msg = "D\u00e9jà factur\u00e9!";
|
||||
const v_msgEng = "Already charged!";
|
||||
alert_ebene(v_msg, v_msgEng);
|
||||
return;
|
||||
}
|
||||
|
||||
// Si le dossier est contesté, on empêche la validation
|
||||
if (contestation == "1") {
|
||||
const v_msg = "Dossier médical contest\u00e9 !";
|
||||
const v_msgEng = "Medical records contested!";
|
||||
alert_ebene(v_msg, v_msgEng);
|
||||
return;
|
||||
}
|
||||
|
||||
const numOrd = $("#numOrd").val();
|
||||
const noPrescription = $("#noPrescription").val();
|
||||
|
||||
// Si aucune ordonnance ni indication "pas de prescription"
|
||||
if (numOrd == "0" && noPrescription == "0") {
|
||||
const v_msg = "Confirmez-vous qu'il n'y a pas de prescription de m\u00e9dicaments?";
|
||||
const v_msgEng = "Do you confirm that there is no drugs prescription?";
|
||||
const codeLangue = $("#codeLangue").val();
|
||||
|
||||
// Appel d'une boîte de confirmation personnalisée, adaptée à la langue
|
||||
confirm_ebene_sweet(
|
||||
v_msg, v_msgEng,
|
||||
() => { // Callback exécuté en cas de confirmation "Oui/Yes"
|
||||
$.ajax({
|
||||
url: $("#racineWeb").val() + "Ajaxenregistrerprescription/noprescription/",
|
||||
type: 'post',
|
||||
error: function(errorData) {},
|
||||
success: function(data) {},
|
||||
complete: function() {
|
||||
feuillemaladie(); // Rechargement de la feuille de maladie
|
||||
}
|
||||
});
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
function prescrire_verre_opt()
|
||||
{
|
||||
// Ajout à la prescription
|
||||
@@ -28821,3 +28771,54 @@ async function supprimer_acte_medical_selection(idPrestationactes, codeTypePrest
|
||||
// Gestion supplémentaire des erreurs pourrait être ajoutée ici
|
||||
}
|
||||
}
|
||||
|
||||
// Fonction appelée lorsqu’on veut indiquer qu’il n’y a pas de prescription pour un patient
|
||||
function no_presciption()
|
||||
{
|
||||
const facture = $("#facture").val();
|
||||
const contestation = $("#contestation").val();
|
||||
|
||||
// Si la facture est déjà émise, on affiche une alerte et on arrête
|
||||
if (facture == "1") {
|
||||
const v_msg = "D\u00e9jà factur\u00e9!";
|
||||
const v_msgEng = "Already charged!";
|
||||
alert_ebene(v_msg, v_msgEng);
|
||||
return;
|
||||
}
|
||||
|
||||
// Si le dossier est contesté, on empêche la validation
|
||||
if (contestation == "1") {
|
||||
const v_msg = "Dossier médical contest\u00e9 !";
|
||||
const v_msgEng = "Medical records contested!";
|
||||
alert_ebene(v_msg, v_msgEng);
|
||||
return;
|
||||
}
|
||||
|
||||
const numOrd = $("#numOrd").val();
|
||||
const noPrescription = $("#noPrescription").val();
|
||||
|
||||
alert("numOrd = "+numOrd+" ; noPrescription = "+noPrescription);
|
||||
|
||||
// Si aucune ordonnance ni indication "pas de prescription"
|
||||
if (numOrd == "0" && noPrescription == "0") {
|
||||
const v_msg = "Confirmez-vous qu'il n'y a pas de prescription de m\u00e9dicaments?";
|
||||
const v_msgEng = "Do you confirm that there is no drugs prescription?";
|
||||
const codeLangue = $("#codeLangue").val();
|
||||
|
||||
// Appel d'une boîte de confirmation personnalisée, adaptée à la langue
|
||||
confirm_ebene_sweet(
|
||||
v_msg, v_msgEng,
|
||||
() => { // Callback exécuté en cas de confirmation "Oui/Yes"
|
||||
$.ajax({
|
||||
url: $("#racineWeb").val() + "Ajaxenregistrerprescription/noprescription/",
|
||||
type: 'post',
|
||||
error: function(errorData) {},
|
||||
success: function(data) {},
|
||||
complete: function() {
|
||||
feuillemaladie(); // Rechargement de la feuille de maladie
|
||||
}
|
||||
});
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user