Subversion Repositories eFlore/Applications.cel

Rev

Rev 3532 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
3120 delphine 1
<!DOCTYPE html>
3208 idir 2
<html xmlns="https://www.w3.org/1999/xhtml">
3228 delphine 3
	<head>
3425 idir 4
		<title><?php echo strip_tags( $widget['titre'] ); ?></title>
3208 idir 5
 
3228 delphine 6
		<meta charset="utf-8" />
7
		<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
8
		<meta http-equiv="Content-style-type" content="text/css" />
9
		<meta http-equiv="Content-script-type" content="text/javascript" />
10
		<meta http-equiv="Content-language" content="fr" />
3208 idir 11
 
3228 delphine 12
		<meta name="revisit-after" content="15 days" />
13
		<meta name="robots" content="index,follow" />
14
		<meta name="author" content="Tela Botanica" />
15
		<meta name="keywords" content="Tela Botanica, CEL" />
3240 idir 16
		<meta name="description" content="Widgets de saisie du carnet en ligne" />
3228 delphine 17
		<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no, user-scalable=no" />
3120 delphine 18
 
3228 delphine 19
		<!-- OpenGraph pour Facebook, Pinterest, Google+ -->
20
		<meta property="og:type" content="website" />
21
		<meta property="og:title" content="Widgets de saisie du CeL" />
22
		<meta property="og:site_name" content="Tela Botanica" />
23
		<meta property="og:description" content="Widgets de saisie du Carnet en Ligne" />
24
		<meta property="og:image" content="https://resources.tela-botanica.org/tb/img/256x256/carre_englobant.png" />
25
		<meta property="og:image:type" content="image/png" />
26
		<meta property="og:image:width" content="256" />
27
		<meta property="og:image:height" content="256" />
28
		<meta property="og:locale" content="fr_FR" />
3120 delphine 29
 
3239 idir 30
		<!-- Favicone -->
3228 delphine 31
		<link rel="shortcut icon" type="image/x-icon" href="https://resources.tela-botanica.org/tb/img/16x16/favicon.ico" />
3239 idir 32
		<!-- Jquery-ui custom css-->
3228 delphine 33
		<link href="https://www.tela-botanica.org/commun/jquery/jquery-ui/1.8.18/css/smoothness/jquery-ui-1.8.18.custom.css" rel="stylesheet" type="text/css" media="screen" />
34
		<!-- Bootstrap CSS -->
35
		<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css" integrity="sha384-MCw98/SFnGE8fJT3GXwEOngsV7Zt27NXFoaoApmYm81iuXoPkFOJwJ8ERdknLPMO" crossorigin="anonymous" />
3239 idir 36
		<!-- Fontawesome -->
3260 idir 37
		<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.7.1/css/all.css" integrity="sha384-fnmOCqbTlWIlj8LyTjo7mOUStjsKC4pOpQbqyi7RrhN7udi9RwhKkMHpvLbHG9Sr" crossorigin="anonymous">
3239 idir 38
		<!-- Carto -->
3268 idir 39
		<link href="<?php echo $url_base; ?>js/tb-geoloc/styles.css" rel="stylesheet" type="text/css" media="screen" />
3239 idir 40
		<!-- STYLE SAISIE -->
3268 idir 41
		<link href="<?php echo $url_base; ?>css/saisie.css" rel="stylesheet" type="text/css" media="screen" />
3425 idir 42
		<link href="<?php echo $url_base; ?>css/saisieSpe.css" rel="stylesheet" type="text/css" media="screen" />
3120 delphine 43
 
3228 delphine 44
		<!--  Google Analytics -->
45
		<?php if( $prod ): ?>
46
			<?php include "analytics.html"; ?>
47
		<?php endif; ?>
3240 idir 48
		<!-- <link rel="icon" type="image/x-icon" href="favicon.ico" /> -->
3228 delphine 49
		<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet" />
3436 idir 50
		<style>
51
			.loading::after {
52
				content:'';
53
				display: inline-block;
54
				background-image: url("<?php echo $url_base; ?>img/icones/chargement-image.gif");
55
				background-size: 1rem;
56
				height: 1rem;
57
				width: 1rem;
58
			}
59
		</style>
3228 delphine 60
	</head>
3120 delphine 61
 
3425 idir 62
	<body id="top" data-sq="<?php echo $url_base; ?>" data-type-loc="<?php echo $widget['type_localisation'];?>">
3239 idir 63
		<?php
3240 idir 64
			echo ( $widget['image_fond'] ) ? '<div id="image-fond" style="' . htmlspecialchars( 'background:url("' . $widget['chemin_fichiers'] . 'image_fond.' . preg_replace( '/(?:imag)?e\/?/','',$widget['image_fond']) . '") no-repeat center center;background-size:cover') . '"></div>': '';
3239 idir 65
		?>
3248 idir 66
		<div id="zone-appli" class="container" data-projet="<?php echo $widget['projet']; ?>" data-url-fichiers="<?php echo $widget['chemin_fichiers']; ?>">
3228 delphine 67
			<div class="layout-wrapper page">
3260 idir 68
				<div class="row mb-3">
69
					<div class="col-md-2 col-sm-10">
70
						<img id="logo" class="mr-3" src="<?php echo htmlspecialchars( $widget['chemin_fichiers'] . 'logo.' . preg_replace( '/(?:imag)?e\/?/','', $widget['logo'] ) ); ?>" alt="logo <?php echo $widget['projet']; ?>" />
71
					</div>
72
					<div class="col-md-10 col-sm-12">
3239 idir 73
						<h1 id="titre-projet" class="mt-0"><?php echo ( $widget['info'] ) ? $widget['titre'] . ' <div id="info-button" class="btn btn-outline-info btn-sm border-0" data-mime-info="' . $widget['info'] . '"><i class="fas fa-info-circle"></i></div>' : $widget['titre']; ?></h1>
3228 delphine 74
					</div>
75
				</div>
3208 idir 76
 
3260 idir 77
				<div class="row mb-3">
3239 idir 78
					<div class="col-md-6">
3248 idir 79
						<div id="description"><?php echo $widget['description']; ?></div>
3239 idir 80
					</div>
81
					<div class="col-md-6">
82
						<div id="aide" class="well well-lg hidden-sm-down">
3248 idir 83
							<h3><?php echo $aide['titre']; ?></h3>
3239 idir 84
							<div id="aide-txt" class="hiden-sm-down">
3248 idir 85
								<p><?php echo $aide['description']; ?></p>
3228 delphine 86
							</div>
87
						</div>
88
					</div>
89
				</div>
3239 idir 90
 
91
				<div id="formulaire" class="row mb-3 bloc-top">
92
					<form id="form-observateur" role="form" autocomplete="on">
3248 idir 93
						<h2><?php echo $observateur['titre']; ?></h2>
3287 idir 94
						<div id="tb-observateur">
3239 idir 95
							<div class="navbar-default mb-3" id="tb-navbar">
3274 idir 96
								<div class="nav navbar-nav navbar-right row control-group">
3239 idir 97
									<div id="bouton-connexion" class="volet col-md-6 col-sm-8">
3248 idir 98
										<label for="bouton-connexion"><?php echo $observateur['compte']; ?></label>
3532 idir 99
										<a id="connexion" href="<?php echo $authTpl; ?>" class="btn btn-success  mr-1 mb-1" target="_blank"><?php echo $observateur['connexion']; ?></a>
3499 delphine 100
										<a id="inscription" href="" class="btn btn-primary mr-1 mb-1" target="_blank"><?php echo $observateur['inscription']; ?></a>
3239 idir 101
									</div>
102
									<div id="creation-compte" class="volet col-md-6 col-sm-8">
3248 idir 103
										<label for="creation-compte"><?php echo $observateur['noninscription']; ?></label>
