33 lines
971 B
PHP
Executable File
33 lines
971 B
PHP
Executable File
<?php
|
|
require_once 'Framework/Controleur.php';
|
|
require_once 'Modele/Profil.php';
|
|
require_once 'Modele/Menuvueutilisateur.php';
|
|
|
|
class ControleurListeprofil extends Controleur {
|
|
private $menuvue;
|
|
|
|
private $profil;
|
|
|
|
public function __construct() {
|
|
$this->menuvue = new Menuvueutilisateur();
|
|
$this->menuvue->getMenuVue('Listeprofil');
|
|
|
|
$this->profil = new Profil();
|
|
}
|
|
|
|
public function index($codesearch="",$libellesearch="") {
|
|
if (isset($_POST['codesearch']))
|
|
{
|
|
$codesearch=$_POST['codesearch'];
|
|
$libellesearch=$_POST['libellesearch'];
|
|
}
|
|
$profils = $this->profil->getProfils($codesearch,$libellesearch);
|
|
$this->genererVue(array('profils' => $profils, 'codesearch' => $codesearch, 'libellesearch' => $libellesearch));
|
|
}
|
|
|
|
public function supprimer() {
|
|
$id = $this->requete->getParametre("id");
|
|
$this->profil->supprimer($id);
|
|
$this->rediriger("Listeprofil");
|
|
}
|
|
} |