Subversion Repositories eFlore/Applications.del

Rev

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

Rev 1180 Rev 1261
Line 397... Line 397...
397
						'prenom', 'nom', 'courriel', 'nom_original');
397
						'prenom', 'nom', 'courriel', 'nom_original');
398
		// Attention le LEFT JOIN est indispensable pour ramener les images n'ayant pas de votes
398
		// Attention le LEFT JOIN est indispensable pour ramener les images n'ayant pas de votes
399
		// en cas de tri par votes
399
		// en cas de tri par votes
400
		$requeteLiaisons = 'SELECT DISTINCT SQL_CALC_FOUND_ROWS '.implode(', ',$champs).' '.
400
		$requeteLiaisons = 'SELECT DISTINCT SQL_CALC_FOUND_ROWS '.implode(', ',$champs).' '.
401
						   ($this->doitJoindreTableVotes() ?
401
						   ($this->doitJoindreTableVotes() ?
402
						   		', IF(dvote.ce_protocole = '.$this->parametres['protocole'].', SUM(dvote.valeur), 0) as total_votes ' :
402
						   		', IF(dvote.ce_protocole = '.$this->parametres['protocole'].', AVG(dvote.valeur), 0) as total_votes ' :
403
						   		''
403
						   		''
404
						   	).
404
						   	).
405
							($this->doitJoindreTableTags() ?
405
							($this->doitJoindreTableTags() ?
406
								// attention le DISTINCT est indispensable !
406
								// attention le DISTINCT est indispensable !
407
						   		', (COUNT(DISTINCT dtag.id_tag) + '.$this->assemblercomptageOccurencesMotsClesCel().') as total_tags ' :
407
						   		', (COUNT(DISTINCT dtag.id_tag) + '.$this->assemblercomptageOccurencesMotsClesCel().') as total_tags ' :