3287 idir 104
										<a id="bouton-anonyme" href="" class="btn btn-info mr-1 mb-1"><?php echo $observateur['nonconnexion']; ?></a>
3239 idir 105
									</div>
106
									<div id="utilisateur-connecte" class="volet hidden">
3248 idir 107
										<label for="utilisateur-connecte"><?php echo $observateur['bienvenue']; ?></label>
3287 idir 108
										<a href="" class="list-tool btn btn-large btn-primary volet-toggle" data-toggle="volet">
3239 idir 109
											<span id="nom-complet"></span> <!-- <i class="fas fa-caret-down"></i> -->
110
										</a>
111
										<div class="volet-menu hidden">
112
											<div id="profil-utilisateur">
3499 delphine 113
												<a href="" target="_blank"><?php echo $observateur['profil']; ?></a>
3239 idir 114
											</div>
3287 idir 115
											<div id="deconnexion"><a href=""><?php echo $observateur['deconnexion']; ?></a></div>
3239 idir 116
										</div>
117
									</div>
118
								</div>
3228 delphine 119
							</div>
120
						</div>
3239 idir 121
 
3425 idir 122
						<div id="identite" class="mb-3 hidden">
123
							<p id="bienvenue" class=" col-md-6 hidden font-weight-bold">
124
								Bonjour<span id="bienvenue-prenom"></span><span id="bienvenue-nom"></span>!
125
							</p>
3239 idir 126
							<div id="zone-courriel" class="row">
127
								<div class="control-group col-md-6">
3248 idir 128
									<label for="courriel" class="col-sm-8 obligatoire" title="<?php echo $observateur['courriel-title']; ?>">
3239 idir 129
										<i class="fa fa-envelope" aria-hidden="true"></i>
3248 idir 130
										<?php echo $observateur['courriel']; ?>
3239 idir 131
									</label>
132
									<div class="col-sm-8 mb-3">
3248 idir 133
										<input id="courriel" name="courriel" class="form-control" type="email" title="<?php echo $observateur['courriel-title']; ?> ">
3239 idir 134
										<input id="id_utilisateur" name="id_utilisateur" type="hidden">
135
									</div>
136
								</div>
137
 
138
								<div id="zone-courriel-confirmation" class="control-group col-md-6 hidden">
3270 idir 139
									<label for="courriel_confirmation" class="col-sm-8 obligatoire" title="<?php echo $observateur['courriel-confirmation-title']; ?>">
3239 idir 140
										<i class="fa fa-envelope" aria-hidden="true"></i>
3248 idir 141
										<?php echo $observateur['courriel-confirmation']; ?>
3239 idir 142
									</label>
143
									<div class="col-sm-8">
144
										<input id="courriel_confirmation" name="courriel_confirmation" class="form-control" type="email">
145
									</div>
146
								</div>
3228 delphine 147
							</div>
3239 idir 148
 
149
							<div id="zone-prenom-nom" class="row hidden">
150
								<div class="control-group col-md-6">
151
									<label for="prenom" class="col-sm-8">
152
										<i class="fa fa-user" aria-hidden="true"></i>
3248 idir 153
										<?php echo $observateur['prenom']; ?>
3239 idir 154
									</label>
155
									<div class="input-group col-sm-8">
156
										<input id="prenom" name="prenom" class="form-control" type="text">
157
									</div>
158
								</div>
159
								<div class="control-group col-md-6">
160
									<label for="nom" class="col-sm-8">
161
										<i class="fa fa-user" aria-hidden="true"></i>
3248 idir 162
										<?php echo $observateur['nom']; ?>
3239 idir 163
									</label>
164
									<div class="input-group col-sm-8">
165
										<input id="nom" name="nom" class="form-control" type="text">
166
									</div>
167
								</div>
3228 delphine 168
							</div>
169
						</div>
3239 idir 170
					</form>
171
 
172
					<!-- Messages d'erreur du formulaire-->
3240 idir 173
					<div class="zone-alerte">
174
						<div id="dialogue-bloquer-copier-coller" class="alert alert-info alert-block hidden">
175
							<a class="close">×</a>
3248 idir 176
							<h4 class="alert-heading"><?php echo $observateur['alertcc-title']; ?></h4>
177
							<p><?php echo $observateur['alertcc']; ?></p>
3228 delphine 178
						</div>
3240 idir 179
						<div id="dialogue-utilisateur-non-identifie" class="alert alert-warning alert-block hidden">
180
							<a class="close">×</a>
3248 idir 181
							<h4 class="alert-heading"><?php echo $observateur['alertni-title']; ?></h4>
182
							<p><?php echo $observateur['alertni']; ?></p>
3240 idir 183
						</div>
3228 delphine 184
					</div>
3208 idir 185
 
3239 idir 186
					<form id="form-observation" role="form" autocomplete="on" class="bloc-top">
3248 idir 187
						<h2><?php echo $observation['titre']; ?></h2>
3239 idir 188
						<div id="zone-observation" class="row">
189
							<div class="col-md-6">
3208 idir 190
 
3268 idir 191
								<div class="mb-3">
3284 idir 192
									<label for="geolocalisation" class="col-sm-8 obligatoire has-tooltip" data-toggle="tooltip" title="<?php echo $observation['geoloc-title']; ?>">
3239 idir 193
										<i class="fa fa-street-view" aria-hidden="true"></i>
3248 idir 194
										<?php echo $observation['geolocalisation']; ?>
3239 idir 195
									</label>
3274 idir 196
									<div class="control-group">
197
										<div id="geoloc-datas">
198
											<input type="hidden" id="pays" name="pays" value="" style="display:none">
199
											<input type="hidden" id="commune-nom" name="commune-nom" value="" style="display:none">
3532 idir 200
											<input type="hidden" id="geometry" name="geometry" value="" style="display:none">
3274 idir 201
											<input type="hidden" id="latitude" name="latitude" value="" style="display:none">
202
											<input type="hidden" id="longitude" name="longitude" value="" style="display:none">
3279 idir 203
											<input type="hidden" id="altitude" name="altitude" value="" style="display:none">
3274 idir 204
											<input type="hidden" id="commune-insee" name="commune-insee" value="" style="display:none">
3330 idir 205
											<input type="hidden" id="coord-lineaire" name="coord-lineaire" value="" style="display:none">
3274 idir 206
										</div>
3425 idir 207
										<div id="geoloc" class="col-sm-12">
3274 idir 208
											<tb-geolocation-element
209
												id="tb-geolocation"
210
												layer='osm'
3425 idir 211
												zoom_init="<?php echo ( isset($widget['localisation']['zoom']) ) ? $widget['localisation']['zoom']: '4' ;?>"
212
												lat_init="<?php echo ( isset($widget['localisation']['latitude']) ) ? $widget['localisation']['latitude']: '46.5' ;?>"
213
												lng_init="<?php echo ( isset($widget['localisation']['longitude'])) ? $widget['localisation']['longitude'] : '2.9' ;?>"
3274 idir 214
												marker="<?php echo ( $widget['type_localisation'] === 'point' ) ? 'true' : 'false' ;?>"
215
												polyline="<?php echo ( $widget['type_localisation'] === 'rue' ) ? 'true' : 'false' ;?>"
216
												polygon="false"
217
												show_lat_lng_elevation_inputs="<?php echo ( $widget['type_localisation'] === 'point' ) ? 'true' : 'false' ;?>"
218
												osm_class_filter=""
219
												elevation_provider="mapquest"
220
												map_quest_api_key="mG6oU5clZHRHrOSnAV0QboFI7ahnGg34"
221
											>
222
											</tb-geolocation-element>
223
										</div>
3239 idir 224
									</div>
225
								</div>
226
 
3243 idir 227
								<div class="control-group">
3279 idir 228
									<label for="lieudit" class="col-sm-8">
