Esempio n. 1
0
 /**
  * Show the form for editing the specified resource.
  *
  * @param  int  $id
  * @return Response
  */
 public function edit($id, PersonneG $personnes, QualiteG $qualites, AdresseG $adresses, TelephoneG $telephones, MailG $mails, StructureG $structures)
 {
     $personne = $personnes->edit($id);
     $listQualites = $qualites->listForSelect();
     $listAdresses = $adresses->listForSelect();
     $adresseCommuneWith = $adresses->adresseCommuneWith($id, $personne->adresses->first()->id);
     $listTelephones = $telephones->listForSelect();
     $listMails = $mails->listForSelect();
     $listStructures = $structures->listForSelect();
     return view('Personnes.edit')->with('title', 'Modification d\'une fiche')->with('titre_page', 'Modification de la fiche de ' . $personne->nom_complet)->with(compact('personne'))->with(compact('listQualites'))->with(compact('listAdresses'))->with(compact('adresseCommuneWith'))->with(compact('listTelephones'))->with(compact('listMails'))->with(compact('listStructures'));
 }
Esempio n. 2
0
 /**
  * Update the specified resource in storage.
  *
  * @param  int  $id
  * @return Response
  */
 public function update($id, StructureG $structure)
 {
     $structure->update($id);
     return \Redirect::action('StructureController@index');
 }