app/Http/Controllers/Admin/AlbumReviewController.php 1 location
|
@@ 78-85 (lines=8) @@
|
| 75 |
|
->with('success', 'Album Review Saved!'); |
| 76 |
|
} |
| 77 |
|
|
| 78 |
|
public function delete($id) |
| 79 |
|
{ |
| 80 |
|
$review = AlbumReview::findOrFail($id); |
| 81 |
|
File::delete(public_path() . '/img/albums/' . $review->img_name); |
| 82 |
|
AlbumReview::destroy($id); |
| 83 |
|
return redirect()->route('admin.reviews.index') |
| 84 |
|
->with('success', 'Album Review Deleted!'); |
| 85 |
|
} |
| 86 |
|
|
| 87 |
|
} |
| 88 |
|
|
app/Http/Controllers/Admin/EventController.php 1 location
|
@@ 85-92 (lines=8) @@
|
| 82 |
|
->with('success', 'Event Saved!'); |
| 83 |
|
} |
| 84 |
|
|
| 85 |
|
public function delete($id) |
| 86 |
|
{ |
| 87 |
|
$event = Event::findOrFail($id); |
| 88 |
|
File::delete(public_path().'/img/events/'.$event->picture); |
| 89 |
|
Event::destroy($id); |
| 90 |
|
return redirect()->route('admin.events.index') |
| 91 |
|
->with('success', 'Event Deleted!'); |
| 92 |
|
} |
| 93 |
|
|
| 94 |
|
} |
| 95 |
|
|
app/Http/Controllers/Admin/UserController.php 1 location
|
@@ 101-108 (lines=8) @@
|
| 98 |
|
* @param int $id |
| 99 |
|
* @return Response |
| 100 |
|
*/ |
| 101 |
|
public function delete($id) |
| 102 |
|
{ |
| 103 |
|
$user = User::findOrFail($id); |
| 104 |
|
File::delete(public_path().'/img/djs/'.$user->picture); |
| 105 |
|
User::destroy($id); |
| 106 |
|
return redirect()->route('admin.users.index') |
| 107 |
|
->with('success', 'User Deleted!'); |
| 108 |
|
} |
| 109 |
|
|
| 110 |
|
} |
| 111 |
|
|