Subversion Repositories eFlore/Applications.cel

Rev

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

Rev 1702 Rev 1706
Line 183... Line 183...
183
 
183
 
184
		// uniquement les champŝ dynamiques
184
		// uniquement les champŝ dynamiques
185
		foreach($colonnes as $abbrev => $colonne) {
185
		foreach($colonnes as $abbrev => $colonne) {
186
			$valeur = null;
186
			$valeur = null;
-
 
187
			if(is_null($colonne['dyna'])) continue;
-
 
188
			// XXX: PHP-5.3
187
			if(is_null($colonne['dyna'])) continue;
189
			call_user_func_array($colonne['dyna'],
188
			$colonne['dyna']($cel, $obs, $ligne_formatee);
190
								 array($cel, $obs, &$ligne_formatee));
Line 189... Line 191...
189
		}
191
		}
190
 
192
 
Line 472... Line 474...
472
					   " WHERE c.id_observation IN (%s)",
474
					   " WHERE c.id_observation IN (%s)",
473
					   //" AND catminat_code IS NOT NULL", // TODO: suppression des NULL ici signifie que le cache sera partiel...
475
					   //" AND catminat_code IS NOT NULL", // TODO: suppression des NULL ici signifie que le cache sera partiel...
474
					   implode(',', array_keys(self::$baseflor_col)),
476
					   implode(',', array_keys(self::$baseflor_col)),
475
					   implode(',', $obsids));
477
					   implode(',', $obsids));
476
		$res = $cel->requeter($req);
478
		$res = $cel->requeter($req);
-
 
479
		if(!$res) return NULL;
Line 477... Line 480...
477
 
480
 
478
		foreach($res as $v) {
481
		foreach($res as $v) {
479
			$data = $v;
482
			$data = $v;
480
			unset($data['referentiel']); // non nécessaire
483
			unset($data['referentiel']); // non nécessaire
Line 487... Line 490...
487
	
490
	
Line 488... Line 491...
488
 
491
 
489
	static function baseflor_ligne($cel, $obs, &$ligne) {
492
	static function baseflor_ligne($cel, $obs, &$ligne) {
490
 
493
 
491
		if(! $obs['nom_ret_nn']) {
494
		if(! $obs['nom_ret_nn']) {
Line 492... Line 495...
492
			$ligne = array_merge($ligne, array_fill(0, count(self::$baseflor_col), 'A'));
495
			$ligne = array_merge($ligne, array_fill(0, count(self::$baseflor_col), NULL));
493
			return;
496
			return;
494
		}
497
		}
495
 
498
 
Line 496... Line 499...
496
		if(! self::referenceTableExiste($cel)) {
499
		if(! self::referenceTableExiste($cel)) {
497
			$ligne = array_merge($ligne, array_fill(0, count(self::$baseflor_col), 'A'));
500
			$ligne = array_merge($ligne, array_fill(0, count(self::$baseflor_col), NULL));
Line 515... Line 518...
515
											 $referentiel,
518
											 $referentiel,
516
											 $obs['nom_ret_nn']),
519
											 $obs['nom_ret_nn']),
517
									 Cel::SQL_RETOUR_LIGNE);
520
									 Cel::SQL_RETOUR_LIGNE);
Line 518... Line 521...
518
 
521
 
519
		if(! $data) {
522
		if(! $data) {
520
			$ligne = array_merge($ligne, array_fill(0, count(self::$baseflor_col), 'A'));
523
			$ligne = array_merge($ligne, array_fill(0, count(self::$baseflor_col), NULL));
521
			return;
524
			return;
Line 522... Line 525...
522
		}
525
		}
523
 
526