3243 idir 229
										<i class="fa fa-map-signs" aria-hidden="true"></i>
3248 idir 230
										<?php echo $observation['lieudit']; ?>
3239 idir 231
									</label>
232
									<div class="col-sm-8 mb-3">
3284 idir 233
										<input type="text" id="lieudit" name="lieudit" class="form-control has-tooltip" data-toggle="tooltip" title="<?php echo $observation['lieudit-title']; ?>">
3239 idir 234
									</div>
235
								</div>
3243 idir 236
								<div class="control-group">
3279 idir 237
									<label for="station" class="col-sm-8">
3243 idir 238
										<i class="fa fa-map-marker" aria-hidden="true"></i>
3248 idir 239
										<?php echo $observation['station']; ?>
3243 idir 240
									</label>
241
									<div class="col-sm-8 mb-3">
3284 idir 242
										<input type="text" id="station" name="station" class="form-control has-tooltip" data-toggle="tooltip" data-placement="bottom"title="<?php echo $observation['station-title']; ?>">
3243 idir 243
									</div>
244
								</div>
3239 idir 245
 
3228 delphine 246
							</div>
3239 idir 247
 
248
							<div class="col-md-6">
249
 
250
								<div class="control-group">
3284 idir 251
									<label for="date_releve" class="col-sm-8 obligatoire">
3239 idir 252
										<i class="fa fa-calendar" aria-hidden="true"></i>
3248 idir 253
										<?php echo $observation['date']; ?>
3239 idir 254
									</label>
3284 idir 255
									<div class="col-sm-8 mb-3 has-tooltip" data-toggle="tooltip" title="<?php echo $observation['date-title']; ?>">
3285 idir 256
										<input type="date" id="date_releve" name="date_releve" class="form-control" max="<?php echo date('Y-m-d', time()); ?>" placeholder="jj/mm/aaaa" required>
3239 idir 257
									</div>
258
								</div>
259
 
3248 idir 260
								<?php if( ( $widget['type_especes'] === 'referentiel' || empty( $widget['type_especes'] ) ) && empty( $widget['referentiel'] ) ) : ?>
3239 idir 261
									<div class="control-group">
3279 idir 262
										<label for="referentiel" class="col-sm-8 obligatoire">
3239 idir 263
											<i class="fa fa-book" aria-hidden="true"></i>
3248 idir 264
											<?php echo $observation['referentiel']; ?>
3239 idir 265
										</label>
266
										<div class="col-sm-8 mb-3">
3284 idir 267
											<select id="referentiel" class="form-control custom-select has-tooltip" data-toggle="tooltip" title="<?php echo $observation['referentiel-title']; ?>">
3260 idir 268
												<option class="choisir" value="" selected hidden><?php echo $general['choisir']; ?></option>
3239 idir 269
												<option value="bdtfxr" selected="selected" title="Trachéophytes de France métropolitaine">Métropole (index réduit)</option>
270
												<option value="bdtfx" title="Trachéophytes de France métropolitaine">Métropole (BDTFX)</option>
271
												<option value="bdtxa" title="Trachéophytes des Antilles">Antilles françaises (BDTXA)</option>
272
												<option value="bdtre" title="Trachéophytes de La Réunion">Réunion (BDTRE)</option>
273
												<option value="aublet" title="Guyane">Guyane (AUBLET2)</option>
274
												<option value="florical" title="Nouvelle-Calédonie">Nouvelle-Calédonie (FLORICAL)</option>
275
												<option value="isfan" title="Afrique du Nord">Afrique du Nord (ISFAN)</option>
276
												<option value="apd" title="Afrique de l'Ouest et du Centre">Afrique de l'Ouest et du Centre (APD)</option>
277
												<option value="lbf" title="Liban">Liban (LBF)</option>
278
												<option value="autre" title="Autre/Inconnu">Autre/Inconnu</option>
279
											</select>
280
										</div>
281
									</div>
3228 delphine 282
								<?php else : ?>
3248 idir 283
									<input id="referentiel" name="referentiel" value="<?php echo $widget['referentiel']; ?>" type="hidden">
3228 delphine 284
								<?php endif; ?>
3208 idir 285
 
3270 idir 286
								<div id="bloc-taxon" class="control-group">
3260 idir 287
									<?php $isTaxonListe = ( isset( $widget['especes']['taxons'] ) && count( (array) $widget['especes']['taxons'] ) > 0 ) ;?>
3436 idir 288
									<label <?php echo ( !$isTaxonListe ) ? 'id="taxon-autocomplete-label" for="taxon"' : 'for="taxon-liste"';?> class="col-sm-8">
3239 idir 289
										<i class="fa fa-leaf" aria-hidden="true"></i>
3256 idir 290
										<?php echo $observation['espece']; ?><?php if ( !empty( $widget['referentiel'] ) ) echo " (" . $widget['referentiel'] . ")"; ?>
3239 idir 291
									</label>
292
									<div class="col-sm-8 mb-3">
3260 idir 293
										<?php if ( $widget['type_especes'] === 'fixe' || $widget['especes']['espece_imposee'] ) : ?>
3436 idir 294
													<input id="taxon" name="taxon" type="text" class="form-control taxon-validation" title="" value="<?php echo $widget['especes']['nom_sci_espece_defaut']; ?>"/>
3260 idir 295
												</div>
296
											</div>
3208 idir 297
 
3330 idir 298
										<?php elseif ( $isTaxonListe ) : ?>
3260 idir 299
											<?php ksort( $widget['especes']['taxons'] ); ?>
3284 idir 300
													<select id="taxon-liste" name="taxon-liste" class="form-control custom-select taxon-validation has-tooltip" data-toggle="tooltip" title="<?php echo $observation['liste-espece-title']; ?>">
3260 idir 301
														<option class="choisir"  value="inconnue" selected hidden><?php echo $general['choisir']; ?></option>
302
														<?php foreach ($widget['especes']['taxons'] as $taxon)  : ?>
303
															<option
304
																class="nom-sci"
305
																value="<?php echo $taxon['nom_sel'];?>"
306
																title="<?php echo $taxon['nom_fr'];?>"
307
																data-num-nom-sel="<?php echo $taxon['num_nom_sel'];?>"
308
																data-nom-ret="<?php echo $taxon['nom_ret'];?>"
309
																data-num-nom-ret="<?php echo $taxon['num_nom_ret'];?>"
310
																data-nt="<?php echo $taxon['num_taxon'];?>"
311
																data-famille="<?php echo $taxon['famille'];?>"
312
															><?php echo $taxon['nom_sel'];?></option>
313
														<?php endforeach; ?>
314
														<option value="autre"><?php echo $observation['autre-espece']; ?></option>
315
													</select>
3279 idir 316
													<span for="taxon-liste" class="error" style="display: none;"><?php echo $observation['error-taxon'];?></span>
3270 idir 317
													<input id="taxon" name="taxon" class="form-control" type="hidden" />
3260 idir 318
												</div>
319
											</div>
320
											<div id="taxon-input-groupe" class="control-group hidden">
3436 idir 321
												<label id="taxon-autocomplete-label" for="taxon-autre" class="col-sm-8" title="">
3260 idir 322
													<i class="fab fa-pagelines" aria-hidden="true"></i>
323
													<?php echo $observation['autre-espece']; ?>
324
												</label>
325
												<div class="col-sm-8 mb-3">
3284 idir 326
													<input id="taxon-autre" name="taxon-autre" class="form-control has-tooltip" type="text" data-toggle="tooltip" title="<?php echo $observation['espece-title']; ?>">
3260 idir 327
												</div>
328
											</div>
329
										<?php else : ?>
3284 idir 330
													<input id="taxon" name="taxon" class="form-control taxon-validation has-tooltip" type="text" data-toggle="tooltip" title="<?php echo $observation['espece-title']; ?>">
