public function AjouterElementsFromListe($nomRef, $colId = COL_ID, $colLibelle = array(COL_LIBELLE, COL_LIBELLE), $colDescription = '', $idParDefaut = NULL) { foreach (GReferentiel::GetReferentiel($nomRef) as $mObjet) { $valParDefaut = false; $id = $mObjet->GetChampSQLFromTableau($colId); if ($idParDefaut !== NULL && $id == $idParDefaut) { $valParDefaut = true; } if ($colDescription !== '') { $this->AjouterElement($id, $mObjet->GetChampSQLFromTableau($colLibelle), $mObjet->GetChampSQLFromTableau($colDescription), $valParDefaut); } else { $this->AjouterElement($id, $mObjet->GetChampSQLFromTableau($colLibelle), '', $valParDefaut); } } $this->AjouterReference($nomRef); }