Subversion Repositories Sites.obs-saisons.fr

Rev

Rev 294 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 294 Rev 324
Line 13... Line 13...
13
 * @version     SVN: $Id: Fiche.php 152 2010-09-06 16:19:12Z jpm $
13
 * @version     SVN: $Id: Fiche.php 152 2010-09-06 16:19:12Z jpm $
14
 */
14
 */
15
class Liens extends aControleur {
15
class Liens extends aControleur {
Line 16... Line 16...
16
 
16
 
17
	public static function construireUrl($tableau_params, $conserver_parametres_actuels = false) {
17
	public static function construireUrl($tableau_params, $conserver_parametres_actuels = false) {
18
		
18
 
19
		if ($conserver_parametres_actuels) {
19
		if ($conserver_parametres_actuels) {
20
			return '?'.http_build_query($tableau_params + $_GET);
20
			return '?'.http_build_query($tableau_params + $_GET);
21
		}
21
		}
22
		return '?'.http_build_query($tableau_params);
22
		return '?'.http_build_query($tableau_params);
23
	}
23
	}
24
	
24
 
25
	public static function getUrlSquelette() {
25
	public static function getUrlSquelette() {
26
    	    	
26
 
27
    	$url_base = self::getUrlBaseComplete();    	
27
    	$url_base = self::getUrlBaseComplete();
28
    	$url_base_squelette = $url_base.Config::get('dossier_squelettes').DS;
28
    	$url_base_squelette = $url_base.Config::get('dossier_squelettes').DS;
29
    	
29
 
30
    	return $url_base_squelette;
30
    	return $url_base_squelette;
31
    }
31
    }
32
    
32
 
33
    public static function getUrlStyle() {
33
    public static function getUrlStyle() {
34
    	$url_base_style = self::getUrlSquelette().'css'.DS;
34
    	$url_base_style = self::getUrlSquelette().'css'.DS;
35
    	
35
 
36
    	return $url_base_style;
36
    	return $url_base_style;
37
    }
37
    }
38
    
38
 
39
    public static function getUrlScript() {
39
    public static function getUrlScript() {
40
    	$url_base_script = self::getUrlSquelette().'js'.DS;
40
    	$url_base_script = self::getUrlSquelette().'js'.DS;
41
    	
41
 
42
    	return $url_base_script;
42
    	return $url_base_script;
43
    }
43
    }
44
    
44
 
45
    public static function getUrlImage() {
45
    public static function getUrlImage() {
46
    	$url_base_image = self::getUrlSquelette().'images'.DS;
46
    	$url_base_image = self::getUrlSquelette().'images'.DS;
47
    	
47
 
48
    	return $url_base_image;
48
    	return $url_base_image;
49
    }
49
    }
50
    
50
 
51
    public static function getUrlImageEspece($nom_sci, $format = 'CXS') {
51
    public static function getUrlImageEspece($nom_sci, $format = 'CXS') {
52
    	
52
 
53
    	$nom_sci_formate = strtolower(str_replace(' ', '_', $nom_sci));
53
    	$nom_sci_formate = strtolower(str_replace(' ', '_', $nom_sci));
54
    	
54
 
55
    	if(!file_exists(Config::get('dossier_images_especes').$format.'/'.$nom_sci_formate.'.jpg')) {
55
    	if(!file_exists(Config::get('dossier_images_especes').$format.'/'.$nom_sci_formate.'.jpg')) {
56
    		return Config::get('url_images_especes').$format.'/'.'vide.jpg';
56
    		return Config::get('url_images_especes').$format.'/'.'vide.jpg';
57
       	}
57
       	}
58
       	
58
 
59
    	return Config::get('url_images_especes').$format.'/'.$nom_sci_formate.'.jpg';
59
    	return Config::get('url_images_especes').$format.'/'.$nom_sci_formate.'.jpg';
60
    }
60
    }
61
    
61
 
62
    public static function getUrlFicheEspece($nom_sci) {
62
    public static function getUrlFicheEspece($nom_sci) {
63
    	
63
 
64
    	$nom_sci_formate = strtolower(str_replace(' ', '_', $nom_sci));
64
    	$nom_sci_formate = strtolower(str_replace(' ', '_', $nom_sci));
65
    	return Config::get('url_fiches_especes').$nom_sci_formate.'/';
65
    	return Config::get('url_fiches_especes').$nom_sci_formate.'/';
66
    }
66
    }
67
    
67
 
68
    public static function getUrlAdministrationEspeces() {
68
    public static function getUrlAdministrationEspeces() {
69
    	$params = array(
69
    	$params = array(
70
    	    		'module' => 'Administration',
70
    	    		'module' => 'Administration',
71
    	    		'action' => 'afficherListeEspecesAdministrables'
71
    	    		'action' => 'afficherListeEspecesAdministrables'
72
    	);
72
    	);
73
    	return self::construireUrl($params);
73
    	return self::construireUrl($params);
74
    }
74
    }
75
    
75
 
76
    public static function getCreditImageEspece($nom_sci) {
76
    public static function getCreditImageEspece($nom_sci) {
77
    	
77
 
78
    	$nom_sci_formate = strtolower(str_replace(' ', '_', $nom_sci));
78
    	$nom_sci_formate = strtolower(str_replace(' ', '_', $nom_sci));
79
    	
79
 
80
    	if(!file_exists(Config::get('dossier_images_especes').'/'.$nom_sci_formate.'.txt')) {
80
    	if(!file_exists(Config::get('dossier_images_especes').'/'.$nom_sci_formate.'.txt')) {
81
    		$credit = '';
81
    		$credit = '';
82
       	} else {
82
       	} else {
83
       		$credit = file_get_contents(Config::get('dossier_images_especes').'/'.$nom_sci_formate.'.txt');
83
       		$credit = file_get_contents(Config::get('dossier_images_especes').'/'.$nom_sci_formate.'.txt');
84
       		$credit = htmlentities($credit);
84
       		$credit = htmlentities($credit);
85
       	}
85
       	}
86
       	
86
 
87
       	if(trim($credit) != '') {
87
       	if(trim($credit) != '') {
88
       		$credit = 'Crédits : '.$credit;
88
       		$credit = 'Crédits : '.$credit;
89
       	}
89
       	}
90
       	
90
 
91
    	return $credit;
91
    	return $credit;
92
    }
92
    }
93
    
93
 
94
	public static function getUrlBaseReecrite() {
94
	public static function getUrlBaseReecrite() {
95
		
95
 
96
		if(isset($_SERVER['REDIRECT_URL']) && $_SERVER['REDIRECT_URL'] != '') {
96
		if(isset($_SERVER['REDIRECT_URL']) && $_SERVER['REDIRECT_URL'] != '') {
97
			
97
 
98
		}
98
		}
99
		
99
 
100
		$base_url_reecrite = 'http://'.$_SERVER['SERVER_NAME'].$_SERVER['REDIRECT_URL'];
100
		$base_url_reecrite = 'http://'.$_SERVER['SERVER_NAME'].$_SERVER['REDIRECT_URL'];
101
		$base_url_reecrite .= '/';
101
		$base_url_reecrite .= '/';
102
		
102
 
103
		return $base_url_reecrite;
103
		return $base_url_reecrite;
104
	}
104
	}
105
    
105
 
106
	public static function getUrlBase() {
106
	public static function getUrlBase() {
107
		
107
 
108
		$base_vrai_chemin = str_replace(realpath($_SERVER['DOCUMENT_ROOT']),'',realpath(Application::getChemin()));
108
		$base_vrai_chemin = str_replace(realpath($_SERVER['DOCUMENT_ROOT']),'',realpath(Application::getChemin()));
109
		$base_vrai_chemin .= '/';
109
		$base_vrai_chemin .= '/';
110
		
110
 
111
		return $base_vrai_chemin;
111
		return $base_vrai_chemin;
112
	}
112
	}
113
	
113
 
114
	public static function getUrlBaseComplete() {
114
	public static function getUrlBaseComplete() {
115
		return 'http://'.$_SERVER['SERVER_NAME'].str_replace(realpath($_SERVER['DOCUMENT_ROOT']),'',realpath(Application::getChemin())).'/';
115
		return 'http://'.$_SERVER['SERVER_NAME'].str_replace(realpath($_SERVER['DOCUMENT_ROOT']),'',realpath(Application::getChemin())).'/';
116
	}
116
	}
117
	
117
 
118
    public static function getUrlDefaut() {  	
118
    public static function getUrlDefaut() {
119
    	
119
 
120
    	$params = array();
120
    	$params = array();
121
    	return self::construireUrl($params);	
121
    	return self::construireUrl($params);
122
    }
122
    }
123
    
123
 
124
    public static function getUrlConsultationFicheStation($id_station) {  	
124
    public static function getUrlConsultationFicheStation($id_station) {
125
    	
125
 
126
    	$params = array(
126
    	$params = array(
127
    		'module' => 'Station',
127
    		'module' => 'Station',
128
    		'action' => 'afficherInformationsStation',
128
    		'action' => 'afficherInformationsStation',
129
    		'id_station' => $id_station
129
    		'id_station' => $id_station
130
    	);
130
    	);
131
    	return self::construireUrl($params);	
131
    	return self::construireUrl($params);
132
    }
132
    }
133
    
133
 
134
    public static function getUrlFormulaireSaisieStation() {
134
    public static function getUrlFormulaireSaisieStation() {
135
    	
135
 
136
    	$params = array(
136
    	$params = array(
137
    		'module' => 'Station',
137
    		'module' => 'Station',
138
    		'action' => 'afficherFormulaireSaisieStation',
138
    		'action' => 'afficherFormulaireSaisieStation',
139
    		'id_station' => 'saisie'
139
    		'id_station' => 'saisie'
140
    	);
140
    	);
141
    	return self::construireUrl($params);
141
    	return self::construireUrl($params);
142
    }
142
    }
143
    
143
 
144
    public static function getUrlValidationFormulaireSaisieStation() {
144
    public static function getUrlValidationFormulaireSaisieStation() {
145
    	$params = array(
145
    	$params = array(
146
    		'module' => 'Station',
146
    		'module' => 'Station',
147
    		'action' => 'validerFormulaireSaisieStation'
147
    		'action' => 'validerFormulaireSaisieStation'
148
    	);
148
    	);
149
    	return self::construireUrl($params);
149
    	return self::construireUrl($params);
150
    }
150
    }
151
    
151
 
152
    public static function getUrlFormulaireModificationStation($id_station) {
152
    public static function getUrlFormulaireModificationStation($id_station) {
153
    	$params = array(
153
    	$params = array(
154
    		'module' => 'Station',
154
    		'module' => 'Station',
155
    		'action' => 'afficherFormulaireModificationStation',
155
    		'action' => 'afficherFormulaireModificationStation',
156
    		'id_station' => $id_station
156
    		'id_station' => $id_station
157
    	);
157
    	);
158
    	return self::construireUrl($params);
158
    	return self::construireUrl($params);
159
    }
159
    }
160
    
160
 
161
    public static function getUrlValidationFormulaireModificationStation($id_station) {
161
    public static function getUrlValidationFormulaireModificationStation($id_station) {
162
    	$params = array(
162
    	$params = array(
163
    		'module' => 'Station',
163
    		'module' => 'Station',
164
    		'action' => 'validerFormulaireModificationStation',
164
    		'action' => 'validerFormulaireModificationStation',
165
    		'id_station' => $id_station
165
    		'id_station' => $id_station
166
    	);
166
    	);
167
    	return self::construireUrl($params);
167
    	return self::construireUrl($params);
168
    }
168
    }
169
    
169
 
170
    public static function getUrlFormulaireSuppressionStation() {
170
    public static function getUrlFormulaireSuppressionStation() {
171
    	
171
 
172
		$params = array(
172
		$params = array(
173
    		'module' => 'Station',
173
    		'module' => 'Station',
174
    		'action' => 'supprimerStation'
174
    		'action' => 'supprimerStation'
175
    	);
175
    	);
176
    	return self::construireUrl($params);
176
    	return self::construireUrl($params);
177
    }
177
    }
178
    
178
 
Line 179... Line 179...
179
	public static function getUrlFormulaireAjoutEspece($id_station) {  
179
	public static function getUrlFormulaireAjoutEspece($id_station) {
180
 
180
 
181
		$params = array(
181
		$params = array(
182
    		'module' => 'Espece',
182
    		'module' => 'Espece',
183
    		'action' => 'afficherFormulaireSaisieEspece',
183
    		'action' => 'afficherFormulaireSaisieEspece',
184
    		'id_station' => $id_station,
184
    		'id_station' => $id_station,
185
    		'id_espece' => 'saisie'
185
    		'id_espece' => 'saisie'
186
    	); 
186
    	);
187
    	
187
 
188
    	return self::construireUrl($params); 
188
    	return self::construireUrl($params);
189
	}
189
	}
190
	
190
 
191
	public static function getUrlValidationFormulaireSaisieEspece($id_station) {  
191
	public static function getUrlValidationFormulaireSaisieEspece($id_station) {
192
		
192
 
193
		$params = array(
193
		$params = array(
194
    		'module' => 'Espece',
194
    		'module' => 'Espece',
195
    		'action' => 'validerFormulaireSaisieEspece',
195
    		'action' => 'validerFormulaireSaisieEspece',
196
    		'id_station' => $id_station,
196
    		'id_station' => $id_station,
197
    		'id_espece' => 'saisie'
197
    		'id_espece' => 'saisie'
198
    	); 	
198
    	);
199
    	
199
 
200
    	return self::construireUrl($params); 	
200
    	return self::construireUrl($params);
201
	}
201
	}
Line 202... Line 202...
202
    
202
 
203
    public static function getUrlConsultationFicheIndividu($id_station, $id_espece, $id_individu) { 
203
    public static function getUrlConsultationFicheIndividu($id_station, $id_espece, $id_individu) {
204
 
204
 
205
    	$params = array(
205
    	$params = array(
206
    		'module' => 'Individu',
206
    		'module' => 'Individu',
207
    		'action' => 'afficherInformationsIndividu',
207
    		'action' => 'afficherInformationsIndividu',
208
    		'id_station' => $id_station,
208
    		'id_station' => $id_station,
209
    		'id_espece' => $id_espece,
209
    		'id_espece' => $id_espece,
210
    		'id_individu' => $id_individu
210
    		'id_individu' => $id_individu
211
    	);
211
    	);
212
    	return self::construireUrl($params);
212
    	return self::construireUrl($params);
213
    	
213
 
214
    }
214
    }
215
    
215
 
216
	public static function getUrlFormulaireSaisieIndividu($id_station, $id_espece) {  	
216
	public static function getUrlFormulaireSaisieIndividu($id_station, $id_espece) {
217
		
217
 
218
		$params = array(
218
		$params = array(
219
    		'module' => 'Individu',
219
    		'module' => 'Individu',
220
    		'action' => 'afficherFormulaireSaisieIndividu',
220
    		'action' => 'afficherFormulaireSaisieIndividu',
221
    		'id_station' => $id_station,
221
    		'id_station' => $id_station,
222
    		'id_espece' => $id_espece
222
    		'id_espece' => $id_espece
223
    	);
223
    	);
224
    	return self::construireUrl($params); 	
224
    	return self::construireUrl($params);
Line 225... Line 225...
225
    }
225
    }
226
    
226
 
227
	public static function getUrlValidationFormulaireSaisieIndividu($id_station, $id_espece) { 
227
	public static function getUrlValidationFormulaireSaisieIndividu($id_station, $id_espece) {
228
 
228
 
229
		$params = array(
229
		$params = array(
230
    		'module' => 'Individu',
230
    		'module' => 'Individu',
231
    		'action' => 'validerFormulaireSaisieIndividu',
231
    		'action' => 'validerFormulaireSaisieIndividu',
232
    		'id_station' => $id_station,
232
    		'id_station' => $id_station,
233
    		'id_espece' => $id_espece
233
    		'id_espece' => $id_espece
234
    	);
234
    	);
235
    	return self::construireUrl($params); 
235
    	return self::construireUrl($params);
236
    }
236
    }
237
    
237
 
238
	public static function getUrlFormulaireModificationIndividu($id_station, $id_espece, $id_individu) {  	
238
	public static function getUrlFormulaireModificationIndividu($id_station, $id_espece, $id_individu) {
239
		
239
 
240
		$params = array(
240
		$params = array(
241
    		'module' => 'Individu',
241
    		'module' => 'Individu',
242
    		'action' => 'afficherFormulaireModificationIndividu',
242
    		'action' => 'afficherFormulaireModificationIndividu',
243
    		'id_station' => $id_station,
243
    		'id_station' => $id_station,
244
    		'id_espece' => $id_espece,
244
    		'id_espece' => $id_espece,
245
			'id_individu' => $id_individu
245
			'id_individu' => $id_individu
246
    	);
246
    	);
Line 247... Line 247...
247
    	return self::construireUrl($params); 	
247
    	return self::construireUrl($params);
248
    }
248
    }
249
    
249
 
250
	public static function getUrlValidationFormulaireModificationIndividu($id_station, $id_espece, $id_individu) { 
250
	public static function getUrlValidationFormulaireModificationIndividu($id_station, $id_espece, $id_individu) {
251
 
251
 
252
		$params = array(
252
		$params = array(
253
    		'module' => 'Individu',
253
    		'module' => 'Individu',
254
    		'action' => 'validerFormulaireModificationIndividu',
254
    		'action' => 'validerFormulaireModificationIndividu',
255
    		'id_station' => $id_station,
255
    		'id_station' => $id_station,
256
    		'id_espece' => $id_espece,
256
    		'id_espece' => $id_espece,
257
			'id_individu' => $id_individu
257
			'id_individu' => $id_individu
Line 258... Line 258...
258
    	);
258
    	);
259
    	return self::construireUrl($params); 
259
    	return self::construireUrl($params);
260
    }
260
    }
261
    
261
 
262
	public static function getUrlSuppressionIndividu($id_station, $id_espece, $id_individu) { 
262
	public static function getUrlSuppressionIndividu($id_station, $id_espece, $id_individu) {
263
 
263
 
264
		$params = array(
264
		$params = array(
265
    		'module' => 'Individu',
265
    		'module' => 'Individu',
266
    		'action' => 'supprimerIndividu',
266
    		'action' => 'supprimerIndividu',
267
    		'id_station' => $id_station
267
    		'id_station' => $id_station
268
    	);
268
    	);
269
    	return self::construireUrl($params); 
269
    	return self::construireUrl($params);
270
    }
270
    }
271
  
271
 
272
    public static function getUrlConsultationEspeceStation($id_station, $id_espece, $annee = null) { 
272
    public static function getUrlConsultationEspeceStation($id_station, $id_espece, $annee = null) {
273
    	
273
 
274
        if($annee == null) {
274
        if($annee == null) {
275
    		$annee = date('Y');
275
    		$annee = date('Y');
276
    	}
276
    	}
277
    	
277
 
278
    	$params = array(
278
    	$params = array(
279
    		'module' => 'Individu',
279
    		'module' => 'Individu',
280
    		'action' => 'afficherListeIndividu',
280
    		'action' => 'afficherListeIndividu',
281
    		'id_station' => $id_station,
281
    		'id_station' => $id_station,
282
    		'id_espece' => $id_espece,
282
    		'id_espece' => $id_espece,
283
    		'annee' => $annee
283
    		'annee' => $annee
284
    	); 	
284
    	);
285
    	
285
 
286
    	return self::construireUrl($params); 
286
    	return self::construireUrl($params);
287
    }
287
    }
288
        
288
 
289
    public static function getUrlFormulaireModificationObservation($id_station,$id_espece, $id_individu, $annee = null) {
289
    public static function getUrlFormulaireModificationObservation($id_station,$id_espece, $id_individu, $annee = null) {
290
    	
290
 
291
        if($annee == null) {
291
        if($annee == null) {
292
    		$annee = date('Y');
292
    		$annee = date('Y');
293
    	}
293
    	}
294
    	
294
 
295
    	$params = array(
295
    	$params = array(
296
    		'module' => 'Observation',
296
    		'module' => 'Observation',
297
    		'action' => 'afficherFormulaireModificationObservation',
297
    		'action' => 'afficherFormulaireModificationObservation',
298
    		'id_station' => $id_station,
298
    		'id_station' => $id_station,
299
    		'id_espece' => $id_espece,
299
    		'id_espece' => $id_espece,
300
    		'id_individu' => $id_individu,
300
    		'id_individu' => $id_individu,
301
    		'annee' => $annee
301
    		'annee' => $annee
302
    	); 	
302
    	);
303
    	
303
 
304
    	return self::construireUrl($params); 	
304
    	return self::construireUrl($params);
305
    }
305
    }
306
    
306
 
307
	public static function getUrlValidationFormulaireModificationObservation($id_station,$id_espece, $id_individu, $annee = null) {
307
	public static function getUrlValidationFormulaireModificationObservation($id_station,$id_espece, $id_individu, $annee = null) {
308
		
308
 
309
		if($annee == null) {
309
		if($annee == null) {
310
    		$annee = date('Y');
310
    		$annee = date('Y');
311
    	}
311
    	}
312
    	
312
 
313
    	$params = array(
313
    	$params = array(
314
    		'module' => 'Observation',
314
    		'module' => 'Observation',
315
    		'action' => 'validerFormulaireModificationObservation',
315
    		'action' => 'validerFormulaireModificationObservation',
316
    		'id_station' => $id_station,
316
    		'id_station' => $id_station,
317
    		'id_espece' => $id_espece,
317
    		'id_espece' => $id_espece,
318
    		'id_individu' => $id_individu,
318
    		'id_individu' => $id_individu,
319
    		'annee' => $annee
319
    		'annee' => $annee
320
    	); 
320
    	);
321
    	
321
 
322
		return self::construireUrl($params); 
322
		return self::construireUrl($params);
323
    }
323
    }
324
    
324
 
325
	public static function getUrlExportDonneesObservations() {
325
	public static function getUrlExportDonneesObservations() {
326
		
326
 
327
		return Config::get('url_jrest').'OdsExport/FichierExportObservationCSV/'; 
327
		return Config::get('url_jrest').'OdsExport/FichierExportObservationCSV/';
328
    }
328
    }
329
    
329
 
330
	public static function getUrlExportDonneesObservationsPourUtilisateur() {
330
	public static function getUrlExportDonneesObservationsPourUtilisateur() {
331
		
331
 
332
		$params = array(
332
		$params = array(
333
    		'module' => 'Export',
333
    		'module' => 'Export',
334
    		'action' => 'envoyerFichierCSVExportObservation'
334
    		'action' => 'envoyerFichierCSVExportObservation'
335
    	); 
335
    	);
336
    	
336
 
337
		return self::construireUrl($params); 
337
		return self::construireUrl($params);
338
    }
338
    }
339
    
339
 
340
    public static function getUrlFormulaireAjoutEspeceAdmin() {
340
    public static function getUrlFormulaireAjoutEspeceAdmin() {
341
    
341
 
342
    	$params = array(
342
    	$params = array(
343
            		'module' => 'Administration',
343
            		'module' => 'Administration',
344
            		'action' => 'afficherFormulaireAjoutEspeceAdmin',
344
            		'action' => 'afficherFormulaireAjoutEspeceAdmin',
345
            		'id_espece' => $id_espece
345
            		'id_espece' => $id_espece
346
    	);
346
    	);
347
    	return self::construireUrl($params);
347
    	return self::construireUrl($params);
348
    }
348
    }
349
    
349
 
350
    public static function getUrlValidationFormulaireAjoutEspeceAdmin() {
350
    public static function getUrlValidationFormulaireAjoutEspeceAdmin() {
351
    	$params = array(
351
    	$params = array(
352
    	            		'module' => 'Administration',
352
    	            		'module' => 'Administration',
353
    	            		'action' => 'validerFormulaireAjoutEspeceAdmin',
353
    	            		'action' => 'validerFormulaireAjoutEspeceAdmin',
354
    	   				 	'id_espece' => $id_espece
354
    	   				 	'id_espece' => $id_espece
355
    	);
355
    	);
356
    	return self::construireUrl($params);
356
    	return self::construireUrl($params);
357
    }
357
    }
358
    
358
 
359
    public static function getUrlFormulaireModificationEspeceAdmin($id_espece) {
359
    public static function getUrlFormulaireModificationEspeceAdmin($id_espece) {
360
    	 
360
 
361
    	$params = array(
361
    	$params = array(
362
        		'module' => 'Administration',
362
        		'module' => 'Administration',
363
        		'action' => 'afficherFormulaireModificationEspeceAdmin',
363
        		'action' => 'afficherFormulaireModificationEspeceAdmin',
364
        		'id_espece' => $id_espece
364
        		'id_espece' => $id_espece
365
    	);
365
    	);
366
    	return self::construireUrl($params);
366
    	return self::construireUrl($params);
367
    }
367
    }
368
    
368
 
369
    public static function getUrlValidationFormulaireModificationEspeceAdmin($id_espece) {  
369
    public static function getUrlValidationFormulaireModificationEspeceAdmin($id_espece) {
370
	    $params = array(
370
	    $params = array(
371
	            		'module' => 'Administration',
371
	            		'module' => 'Administration',
372
	            		'action' => 'validerFormulaireModificationEspeceAdmin',
372
	            		'action' => 'validerFormulaireModificationEspeceAdmin',
373
	   				 	'id_espece' => $id_espece
373
	   				 	'id_espece' => $id_espece
374
	    );
374
	    );
375
	    return self::construireUrl($params);
375
	    return self::construireUrl($params);
376
    }
376
    }
377
    
377
 
378
    public static function getUrlFormulaireAjoutImageEspeceAdmin($id_espece) {
378
    public static function getUrlFormulaireAjoutImageEspeceAdmin($id_espece) {
379
    	$params = array(
379
    	$params = array(
380
        	            		'module' => 'Administration',
380
        	            		'module' => 'Administration',
381
        	            		'action' => 'afficherFormulaireAjoutImageEspeceAdmin',
381
        	            		'action' => 'afficherFormulaireAjoutImageEspeceAdmin',
382
        	   				 	'id_espece' => $id_espece
382
        	   				 	'id_espece' => $id_espece
383
    	);
383
    	);
384
    	return self::construireUrl($params);
384
    	return self::construireUrl($params);
385
    }
385
    }
386
    
386
 
387
    public static function getUrlValidationFormulaireAjoutImageEspeceAdmin($id_espece) {
387
    public static function getUrlValidationFormulaireAjoutImageEspeceAdmin($id_espece) {
388
    	$params = array(
388
    	$params = array(
389
    	            		'module' => 'Administration',
389
    	            		'module' => 'Administration',
390
    	            		'action' => 'validerFormulaireAjoutImageEspeceAdmin',
390
    	            		'action' => 'validerFormulaireAjoutImageEspeceAdmin',
391
    	   				 	'id_espece' => $id_espece
391
    	   				 	'id_espece' => $id_espece
392
    	);
392
    	);
393
    	return self::construireUrl($params);
393
    	return self::construireUrl($params);
394
    }
394
    }
395
    
395
 
396
    public static function renvoyerStylesInclus() {
396
    public static function renvoyerStylesInclus() {
397
    	
397
 
Line 398... Line 398...
398
    	$styles = '';
398
    	$styles = '';
399
    	$styles .= '<link href="'.self::getUrlStyle().'saisie.css" rel="stylesheet" type="text/css"/>';		
399
    	$styles .= '<link href="'.self::getUrlStyle().'saisie.css" rel="stylesheet" type="text/css"/>';
400
		$styles .= '<link href="'.self::getUrlStyle().'jquery_ui/jquery-ui-1.8.6.custom.css" rel="stylesheet" type="text/css"/>';
400
		$styles .= '<link href="'.self::getUrlStyle().'jquery_ui/jquery-ui-1.8.6.custom.css" rel="stylesheet" type="text/css"/>';
401
		$styles .= '<link href="'.self::getUrlStyle().'jquery_ui/jquery.ui.datepicker.css" rel="stylesheet" type="text/css"/>';
401
		$styles .= '<link href="'.self::getUrlStyle().'jquery_ui/jquery.ui.datepicker.css" rel="stylesheet" type="text/css"/>';
402
    	
402
 
403
    	return $styles;
403
    	return $styles;
404
    	
404
    	
405
    }
405
    }
406
    
406
 
407
	public static function renvoyerScriptsInclus() {
407
	public static function renvoyerScriptsInclus() {
408
		
408
 
409
    	$scripts = '<script type="text/javascript">'.
409
    	$scripts = '<script type="text/javascript">'.
410
    					' var urlBaseJrest = "'.Config::get('url_jrest').'"; '.
410
    					' var urlBaseJrest = "'.Config::get('url_jrest').'"; '.
411
    				'</script>';
411
    				'</script>';
412
    	$scripts .= '<script type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=false"></script>';
412
    	$scripts .= '<script type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=false&key=AIzaSyC_HBnP1YDEX1ATgnvylxkW2HImJV485ZQ"></script>';
413
    	$scripts .= '<script type="text/javascript" src="'.self::getUrlScript().'jquery-1.4.4.min.js"></script>';
413
    	$scripts .= '<script type="text/javascript" src="'.self::getUrlScript().'jquery-1.4.4.min.js"></script>';
414
    	$scripts .= '<script type="text/javascript" src="'.self::getUrlScript().'jquery_ui/jquery-ui-1.8.6.custom.min.js"></script>';
414
    	$scripts .= '<script type="text/javascript" src="'.self::getUrlScript().'jquery_ui/jquery-ui-1.8.6.custom.min.js"></script>';
415
		$scripts .= '<script type="text/javascript" src="'.self::getUrlScript().'saisie.js"></script>';
415
		$scripts .= '<script type="text/javascript" src="'.self::getUrlScript().'saisie.js"></script>';
416
		
416
 
417
		if(AppControleur::getUtilisateur()->estAdmin()) {
417
		if(AppControleur::getUtilisateur()->estAdmin()) {
418
			$scripts .= '<script type="text/javascript" src="'.self::getUrlScript().'saisie_admin.js"></script>';
418
			$scripts .= '<script type="text/javascript" src="'.self::getUrlScript().'saisie_admin.js"></script>';
419
		}
419
		}
420
		
420
 
421
    	$scripts .= '<script type="text/javascript" src="'.self::getUrlScript().'jquery_ui/jquery.ui.datepicker.js"></script>';
421
    	$scripts .= '<script type="text/javascript" src="'.self::getUrlScript().'jquery_ui/jquery.ui.datepicker.js"></script>';
422
    	$scripts .= '<script type="text/javascript" src="'.self::getUrlScript().'jquery_ui/jquery.ui.datepicker-fr.js"></script>';
422
    	$scripts .= '<script type="text/javascript" src="'.self::getUrlScript().'jquery_ui/jquery.ui.datepicker-fr.js"></script>';
423
    	
-
 
424
    	return $scripts;
423
 
-
 
424
    	return $scripts;