3279 idir 331
													<span for="taxon" class="error" style="display: none;"><?php echo $observation['error-taxon'];?></span>
3260 idir 332
												</div>
333
											</div>
334
										<?php endif; ?>
335
 
3239 idir 336
								<div class="control-group">
3279 idir 337
									<label for="certitude" class="col-sm-8 obligatoire">
3239 idir 338
										<i class="fa fa-question" aria-hidden="true"></i>
3248 idir 339
										<?php echo $observation['certitude']; ?>
3239 idir 340
									</label>
341
									<div class="col-sm-8 mb-3">
3284 idir 342
										<select id="certitude" name="certitude" class="form-control custom-select has-tooltip" data-toggle="tooltip" title="<?php echo $observation['certitude-title']; ?>">
3263 idir 343
											<option class="aDeterminer" value="à determiner" ><?php echo $observation['certADet']; ?></option>
3532 idir 344
											<option class="douteux" value="douteux" ><?php echo $observation['certDout']; ?></option>
345
											<option class="certain" value="certain" selected="selected" ><?php echo $observation['certCert']; ?></option>
3239 idir 346
										</select>
347
									</div>
348
								</div>
3352 idir 349
								<!-- choix du (des) milieu(x) -->
350
								<?php if ( 0 < count( (array) $widget['milieux'] ) ) :?>
351
									<?php if ( in_array('multimilieux', $widget['milieux'] ) ) :?>
352
										<div class="multiselect list-checkbox">
353
											<label class="col-sm-8" title="<?php echo $chpsupp['select-checkboxes-texte'];?>">
354
												<i class="fa fa-street-view" aria-hidden="true"></i>
355
												<?php echo $observation['milieu']; ?>
356
											</label>
357
											<div class="control-group col-sm-8 mb-3 has-tooltip" data-toggle="tooltip" title="<?php echo $observation['liste-milieu-title']; ?>">
358
												<div class="selectBox">
359
													<select class="form-control list-checkbox custom-select" id="list-checkbox-milieu">
360
														<option><?php echo $chpsupp['select-checkboxes-texte'];?></option>
361
													</select>
362
													<div class="overSelect"></div>
363
												</div>
364
												<div class="checkboxes hidden" data-name="milieu">
3331 idir 365
													<?php foreach ( $widget['milieux'] as $milieu ) :?>
3352 idir 366
														<?php if ( 'autre' !== strtolower( $milieu ) && 'multimilieux' !== strtolower( $milieu ) ) :?>
367
															<label for="<?php echo strtolower( $milieu );?>">
368
																<input type="checkbox" id="<?php echo strtolower( $milieu );?>" name="milieu" value="<?php echo $milieu;?>" class="<?php echo strtolower( $milieu );?> milieu" data-label="<?php echo $observation['milieu']; ?>" data-name="milieu">
369
																<?php echo $milieu;?>
370
															</label>
3331 idir 371
														<?php endif; ?>
372
													<?php endforeach; ?>
3352 idir 373
													<?php if ( in_array('autre', $widget['milieux'] ) ) :?>
374
														<label for="other-milieu">
375
															<input type="checkbox" id="other-milieu" name="milieu" value="other" class="other milieu" data-label="<?php echo $observation['milieu']; ?>" data-element="checkboxes" data-name="milieu">
376
															Autre
377
														</label>
378
													<?php endif; ?>
379
												</div>
3331 idir 380
											</div>
3352 idir 381
										</div>
382
									<?php else : ?>
383
										<div class="">
384
											<label for="milieu" class="col-sm-8">
385
												<i class="fa fa-street-view" aria-hidden="true"></i>
386
												<?php echo $observation['milieu']; ?>
387
											</label>
388
											<div class="col-sm-8 mb-3">
389
												<div class="select-wrapper add-field-select">
390
													<select id="milieu" class="form-control milieu select custom-select has-tooltip mb-2" data-toggle="tooltip" title="<?php echo $observation['liste-milieu-title']; ?>" data-name="milieu" data-label="milieu">
391
														<option class="choisir" value="" selected hidden><?php echo $general['choisir']; ?></option>
392
														<?php foreach ( $widget['milieux'] as $milieu ) :?>
393
															<?php if ( 'autre' !== strtolower( $milieu ) && 'multimilieux' !== strtolower( $milieu ) ) :?>
394
																<option value="<?php echo $milieu; ?>" data-name="milieu"><?php echo $milieu; ?></option>
395
															<?php endif; ?>
396
														<?php endforeach; ?>
397
														<?php if ( in_array('autre', $widget['milieux'] ) ) :?>
398
															<option id="other-milieu" class="other form-control is-select" value="other" data-element="select" data-name="milieu"><?php echo $milieu; ?></option>
399
														<?php endif; ?>
400
													</select>
401
												</div>
402
											</div>
403
										</div>
404
									<?php endif; ?>
405
								<?php else : ?>
406
									<div class="">
407
										<label for="milieu" class="col-sm-8">
408
											<i class="fa fa-street-view" aria-hidden="true"></i>
409
											<?php echo $observation['milieu']; ?>
410
										</label>
411
										<div class="col-sm-8 mb-3">
3284 idir 412
											<input id="milieu" name="milieu" class="form-control has-tooltip" data-toggle="tooltip" type="text" placeholder="<?php echo $observation['milieu-ph']; ?>" title="<?php echo $observation['milieu-title']; ?>">
3352 idir 413
										</div>
3243 idir 414
									</div>
3352 idir 415
								<?php endif; ?><!-- fin choix milieu(x) -->
3243 idir 416
								<div class="">
3279 idir 417
									<label for="notes" class="col-sm-8">
3260 idir 418
										<i class="fa fa-pen" aria-hidden="true"></i>
419
										<?php echo $observation['notes']; ?>
420
									</label>
421
									<div class="col-sm-8 mb-3">
3284 idir 422
										<textarea id="notes" form="form-observation" class="col-md-12 has-tooltip" data-toggle="tooltip" rows="7" name="notes" placeholder="<?php echo $observation['notes_ph']; ?>" title="<?php echo $observation['notes-title']; ?>"></textarea>
3260 idir 423
									</div>
424
								</div>
3208 idir 425
 
3230 delphine 426
							</div>
427
						</div>
3239 idir 428
					</form>
3208 idir 429
 
3260 idir 430
					<!-- Messages d'erreur du formulaire-->
431
					<div class="zone-alerte">
432
						<div id="dialogue-geoloc-ko" class="alert alert-warning alert-block hidden">
433
							<a class="close">×</a>
434
							<h4 class="alert-heading"><?php echo $observation['alertgk-title']; ?></h4>
435
							<p><?php echo $observation['alertgk']; ?></p>
436
						</div>
437
						<div id="dialogue-taxon-or-image" class="alert alert-warning alert-block hidden">
438
							<a class="close">×</a>
439
							<h4 class="alert-heading"><?php echo $observation['alert-img-tax-title']; ?></h4>
440
							<p><?php echo $observation['alert-img-tax']; ?></p>
441
						</div>
442
					</div>
443
 
3239 idir 444
					<!-- Champs supplémentaires -->
445
					<?php if ( isset($widget['chpSupp'] ) && 0 < count( (array) $widget['chpSupp'] ) ) : ?>
446
						<form id="form-supp"  class="bloc-top" role="form" autocomplete="on">
3248 idir 447
							<h2><?php echo $chpsupp['titre']; ?></h2>
3239 idir 448
							<div id="zone-supp" class="row">
3208 idir 449
 
3348 idir 450
								<?php foreach( $widget['chpSupp'][ $widget['projet'] ]['champs-supp'] as $champ ) : ?>
451
									<?php
452
										$min         = ( isset( $champ['fieldValues']['min'] ) )? ' min="' . $champ['fieldValues']['min'] . '"':'';
