This commit is contained in:
KANE LAZENI 2025-12-19 19:02:51 +00:00
parent 936378f55b
commit 5dcb666d6e
3 changed files with 11 additions and 23 deletions

View File

@ -33,26 +33,17 @@ class ControleurAjaxhistoriqueprestation extends Controleur {
public function prestations()
{
$numeroAdherent = $this->requete->getParametreFormulaire("numeroAdherent");
//$_SESSION['numeroBeneficiaire'] = $numeroBeneficiaire;
$codeGarantie = $this->requete->getParametreFormulaire("codeGarantie");
$d1 = $this->requete->getParametreDate("d1");
$d2 = $this->requete->getParametreDate("d2");
$garanties = $this->garantie->getListePourActe();
$historiqueprestations = $this->prestationactes->gethistoriqueprestation($numeroAdherent, $codeGarantie, $d1, $d2);
$totalprestations = $this->prestationactes->gettotalprestation($numeroAdherent, $codeGarantie, $d1, $d2);
$historiqueprestations = $this->prestationactes->gethistoriqueprestation($d1, $d2);
$totalprestations = $this->prestationactes->gettotalprestation($d1, $d2);
$this->genererVueAjax(array('garanties' => $garanties,'historiqueprestations' => $historiqueprestations,
'totalprestations' => $totalprestations));
}
public function majquantite()

View File

@ -16956,15 +16956,12 @@ function afficherMasquerGaranties()
}
function afficherhistoriqueadherent(numeroAdherent){
debugger;
function afficherhistoriqueadherent()
{
d1=$("#d1").val();
d2=$("#d2").val();
codeGarantie=$("#codeGarantie").val();
donnees = "numeroAdherent="+numeroAdherent+"&codeGarantie="+codeGarantie;
donnees += '&d1='+d1+'&d2='+d2;
donnees = 'd1='+d1+'&d2='+d2;
$("#div_prestation").html('<div class="spinner-responsive">' + '<span><i class="fa fa-spinner"></i></span>' + '</div>');

View File

@ -378,20 +378,20 @@ class Prestationactes extends Modele {
}
public function gethistoriqueprestation($numeroAdherent, $d1, $d2)
public function gethistoriqueprestation($d1, $d2)
{
$sql = 'call sp_a_get_historique_prestation_adherent(?, ?, ?);';
$resultat = $this->executerRequete($sql, array($numeroAdherent, $d1, $d2));
$resultat = $this->executerRequete($sql, array($_SESSION['idAdherent_C'], $d1, $d2));
return $resultat->fetchAll(PDO::FETCH_ASSOC);
}
public function gettotalprestation($numeroAdherent, $codeGarantie, $d1, $d2)
public function gettotalprestation($d1, $d2)
{
$sql = 'call sp_get_total_historique_prestation_adherent(?, ?, ?, ?);';
$sql = 'call sp_get_total_historique_prestation_adherent(?, ?, ?);';
$resultat = $this->executerRequete($sql, array($numeroAdherent, $codeGarantie, $d1, $d2));
$resultat = $this->executerRequete($sql, array($_SESSION['idAdherent_C'], $d1, $d2));
return $resultat->fetch(PDO::FETCH_ASSOC);
}