/**
  * Show the form for editing the specified resource.
  *
  * @param IndicadorValor $indicador
  * @return \Illuminate\Http\Response
  * @internal param int $id
  */
 public function edit(IndicadorValor $indicador)
 {
     $indicadores = Indicador::all()->lists('nome', 'id');
     $fontes = Fonte::all()->lists('nome', 'id');
     $referencias = Referencia::all()->lists('tabela', 'id');
     return view('indicador-valor.edit', compact('indicadores', 'fontes', 'referencias', 'indicador'));
 }
Exemplo n.º 2
0
 /**
  * Remove the specified resource from storage.
  *
  * @param Fonte $fonte
  * @return \Illuminate\Http\Response
  */
 public function destroy(Fonte $fonte)
 {
     $fonte->delete();
     session()->flash('flash_message', 'Fonte excluída!');
     return redirect('fonte');
 }