453
										$max         = ( isset( $champ['fieldValues']['max'] ) )? ' max="' . $champ['fieldValues']['max'] . '"':'';
454
										$step        = ( isset( $champ['fieldValues']['step'] ) )? ' step="' . $champ['fieldValues']['step'] . '"':'';
455
										$default     = ( isset( $champ['fieldValues']['default'] ) )? ' value="' . $champ['fieldValues']['default'] . '" data-default="' . $champ['fieldValues']['default'] . '"' :'';
456
										$description = ( isset( $champ['description'] ) )? ' data-toggle="tooltip" title="' . $champ['description'] . '"':'';
457
										$placeholder = ( isset( $champ['fieldValues']['placeholder'] ) )? ' placeholder="' . $champ['fieldValues']['placeholder'] . '"':'';
458
										$required    = '';
459
										$mandatory   = '';
460
										$pattern     = '';
461
										$obs_radio   = '';
462
										$help        = '';
463
										$help_button = '';
464
 
465
										if( $champ['help'] ) {
466
											$help = ' and-help';
467
											$help_button = ' <div class="help-button help-' . $champ['key'] . ' btn btn-outline-info btn-sm border-0" data-key="' . $champ['key'] . '" data-name="' . $champ['name'] . '" data-mime-type="' . $champ['help'] . '"><i class="fas fa-info-circle"></i></div>';
468
										}
469
 
470
										if( $champ['mandatory'] ) {
471
											// Attr required
472
											$required  = ' required';
473
											// class="obligatoire"
474
											$mandatory = ' obligatoire';
475
										}?>
476
											<div class="col-md-6">
3239 idir 477
										<?php
