prestation/Controleur/ControleurAjaxmajcheancier.php
2025-12-05 10:42:46 +00:00

54 lines
1.8 KiB
PHP
Executable File

<?php
require_once 'Framework/Controleur.php';
require_once 'Modele/Echeancier_temp.php';
class ControleurAjaxmajcheancier extends Controleur {
private $echeancier_temp;
public function __construct() {
$this->echeancier_temp = new Echeancier_temp();
}
public function index()
{
$idEmission = $_SESSION['idEmission_temp'];
$codeTypeEcheancier = $this->requete->getParametreFormulaire("codeTypeEcheancier");
$nbEcheance = $this->requete->getParametreFormulaire("nbEcheance");
$tauxInteret = $this->requete->getParametreFormulaire("tauxInteret");
$this->echeancier_temp->majEcheancier_temp($idEmission, $codeTypeEcheancier, $nbEcheance, $tauxInteret);
}
public function enregistrer()
{
$idEmission = $_SESSION['idEmission_temp'];
$this->echeancier_temp->enregistrer($idEmission);
$this->rediriger("Facturerpolice");
}
public function majlibelle()
{
$idEcheancier = $this->requete->getParametreFormulaire("idEcheancier");
$libelleEcheance = $this->requete->getParametreFormulaire("libelleEcheance");
$this->echeancier_temp->majlibelle($idEcheancier, $libelleEcheance);
}
public function majdatepaiement()
{
$idEcheancier = $this->requete->getParametreFormulaire("idEcheancier");
$datePaiement = $this->requete->getParametreDate("datePaiement");
$this->echeancier_temp->majdatepaiement($idEcheancier, $datePaiement);
}
public function majtauxecheance()
{
$idEcheancier = $this->requete->getParametreFormulaire("idEcheancier");
$tauxEcheance = $this->requete->getParametreFormulaire("tauxEcheance");
$nbEcheance = $this->requete->getParametreFormulaire("nbEcheance");
$this->echeancier_temp->majtauxecheance($idEcheancier, $tauxEcheance, $nbEcheance);
}
}