Line 64... |
Line 64... |
64 |
*@param identifiant utilisateur.
|
64 |
*@param identifiant utilisateur.
|
65 |
*/
|
65 |
*/
|
66 |
function recupererTableauPreferences()
|
66 |
function recupererTableauPreferences()
|
67 |
{
|
67 |
{
|
68 |
$table = array();
|
68 |
$table = array();
|
69 |
$requete = "SELECT P.".GEST_CHAMPS_ID_PROJET.", P.".GEST_CHAMPS_NOM_PROJET." ,C.".GEST_CHAMPS_ID_CATEGORIE.",C.".GEST_CHAMPS_LIBELLE_CATEGORIE.
|
69 |
$requete = 'SELECT P.gp_id_projet, P.gp_nom_projet , C.gc_id_categorie, C.gc_libelle_categorie '.
|
70 |
" FROM ".GEST_PREFERENCES." F, ".GEST_PROJET." P,".GEST_CATEGORIE." C".
|
70 |
'FROM gestion_preferences F, gestion_projet P, gestion_categorie C '.
|
71 |
" WHERE ".GEST_CHAMPS_ID_UTILISATEUR. " = $this->_utilisateur".
|
71 |
'WHERE gp_id_utilisateur = '.$this->_utilisateur.' '.
|
72 |
" AND F.".GEST_CHAMPS_ID_PROJET." = P.".GEST_CHAMPS_ID_PROJET.
|
72 |
'AND F.gp_id_projet = P.gp_id_projet '.
|
73 |
" AND P.".GEST_CHAMPS_ID_CATEGORIE." = C.".GEST_CHAMPS_ID_CATEGORIE.
|
73 |
'AND P.gc_id_categorie = C.gc_id_categorie '.
|
74 |
" ORDER BY ".GEST_CHAMPS_LIBELLE_CATEGORIE;
|
74 |
'ORDER BY gc_libelle_categorie ';
|
75 |
$resultat = $GLOBALS['db']->query($requete);
|
75 |
$resultat = $GLOBALS['db']->query($requete);
|
Line 76... |
Line 76... |
76 |
|
76 |
|
Line 77... |
Line 77... |
77 |
(DB::isError($resultat)) ? die (BOG_afficherErreurSql(__FILE__, __LINE__, $resultat->getMessage(), $requete)) : '' ;
|
77 |
(DB::isError($resultat)) ? die (BOG_afficherErreurSql(__FILE__, __LINE__, $resultat->getMessage(), $requete)) : '' ;
|
Line 86... |
Line 86... |
86 |
/**
|
86 |
/**
|
87 |
*supprimer liste de preferences
|
87 |
*supprimer liste de preferences
|
88 |
*pour un utilisateur donne
|
88 |
*pour un utilisateur donne
|
89 |
*@param identifiant d'un utilisateur
|
89 |
*@param identifiant d'un utilisateur
|
90 |
*/
|
90 |
*/
|
91 |
|
- |
|
92 |
function supprimerPreferences($id)
|
91 |
function supprimerPreferences($id)
|
93 |
{
|
92 |
{
|
94 |
$requete = 'DELETE FROM '.GEST_PREFERENCES.' '.
|
93 |
$requete = 'DELETE FROM '.GEST_PREFERENCES.' '.
|
95 |
'WHERE '.GEST_CHAMPS_ID_UTILISATEUR.' = '.$id;
|
94 |
'WHERE '.GEST_CHAMPS_ID_UTILISATEUR.' = '.$id;
|
96 |
$resultat = $GLOBALS['db']->query($requete);
|
95 |
$resultat = $GLOBALS['db']->query($requete);
|