Beispiel #1
0
 /**
  * Display a listing of the resource.
  *
  * @return \Illuminate\Http\Response
  */
 public function today()
 {
     $bajas = \DB::table('bajas')->select('id', 'fecha', 'rodeo_id', 'animal_id', 'motivo')->where('fecha', '=', date('Y-m-d'))->get();
     $potreros = Potreros::get()->all();
     $rodeos = Rodeos::get()->all();
     $caravanas = Animales::get()->all();
     return view('bajas.today', ['bajas' => $bajas, 'potreros' => $potreros, 'rodeos' => $rodeos, 'caravanas' => $caravanas]);
 }
Beispiel #2
0
 /**
  * Remove the specified resource from storage.
  *
  * @param  int  $id
  * @return \Illuminate\Http\Response
  */
 public function destroy($id)
 {
     Rodeos::destroy($id);
     return redirect()->route('rodeos.index');
 }