Initial commit for radiantprestation project
This commit is contained in:
198
Modele/Seance_temp.php
Normal file
198
Modele/Seance_temp.php
Normal file
@@ -0,0 +1,198 @@
|
||||
<?php
|
||||
require_once 'Framework/Modele.php';
|
||||
|
||||
class Seance_temp extends Modele {
|
||||
|
||||
public function getseancetemp()
|
||||
{
|
||||
$numeroFeuilleMaladie = $_SESSION['p_numeroFeuilleMaladie_C'];
|
||||
$idSaisie = $_SESSION['p_idSaisie'];
|
||||
$user = $_SESSION['p_login'];
|
||||
|
||||
$sql = 'call sp_p_get_seance_feuille(?, ?, ?)';
|
||||
|
||||
$resultat = $this->executerRequete($sql, array($numeroFeuilleMaladie, $idSaisie, $user));
|
||||
|
||||
return $resultat->fetch(PDO::FETCH_ASSOC);
|
||||
}
|
||||
|
||||
public function getprescription_sea($numeroBonKine)
|
||||
{
|
||||
$idSaisie = $_SESSION['p_idSaisie'];
|
||||
$user = $_SESSION['p_login'];
|
||||
|
||||
$sql = 'call sp_p_get_prescription_temp_sea(?, ?, ?)';
|
||||
|
||||
$prescription = $this->executerRequete($sql, array($numeroBonKine, $idSaisie, $user));
|
||||
|
||||
$ligne = $prescription->fetch(PDO::FETCH_ASSOC);
|
||||
$_SESSION['p_numeroBonKine_C'] = $ligne['numeroBonKine'];
|
||||
$_SESSION['p_numeroPrescriptionKine_C'] = $ligne['numeroPrescriptionKine'];
|
||||
$_SESSION['p_numeroFeuilleMaladie_C'] = $ligne['numeroFeuilleMaladie'];
|
||||
|
||||
return $ligne;
|
||||
}
|
||||
|
||||
public function attributionbontemporaire($numeroBonSeance, $codeGestionBon)
|
||||
{
|
||||
$numeroFeuilleMaladie = $_SESSION['p_numeroFeuilleMaladie_C'];
|
||||
$idSaisie = $_SESSION['p_idSaisie'];
|
||||
$user = $_SESSION['p_login'];
|
||||
|
||||
$sql = 'call sp_p_attrubuer_bon_seance_kine(?, ?, ?, ?, ?)';
|
||||
|
||||
$this->executerRequete($sql, array($numeroFeuilleMaladie, $idSaisie, $user, $numeroBonSeance, $codeGestionBon));
|
||||
}
|
||||
|
||||
public function getContexteAjaxOptique($numeroExamen)
|
||||
{
|
||||
$_SESSION['p_numeroExamen_C'] = $numeroExamen;
|
||||
}
|
||||
|
||||
public function enregistrerprescriptionseance($numeroBonKine, $codeMedecin, $codeGestionBon)
|
||||
{
|
||||
$codeSociete = $_SESSION['p_codeSociete'];
|
||||
$numeroFeuilleMaladie = $_SESSION['p_numeroFeuilleMaladie_C'];
|
||||
$idSaisie = $_SESSION['p_idSaisie'];
|
||||
$user = $_SESSION['p_login'];
|
||||
$idBeneficiaire = $_SESSION['p_idBeneficiaire_C'];
|
||||
|
||||
$sql = 'call sp_p_enregistrer_prescription_seance(?, ?, ?, ?, ?, ?, ?, ?)';
|
||||
|
||||
$this->executerRequete($sql, array($codeSociete, $idBeneficiaire, $numeroFeuilleMaladie, $numeroBonKine, $codeMedecin,
|
||||
$user, $idSaisie, $codeGestionBon));
|
||||
}
|
||||
|
||||
|
||||
public function modifierprescriptionseance($codeActePrescription, $quantite, $prixActe, $montantTm, $montantArembourser,
|
||||
$fraisReel, $ententePrealable)
|
||||
{
|
||||
$numeroFeuilleMaladie = $_SESSION['p_numeroFeuilleMaladie_C'];
|
||||
$idSaisie = $_SESSION['p_idSaisie'];
|
||||
$user = $_SESSION['p_login'];
|
||||
$tm = $_SESSION['p_tm_C'];
|
||||
|
||||
$sql = 'call sp_p_modifier_prescription_seance(?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)';
|
||||
|
||||
$this->executerRequete($sql, array($numeroFeuilleMaladie, $codeActePrescription, $quantite, $user, $idSaisie, $tm,
|
||||
$prixActe, $montantTm, $montantArembourser, $fraisReel, $ententePrealable));
|
||||
}
|
||||
|
||||
public function modifierseancecso($quantite, $fraisReel, $montantTm, $montantArembourser)
|
||||
{
|
||||
$numeroFeuilleMaladie = $_SESSION['p_numeroFeuilleMaladie_C'];
|
||||
$idSaisie = $_SESSION['p_idSaisie'];
|
||||
$user = $_SESSION['p_login'];
|
||||
|
||||
$sql = 'call sp_p_modifier_seance_cso(?, ?, ?, ?, ?, ?, ?)';
|
||||
|
||||
$this->executerRequete($sql, array($numeroFeuilleMaladie, $user, $idSaisie, $quantite, $fraisReel, $montantTm, $montantArembourser));
|
||||
}
|
||||
|
||||
|
||||
public function modifierseancesea($codeActe, $quantite)
|
||||
{
|
||||
$codeTarifActe = $_SESSION['p_codeTarifActe_C'];
|
||||
$numeroPrescriptionKine = $_SESSION['p_numeroPrescriptionKine_C'];
|
||||
$user = $_SESSION['p_login'];
|
||||
$idSaisie = $_SESSION['p_idSaisie'];
|
||||
$tm = $_SESSION['p_tm_C'];
|
||||
$codePrestataire = $_SESSION['p_codePrestataire_C'];
|
||||
|
||||
$sql = 'call sp_p_modifier_seance_sea(?, ?, ?, ?, ?, ?, ?, ?);';
|
||||
|
||||
$this->executerRequete($sql, array($codeTarifActe, $numeroPrescriptionKine, $codeActe, $user, $idSaisie, $tm, $quantite, $codePrestataire));
|
||||
}
|
||||
|
||||
public function initseance_cso()
|
||||
{
|
||||
$codePrestataire = $_SESSION['p_codePrestataire_C'];
|
||||
$numeroFeuilleMaladie = $_SESSION['p_numeroFeuilleMaladie_C'];
|
||||
$idSaisie = $_SESSION['p_idSaisie'];
|
||||
$user = $_SESSION['p_login'];
|
||||
$tm = $_SESSION['p_tm_C'];
|
||||
|
||||
$sql = 'call sp_p_init_seance_cso(?, ?, ?, ?, ?)';
|
||||
|
||||
$this->executerRequete($sql, array($codePrestataire, $idSaisie, $numeroFeuilleMaladie, $user, $tm));
|
||||
}
|
||||
|
||||
public function initseancekine_cso($codeGestionBon)
|
||||
{
|
||||
$codePrestataire = $_SESSION['p_codePrestataire_C'];
|
||||
$numeroPrescriptionKine = $_SESSION['p_numeroPrescriptionKine_C'];
|
||||
$idSaisie = $_SESSION['p_idSaisie'];
|
||||
$user = $_SESSION['p_login'];
|
||||
|
||||
$codeTarifActe = $_SESSION['p_codeTarifActe_C'];
|
||||
$tm = $_SESSION['p_tm_C'];
|
||||
|
||||
$sql = 'call sp_p_init_seance_kine_cso(?, ?, ?, ?, ?, ?, ?)';
|
||||
|
||||
$this->executerRequete($sql, array($codePrestataire, $idSaisie, $numeroPrescriptionKine, $user, $codeTarifActe, $tm, $codeGestionBon));
|
||||
}
|
||||
|
||||
public function initseancekine_sea($codeGestionBon)
|
||||
{
|
||||
$codePrestataire = $_SESSION['p_codePrestataire_C'];
|
||||
$numeroBonKine = $_SESSION['p_numeroBonKine_C'];
|
||||
$idSaisie = $_SESSION['p_idSaisie'];
|
||||
$user = $_SESSION['p_login'];
|
||||
|
||||
$codeTarifActe = $_SESSION['p_codeTarifActe_C'];
|
||||
$tm = $_SESSION['p_tm_C'];
|
||||
|
||||
$sql = 'call sp_p_init_seance_kine_sea(?, ?, ?, ?, ?, ?, ?)';
|
||||
|
||||
$this->executerRequete($sql, array($codePrestataire, $idSaisie, $numeroBonKine, $user, $codeTarifActe, $tm, $codeGestionBon));
|
||||
}
|
||||
|
||||
public function getContexteAjaxPrescription($numeroExamen)
|
||||
{
|
||||
$_SESSION['p_numeroExamen_C'] = $numeroExamen;
|
||||
}
|
||||
|
||||
public function getContexteAjaxOrdonnance($numeroBonExamen)
|
||||
{
|
||||
$_SESSION['p_numeroBonExamen_C'] = $numeroBonExamen;
|
||||
}
|
||||
|
||||
public function enregistrerseance($codeGestionBon)
|
||||
{
|
||||
$numeroPrescriptionKine = $_SESSION['p_numeroPrescriptionKine_C'];
|
||||
$idSaisie = $_SESSION['p_idSaisie'];
|
||||
$user = $_SESSION['p_login'];
|
||||
|
||||
$idAdherent = $_SESSION['p_idAdherent_C'];
|
||||
$numeroAdherent = $_SESSION['p_numeroAdherent_C'];
|
||||
$idBeneficiaire = $_SESSION['p_idBeneficiaire_C'];
|
||||
$numeroBeneficiaire = $_SESSION['p_numeroBeneficiaire_C'];
|
||||
|
||||
$sql = 'call sp_p_enregistrer_seance_cso(?, ?, ?, ?, ?, ?, ?, ?)';
|
||||
|
||||
$this->executerRequete($sql, array($numeroPrescriptionKine, $idSaisie, $user, $idAdherent, $numeroAdherent,
|
||||
$idBeneficiaire, $numeroBeneficiaire, $codeGestionBon));
|
||||
}
|
||||
|
||||
public function facturerseance($user_id_substitut, $codeGestionBon)
|
||||
{
|
||||
$numeroPrescriptionKine = $_SESSION['p_numeroPrescriptionKine_C'];
|
||||
$idSaisie = $_SESSION['p_idSaisie'];
|
||||
$user = $_SESSION['p_login'];
|
||||
|
||||
$user_id = $_SESSION['p_user_id_C'];
|
||||
|
||||
$idAdherent = $_SESSION['p_idAdherent_C'];
|
||||
$numeroAdherent = $_SESSION['p_numeroAdherent_C'];
|
||||
$idBeneficiaire = $_SESSION['p_idBeneficiaire_C'];
|
||||
$numeroBeneficiaire = $_SESSION['p_numeroBeneficiaire_C'];
|
||||
|
||||
$sql = 'call sp_p_enregistrer_seance_sea(?, ?, ?, ?, ? , ?, ?, ?, ?, ?)';
|
||||
|
||||
$this->executerRequete($sql, array($numeroPrescriptionKine, $idSaisie, $user, $user_id, $idAdherent, $numeroAdherent,
|
||||
$idBeneficiaire, $numeroBeneficiaire, $user_id_substitut, $codeGestionBon));
|
||||
|
||||
$_SESSION['p_okId'] = "-1";
|
||||
$_SESSION['p_okId_face'] = "-1";
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user