You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
ProjetPHP/controller/CtrlUser.php

55 lines
1.2 KiB

<?php
class CtrlUser
{
private $model;
private $view;
private $con;
public function __construct(TaskModel $model, HomeView $view,
Connection $con){
session_start();
$this->model = $model;
$this->view = $view;
$this->con = $con;
}
try{
$action=$_REQUEST['action'];
switch($action){
// pas d'action afficher la home page avec toutes les listes
case NULL:
$this->home();
break;
// ajouter une liste publique
case 'creer_liste_pub'
$this->newList('private');
break;
// ajouter une liste privee
case 'creer_liste_priv'
$this->newList('public');
break;
// supprimer une liste
case 'supprimer_liste'
$this->delList();
break;
// changer nom de la liste
case 'changer_nom'
$this->changeListName();
break;
// ajouter une tache
// completer tache
}
}
}
?>