/trunk/bibliotheque/metier/NoteFraisLigne.class.php |
---|
1,69 → 1,69 |
<?php |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// CVS : $Id$ |
/** |
/** |
* Classe NoteFraisLigne |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
*@version $Revision$ $Date$ |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class NoteFraisLigne : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class NoteFraisLigne extends aGttSql { |
/*** Constantes : */ |
const GNFL_ID = 'NOTEFRAISLIGNE_ID'; |
const GNFL_ID_MAX = 'NOTEFRAISLIGNE_ID_MAX'; |
/*** Attributs : */ |
private $id_note_frais_ligne; |
private $ce_note_frais; |
private $date; |
private $montant_ht; |
private $taux_tva; |
private $montant_ttc; |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = 'gestion_note_frais_ligne'; |
$this->dao_correspondance = array( |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class NoteFraisLigne : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class NoteFraisLigne extends aGttSql { |
/*** Constantes : */ |
const GNFL_ID = 'NOTEFRAISLIGNE_ID'; |
const GNFL_ID_MAX = 'NOTEFRAISLIGNE_ID_MAX'; |
/*** Attributs : */ |
private $id_note_frais_ligne; |
private $ce_note_frais; |
private $date; |
private $montant_ht; |
private $taux_tva; |
private $montant_ttc; |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = GTT_BDD_PREFIXE . 'gestion_note_frais_ligne'; |
$this->dao_correspondance = array( |
'gnfl_id_note_frais_ligne' => 'id_note_frais_ligne', |
'gnfl_ce_note_frais' => 'ce_note_frais', |
'gnfl_date' => 'date', |
70,105 → 70,105 |
'gnfl_montant_ht' => 'montant_ht', |
'gnfl_taux_tva' => 'taux_tva', |
'gnfl_montant_ttc' => 'montant_ttc'); |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Id Note Frais Ligne |
public function getIdNoteFraisLigne() |
{ |
return $this->id_note_frais_ligne; |
} |
public function setIdNoteFraisLigne( $infl ) |
{ |
$this->id_note_frais_ligne = $infl; |
} |
public function getIdNoteFraisLigne() |
{ |
return $this->id_note_frais_ligne; |
} |
public function setIdNoteFraisLigne( $infl ) |
{ |
$this->id_note_frais_ligne = $infl; |
} |
// Ce Note Frais |
public function getCeNoteFrais() |
{ |
return $this->ce_note_frais; |
} |
public function setCeNoteFrais( $cnf ) |
{ |
$this->ce_note_frais = $cnf; |
} |
public function getCeNoteFrais() |
{ |
return $this->ce_note_frais; |
} |
public function setCeNoteFrais( $cnf ) |
{ |
$this->ce_note_frais = $cnf; |
} |
// Date |
public function getDate() |
{ |
return $this->date; |
} |
public function setDate( $d ) |
{ |
$this->date = $d; |
} |
public function getDate() |
{ |
return $this->date; |
} |
public function setDate( $d ) |
{ |
$this->date = $d; |
} |
// Montant Ht |
public function getMontantHt() |
{ |
return $this->montant_ht; |
} |
public function setMontantHt( $mh ) |
{ |
$this->montant_ht = $mh; |
} |
public function getMontantHt() |
{ |
return $this->montant_ht; |
} |
public function setMontantHt( $mh ) |
{ |
$this->montant_ht = $mh; |
} |
// Taux Tva |
public function getTauxTva() |
{ |
return $this->taux_tva; |
} |
public function setTauxTva( $tt ) |
{ |
$this->taux_tva = $tt; |
} |
public function getTauxTva() |
{ |
return $this->taux_tva; |
} |
public function setTauxTva( $tt ) |
{ |
$this->taux_tva = $tt; |
} |
// Montant Ttc |
public function getMontantTtc() |
{ |
return $this->montant_ttc; |
} |
public function setMontantTtc( $mt ) |
{ |
$this->montant_ttc = $mt; |
} |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_note_frais_ligne. |
* @return mixed un tableau d'objets NoteFraisLigne s'il y en a plusieurs, l'objet NoteFraisLigne s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
{ |
switch ($cmd) { |
case NoteFraisLigne::GNFL_ID: |
$requete = 'SELECT * '. |
'FROM gestion_note_frais_ligne '. |
'WHERE gnfl_id_note_frais_ligne = #0 '; |
break; |
case NoteFraisLigne::GNFL_ID_MAX: |
$requete = 'SELECT MAX(gnfl_id_note_frais_ligne) '. |
'FROM gestion_note_frais_ligne '; |
break; |
default : |
$message = 'Commande '.$cmd.'inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
public function getMontantTtc() |
{ |
return $this->montant_ttc; |
} |
public function setMontantTtc( $mt ) |
{ |
$this->montant_ttc = $mt; |
} |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_note_frais_ligne. |
* @return mixed un tableau d'objets NoteFraisLigne s'il y en a plusieurs, l'objet NoteFraisLigne s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
{ |
switch ($cmd) { |
case NoteFraisLigne::GNFL_ID: |
$requete = 'SELECT * '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_note_frais_ligne '. |
'WHERE gnfl_id_note_frais_ligne = #0 '; |
break; |
case NoteFraisLigne::GNFL_ID_MAX: |
$requete = 'SELECT MAX(gnfl_id_note_frais_ligne) '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_note_frais_ligne '; |
break; |
default : |
$message = 'Commande '.$cmd.'inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
return parent::consulter($requete, $parametres, $instancier); |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
* $Log$ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
?> |
/trunk/bibliotheque/metier/NoteFrais.class.php |
---|
1,138 → 1,138 |
<?php |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// CVS : $Id$ |
/** |
/** |
* Classe NoteFrais |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
*@version $Revision$ $Date$ |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class NoteFrais : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class NoteFrais extends aGttSql { |
/*** Constantes : */ |
const GNF_ID = 'NOTEFRAIS_ID'; |
const GNF_ID_MAX = 'NOTEFRAIS_ID_MAX'; |
/*** Attributs : */ |
private $id_note_frais; |
private $ce_utilisateur; |
private $libelle; |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = 'gestion_note_frais'; |
$this->dao_correspondance = array( |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class NoteFrais : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class NoteFrais extends aGttSql { |
/*** Constantes : */ |
const GNF_ID = 'NOTEFRAIS_ID'; |
const GNF_ID_MAX = 'NOTEFRAIS_ID_MAX'; |
/*** Attributs : */ |
private $id_note_frais; |
private $ce_utilisateur; |
private $libelle; |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = GTT_BDD_PREFIXE . 'gestion_note_frais'; |
$this->dao_correspondance = array( |
'gnf_id_note_frais' => 'id_note_frais', |
'gnf_ce_utilisateur' => 'ce_utilisateur', |
'gnf_libelle' => 'libelle'); |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Id Note Frais |
public function getIdNoteFrais() |
{ |
return $this->id_note_frais; |
} |
public function setIdNoteFrais( $inf ) |
{ |
$this->id_note_frais = $inf; |
} |
public function getIdNoteFrais() |
{ |
return $this->id_note_frais; |
} |
public function setIdNoteFrais( $inf ) |
{ |
$this->id_note_frais = $inf; |
} |
// Ce Utilisateur |
public function getCeUtilisateur() |
{ |
return $this->ce_utilisateur; |
} |
public function setCeUtilisateur( $cu ) |
{ |
$this->ce_utilisateur = $cu; |
} |
public function getCeUtilisateur() |
{ |
return $this->ce_utilisateur; |
} |
public function setCeUtilisateur( $cu ) |
{ |
$this->ce_utilisateur = $cu; |
} |
// Libelle |
public function getLibelle() |
{ |
return $this->libelle; |
} |
public function setLibelle( $l ) |
{ |
$this->libelle = $l; |
} |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_note_frais. |
* @return mixed un tableau d'objets NoteFrais s'il y en a plusieurs, l'objet NoteFrais s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
public function getLibelle() |
{ |
switch ($cmd) { |
case NoteFrais::GNF_ID: |
$requete = 'SELECT * '. |
'FROM gestion_note_frais '. |
'WHERE gnf_id_note_frais = #0 '; |
break; |
case NoteFrais::GNF_ID_MAX: |
$requete = 'SELECT MAX(gnf_id_note_frais) '. |
'FROM gestion_note_frais '; |
break; |
default : |
$message = 'Commande '.$cmd.'inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
return parent::consulter($requete, $parametres, $instancier); |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
return $this->libelle; |
} |
public function setLibelle( $l ) |
{ |
$this->libelle = $l; |
} |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_note_frais. |
* @return mixed un tableau d'objets NoteFrais s'il y en a plusieurs, l'objet NoteFrais s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
{ |
switch ($cmd) { |
case NoteFrais::GNF_ID: |
$requete = 'SELECT * '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_note_frais '. |
'WHERE gnf_id_note_frais = #0 '; |
break; |
case NoteFrais::GNF_ID_MAX: |
$requete = 'SELECT MAX(gnf_id_note_frais) '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_note_frais '; |
break; |
default : |
$message = 'Commande '.$cmd.'inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
return parent::consulter($requete, $parametres, $instancier); |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
* $Log$ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
?> |
/trunk/bibliotheque/metier/Utilisateur.class.php |
---|
1,72 → 1,72 |
<?php |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// CVS : $Id$ |
/** |
/** |
* Classe Utilisateur |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
*@version $Revision$ $Date$ |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class Utilisateur : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class Utilisateur extends aGttSql { |
/*** Constantes : */ |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class Utilisateur : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class Utilisateur extends aGttSql { |
/*** Constantes : */ |
const GU_TOUS = 'UTILISATEUR_TOUS'; |
const GU_ID = 'UTILISATEUR_ID'; |
const GU_ID = 'UTILISATEUR_ID'; |
const GU_ID_MAX = 'UTILISATEUR_ID_MAX'; |
const GU_CE_STATUT = 'UTILISATEUR_CE_STATUT'; |
const GU_MAIL = 'UTILISATEUR_MAIL'; |
const GU_TOUS_AFFICHABLE = 'UTILISATEUR_TOUS_AFFICHABLE'; |
const GU_ADMIN = 'UTILISATEUR_ADMIN'; |
/*** Attributs : */ |
private $id_utilisateur; |
private $ce_statut = 0; |
private $nom; |
private $prenom; |
private $password; |
private $email; |
private $telephone; |
private $adresse; |
private $code_postal; |
private $ville; |
private $quota_heures_supp = 0; |
private $conges_payes = 0; |
const GU_ADMIN = 'UTILISATEUR_ADMIN'; |
/*** Attributs : */ |
private $id_utilisateur; |
private $ce_statut = 0; |
private $nom; |
private $prenom; |
private $password; |
private $email; |
private $telephone; |
private $adresse; |
private $code_postal; |
private $ville; |
private $quota_heures_supp = 0; |
private $conges_payes = 0; |
private $temps_de_travail_jour = 7; |
private $temps_de_travail_mois = 0; |
private $tdt_lundi = 0; |
75,18 → 75,18 |
private $tdt_jeudi = 0; |
private $tdt_vendredi = 0; |
private $tdt_samedi = 0; |
private $tdt_dimanche = 0; |
private $mark_admin = 0; |
private $mark_recapitulatif = 1; |
private $notes; |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = 'gestion_utilisateur'; |
$this->dao_correspondance = array( |
private $tdt_dimanche = 0; |
private $mark_admin = 0; |
private $mark_recapitulatif = 1; |
private $notes; |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = GTT_BDD_PREFIXE . 'gestion_utilisateur'; |
$this->dao_correspondance = array( |
'gu_id_utilisateur' => 'id_utilisateur', |
'gu_ce_statut' => 'ce_statut', |
'gu_nom' => 'nom', |
111,152 → 111,152 |
'gu_mark_admin' => 'mark_admin', |
'gu_mark_recapitulatif' => 'mark_recapitulatif', |
'gu_notes' => 'notes'); |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Id Utilisateur |
public function getIdUtilisateur() |
{ |
return $this->id_utilisateur; |
} |
public function setIdUtilisateur( $iu ) |
{ |
$this->id_utilisateur = $iu; |
} |
public function getIdUtilisateur() |
{ |
return $this->id_utilisateur; |
} |
public function setIdUtilisateur( $iu ) |
{ |
$this->id_utilisateur = $iu; |
} |
// Gus Id Utilisateur Statut |
public function getCeStatut() |
{ |
return $this->ce_statut; |
} |
public function setCeStatut( $cs ) |
{ |
$this->ce_statut = $cs; |
} |
public function getCeStatut() |
{ |
return $this->ce_statut; |
} |
public function setCeStatut( $cs ) |
{ |
$this->ce_statut = $cs; |
} |
// Nom |
public function getNom() |
{ |
return $this->nom; |
} |
public function setNom( $n ) |
{ |
public function getNom() |
{ |
return $this->nom; |
} |
public function setNom( $n ) |
{ |
if (!is_null($n)) { |
$this->nom = strtoupper($n); |
} else { |
$this->nom = $n; |
} |
} |
} |
} |
// Prenom |
public function getPrenom() |
{ |
return $this->prenom; |
} |
public function setPrenom( $p ) |
{ |
$this->prenom = $p; |
} |
public function getPrenom() |
{ |
return $this->prenom; |
} |
public function setPrenom( $p ) |
{ |
$this->prenom = $p; |
} |
// Password |
public function getPassword() |
{ |
return $this->password; |
} |
public function setPassword( $p ) |
{ |
public function getPassword() |
{ |
return $this->password; |
} |
public function setPassword( $p ) |
{ |
if (!is_null($p)) { |
$this->password = md5($p); |
} else { |
$this->password = $p; |
} |
} |
} |
} |
public function getEmail() |
{ |
return $this->email; |
} |
public function setEmail( $e ) |
{ |
$this->email = $e; |
} |
public function getEmail() |
{ |
return $this->email; |
} |
public function setEmail( $e ) |
{ |
$this->email = $e; |
} |
// Telephone |
public function getTelephone() |
{ |
return $this->telephone; |
} |
public function setTelephone( $t ) |
{ |
$this->telephone = (string) $t; |
} |
public function getTelephone() |
{ |
return $this->telephone; |
} |
public function setTelephone( $t ) |
{ |
$this->telephone = (string) $t; |
} |
// Adresse |
public function getAdresse() |
{ |
return $this->adresse; |
} |
public function setAdresse( $a ) |
{ |
$this->adresse = $a; |
} |
public function getAdresse() |
{ |
return $this->adresse; |
} |
public function setAdresse( $a ) |
{ |
$this->adresse = $a; |
} |
// Code Postal |
public function getCodePostal() |
{ |
return $this->code_postal; |
} |
public function setCodePostal( $cp ) |
{ |
$this->code_postal = $cp; |
} |
public function getCodePostal() |
{ |
return $this->code_postal; |
} |
public function setCodePostal( $cp ) |
{ |
$this->code_postal = $cp; |
} |
// Ville |
public function getVille() |
{ |
return $this->ville; |
} |
public function setVille( $v ) |
{ |
$this->ville = $v; |
} |
public function getVille() |
{ |
return $this->ville; |
} |
public function setVille( $v ) |
{ |
$this->ville = $v; |
} |
// Quota Heures Supp |
public function getQuotaHeuresSupp() |
{ |
return $this->quota_heures_supp; |
} |
public function setQuotaHeuresSupp( $qhs ) |
{ |
$this->quota_heures_supp = $qhs; |
} |
public function getQuotaHeuresSupp() |
{ |
return $this->quota_heures_supp; |
} |
public function setQuotaHeuresSupp( $qhs ) |
{ |
$this->quota_heures_supp = $qhs; |
} |
// Conges Payes |
public function getCongesPayes() |
{ |
return $this->conges_payes; |
} |
public function setCongesPayes( $cp ) |
{ |
$this->conges_payes = $cp; |
} |
public function getCongesPayes() |
{ |
return $this->conges_payes; |
} |
public function setCongesPayes( $cp ) |
{ |
$this->conges_payes = $cp; |
} |
// Temps De Travail Jour |
public function getTempsDeTravailJour() |
{ |
return $this->temps_de_travail_jour; |
} |
public function setTempsDeTravailJour( $tdt ) |
{ |
$this->temps_de_travail_jour = $tdt; |
} |
public function getTempsDeTravailJour() |
{ |
return $this->temps_de_travail_jour; |
} |
public function setTempsDeTravailJour( $tdt ) |
{ |
$this->temps_de_travail_jour = $tdt; |
} |
// Temps De Travail Mois |
public function getTempsDeTravailMois() |
{ |
361,91 → 361,91 |
} |
// Mark Admin |
public function getMarkAdmin() |
{ |
return $this->mark_admin; |
} |
public function setMarkAdmin( $ma ) |
{ |
$this->mark_admin = $ma; |
} |
public function getMarkAdmin() |
{ |
return $this->mark_admin; |
} |
public function setMarkAdmin( $ma ) |
{ |
$this->mark_admin = $ma; |
} |
// Mark Recapitulatif |
public function getMarkRecapitulatif() |
{ |
return $this->mark_recapitulatif; |
} |
public function setMarkRecapitulatif( $mr ) |
{ |
$this->mark_recapitulatif = $mr; |
} |
public function getMarkRecapitulatif() |
{ |
return $this->mark_recapitulatif; |
} |
public function setMarkRecapitulatif( $mr ) |
{ |
$this->mark_recapitulatif = $mr; |
} |
// Notes |
public function getNotes() |
{ |
return $this->notes; |
} |
public function setNotes( $n ) |
{ |
$this->notes = $n; |
} |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_utilisateur. |
* @return mixed un tableau d'objets Utilisateur s'il y en a plusieurs, l'objet Utilisateur s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
{ |
switch ($cmd) { |
public function getNotes() |
{ |
return $this->notes; |
} |
public function setNotes( $n ) |
{ |
$this->notes = $n; |
} |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_utilisateur. |
* @return mixed un tableau d'objets Utilisateur s'il y en a plusieurs, l'objet Utilisateur s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
{ |
switch ($cmd) { |
case Utilisateur::GU_TOUS: |
$requete = 'SELECT * '. |
'FROM gestion_utilisateur '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_utilisateur '. |
'ORDER BY gu_nom, gu_prenom ASC'; |
break; |
case Utilisateur::GU_ID: |
$requete = 'SELECT * '. |
'FROM gestion_utilisateur '. |
'WHERE gu_id_utilisateur = #0 '; |
break; |
case Utilisateur::GU_ID_MAX: |
$requete = 'SELECT MAX(gu_id_utilisateur) AS gu_id_utilisateur '. |
'FROM gestion_utilisateur '; |
case Utilisateur::GU_ID: |
$requete = 'SELECT * '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_utilisateur '. |
'WHERE gu_id_utilisateur = #0 '; |
break; |
case Utilisateur::GU_ID_MAX: |
$requete = 'SELECT MAX(gu_id_utilisateur) AS gu_id_utilisateur '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_utilisateur '; |
break; |
case Utilisateur::GU_CE_STATUT: |
$requete = 'SELECT * '. |
'FROM gestion_utilisateur '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_utilisateur '. |
'WHERE gu_ce_statut = "#0" '; |
break; |
case Utilisateur::GU_MAIL: |
$requete = 'SELECT * '. |
'FROM gestion_utilisateur '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_utilisateur '. |
'WHERE gu_email = "#0" '; |
break; |
case Utilisateur::GU_TOUS_AFFICHABLE: |
$requete = 'SELECT * '. |
'FROM gestion_utilisateur '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_utilisateur '. |
'WHERE gu_mark_recapitulatif = 0 '. |
'ORDER BY gu_nom, gu_prenom ASC'; |
break; |
case Utilisateur::GU_ADMIN: |
$requete = 'SELECT * '. |
'FROM gestion_utilisateur '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_utilisateur '. |
'WHERE gu_mark_admin = 1 '; |
break; |
default : |
$message = 'Commande '.$cmd.'inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
return parent::consulter($requete, $parametres, $instancier); |
} |
default : |
$message = 'Commande '.$cmd.'inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
return parent::consulter($requete, $parametres, $instancier); |
} |
public function supprimer() |
{ |
$requete = 'DELETE FROM gestion_utilisateur '. |
$requete = 'DELETE FROM ' . GTT_BDD_PREFIXE . 'gestion_utilisateur '. |
'WHERE gu_id_utilisateur = '.$this->getIdUtilisateur(); |
$resultat = $GLOBALS['db']->query($requete); |
(DB::isError($resultat)) ? die (GestionnaireErreur::retournerErreurSql(__FILE__, __LINE__, $resultat->getMessage(), $requete)) : '' ; |
482,13 → 482,13 |
public function diminuerCongesPayes($nb) |
{ |
$this->conges_payes = $this->conges_payes - abs($nb); |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
* $Log$ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
?> |
/trunk/bibliotheque/metier/FraisKm.class.php |
---|
1,71 → 1,71 |
<?php |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// CVS : $Id$ |
/** |
/** |
* Classe FraisKm |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
*@version $Revision$ $Date$ |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class FraisKm : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class FraisKm extends aGttSql { |
/*** Constantes : */ |
const GFK_ID = 'FRAISKM_ID'; |
const GFK_ID_MAX = 'FRAISKM_ID_MAX'; |
/*** Attributs : */ |
private $id_frais_km; |
private $gfkt_id_frais_km_taux; |
private $ce_utilisateur; |
private $date; |
private $nbre_km; |
private $objet; |
private $trajet; |
private $montant_total; |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = 'gestion_frais_km'; |
$this->dao_correspondance = array( |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class FraisKm : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class FraisKm extends aGttSql { |
/*** Constantes : */ |
const GFK_ID = 'FRAISKM_ID'; |
const GFK_ID_MAX = 'FRAISKM_ID_MAX'; |
/*** Attributs : */ |
private $id_frais_km; |
private $gfkt_id_frais_km_taux; |
private $ce_utilisateur; |
private $date; |
private $nbre_km; |
private $objet; |
private $trajet; |
private $montant_total; |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = GTT_BDD_PREFIXE . 'gestion_frais_km'; |
$this->dao_correspondance = array( |
'gfk_id_frais_km' => 'id_frais_km', |
'gfkt_id_frais_km_taux' => 'gfkt_id_frais_km_taux', |
'gfk_ce_utilisateur' => 'ce_utilisateur', |
74,125 → 74,125 |
'gfk_objet' => 'objet', |
'gfk_trajet' => 'trajet', |
'gfk_montant_total' => 'montant_total'); |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Id Frais Km |
public function getIdFraisKm() |
{ |
return $this->id_frais_km; |
} |
public function setIdFraisKm( $ifk ) |
{ |
$this->id_frais_km = $ifk; |
} |
public function getIdFraisKm() |
{ |
return $this->id_frais_km; |
} |
public function setIdFraisKm( $ifk ) |
{ |
$this->id_frais_km = $ifk; |
} |
// Gfkt Id Frais Km Taux |
public function getGfktIdFraisKmTaux() |
{ |
return $this->gfkt_id_frais_km_taux; |
} |
public function setGfktIdFraisKmTaux( $gifkt ) |
{ |
$this->gfkt_id_frais_km_taux = $gifkt; |
} |
public function getGfktIdFraisKmTaux() |
{ |
return $this->gfkt_id_frais_km_taux; |
} |
public function setGfktIdFraisKmTaux( $gifkt ) |
{ |
$this->gfkt_id_frais_km_taux = $gifkt; |
} |
// Ce Utilisateur |
public function getCeUtilisateur() |
{ |
return $this->ce_utilisateur; |
} |
public function setCeUtilisateur( $cu ) |
{ |
$this->ce_utilisateur = $cu; |
} |
public function getCeUtilisateur() |
{ |
return $this->ce_utilisateur; |
} |
public function setCeUtilisateur( $cu ) |
{ |
$this->ce_utilisateur = $cu; |
} |
// Date |
public function getDate() |
{ |
return $this->date; |
} |
public function setDate( $d ) |
{ |
$this->date = $d; |
} |
public function getDate() |
{ |
return $this->date; |
} |
public function setDate( $d ) |
{ |
$this->date = $d; |
} |
// Nbre Km |
public function getNbreKm() |
{ |
return $this->nbre_km; |
} |
public function setNbreKm( $nk ) |
{ |
$this->nbre_km = $nk; |
} |
public function getNbreKm() |
{ |
return $this->nbre_km; |
} |
public function setNbreKm( $nk ) |
{ |
$this->nbre_km = $nk; |
} |
// Objet |
public function getObjet() |
{ |
return $this->objet; |
} |
public function setObjet( $o ) |
{ |
$this->objet = $o; |
} |
public function getObjet() |
{ |
return $this->objet; |
} |
public function setObjet( $o ) |
{ |
$this->objet = $o; |
} |
// Trajet |
public function getTrajet() |
{ |
return $this->trajet; |
} |
public function setTrajet( $t ) |
{ |
$this->trajet = $t; |
} |
public function getTrajet() |
{ |
return $this->trajet; |
} |
public function setTrajet( $t ) |
{ |
$this->trajet = $t; |
} |
// Montant Total |
public function getMontantTotal() |
{ |
return $this->montant_total; |
} |
public function setMontantTotal( $mt ) |
{ |
$this->montant_total = $mt; |
} |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_frais_km. |
* @return mixed un tableau d'objets FraisKm s'il y en a plusieurs, l'objet FraisKm s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
{ |
switch ($cmd) { |
case FraisKm::GFK_ID: |
$requete = 'SELECT * '. |
'FROM gestion_frais_km '. |
'WHERE gfk_id_frais_km = #0 '; |
break; |
case FraisKm::GFK_ID_MAX: |
$requete = 'SELECT MAX(gfk_id_frais_km) '. |
'FROM gestion_frais_km '; |
break; |
default : |
$message = 'Commande '.$cmd.'inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
return parent::consulter($requete, $parametres, $instancier); |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
public function getMontantTotal() |
{ |
return $this->montant_total; |
} |
public function setMontantTotal( $mt ) |
{ |
$this->montant_total = $mt; |
} |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_frais_km. |
* @return mixed un tableau d'objets FraisKm s'il y en a plusieurs, l'objet FraisKm s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
{ |
switch ($cmd) { |
case FraisKm::GFK_ID: |
$requete = 'SELECT * '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_frais_km '. |
'WHERE gfk_id_frais_km = #0 '; |
break; |
case FraisKm::GFK_ID_MAX: |
$requete = 'SELECT MAX(gfk_id_frais_km) '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_frais_km '; |
break; |
default : |
$message = 'Commande '.$cmd.'inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
return parent::consulter($requete, $parametres, $instancier); |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
* $Log$ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
?> |
/trunk/bibliotheque/metier/FraisKmTaux.class.php |
---|
1,126 → 1,126 |
<?php |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// CVS : $Id$ |
/** |
/** |
* Classe FraisKmTaux |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
*@version $Revision$ $Date$ |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class FraisKmTaux : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class FraisKmTaux extends aGttSql { |
/*** Constantes : */ |
const GFKT_ID = 'FRAISKMTAUX_ID'; |
const GFKT_ID_MAX = 'FRAISKMTAUX_ID_MAX'; |
/*** Attributs : */ |
private $id_frais_km_taux; |
private $taux; |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = 'gestion_frais_km_taux'; |
$this->dao_correspondance = array( |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class FraisKmTaux : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class FraisKmTaux extends aGttSql { |
/*** Constantes : */ |
const GFKT_ID = 'FRAISKMTAUX_ID'; |
const GFKT_ID_MAX = 'FRAISKMTAUX_ID_MAX'; |
/*** Attributs : */ |
private $id_frais_km_taux; |
private $taux; |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = GTT_BDD_PREFIXE . 'gestion_frais_km_taux'; |
$this->dao_correspondance = array( |
'gfkt_id_frais_km_taux' => 'id_frais_km_taux', |
'gfkt_taux' => 'taux'); |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Id Frais Km Taux |
public function getIdFraisKmTaux() |
{ |
return $this->id_frais_km_taux; |
} |
public function setIdFraisKmTaux( $ifkt ) |
{ |
$this->id_frais_km_taux = $ifkt; |
} |
public function getIdFraisKmTaux() |
{ |
return $this->id_frais_km_taux; |
} |
public function setIdFraisKmTaux( $ifkt ) |
{ |
$this->id_frais_km_taux = $ifkt; |
} |
// Taux |
public function getTaux() |
{ |
return $this->taux; |
} |
public function setTaux( $t ) |
{ |
$this->taux = $t; |
} |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_frais_km_taux. |
* @return mixed un tableau d'objets FraisKmTaux s'il y en a plusieurs, l'objet FraisKmTaux s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
{ |
switch ($cmd) { |
case FraisKmTaux::GFKT_ID: |
$requete = 'SELECT * '. |
'FROM gestion_frais_km_taux '. |
'WHERE gfkt_id_frais_km_taux = #0 '; |
break; |
case FraisKmTaux::GFKT_ID_MAX: |
$requete = 'SELECT MAX(gfkt_id_frais_km_taux) '. |
'FROM gestion_frais_km_taux '; |
break; |
default : |
$message = 'Commande '.$cmd.'inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
return parent::consulter($requete, $parametres, $instancier); |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
public function getTaux() |
{ |
return $this->taux; |
} |
public function setTaux( $t ) |
{ |
$this->taux = $t; |
} |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_frais_km_taux. |
* @return mixed un tableau d'objets FraisKmTaux s'il y en a plusieurs, l'objet FraisKmTaux s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
{ |
switch ($cmd) { |
case FraisKmTaux::GFKT_ID: |
$requete = 'SELECT * '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_frais_km_taux '. |
'WHERE gfkt_id_frais_km_taux = #0 '; |
break; |
case FraisKmTaux::GFKT_ID_MAX: |
$requete = 'SELECT MAX(gfkt_id_frais_km_taux) '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_frais_km_taux '; |
break; |
default : |
$message = 'Commande '.$cmd.'inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
return parent::consulter($requete, $parametres, $instancier); |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
* $Log$ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
?> |
/trunk/bibliotheque/metier/AbsenceMotif.class.php |
---|
1,100 → 1,100 |
<?php |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// CVS : $Id$ |
/** |
/** |
* Classe AbsenceMotif |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
*@version $Revision$ $Date$ |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class AbsenceMotif : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class AbsenceMotif extends aGttSql { |
/*** Constantes : */ |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class AbsenceMotif : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class AbsenceMotif extends aGttSql { |
/*** Constantes : */ |
const GAM_TOUS = 'ABSENCEMOTIF_TOUS'; |
const GAM_ID = 'ABSENCEMOTIF_ID'; |
const GAM_ID_MAX = 'ABSENCEMOTIF_ID_MAX'; |
const GAM_ID = 'ABSENCEMOTIF_ID'; |
const GAM_ID_MAX = 'ABSENCEMOTIF_ID_MAX'; |
const GAM_LIBELLE = 'ABSENCEMOTIF_LIBELLE'; |
/*** Attributs : */ |
private $id_absence_motif; |
/*** Attributs : */ |
private $id_absence_motif; |
private $libelle; |
private $mark_cp_diminuer; |
private $mark_hs_diminuer; |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = 'gestion_absence_motif'; |
$this->dao_correspondance = array( |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = GTT_BDD_PREFIXE . 'gestion_absence_motif'; |
$this->dao_correspondance = array( |
'gam_id_absence_motif' => 'id_absence_motif', |
'gam_libelle' => 'libelle', |
'gam_mark_cp_diminuer' => 'mark_cp_diminuer', |
'gam_mark_hs_diminuer' => 'mark_hs_diminuer'); |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Id Absence Motif |
public function getIdAbsenceMotif() |
{ |
return $this->id_absence_motif; |
} |
public function setIdAbsenceMotif( $iam ) |
{ |
$this->id_absence_motif = $iam; |
} |
public function getIdAbsenceMotif() |
{ |
return $this->id_absence_motif; |
} |
public function setIdAbsenceMotif( $iam ) |
{ |
$this->id_absence_motif = $iam; |
} |
// Libelle |
public function getLibelle() |
{ |
return $this->libelle; |
} |
public function setLibelle( $l ) |
{ |
$this->libelle = $l; |
} |
public function getLibelle() |
{ |
return $this->libelle; |
} |
public function setLibelle( $l ) |
{ |
$this->libelle = $l; |
} |
// CP Diminuer |
public function getMarkCpDiminuer() |
116,46 → 116,46 |
$this->mark_hs_diminuer = $hd; |
} |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_absence_motif. |
* @return mixed un tableau d'objets AbsenceMotif s'il y en a plusieurs, l'objet AbsenceMotif s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
{ |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_absence_motif. |
* @return mixed un tableau d'objets AbsenceMotif s'il y en a plusieurs, l'objet AbsenceMotif s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
{ |
switch ($cmd) { |
case AbsenceMotif::GAM_TOUS: |
$requete = 'SELECT * '. |
'FROM gestion_absence_motif '; |
break; |
case AbsenceMotif::GAM_ID: |
$requete = 'SELECT * '. |
'FROM gestion_absence_motif '. |
'WHERE gam_id_absence_motif = #0 '; |
break; |
case AbsenceMotif::GAM_ID_MAX: |
$requete = 'SELECT MAX(gam_id_absence_motif) AS gam_id_absence_motif '. |
'FROM gestion_absence_motif '; |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_absence_motif '; |
break; |
case AbsenceMotif::GAM_ID: |
$requete = 'SELECT * '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_absence_motif '. |
'WHERE gam_id_absence_motif = #0 '; |
break; |
case AbsenceMotif::GAM_ID_MAX: |
$requete = 'SELECT MAX(gam_id_absence_motif) AS gam_id_absence_motif '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_absence_motif '; |
break; |
case AbsenceMotif::GAM_LIBELLE: |
$requete = 'SELECT * '. |
'FROM gestion_absence_motif '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_absence_motif '. |
'WHERE gam_libelle = "#0" '; |
break; |
default : |
$message = 'Commande '.$cmd.'inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
return parent::consulter($requete, $parametres, $instancier); |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
break; |
default : |
$message = 'Commande '.$cmd.'inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
return parent::consulter($requete, $parametres, $instancier); |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
* $Log$ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
?> |
/trunk/bibliotheque/metier/UtilisateurAProjet.class.php |
---|
1,144 → 1,144 |
<?php |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// CVS : $Id$ |
/** |
/** |
* Classe UtilisateurAProjet |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
*@version $Revision$ $Date$ |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class UtilisateurAProjet : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class UtilisateurAProjet extends aGttSql { |
/*** Constantes : */ |
const GUAP_ID = 'UTILISATEURAPROJET_ID'; |
const GUAP_ID_MAX_UTILISATEUR = 'UTILISATEURAPROJET_ID_MAX_UTILISATEUR'; |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class UtilisateurAProjet : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class UtilisateurAProjet extends aGttSql { |
/*** Constantes : */ |
const GUAP_ID = 'UTILISATEURAPROJET_ID'; |
const GUAP_ID_MAX_UTILISATEUR = 'UTILISATEURAPROJET_ID_MAX_UTILISATEUR'; |
const GUAP_ID_MAX_PROJET = 'UTILISATEURAPROJET_ID_MAX_PROJET'; |
const GUAP_UTILISATEUR = 'UTILISATEURAPROJET_ID_UTILISATEUR'; |
const GUAP_UTILISATEUR = 'UTILISATEURAPROJET_ID_UTILISATEUR'; |
const GUAP_PROJET = 'UTILISATEURAPROJET_ID_PROJET'; |
/*** Attributs : */ |
private $id_utilisateur; |
private $id_projet; |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = 'gestion_utilisateur_a_projet'; |
$this->dao_correspondance = array( |
/*** Attributs : */ |
private $id_utilisateur; |
private $id_projet; |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = GTT_BDD_PREFIXE . 'gestion_utilisateur_a_projet'; |
$this->dao_correspondance = array( |
'guap_id_utilisateur' => 'id_utilisateur', |
'guap_id_projet' => 'id_projet'); |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Id Utilisateur |
public function getIdUtilisateur() |
{ |
return $this->id_utilisateur; |
} |
public function setIdUtilisateur( $iu ) |
{ |
$this->id_utilisateur = $iu; |
} |
public function getIdUtilisateur() |
{ |
return $this->id_utilisateur; |
} |
public function setIdUtilisateur( $iu ) |
{ |
$this->id_utilisateur = $iu; |
} |
// Id Projet |
public function getIdProjet() |
{ |
return $this->id_projet; |
} |
public function setIdProjet( $ip ) |
{ |
$this->id_projet = $ip; |
} |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_utilisateur_a_projet. |
* @return mixed un tableau d'objets UtilisateurAProjet s'il y en a plusieurs, l'objet UtilisateurAProjet s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
{ |
switch ($cmd) { |
case UtilisateurAProjet::GUAP_ID: |
$requete = 'SELECT * '. |
'FROM gestion_utilisateur_a_projet '. |
public function getIdProjet() |
{ |
return $this->id_projet; |
} |
public function setIdProjet( $ip ) |
{ |
$this->id_projet = $ip; |
} |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_utilisateur_a_projet. |
* @return mixed un tableau d'objets UtilisateurAProjet s'il y en a plusieurs, l'objet UtilisateurAProjet s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
{ |
switch ($cmd) { |
case UtilisateurAProjet::GUAP_ID: |
$requete = 'SELECT * '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_utilisateur_a_projet '. |
'WHERE guap_id_utilisateur = #0 '. |
' AND guap_id_projet = #1 '; |
break; |
case UtilisateurAProjet::GUAP_ID_MAX_UTILISATEUR: |
$requete = 'SELECT MAX(guap_id_utilisateur) '. |
'FROM gestion_utilisateur_a_projet '; |
break; |
case UtilisateurAProjet::GUAP_ID_MAX_PROJET: |
$requete = 'SELECT MAX(guap_id_projet) '. |
'FROM gestion_utilisateur_a_projet '; |
' AND guap_id_projet = #1 '; |
break; |
case UtilisateurAProjet::GUAP_ID_MAX_UTILISATEUR: |
$requete = 'SELECT MAX(guap_id_utilisateur) '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_utilisateur_a_projet '; |
break; |
case UtilisateurAProjet::GUAP_ID_MAX_PROJET: |
$requete = 'SELECT MAX(guap_id_projet) '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_utilisateur_a_projet '; |
break; |
case UtilisateurAProjet::GUAP_UTILISATEUR: |
$requete = 'SELECT * '. |
'FROM gestion_utilisateur_a_projet '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_utilisateur_a_projet '. |
'WHERE guap_id_utilisateur = #0 '; |
break; |
case UtilisateurAProjet::GUAP_PROJET: |
$requete = 'SELECT * '. |
'FROM gestion_utilisateur_a_projet '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_utilisateur_a_projet '. |
'WHERE guap_id_projet = #0 '; |
break; |
default : |
$message = 'Commande '.$cmd.'inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
return parent::consulter($requete, $parametres, $instancier); |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
break; |
default : |
$message = 'Commande '.$cmd.'inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
return parent::consulter($requete, $parametres, $instancier); |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
* $Log$ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
?> |
/trunk/bibliotheque/metier/UtilisateurStatut.class.php |
---|
1,98 → 1,98 |
<?php |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// CVS : $Id$ |
/** |
/** |
* Classe UtilisateurStatut |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
*@version $Revision$ $Date$ |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class UtilisateurStatut : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class UtilisateurStatut extends aGttSql { |
/*** Constantes : */ |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class UtilisateurStatut : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class UtilisateurStatut extends aGttSql { |
/*** Constantes : */ |
const GUS_TOUS = 'UTILISATEURSTATUT_TOUS'; |
const GUS_ID = 'UTILISATEURSTATUT_ID'; |
const GUS_ID_MAX = 'UTILISATEURSTATUT_ID_MAX'; |
const GUS_ID = 'UTILISATEURSTATUT_ID'; |
const GUS_ID_MAX = 'UTILISATEURSTATUT_ID_MAX'; |
const GUS_LIBELLE = 'UTILISATEURSTATUT_LIBELLE'; |
/*** Attributs : */ |
private $id_utilisateur_statut; |
/*** Attributs : */ |
private $id_utilisateur_statut; |
private $libelle; |
private $mark_recapitulatif; |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = 'gestion_utilisateur_statut'; |
$this->dao_correspondance = array( |
private $mark_recapitulatif; |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = GTT_BDD_PREFIXE . 'gestion_utilisateur_statut'; |
$this->dao_correspondance = array( |
'gus_id_utilisateur_statut' => 'id_utilisateur_statut', |
'gus_libelle' => 'libelle', |
'gus_mark_recapitulatif' => 'mark_recapitulatif'); |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Id Utilisateur Statut |
public function getIdUtilisateurStatut() |
{ |
return $this->id_utilisateur_statut; |
} |
public function setIdUtilisateurStatut( $ius ) |
{ |
$this->id_utilisateur_statut = $ius; |
} |
public function getIdUtilisateurStatut() |
{ |
return $this->id_utilisateur_statut; |
} |
public function setIdUtilisateurStatut( $ius ) |
{ |
$this->id_utilisateur_statut = $ius; |
} |
// Libelle |
public function getLibelle() |
{ |
return $this->libelle; |
} |
public function setLibelle( $l ) |
{ |
$this->libelle = $l; |
} |
public function getLibelle() |
{ |
return $this->libelle; |
} |
public function setLibelle( $l ) |
{ |
$this->libelle = $l; |
} |
// Mark Recapitulatif |
public function getMarkRecapitulatif() |
103,47 → 103,47 |
{ |
$this->mark_recapitulatif = $mr; |
} |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_utilisateur_statut. |
* @return mixed un tableau d'objets UtilisateurStatut s'il y en a plusieurs, l'objet UtilisateurStatut s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
{ |
switch ($cmd) { |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_utilisateur_statut. |
* @return mixed un tableau d'objets UtilisateurStatut s'il y en a plusieurs, l'objet UtilisateurStatut s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
{ |
switch ($cmd) { |
case UtilisateurStatut::GUS_TOUS: |
$requete = 'SELECT * '. |
'FROM gestion_utilisateur_statut '; |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_utilisateur_statut '; |
break; |
case UtilisateurStatut::GUS_ID: |
$requete = 'SELECT * '. |
'FROM gestion_utilisateur_statut '. |
'WHERE gus_id_utilisateur_statut = #0 '; |
break; |
case UtilisateurStatut::GUS_ID_MAX: |
$requete = 'SELECT MAX(gus_id_utilisateur_statut) AS gus_id_utilisateur_statut '. |
'FROM gestion_utilisateur_statut '; |
case UtilisateurStatut::GUS_ID: |
$requete = 'SELECT * '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_utilisateur_statut '. |
'WHERE gus_id_utilisateur_statut = #0 '; |
break; |
case UtilisateurStatut::GUS_ID_MAX: |
$requete = 'SELECT MAX(gus_id_utilisateur_statut) AS gus_id_utilisateur_statut '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_utilisateur_statut '; |
break; |
case UtilisateurStatut::GUS_LIBELLE: |
$requete = 'SELECT * '. |
'FROM gestion_utilisateur_statut '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_utilisateur_statut '. |
'WHERE gus_libelle = "#0" '; |
break; |
default : |
$message = 'Commande '.$cmd.'inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
break; |
default : |
$message = 'Commande '.$cmd.'inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
return parent::consulter($requete, $parametres, $instancier); |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
* $Log$ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
?> |
/trunk/bibliotheque/metier/Absence.class.php |
---|
1,182 → 1,182 |
<?php |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// CVS : $Id$ |
/** |
/** |
* Classe Absence |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
*@version $Revision$ $Date$ |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class Absence : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class Absence extends aGttSql { |
/*** Constantes : */ |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class Absence : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class Absence extends aGttSql { |
/*** Constantes : */ |
const GA_ID = 'ABSENCE_ID'; |
const GA_ID_ABSENCE_MOTIF = 'ABSENCE_ID_ABSENCE_MOTIF'; |
const GA_ID_UTILISATEUR = 'ABSENCE_ID_UTILISATEUR'; |
const GA_ID_UTILISATEUR_DATE_DEB_FIN = 'ABSENCE_ID_UTILISATEUR_DATE_DEB_FIN'; |
const GA_ID_MAX_UTILISATEUR = 'ABSENCE_ID_MAX_UTILISATEUR'; |
const GA_ID_MAX_ABSENCE_MOTIF = 'ABSENCE_ID_MAX_ABSENCE_MOTIF'; |
const GA_ID_MAX_DATE_ABSENCE = 'ABSENCE_ID_MAX_DATE_ABSENCE'; |
/*** Attributs : */ |
private $id_utilisateur; |
private $id_absence_motif; |
private $id_date_absence; |
private $duree; |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = 'gestion_absence'; |
$this->dao_correspondance = array( |
const GA_ID_UTILISATEUR_DATE_DEB_FIN = 'ABSENCE_ID_UTILISATEUR_DATE_DEB_FIN'; |
const GA_ID_MAX_UTILISATEUR = 'ABSENCE_ID_MAX_UTILISATEUR'; |
const GA_ID_MAX_ABSENCE_MOTIF = 'ABSENCE_ID_MAX_ABSENCE_MOTIF'; |
const GA_ID_MAX_DATE_ABSENCE = 'ABSENCE_ID_MAX_DATE_ABSENCE'; |
/*** Attributs : */ |
private $id_utilisateur; |
private $id_absence_motif; |
private $id_date_absence; |
private $duree; |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = GTT_BDD_PREFIXE . 'gestion_absence'; |
$this->dao_correspondance = array( |
'ga_id_utilisateur' => 'id_utilisateur', |
'ga_id_absence_motif' => 'id_absence_motif', |
'ga_id_date_absence' => 'id_date_absence', |
'ga_duree' => 'duree'); |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Id Utilisateur |
public function getIdUtilisateur() |
{ |
return $this->id_utilisateur; |
} |
public function setIdUtilisateur( $iu ) |
{ |
$this->id_utilisateur = $iu; |
} |
public function getIdUtilisateur() |
{ |
return $this->id_utilisateur; |
} |
public function setIdUtilisateur( $iu ) |
{ |
$this->id_utilisateur = $iu; |
} |
// Id Absence Motif |
public function getIdAbsenceMotif() |
{ |
return $this->id_absence_motif; |
} |
public function setIdAbsenceMotif( $iam ) |
{ |
$this->id_absence_motif = $iam; |
} |
public function getIdAbsenceMotif() |
{ |
return $this->id_absence_motif; |
} |
public function setIdAbsenceMotif( $iam ) |
{ |
$this->id_absence_motif = $iam; |
} |
// Id Date Absence |
public function getIdDateAbsence() |
{ |
return $this->id_date_absence; |
} |
public function setIdDateAbsence( $ida ) |
{ |
$this->id_date_absence = $ida; |
} |
public function getIdDateAbsence() |
{ |
return $this->id_date_absence; |
} |
public function setIdDateAbsence( $ida ) |
{ |
$this->id_date_absence = $ida; |
} |
// Duree |
public function getDuree() |
{ |
return $this->duree; |
} |
public function setDuree( $d ) |
{ |
$this->duree = $d; |
} |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_absence. |
* @return mixed un tableau d'objets Absence s'il y en a plusieurs, l'objet Absence s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
{ |
switch ($cmd) { |
case Absence::GA_ID: |
$requete = 'SELECT * '. |
'FROM gestion_absence '. |
public function getDuree() |
{ |
return $this->duree; |
} |
public function setDuree( $d ) |
{ |
$this->duree = $d; |
} |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_absence. |
* @return mixed un tableau d'objets Absence s'il y en a plusieurs, l'objet Absence s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
{ |
switch ($cmd) { |
case Absence::GA_ID: |
$requete = 'SELECT * '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_absence '. |
'WHERE ga_id_utilisateur = #0 '. |
' AND ga_id_absence_motif = #1 '. |
' AND ga_id_date_absence = #2 '; |
' AND ga_id_date_absence = #2 '; |
break; |
case Absence::GA_ID_ABSENCE_MOTIF: |
$requete = 'SELECT * '. |
'FROM gestion_absence '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_absence '. |
'WHERE ga_id_absence_motif = #0 '; |
break; |
case Absence::GA_ID_UTILISATEUR: |
$requete = 'SELECT * '. |
'FROM gestion_absence '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_absence '. |
'WHERE ga_id_utilisateur = #0 '; |
break; |
case Absence::GA_ID_UTILISATEUR_DATE_DEB_FIN: |
$requete = 'SELECT * '. |
'FROM gestion_absence '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_absence '. |
'WHERE ga_id_utilisateur = #0 '. |
' AND ga_id_date_absence >= "#1" '. |
' AND ga_id_date_absence <= "#2" '; |
break; |
case Absence::GA_ID_MAX_UTILISATEUR: |
$requete = 'SELECT MAX(ga_id_utilisateur) '. |
'FROM gestion_absence '; |
break; |
case Absence::GA_ID_MAX_ABSENCE_MOTIF: |
$requete = 'SELECT MAX(ga_id_absence_motif) '. |
'FROM gestion_absence '; |
break; |
case Absence::GA_ID_MAX_DATE_ABSENCE: |
$requete = 'SELECT MAX(ga_id_date_absence) '. |
'FROM gestion_absence '; |
break; |
default : |
$message = 'Commande '.$cmd.'inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
return parent::consulter($requete, $parametres, $instancier); |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
break; |
case Absence::GA_ID_MAX_UTILISATEUR: |
$requete = 'SELECT MAX(ga_id_utilisateur) '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_absence '; |
break; |
case Absence::GA_ID_MAX_ABSENCE_MOTIF: |
$requete = 'SELECT MAX(ga_id_absence_motif) '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_absence '; |
break; |
case Absence::GA_ID_MAX_DATE_ABSENCE: |
$requete = 'SELECT MAX(ga_id_date_absence) '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_absence '; |
break; |
default : |
$message = 'Commande '.$cmd.'inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
return parent::consulter($requete, $parametres, $instancier); |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
* $Log$ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
?> |
/trunk/bibliotheque/metier/Projet.class.php |
---|
1,77 → 1,77 |
<?php |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// CVS : $Id$ |
/** |
/** |
* Classe Projet |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
*@version $Revision$ $Date$ |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class Projet : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class Projet extends aGttSql { |
/*** Constantes : */ |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class Projet : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class Projet extends aGttSql { |
/*** Constantes : */ |
const GP_TOUS = 'PROJET_TOUS'; |
const GP_ID = 'PROJET_ID'; |
const GP_NOM = 'PROJET_NOM'; |
const GP_NOM = 'PROJET_NOM'; |
const GP_ID_MAX = 'PROJET_ID_MAX'; |
const GP_ID_LIST = 'PROJET_ID_LIST'; |
const GP_CE_CATEGORIE = 'PROJET_CE_CATEGORIE'; |
/*** Attributs : */ |
private $id_projet; |
const GP_CE_CATEGORIE = 'PROJET_CE_CATEGORIE'; |
/*** Attributs : */ |
private $id_projet; |
private $ce_projet_parent; |
private $ce_categorie; |
private $nom; |
private $description; |
private $ce_categorie; |
private $nom; |
private $description; |
private $date_debut; |
private $date_fin; |
private $date_fin; |
private $duree_prevue; |
private $duree_finance; |
private $avancement; |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = 'gestion_projet'; |
$this->dao_correspondance = array( |
private $duree_finance; |
private $avancement; |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = GTT_BDD_PREFIXE . 'gestion_projet'; |
$this->dao_correspondance = array( |
'gp_id_projet' => 'id_projet', |
'gp_ce_projet_parent' => 'ce_projet_parent', |
'gp_ce_categorie' => 'ce_categorie', |
82,23 → 82,23 |
'gp_duree_prevue' => 'duree_prevue', |
'gp_duree_finance' => 'duree_finance', |
'gp_avancement' => 'avancement'); |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Id Projet |
public function getIdProjet() |
{ |
return $this->id_projet; |
} |
public function setIdProjet( $ip ) |
{ |
$this->id_projet = $ip; |
} |
public function getIdProjet() |
{ |
return $this->id_projet; |
} |
public function setIdProjet( $ip ) |
{ |
$this->id_projet = $ip; |
} |
// Ce Projet Parent |
public function getCeProjetParent() |
110,46 → 110,46 |
$this->ce_projet_parent = $cpp; |
} |
// Ce Categorie |
public function getCeCategorie() |
{ |
return $this->ce_categorie; |
} |
public function setCeCategorie( $cc ) |
{ |
$this->ce_categorie = $cc; |
} |
public function getCeCategorie() |
{ |
return $this->ce_categorie; |
} |
public function setCeCategorie( $cc ) |
{ |
$this->ce_categorie = $cc; |
} |
// Nom |
public function getNom() |
{ |
return $this->nom; |
} |
public function setNom( $n ) |
{ |
$this->nom = $n; |
} |
public function getNom() |
{ |
return $this->nom; |
} |
public function setNom( $n ) |
{ |
$this->nom = $n; |
} |
// Description |
public function getDescription() |
{ |
return $this->description; |
} |
public function setDescription( $d ) |
{ |
$this->description = $d; |
} |
public function getDescription() |
{ |
return $this->description; |
} |
public function setDescription( $d ) |
{ |
$this->description = $d; |
} |
// Date Debut |
public function getDateDebut() |
{ |
return $this->date_debut; |
} |
public function setDateDebut( $dd ) |
{ |
$this->date_debut = $dd; |
public function getDateDebut() |
{ |
return $this->date_debut; |
} |
public function setDateDebut( $dd ) |
{ |
$this->date_debut = $dd; |
} |
// Date Fin |
public function getDateFin() |
159,17 → 159,17 |
public function setDateFin( $df ) |
{ |
$this->date_fin = $df; |
} |
} |
// Duree Prevue |
public function getDureePrevue() |
{ |
return $this->duree_prevue; |
} |
public function setDureePrevue( $dp ) |
{ |
$this->duree_prevue = $dp; |
} |
public function getDureePrevue() |
{ |
return $this->duree_prevue; |
} |
public function setDureePrevue( $dp ) |
{ |
$this->duree_prevue = $dp; |
} |
// Duree Finance |
public function getDureeFinance() |
180,69 → 180,69 |
{ |
$this->duree_finance = $df; |
} |
// Avancement |
public function getAvancement() |
{ |
return $this->avancement; |
} |
public function setAvancement( $a ) |
{ |
$this->avancement = $a; |
} |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_projet. |
* @return mixed un tableau d'objets Projet s'il y en a plusieurs, l'objet Projet s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
public function getAvancement() |
{ |
return $this->avancement; |
} |
public function setAvancement( $a ) |
{ |
$this->avancement = $a; |
} |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_projet. |
* @return mixed un tableau d'objets Projet s'il y en a plusieurs, l'objet Projet s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
{ |
switch ($cmd) { |
case Projet::GP_TOUS: |
$requete = 'SELECT * '. |
'FROM gestion_projet LEFT JOIN gestion_projet_categorie ON (gp_ce_categorie = gpc_id_categorie) '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_projet LEFT JOIN ' . GTT_BDD_PREFIXE . 'gestion_projet_categorie ON (gp_ce_categorie = gpc_id_categorie) '. |
'ORDER BY gpc_libelle, gp_nom ASC'; |
break; |
case Projet::GP_ID: |
$requete = 'SELECT * '. |
'FROM gestion_projet '. |
'WHERE gp_id_projet = #0 '; |
break; |
case Projet::GP_ID: |
$requete = 'SELECT * '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_projet '. |
'WHERE gp_id_projet = #0 '; |
break; |
case Projet::GP_NOM: |
$requete = 'SELECT * '. |
'FROM gestion_projet '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_projet '. |
'WHERE gp_nom = "#0" '; |
break; |
case Projet::GP_ID_MAX: |
$requete = 'SELECT MAX(gp_id_projet) AS gp_id_projet '. |
'FROM gestion_projet '; |
break; |
case Projet::GP_ID_MAX: |
$requete = 'SELECT MAX(gp_id_projet) AS gp_id_projet '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_projet '; |
break; |
case Projet::GP_ID_LIST: |
$requete = 'SELECT * '. |
'FROM gestion_projet LEFT JOIN gestion_projet_categorie ON (gp_ce_categorie = gpc_id_categorie) '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_projet LEFT JOIN ' . GTT_BDD_PREFIXE . 'gestion_projet_categorie ON (gp_ce_categorie = gpc_id_categorie) '. |
'WHERE gp_id_projet IN (#0) '. |
'ORDER BY gpc_libelle, gp_nom ASC'; |
break; |
case Projet::GP_CE_CATEGORIE: |
$requete = 'SELECT * '. |
'FROM gestion_projet '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_projet '. |
'WHERE gp_ce_categorie = #0 '; |
break; |
default : |
$message = 'Commande '.$cmd.'inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
break; |
default : |
$message = 'Commande '.$cmd.'inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
return parent::consulter($requete, $parametres, $instancier); |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
* $Log$ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
?> |
/trunk/bibliotheque/metier/ProjetCategorie.class.php |
---|
1,98 → 1,98 |
<?php |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// CVS : $Id$ |
/** |
/** |
* Classe ProjetCategorie |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
*@version $Revision$ $Date$ |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class ProjetCategorie : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class ProjetCategorie extends aGttSql { |
/*** Constantes : */ |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class ProjetCategorie : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class ProjetCategorie extends aGttSql { |
/*** Constantes : */ |
const GPC_TOUS = 'PROJETCATEGORIE_TOUS'; |
const GPC_ID = 'PROJETCATEGORIE_ID'; |
const GPC_ID = 'PROJETCATEGORIE_ID'; |
const GPC_ID_MAX = 'PROJETCATEGORIE_ID_MAX'; |
const GPC_LIBELLE = 'PROJETCATEGORIE_LIBELLE'; |
/*** Attributs : */ |
private $id_categorie; |
const GPC_LIBELLE = 'PROJETCATEGORIE_LIBELLE'; |
/*** Attributs : */ |
private $id_categorie; |
private $libelle; |
private $abreviation; |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = 'gestion_projet_categorie'; |
$this->dao_correspondance = array( |
private $abreviation; |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = GTT_BDD_PREFIXE . 'gestion_projet_categorie'; |
$this->dao_correspondance = array( |
'gpc_id_categorie' => 'id_categorie', |
'gpc_libelle' => 'libelle', |
'gpc_abreviation' => 'abreviation'); |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Id Categorie |
public function getIdCategorie() |
{ |
return $this->id_categorie; |
} |
public function setIdCategorie( $ic ) |
{ |
$this->id_categorie = $ic; |
} |
public function getIdCategorie() |
{ |
return $this->id_categorie; |
} |
public function setIdCategorie( $ic ) |
{ |
$this->id_categorie = $ic; |
} |
// Libelle |
public function getLibelle() |
{ |
return $this->libelle; |
} |
public function setLibelle( $l ) |
{ |
$this->libelle = $l; |
} |
public function getLibelle() |
{ |
return $this->libelle; |
} |
public function setLibelle( $l ) |
{ |
$this->libelle = $l; |
} |
// Abreviation |
public function getAbreviation() |
104,48 → 104,48 |
$this->abreviation = $a; |
} |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_projet_categorie. |
* @return mixed un tableau d'objets ProjetCategorie s'il y en a plusieurs, l'objet ProjetCategorie s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_projet_categorie. |
* @return mixed un tableau d'objets ProjetCategorie s'il y en a plusieurs, l'objet ProjetCategorie s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
{ |
switch ($cmd) { |
switch ($cmd) { |
case ProjetCategorie::GPC_TOUS: |
$requete = 'SELECT * '. |
'FROM gestion_projet_categorie '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_projet_categorie '. |
'ORDER BY gpc_libelle'; |
break; |
case ProjetCategorie::GPC_ID: |
$requete = 'SELECT * '. |
'FROM gestion_projet_categorie '. |
'WHERE gpc_id_categorie = #0 '; |
break; |
case ProjetCategorie::GPC_ID_MAX: |
$requete = 'SELECT MAX(gpc_id_categorie) AS gpc_id_categorie '. |
'FROM gestion_projet_categorie '; |
case ProjetCategorie::GPC_ID: |
$requete = 'SELECT * '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_projet_categorie '. |
'WHERE gpc_id_categorie = #0 '; |
break; |
case ProjetCategorie::GPC_ID_MAX: |
$requete = 'SELECT MAX(gpc_id_categorie) AS gpc_id_categorie '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_projet_categorie '; |
break; |
case ProjetCategorie::GPC_LIBELLE: |
$requete = 'SELECT * '. |
'FROM gestion_projet_categorie '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_projet_categorie '. |
'WHERE gpc_libelle = "#0" '; |
break; |
default : |
$message = 'Commande '.$cmd.'inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
return parent::consulter($requete, $parametres, $instancier); |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
break; |
default : |
$message = 'Commande '.$cmd.'inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
return parent::consulter($requete, $parametres, $instancier); |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
* $Log$ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
?> |
/trunk/bibliotheque/metier/TravailProjet.class.php |
---|
1,182 → 1,182 |
<?php |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// +------------------------------------------------------------------------------------------------------+ |
// | PHP version 5.1.1 | |
// +------------------------------------------------------------------------------------------------------+ |
// | Copyright (C) 2006 Tela Botanica (accueil@tela-botanica.org) | |
// +------------------------------------------------------------------------------------------------------+ |
// | This file is part of eFlore. | |
// | | |
// | Foobar is free software; you can redistribute it and/or modify | |
// | it under the terms of the GNU General Public License as published by | |
// | the Free Software Foundation; either version 2 of the License, or | |
// | (at your option) any later version. | |
// | | |
// | Foobar is distributed in the hope that it will be useful, | |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
// | GNU General Public License for more details. | |
// | | |
// | You should have received a copy of the GNU General Public License | |
// | along with Foobar; if not, write to the Free Software | |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
// +------------------------------------------------------------------------------------------------------+ |
// CVS : $Id$ |
/** |
/** |
* Classe TravailProjet |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
* |
* Description |
* |
*@package eFlore |
*@subpackage modele |
//Auteur original : |
*@version 3 |
*@author Shaheen ABDOOL RAHEEM <shaheenar50@hotmail.com> |
//Autres auteurs : |
*@version 4 |
*@author Jean-Pascal MILCENT <jpm@clapas.org> |
*@author aucun |
*@copyright Tela-Botanica 2000-2006 |
*@version $Revision$ $Date$ |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class TravailProjet : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class TravailProjet extends aGttSql { |
/*** Constantes : */ |
// +------------------------------------------------------------------------------------------------------+ |
*/ |
/** |
* class TravailProjet : est à la fois le DAO et le conteneur de la table gestion_utilisateur. |
* classe métier |
*/ |
class TravailProjet extends aGttSql { |
/*** Constantes : */ |
const GTP_ID = 'TRAVAILPROJET_ID'; |
const GTP_ID_UTILISATEUR_DATE_DEB_FIN = 'TRAVAILPROJET_ID_UTILISATEUR_DATE'; |
const GTP_ID_MAX_UTILISATEUR = 'TRAVAILPROJET_ID_MAX_UTILISATEUR'; |
const GTP_ID_MAX_PROJET = 'TRAVAILPROJET_ID_MAX_PROJET'; |
const GTP_ID_MAX_DATE_TRAVAIL = 'TRAVAILPROJET_ID_MAX_DATE_TRAVAIL'; |
const GTP_ID_UTILISATEUR_DATE_DEB_FIN = 'TRAVAILPROJET_ID_UTILISATEUR_DATE'; |
const GTP_ID_MAX_UTILISATEUR = 'TRAVAILPROJET_ID_MAX_UTILISATEUR'; |
const GTP_ID_MAX_PROJET = 'TRAVAILPROJET_ID_MAX_PROJET'; |
const GTP_ID_MAX_DATE_TRAVAIL = 'TRAVAILPROJET_ID_MAX_DATE_TRAVAIL'; |
const GTP_PROJET = 'TRAVAILPROJET_ID_PROJET'; |
const GTP_UTILISATEUR = 'TRAVAILPROJET_ID_UTILISATEUR'; |
/*** Attributs : */ |
private $id_utilisateur; |
private $id_projet; |
private $id_date_travail; |
private $duree; |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = 'gestion_travail_projet'; |
$this->dao_correspondance = array( |
/*** Attributs : */ |
private $id_utilisateur; |
private $id_projet; |
private $id_date_travail; |
private $duree; |
/*** Aggregations : */ |
/*** Constructeur : */ |
public function __construct($cmd = null, $parametres = null) |
{ |
$this->dao_table_nom = GTT_BDD_PREFIXE . 'gestion_travail_projet'; |
$this->dao_correspondance = array( |
'gtp_id_utilisateur' => 'id_utilisateur', |
'gtp_id_projet' => 'id_projet', |
'gtp_id_date_travail' => 'id_date_travail', |
'gtp_duree' => 'duree'); |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Si l'on veut remplir l'objet à la création on lance la requete correspondante |
if (!is_null($cmd)) { |
$this->consulter($cmd, $parametres, true); |
} |
} |
/*** Accesseurs : */ |
// Id Utilisateur |
public function getIdUtilisateur() |
{ |
return $this->id_utilisateur; |
} |
public function setIdUtilisateur( $iu ) |
{ |
$this->id_utilisateur = $iu; |
} |
public function getIdUtilisateur() |
{ |
return $this->id_utilisateur; |
} |
public function setIdUtilisateur( $iu ) |
{ |
$this->id_utilisateur = $iu; |
} |
// Id Projet |
public function getIdProjet() |
{ |
return $this->id_projet; |
} |
public function setIdProjet( $ip ) |
{ |
$this->id_projet = $ip; |
} |
public function getIdProjet() |
{ |
return $this->id_projet; |
} |
public function setIdProjet( $ip ) |
{ |
$this->id_projet = $ip; |
} |
// Id Date Travail |
public function getIdDateTravail() |
{ |
return $this->id_date_travail; |
} |
public function setIdDateTravail( $idt ) |
{ |
$this->id_date_travail = $idt; |
} |
public function getIdDateTravail() |
{ |
return $this->id_date_travail; |
} |
public function setIdDateTravail( $idt ) |
{ |
$this->id_date_travail = $idt; |
} |
// Duree |
public function getDuree() |
{ |
return $this->duree; |
} |
public function setDuree( $d ) |
{ |
$this->duree = $d; |
} |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_travail_projet. |
* @return mixed un tableau d'objets TravailProjet s'il y en a plusieurs, l'objet TravailProjet s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
{ |
switch ($cmd) { |
case TravailProjet::GTP_ID: |
$requete = 'SELECT * '. |
'FROM gestion_travail_projet '. |
public function getDuree() |
{ |
return $this->duree; |
} |
public function setDuree( $d ) |
{ |
$this->duree = $d; |
} |
/*** Méthodes : */ |
/** |
* Consulter la table gestion_travail_projet. |
* @return mixed un tableau d'objets TravailProjet s'il y en a plusieurs, l'objet TravailProjet s'il y en a 1 seul sinon false. |
*/ |
public function consulter($cmd = '', $parametres = array(), $instancier = false) |
{ |
switch ($cmd) { |
case TravailProjet::GTP_ID: |
$requete = 'SELECT * '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_travail_projet '. |
'WHERE gtp_id_utilisateur = #0 '. |
' AND gtp_id_projet = #1 '. |
' AND gtp_id_date_travail = "#2" '; |
break; |
' AND gtp_id_date_travail = "#2" '; |
break; |
case TravailProjet::GTP_ID_UTILISATEUR_DATE_DEB_FIN: |
$requete = 'SELECT * '. |
'FROM gestion_travail_projet '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_travail_projet '. |
'WHERE gtp_id_utilisateur = #0 '. |
' AND gtp_id_date_travail >= "#1" '. |
' AND gtp_id_date_travail <= "#2" '; |
break; |
case TravailProjet::GTP_ID_MAX_UTILISATEUR: |
$requete = 'SELECT MAX(gtp_id_utilisateur) '. |
'FROM gestion_travail_projet '; |
break; |
case TravailProjet::GTP_ID_MAX_PROJET: |
$requete = 'SELECT MAX(gtp_id_projet) '. |
'FROM gestion_travail_projet '; |
break; |
case TravailProjet::GTP_ID_MAX_DATE_TRAVAIL: |
$requete = 'SELECT MAX(gtp_id_date_travail) '. |
'FROM gestion_travail_projet '; |
case TravailProjet::GTP_ID_MAX_UTILISATEUR: |
$requete = 'SELECT MAX(gtp_id_utilisateur) '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_travail_projet '; |
break; |
case TravailProjet::GTP_ID_MAX_PROJET: |
$requete = 'SELECT MAX(gtp_id_projet) '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_travail_projet '; |
break; |
case TravailProjet::GTP_ID_MAX_DATE_TRAVAIL: |
$requete = 'SELECT MAX(gtp_id_date_travail) '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_travail_projet '; |
break; |
case TravailProjet::GTP_PROJET: |
$requete = 'SELECT gtp_id_projet '. |
'FROM gestion_travail_projet '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_travail_projet '. |
'WHERE gtp_id_projet = #0 '; |
break; |
case TravailProjet::GTP_UTILISATEUR: |
$requete = 'SELECT gtp_id_utilisateur '. |
'FROM gestion_travail_projet '. |
'FROM ' . GTT_BDD_PREFIXE . 'gestion_travail_projet '. |
'WHERE gtp_id_utilisateur = #0 '; |
break; |
default : |
$message = 'Commande '.$cmd.' inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
return parent::consulter($requete, $parametres, $instancier); |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
default : |
$message = 'Commande '.$cmd.' inconnue!'; |
$e = GestionnaireErreur::formaterMessageErreur(__FILE__, __LINE__, $message); |
trigger_error($e, E_USER_ERROR); |
} |
return parent::consulter($requete, $parametres, $instancier); |
} |
} |
/* +--Fin du code ----------------------------------------------------------------------------------------+ |
* |
* $Log$ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
* |
* +-- Fin du code ----------------------------------------------------------------------------------------+ |
*/ |
?> |