production/Controleur/ControleurAjaxexclusiondecompteobs.php
2025-12-02 11:29:44 +00:00

61 lines
2.1 KiB
PHP
Executable File

<?php
require_once 'Framework/Controleur.php';
require_once 'Modele/Motifecxlusionprestation.php';
class ControleurAjaxexclusiondecompteobs extends Controleur {
private $exclusionsDecompte;
public function __construct() {
$this->exclusionsDecompte = new Motifecxlusionprestation();
//$this->reglement = new Motifecxlusionprestation();
}
public function index() {
$idFacture = $this->requete->getParametreFormulaire("idFacture");
$numeroLotDecompte = $this->requete->getParametreFormulaire("numeroLotDecompte");
$numeroDecompte = $this->requete->getParametreFormulaire("numeroDecompte");
$motifrejets = $this->exclusionsDecompte->getListe();
$numeroDecompte = $_SESSION['numeroDecompte_C'];
$numeroLotDecompte = $_SESSION['numeroLotDecompte_C'];
$idReglement = $_SESSION['idReglement_C'];
$motifrejetsAll = $this->exclusionsDecompte->getMotifDecomptesObs($numeroDecompte);
//highlight_string("<?php\n\$datas =\n" . var_export($motifrejetsAll , true) . ";\n>");
//die();
$this->genererVueAjax(array('motifrejets' => $motifrejets,'idFacture' => $idFacture,
'numeroLotDecompte' => $numeroLotDecompte,'numeroDecompte' => $numeroDecompte,'motifrejetsAll' => $motifrejetsAll));
}
public function majmotifdecompteobs()
{
//$idFacture = $this->requete->getParametreFormulaire("idFacture");
$codeMotifRejet = $this->requete->getParametreFormulaire("codeMotifRejet");
$numeroLotDecompte = $this->requete->getParametreFormulaire("numeroLotDecompte");
$numeroDecompte = $this->requete->getParametreFormulaire("numeroDecompte");
$motifManuel = $this->requete->getParametreFormulaire("motifManuel");
$this->exclusionsDecompte->majobservationsobs( $codeMotifRejet,$numeroLotDecompte,$numeroDecompte ,$motifManuel);
$this->rediriger("Decompte");
}
public function supprimermotifDecompte()
{
$idMotifDecompte = $this->requete->getParametreFormulaire("idMotifDecompte");
$this->exclusionsDecompte->supprimermotifDecompte($idMotifDecompte);
}
}