3348 idir 478
										switch( $champ['element'] ) {
479
											case 'radio':
480
											case 'checkbox': ?>
481
												<div class="control-group <?php echo $champ['element']; ?> mb-3"<?php echo $required; ?> data-name="<?php echo $champ['key']; ?>[]">
482
													<div class="col-sm-8 list-label<?php echo $help . $mandatory; ?>">
483
														<?php echo $champ['name'] . $help_button; ?>
484
													</div>
485
													<div class="col-sm-8 has-tooltip" <?php echo $description; ?>>
3208 idir 486
 
3348 idir 487
														<?php foreach ( $champ['fieldValues']['listValue'] as $i => $list_value_array ) : ?>
3208 idir 488
 
3348 idir 489
																<?php
490
																	$checked = '';
491
																	if ( '#' === substr( $list_value_array[0], -1 ) ) :
492
																		$checked = ' checked';
493
																		$list_value_array[0] = substr( $list_value_array[0], 0, -1 );
494
																	endif;
495
																?>
3208 idir 496
 
3348 idir 497
																<?php if( 'other' !== $list_value_array ) : ?>
498
																	<label for="<?php echo $champ['fieldValues']['cleanListValue'][$i]; ?>" class="<?php echo $champ['fieldValues']['cleanListValue'][$i]; ?>">
499
																		<input type="<?php echo $champ['element']; ?>" id="<?php echo $champ['fieldValues']['cleanListValue'][$i]; ?>" name="<?php echo $champ['key']; ?>[]" value="<?php echo $list_value_array[0]; ?>"<?php echo $checked; ?> class="<?php echo $champ['fieldValues']['cleanListValue'][$i] . ' ' . $champ['key']; ?>" data-label="<?php echo $champ['name']; ?>" data-name="<?php echo $champ['key']; ?>">
500
																		<?php echo ( '' !== $list_value_array[1] ) ? ucfirst($list_value_array[1]) : ucfirst($list_value_array[0]); ?>
501
																	</label>
502
																<?php else : ?>
503
																	<label for="other-<?php echo $champ['key']; ?>">
504
																		<input type="<?php echo $champ['element']; ?>" id="other-<?php echo $champ['key']; ?>" name="<?php echo $champ['key']; ?>[]" value="other" class="other <?php echo $champ['key']; ?>" data-label="<?php echo $champ['name']; ?>" data-element="<?php echo $champ['element']; ?>" data-name="<?php echo $champ['key']; ?>">
505
																		Autre
506
																	</label>
507
																<?php endif; ?>
508
 
509
														<?php endforeach; ?>
510
 
511
													</div>
512
												</div>
513
											<?php break;
514
 
515
											case 'list-checkbox': ?>
516
												<div class="multiselect <?php echo $champ['element'] . $help; ?>">
517
													<label class="col-sm-8<?php echo $mandatory; ?>" title="<?php echo $chpsupp['select-checkboxes-texte'];?>">
518
														<?php echo $champ['name'] . $help_button; ?>
519
													</label>
520
													<div class="control-group col-sm-8 mb-3 has-tooltip" <?php echo $description; ?>>
521
														<div class="selectBox">
522
															<select class="form-control list-checkbox custom-select" id="list-checkbox-<?php echo $champ['key']; ?>">
523
																<option><?php echo $chpsupp['select-checkboxes-texte'];?></option>
524
															</select>
525
															<div class="overSelect"></div>
3239 idir 526
														</div>
3348 idir 527
														<div class="checkboxes hidden" <?php echo $required; ?> data-name="<?php echo $champ['key']; ?>[]">
3347 idir 528
															<?php foreach ( $champ['fieldValues']['listValue'] as $i => $list_value_array ) : ?>
3208 idir 529
 
3348 idir 530
																<?php
531
																	$checked = '';
532
																	if ( '#' === substr( $list_value_array[0], -1 ) ) :
533
																		$checked = ' checked';
534
																		$list_value_array[0] = substr( $list_value_array[0], 0, -1 );
535
																	endif;
536
																?>
3208 idir 537
 
3348 idir 538
																<?php if( 'other' !== $list_value_array ) : ?>
539
																	<label for="<?php echo $champ['fieldValues']['cleanListValue'][$i]; ?>">
540
																		<input type="checkbox" id="<?php echo $champ['fieldValues']['cleanListValue'][$i]; ?>" name="<?php echo $champ['key']; ?>[]" value="<?php echo $list_value_array[0]; ?>"<?php echo $checked; ?> class="<?php echo $champ['fieldValues']['cleanListValue'][$i] . ' ' . $champ['key']; ?>" data-label="<?php echo $champ['name']; ?>" data-name="<?php echo $champ['key']; ?>">
541
																		<?php echo ( '' !== $list_value_array[1] ) ? ucfirst($list_value_array[1]) : ucfirst($list_value_array[0]); ?>
542
																	</label>
543
																<?php else : ?>
544
																	<label for="other-<?php echo $champ['key']; ?>">
545
																		<input type="checkbox" id="other-<?php echo $champ['key']; ?>" name="<?php echo $champ['key']; ?>[]" value="other" class="other <?php echo $champ['key']; ?>" data-label="<?php echo $champ['name']; ?>" data-element="checkboxes" data-name="<?php echo $champ['key']; ?>">
546
																		Autre
547
																	</label>
548
																<?php endif; ?>
3208 idir 549
 
3239 idir 550
															<?php endforeach; ?>
3208 idir 551
 
3239 idir 552
														</div>
553
													</div>
3348 idir 554
												</div>
555
											<?php break;
3208 idir 556
 
3348 idir 557
											case 'select': ?>
558
												<div class="control-group mb-3">
559
													<label for="<?php echo $champ['key']; ?>" class="col-sm-8<?php echo $mandatory; ?>"><?php echo $champ['name'] . $help_button; ?></label>
560
													<div class="col-sm-8 mb-3">
561
														<div class="select-wrapper add-field-select <?php echo $help; ?>">
562
															<select id="<?php echo $champ['key']; ?>" class="<?php echo $champ['key'] . ' ' . $champ['element']; ?> form-control has-tooltip custom-select mb-2"<?php echo $required; ?> data-label="<?php echo $champ['name']; ?>" data-name="<?php echo $champ['key']; ?>" <?php echo $description; ?>>
3208 idir 563
 
3348 idir 564
																<?php foreach ( $champ['fieldValues']['listValue'] as $list_value_array ) : ?>
565
 
3239 idir 566
																	<?php
3348 idir 567
																		$selected = '';
3347 idir 568
																		if ( '#' === substr( $list_value_array[0], -1 ) ) :
3348 idir 569
																			$selected = ' selected="selected"';
3347 idir 570
																			$list_value_array[0] = substr( $list_value_array[0], 0, -1 );
3239 idir 571
																		endif;
572
																	?>
3208 idir 573
 
3347 idir 574
																	<?php if( 'other' !== $list_value_array ) : ?>
3348 idir 575
																		<option value="<?php echo $list_value_array[0]; ?>"<?php echo $selected; ?> data-name="<?php echo $champ['key']; ?>">
3347 idir 576
																			<?php echo ( '' !== $list_value_array[1] ) ? ucfirst($list_value_array[1]) : ucfirst($list_value_array[0]); ?>
3348 idir 577
																		</option>
3239 idir 578
																	<?php else : ?>
3348 idir 579
																		<option id="other-<?php echo $champ['key']; ?>" class="other form-control is-select" value="other" data-element="<?php echo $champ['element']; ?>" data-name="<?php echo $champ['key']; ?>">Autre</option>
3239 idir 580
																	<?php endif; ?>
581
																<?php endforeach; ?>
3348 idir 582
															</select>
3239 idir 583
														</div>
584
													</div>
3348 idir 585
												</div>
586
											<?php break;
3208 idir 587
 
3348 idir 588
											case 'textarea': ?>
589
												<div class="control-group">
590
													<label for="<?php echo $champ['key']; ?>" class="col-sm-8<?php echo $help . $mandatory; ?> " ><?php echo $champ['name'] . $help_button; ?></label>
591
													<div class="col-sm-8 mb-3">
592
														<textarea type="<?php echo $champ['element']; ?>" id="<?php echo $champ['key']; ?>" name="<?php echo $champ['key']; ?>" class="<?php echo $champ['key'] . $help; ?> form-control has-tooltip" <?php echo $description . $placeholder . $required; ?> data-label="<?php echo $champ['name']; ?>"></textarea>
3239 idir 593
													</div>
3348 idir 594
												</div>
595
											<?php break;
3208 idir 596
 
3348 idir 597
											case 'range': ?>
598
												<div class="control-group">
599
													<label for="<?php echo $champ['key']; ?>" class="col-sm-8<?php echo $help . $mandatory; ?>"><?php echo $champ['name'] . $help_button; ?></label>
600
													<div class="col-sm-8 mb-3 row">
601
														<?php
602
															$div_range_min_max = '';
3208 idir 603
 
3348 idir 604
															if ( isset( $champ['fieldValues']['min'] ) )  {
605
																$div_range_min_max =
606
																	"<p class=\"col-2 range-values text-center font-weight-bold\">".
607
																		"Min " . $champ['fieldValues']['min'] .
608
																	"</p>";
609
															}
3208 idir 610
 
3348 idir 611
															$div_range_min_max .= '<div class="range-live-value range-values text-center font-weight-bold col-';
3208 idir 612
 
3348 idir 613
															if ( isset( $champ['fieldValues']['min'] ) && isset( $champ['fieldValues']['max'] ) ) {
614
																$div_range_min_max .= '8';
615
															} elseif ( isset( $champ['fieldValues']['min'] ) || isset( $champ['fieldValues']['max'] ) ) {
616
																$div_range_min_max .= '10';
617
															} else {
618
																$div_range_min_max .= '12';
619
															}
3208 idir 620
 
3348 idir 621
															$div_range_min_max .= '" onload="this.innerText = document.getElementById(&apos;ajouter-obs&apos;).value"></div>';
3208 idir 622
 
3348 idir 623
															if( isset( $champ['fieldValues']['max'] ) ) {
624
																$div_range_min_max .=
625
																	"<p class=\"col-2 range-values text-center font-weight-bold\">".
626
																		"Max " . $champ['fieldValues']['max'] .
627
																	"</p>";
628
															}
3208 idir 629
 
3348 idir 630
															echo $div_range_min_max;
631
														?>
632
														<input type="<?php echo $champ['element']; ?>" name="<?php echo $champ['key']; ?>" class="pl-3 custom-range <?php echo $champ['key'] . $help; ?> form-control has-tooltip" <?php echo $description . $placeholder . $step . $default . $min . $max . $required; ?> data-label="<?php echo $champ['name']; ?>">
3239 idir 633
													</div>
3348 idir 634
												</div>
635
												<?php break;
3208 idir 636
 
3348 idir 637
											case 'number':
638
											case 'date': ?>
639
												<div class="control-group">
640
													<label for="<?php echo $champ['key']; ?>" class="col-sm-8<?php echo $mandatory; ?>"><?php echo $champ['name'] . $help_button; ?></label>
641
													<div class="col-sm-8 mb-3">
642
														<input type="<?php echo $champ['element']; ?>" name="<?php echo $champ['key']; ?>" class="<?php echo $champ['key'] . $help; ?> form-control has-tooltip"<?php echo  $pattern . $description . $placeholder . $step . $default . $min . $max . $required; ?> data-label="<?php echo $champ['name']; ?>">
3239 idir 643
													</div>
3348 idir 644
												</div>
645
												<?php break;
3208 idir 646
 
3348 idir 647
											case 'text' :
648
											case 'email':
649
											default: ?>
650
												<div class="control-group">
651
													<label for="<?php echo $champ['key']; ?>" class="col-sm-8<?php echo $mandatory; ?>"><?php echo $champ['name'] . $help_button; ?></label>
652
													<div class="col-sm-8 mb-3">
653
														<input type="<?php echo $champ['element']; ?>" name="<?php echo $champ['key']; ?>" class="<?php echo $champ['key'] . $help; ?> form-control has-tooltip" <?php echo $description . $placeholder . $required; ?> data-label="<?php echo $champ['name']; ?>">
3239 idir 654
													</div>
3348 idir 655
												</div>
656
											<?php break;
657
										}
658
									?>
659
										</div>
660
								<?php endforeach; ?>
3239 idir 661
							</div>
662
						</form>
663
					<?php endif; ?><!-- Fin champs supplémentaires -->
3208 idir 664
 
3248 idir 665
					<form id="form-upload" class="form-horizontal bloc-top" action="<?php echo $url_ws_upload ?>" method="post" enctype="multipart/form-data">
666
						<h2><?php echo $image['titre']; ?></h2>
3330 idir 667
						<p id="miniature-info">
3248 idir 668
							<?php echo $image['aide']; ?>
3239 idir 669
						</p>
3428 idir 670
						<div id ="photos-conteneur" class="control-group col-sm-12">
3239 idir 671
							<div>
672
								<label for="fichier" class="label-file btn btn-large btn-info mb-3">
3248 idir 673
									<span class="label-text"><i class="fas fa-download"></i> <?php echo $image['ajouter']; ?></span>
3239 idir 674
									<input type="file" id="fichier" name="fichier" class="input-file" accept="image/jpeg" multiple>
675
									<input type="hidden" name="MAX_FILE_SIZE" value="5242880">
676
								</label>
677
							</div>
3284 idir 678
							<span for="fichier" class="error" style="display: none;"><?php echo $observation['error-taxon'];?></span>
3208 idir 679
 
3239 idir 680
							<div id="miniatures"></div>
681
							<p class="miniature-msg" class="span12">&nbsp;</p>
682
						</div>
683
					</form>
3208 idir 684
 
3239 idir 685
					<div id="image" class="row"></div>
