Example #1
0
 $biblio->commentaires = $comment;
 $biblio->siret = $siret;
 $biblio->naf = $naf;
 $biblio->rcs = $rcs;
 $biblio->tva = $tva;
 $biblio->site_web = $site_web;
 $biblio->logo = $logo;
 if (is_array($user_aut)) {
     $biblio->autorisations = ' ' . implode(' ', $user_aut) . ' ';
 } else {
     $biblio->autorisations = ' 1 ';
 }
 $biblio->save();
 if ($id) {
     //màj des autorisations dans les rubriques
     $biblio->majAutorisations();
 }
 $id = $biblio->id_entite;
 for ($i = 1; $i <= $max_coord; $i++) {
     switch ($mod_[$i]) {
         case '1':
             $coord = new coordonnees($no_[$i]);
             $coord->num_entite = $id;
             if ($i == 1 || $i == 2) {
                 $coord->type_coord = $i;
             } else {
                 $coord->type_coord = 0;
             }
             $coord->libelle = $lib_[$i];
             $coord->contact = $cta_[$i];
             $coord->adr1 = $ad1_[$i];