Subversion Repositories Applications.projet

Rev

Rev 38 | Rev 87 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 38 Rev 86
Line 17... Line 17...
17
// |                                                                                                      |
17
// |                                                                                                      |
18
// | You should have received a copy of the GNU General Public                                            |
18
// | You should have received a copy of the GNU General Public                                            |
19
// | License along with this library; if not, write to the Free Software                                  |
19
// | License along with this library; if not, write to the Free Software                                  |
20
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA                            |
20
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA                            |
21
// +------------------------------------------------------------------------------------------------------+
21
// +------------------------------------------------------------------------------------------------------+
22
// CVS : $Id: HTML_formulaireProjet.class.php,v 1.3 2005-10-14 08:57:17 alexandre_tb Exp $
22
// CVS : $Id: HTML_formulaireProjet.class.php,v 1.4 2005-12-13 09:19:22 alexandre_tb Exp $
23
/**
23
/**
24
* Application projet
24
* Application projet
25
*
25
*
26
* La classe HTML_formulaireProjet
26
* La classe HTML_formulaireProjet
27
*
27
*
Line 29... Line 29...
29
//Auteur original :
29
//Auteur original :
30
*@author        Alexandre Granier <alexandre@tela-botanica.org>
30
*@author        Alexandre Granier <alexandre@tela-botanica.org>
31
//Autres auteurs :
31
//Autres auteurs :
32
*@author        Aucun
32
*@author        Aucun
33
*@copyright     Tela-Botanica 2000-2004
33
*@copyright     Tela-Botanica 2000-2004
34
*@version       $Revision: 1.3 $
34
*@version       $Revision: 1.4 $
35
// +------------------------------------------------------------------------------------------------------+
35
// +------------------------------------------------------------------------------------------------------+
36
*/
36
*/
Line 37... Line 37...
37
 
37
 
Line 98... Line 98...
98
     */
98
     */
99
    function construitFormulaire(&$tableau_projet, $tableau_type = '')
99
    function construitFormulaire(&$tableau_projet, $tableau_type = '')
100
    {
100
    {
101
        $this->addElement ('text', 'projet_titre', PROJET_TITRE, array ('class' => 'projet_titre', 'maxlength' => 255)) ;
101
        $this->addElement ('text', 'projet_titre', PROJET_TITRE, array ('class' => 'projet_titre', 'maxlength' => 255)) ;
102
        $this->addRule ('projet_titre', PROJET_ALERTE_TITRE, 'required', '', 'client') ;
102
        $this->addRule ('projet_titre', PROJET_ALERTE_TITRE, 'required', '', 'client') ;
-
 
103
        if ($tableau_type != '') {
-
 
104
            $select = new HTML_QuickForm_select ('projet_type', PROJET_TYPE, $tableau_type, array ('class' => 'projet_type')) ;
-
 
105
            $this->addElement($select) ;
-
 
106
            unset ($select) ;
103
        
107
        }
104
        $this->addElement ('textarea', 'projet_resume', PROJET_RESUME, array('class'=>'projet_resume', 'rows'=>"10")) ;
108
        $this->addElement ('textarea', 'projet_resume', PROJET_RESUME, array('class'=>'projet_resume', 'rows'=>"10")) ;
105
        $this->addElement ('textarea', 'projet_description', PROJET_DESCRIPTION, array('class'=>"projet_resume", 'rows'=>"40")) ;
109
        $this->addElement ('textarea', 'projet_description', PROJET_DESCRIPTION, array('class'=>"projet_resume", 'rows'=>"40")) ;
106
        $this->addElement ('text', 'projet_espace_internet', PROJET_ESPACE_INTERNET, array ('class' => 'projet_espace_internet')) ;
110
        $this->addElement ('text', 'projet_espace_internet', PROJET_ESPACE_INTERNET, array ('class' => 'projet_espace_internet')) ;
Line 107... Line 111...
107
        
111
        
Line 116... Line 120...
116
	        $this->addElement($select) ;
120
	        $this->addElement($select) ;
117
	        unset ($select) ;
121
	        unset ($select) ;
118
        }
122
        }
119
        $this->applyFilter(array('projet_resume', 'projet_description'), 'addslashes') ;
123
        $this->applyFilter(array('projet_resume', 'projet_description'), 'addslashes') ;
Line 120... Line -...
120
        
-
 
121
        if ($tableau_type != '') {
-
 
122
            $select = new HTML_QuickForm_select ('projet_type', PROJET_TYPE, $tableau_type, array ('class' => 'projet_type')) ;
-
 
123
            $this->addElement($select) ;
-
 
124
            unset ($select) ;
124
        
125
        }
125
 
126
        $this->setRequiredNote('<span style="color: #ff0000">*</span>'.PROJET_CHAMPS_REQUIS) ;
126
        $this->setRequiredNote('<span style="color: #ff0000">*</span>'.PROJET_CHAMPS_REQUIS) ;
127
        $url_annuler = new Net_URL($this->getAttribute('action')) ;
127
        $url_annuler = new Net_URL($this->getAttribute('action')) ;
Line 128... Line 128...
128
        $url_annuler->removeQueryString(PROJET_VARIABLE_ACTION) ;
128
        $url_annuler->removeQueryString(PROJET_VARIABLE_ACTION) ;