Subversion Repositories eFlore/Applications.cel

Rev

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

Rev 3518 Rev 3519
Line 64... Line 64...
64
		$project_id = $resultat[0]['idprojet']; 
64
		$project_id = $resultat[0]['idprojet']; 
65
		if (array_diff_key($this->champs_defaut_valeur, $parametres)) {
65
		if (array_diff_key($this->champs_defaut_valeur, $parametres)) {
66
		    $parametres = array_merge($parametres, array_diff_key($this->champs_defaut_valeur, $parametres));
66
		    $parametres = array_merge($parametres, array_diff_key($this->champs_defaut_valeur, $parametres));
67
		}
67
		}
68
	    $requete_insertion = 'INSERT INTO project_settings '.
68
	    $requete_insertion = 'INSERT INTO project_settings '.
69
	   	    '(project_id, '.implode(array_keys($parametres), ', ').') VALUES ("'.$project_id.'", '.implode(Cel::db()->proteger($parametres), ', ').'")';
69
	   	    '(project_id, '.implode(array_keys($parametres), ', ').') VALUES ("'.$project_id.'", '.implode(Cel::db()->proteger($parametres), ', ').')';
70
	    $requete_insertion = str_replace("'CURRENT_TIMESTAMP'", 'CURRENT_TIMESTAMP', $requete_insertion);
70
	    $requete_insertion = str_replace("'CURRENT_TIMESTAMP'", 'CURRENT_TIMESTAMP', $requete_insertion);
71
	    $resultat_ajout = Cel::db()->executer($requete_insertion);
71
	    $resultat_ajout = Cel::db()->executer($requete_insertion);
72
		$retour = true;
72
		$retour = true;
73
		if ($resultat_ajout === false) {
73
		if ($resultat_ajout === false) {
74
			$retour = false;
74
			$retour = false;