/**
  * Remove the specified resource from storage.
  *
  * @param  int  $id
  *
  * @return Response
  */
 public function destroy($id)
 {
     $bannereslider = BannereSlider::findOrFail($id);
     \File::delete("frontend/images/bannere-slider/{$bannereslider->Imagine}");
     BannereSlider::destroy($id);
     Session::flash('flash_message', 'BannereSlider deleted!');
     return redirect('auth/bannere_slider');
 }
Esempio n. 2
0
 /**
  * Show the application dashboard.
  *
  * @return Response
  */
 public function index()
 {
     $bannereSlider = BannereSlider::where('Activ', 1)->orderBy('Ord', 'asc')->get();
     $categoriiOferte = PrimaPaginaCateg::where('Activ', 1)->orderBy('Ord', 'asc')->with('OfertePrimaPagina')->get();
     return view('frontend/prima-pagina', compact('bannereSlider', 'categoriiOferte'));
 }