686
				</div>
3208 idir 687
 
3239 idir 688
				<!-- Bouton cr&ation d'une obs -->
3240 idir 689
				<div class="row mb-3">
3248 idir 690
					<div class="centre" title="<?php echo $resume['creer-title']; ?>">
3269 idir 691
						<button id="ajouter-obs" class="btn btn-success"><i class="fas fa-check-square"></i> <?php echo $resume['creer']; ?></button>
3239 idir 692
					</div>
693
				</div>
3208 idir 694
 
3239 idir 695
				<!-- Messages d'erreur du formulaire-->
696
				<div class="row">
697
					<div class="zone-alerte">
3433 idir 698
						<div id="message-chargement" class="alert alert-secondary alert-block hidden">
699
							<a class="close">×</a>
700
							<h4 class="alert-heading"><?php echo $resume['alertchargt']; ?></h4>
701
							<p><?php echo $resume['alertchargt-desc']; ?></p>
702
						</div>
703
					</div>
704
					<div class="zone-alerte">
3239 idir 705
						<div id="dialogue-bloquer-creer-obs" class="alert alert-warning alert-block hidden">
706
							<a class="close">×</a>
3248 idir 707
							<h4 class="alert-heading"><?php echo $resume['alert10max']; ?></h4>
708
							<p><?php echo $resume['alert10max-desc']; ?></p>
3239 idir 709
						</div>
710
					</div>
711
					<div class="zone-alerte">
712
						<div id="dialogue-form-invalide" class="alert alert-warning alert-block hidden">
713
							<a class="close">×</a>
3248 idir 714
							<h4 class="alert-heading"><?php echo $resume['alertchp']; ?></h4>
715
							<p><?php echo $resume['alertchp-desc']; ?></p>
3239 idir 716
						</div>
717
					</div>
718
				</div>
3208 idir 719
 
3239 idir 720
				<!-- Affiche le tableau récapitualif des observations ajoutées -->
3240 idir 721
				<div id="zone-liste-obs" class="bloc-top hidden">
3239 idir 722
					<div class="alert alert-info">
3248 idir 723
						<h2 class="transmission-title"><strong><?php echo $resume['titre']; ?> <span class="obs-nbre badge badge-info">0</span></strong></h2>
3269 idir 724
						<button id="transmettre-obs" class="btn btn-success droite" disabled="disabled"
3248 idir 725
							title="<?php echo $resume['trans-title']; ?>" type="button">
726
							<?php echo $resume['trans']; ?>
3239 idir 727
						</button>
728
					</div>
3260 idir 729
					<!-- chargement -->
730
					<div id="chargement" class="modal-fenetre hidden">
731
						<div id="chargement-centrage" class="modal-contenu">
732
							<div class="progress active">
733
								<div id="barre-progression-upload" class="progress-bar progress-bar-striped" role="progressbar" aria-valuenow="0" aria-valuemin="0" aria-valuemax="10" style="">
734
										<span class="sr-only">0/10 <?php echo $resume['nbobs']; ?></span>
735
									</div>
736
							</div>
737
							<p id="chargement-txt"><?php echo $resume['transencours']; ?></p>
738
						</div>
739
					</div>
3239 idir 740
					<div id="liste-obs" ></div>
741
					<div class="row">
742
						<div class="zone-alerte">
743
							<div id="dialogue-zero-obs" class="alert alert-block hidden">
744
								<a class="close">×</a>
3248 idir 745
								<h4 class="alert-heading"><?php echo $resume['alert0obs']; ?></h4>
746
								<p><?php echo $resume['alert0obs-desc']; ?></p>
3239 idir 747
							</div>
748
							<div id="dialogue-obs-transaction-ok" class="alert alert-success alert-block hidden">
749
								<a class="close">×</a>
3248 idir 750
								<h4 class="alert-heading"><?php echo $resume['info-trans']; ?></h4>
3239 idir 751
								<div class="alert-txt"></div>
752
							</div>
753
							<div id="dialogue-obs-transaction-ko" class="alert alert-error alert-block hidden">
754
								<a class="close">×</a>
3248 idir 755
								<h4 class="alert-heading"><?php echo $resume['alerttrans']; ?></h4>
3239 idir 756
								<div class="alert-txt"></div>
757
							</div>
758
						</div>
759
					</div>
760
				</div>
3208 idir 761
 
3239 idir 762
				<!-- Templates HTML -->
763
				<div id="tpl-transmission-ok" class="hidden">
3248 idir 764
					<p class="msg"><?php echo $resume['transok']; ?></p>
3239 idir 765
				</div>
766
				<div id="tpl-transmission-ko" class="hidden">
3248 idir 767
					<p class="msg"><?php echo $resume['transko']; ?></p>
3239 idir 768
				</div>
769
			</div>
770
		</div>
3260 idir 771
 
3425 idir 772
		<!-- modale -->
773
		<div id="fenetre-modal" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="fenetre-modal-label" style="display: none;" aria-hidden="true">
3239 idir 774
			<div class="modal-dialog modal-dialog-centered" role="document">
775
				<div class="modal-content">
776
					<div class="modal-header">
3425 idir 777
						<h5 class="modal-title" id="fenetre-modal-label"></h5>
3239 idir 778
						<button type="button" class="close" data-dismiss="modal" aria-label="Close">
779
							<span aria-hidden="true">&times;</span>
780
						</button>
781
					</div>
782
					<div class="modal-body" id="print_content"></div>
3425 idir 783
					<div class="modal-footer"></div>
3239 idir 784
				</div>
785
			</div>
786
		</div>
787
		<!-- carto -->
3268 idir 788
		<script type="text/javascript" src="<?php echo $url_base; ?>js/tb-geoloc/tb-geoloc-lib-app.js"></script>
3239 idir 789
		<!-- Jquery -->
790
		<script type="text/javascript" src="https://resources.tela-botanica.org/jquery/1.11.1/jquery-1.11.1.min.js"></script>
791
		<!-- Jquery UI : nécessaire pour le minicalendrier et l'auto-complétion -->
792
		<script type="text/javascript" src="https://resources.tela-botanica.org/jquery/jquery-ui/1.11.0/js/jquery-ui.min.js"></script>
3240 idir 793
		<!-- <script type="text/javascript" src="https://resources.tela-botanica.org/jquery/jquery-ui/1.11.0/js/datepicker-fr.js"></script> -->
3239 idir 794
		<!-- Jquery Plugins -->
795
		<!-- Jquery Validate : nécessaire pour la validation des formulaires -->
796
		<script type="text/javascript" src="https://resources.tela-botanica.org/jquery/validate/1.11.1/jquery.validate.min.js"></script>
797
		<script type="text/javascript" src="https://resources.tela-botanica.org/jquery/validate/1.11.1/additional-methods.min.js"></script>
798
		<script type="text/javascript" src="https://resources.tela-botanica.org/jquery/validate/1.11.1/messages_fr.js"></script>
799
		<!-- Jquery Form :nécessaire pour l'upload des images -->
800
		<script type="text/javascript" src="https://resources.tela-botanica.org/jquery/form/3.51/jquery.form.min.js"></script>
801
		<!-- Bootstrap -->
802
		<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.3/umd/popper.min.js" integrity="sha384-ZMP7rVo3mIykV+2+9J3UJ46jBk0WLaUAdn689aCwoqbBJiSnjAK/l8WvCWPIPm49" crossorigin="anonymous"></script>
803
		<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/js/bootstrap.min.js" integrity="sha384-ChfqqxuZUCnJSK3+MXmPNIyE6ZbWh2IMqE241rYiqJxyMiZ6OW/JmZQ5stwEULTy" crossorigin="anonymous"></script>
804
		<!-- Connexion, bloc de prévisualisation, date -->
