/** * Remove the specified resource from storage. * * @param int $id * @return \Illuminate\Http\Response */ public function destroy($id) { $banner = Banner::findOrFail($id); if (file_exists($banner->path)) { unlink($banner->path); } Banner::destroy($id); return redirect('/admin/banners'); }
/** * Remove the specified resource from storage. * * @param int $id * @return Response */ public function destroy($id) { Banner::destroy($id); $showDefault = cmsHelp('App\\Banner', 'banners'); return Redirect('banner')->with($showDefault); }
/** * Remove the specified resource from storage. * * @param int $id * @return \Illuminate\Http\Response */ public function destroy($id) { // Banner::destroy($id); return redirect()->route('admin.banner.index'); }