3425 idir 805
		<script type="text/javascript" src="<?php echo $url_base; ?>js/Utils.js"></script>
806
		<script type="text/javascript" src="<?php echo $url_base; ?>js/WidgetsSaisiesCommun.js"></script>
3268 idir 807
		<script type="text/javascript" src="<?php echo $url_base; ?>js/WidgetSaisie.js"></script>
3239 idir 808
		<script type="text/javascript">
809
			//<![CDATA[
3425 idir 810
				const NBRE_ELTS_AUTOCOMP = 20;
811
				const OBS_MAX_NBRE       = 10;
812
				const DUREE_MESSAGE      = 1000;
3208 idir 813
 
3425 idir 814
				var widgetProp = {
815
					// url jusqu'à "/widget:cel:"
816
					'urlWidgets'                        : "<?php echo $widgets_url; ?>",
817
					// module utilisé (apa,lg,streets)
3532 idir 818
					'projet'                            : "<?php echo $widget['projet']; ?>",
819
					// id du projet
820
					'idProjet'                          : "<?php echo $widget['id_projet']; ?>",
3239 idir 821
					// La présence du parametre 'debug' dans l'URL enclenche le débogage
3425 idir 822
					'debug'                             : <?php echo isset( $_GET['debug'] ) ? 'true' : 'false'; ?>,
3239 idir 823
					// La présence du parametre 'html5' dans l'URL enclenche les fonctions avancées HTML5
3425 idir 824
					'html5'                             : <?php echo isset($_GET['html5']) ? 'true' : 'false'; ?>,
3239 idir 825
					// Mot-clé du widget/projet
3532 idir 826
					'tagsMotsCles'                      : "<?php echo $widget['motscles']; ?>",
3239 idir 827
					// Mots-clés à ajouter aux images
3545 idir 828
					'tagImg'                            : "<?php echo isset($widget['tag-img']) ? $widget['tag-img'] : ''; ?>",
3239 idir 829
					// Mots-clés à ajouter aux observations
3545 idir 830
					'tagObs'                            : "<?php echo isset($widget['tag-obs']) ? $widget['tag-obs'] : ''; ?>",
3239 idir 831
					// Précharger le formulaire avec les infos d'une observation
3425 idir 832
					'obsId'                             : "<?php echo isset($_GET['id-obs']) ? $_GET['id-obs'] : ''; ?>",
3239 idir 833
					// URL du web service réalisant l'insertion des données dans la base du CEL.
3425 idir 834
					'serviceSaisieUrl'                  : "<?php echo $url_ws_saisie; ?>",
3239 idir 835
					// URL du web service permettant de récupérer les infos d'une observation du CEL.
3425 idir 836
					'serviceObsUrl'                     : "<?php echo $url_ws_obs; ?>",
3239 idir 837
					// langue
3425 idir 838
					'langue'                            : "<?php echo $widget['langue']; ?>",
3239 idir 839
					// Squelette d'URL du web service de l'annuaire.
3425 idir 840
					'serviceAnnuaireIdUrl'              : "<?php echo $url_ws_annuaire; ?>",
3287 idir 841
					// mode : prod / beta / local
3425 idir 842
					'mode'                              : "<?php echo $conf_mode; ?>",
3239 idir 843
					// URL de l'icône du chargement en cours d'une image
3433 idir 844
					'chargementImageIconeUrl'           : "<?php echo $url_base; ?>img/icones/chargement.gif",
3239 idir 845
					// URL de l'icône pour une photo manquante
3425 idir 846
					'pasDePhotoIconeUrl'                : "<?php echo $url_base; ?>img/icones/pasdephoto.png",
3239 idir 847
					// Code du référentiel utilisé pour les nom scientifiques.
3425 idir 848
					'nomSciReferentiel'                 : "<?php echo ( !empty( $widget['referentiel'] ) ) ? strtolower( $widget['referentiel'] ) : 'bdtfxr'; ?>",
3239 idir 849
					// Indication de la présence d'une espèce imposée
3425 idir 850
					'especeImposee'                     : "<?php echo $widget['especes']['espece_imposee']; ?>",
3239 idir 851
					// Tableau d'informations sur l'espèce imposée
3425 idir 852
					'infosEspeceImposee'                : "<?php echo $widget['especes']['infos_espece']; ?>",
3239 idir 853
					// Indication de la présence d'un référentiel imposé
3425 idir 854
					'referentielImpose'                 : "<?php echo ( !empty( $widget['referentiel'] ) ) ? strtolower( $widget['referentiel'] ) : 'bdtfxr'; ?>",
3260 idir 855
					// #taxon est une liste
3425 idir 856
					'isTaxonListe'                      : <?php echo ( isset( $widget['especes']['taxons'] ) && count( (array) $widget['especes']['taxons'] ) )? 'true' : 'false' ; ?>,
857
					// Nombre d'élément dans les listes d'auto-complétion
858
					'autocompletionElementsNbre'        : NBRE_ELTS_AUTOCOMP,
3239 idir 859
					// URL du web service permettant l'auto-complétion des noms scientifiques
3425 idir 860
					'serviceAutocompletionNomSciUrl'    : "<?php echo $widget['especes']['url_ws_autocompletion_ns']; ?>?"+
3239 idir 861
						"masque={masque}&"+
862
						"recherche=etendue&"+
863
						"retour.champs=famille,nom_retenu,nom_retenu_complet,num_taxonomique,nom_retenu.id&"+
864
						"ns.structure=au&"+
3425 idir 865
						"navigation.limite=" + NBRE_ELTS_AUTOCOMP,
3239 idir 866
					// Squelette d'URL du web service permettant l'auto-complétion des noms scientifiques
3425 idir 867
					'serviceAutocompletionNomSciUrlTpl' : "<?php echo $widget['especes']['url_ws_autocompletion_ns_tpl']; ?>?"+
3239 idir 868
						"masque={masque}&"+
869
						"recherche=etendue&"+
870
						"retour.champs=famille,nom_retenu,nom_retenu_complet,num_taxonomique,nom_retenu.id&"+
871
						"retour.tri=alpharet&"+ // tri "à la CeL"
872
						"ns.structure=au&"+
3425 idir 873
						"navigation.limite=" + NBRE_ELTS_AUTOCOMP,
3239 idir 874
					// Nombre d'observations max autorisé avant transmission
3425 idir 875
					'obsMaxNbre'                        : OBS_MAX_NBRE,
3239 idir 876
					// Durée d'affichage en milliseconde des messages d'informations
3425 idir 877
					'dureeMessage'                      : DUREE_MESSAGE,
3239 idir 878
					// Squelette d'URL du web service d'eFlore fournissant les noms de communes.
3425 idir 879
					'serviceNomCommuneUrl'              : "https://api.tela-botanica.org/service:eflore:0.1/osm/nom-commune?lon={lon}&lat={lat}",
3239 idir 880
					// Squelette d'URL du web service d'eFlore fournissant les noms de communes hors de France (localisation approximative).
3425 idir 881
					'serviceNomCommuneUrlAlt'           : "https://api.tela-botanica.org/service:eflore:0.1/wikipedia/nom-commune?lon={lon}&lat={lat}&nbre=1"
882
				};
3239 idir 883
 
3425 idir 884
				$( document ).ready( function() {
885
					widget = new WidgetSaisie(widgetProp);
3239 idir 886
					widget.init();
3425 idir 887
					// Fonctions de Style et Affichage des éléments "spéciaux"
888
					utils.init();
3239 idir 889
				});
890
			//]]>
3230 delphine 891
		</script>
892
		<!-- Barre de navigation -->
893
		<?php if ( $bar ): ?>
3248 idir 894
			<script src="<?php echo $url_script_navigation; ?>"></script>
3230 delphine 895
		<?php endif; ?>
896
	</body>
3208 idir 897
</html>