Changeset ff9da8b for app/Http/Controllers
- Timestamp:
- 02/26/21 18:14:28 (4 years ago)
- Branches:
- master
- Children:
- 7ed1069
- Parents:
- f457265
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
app/Http/Controllers/Dashboard/CompaniesController.php
rf457265 rff9da8b 3 3 namespace App\Http\Controllers\Dashboard; 4 4 5 use App\Helpers\Alert; 5 6 use App\Models\Company; 6 7 use Illuminate\Http\Request; … … 29 30 ]); 30 31 } 32 33 public function destroy($id) 34 { 35 $company = Company::findOrFail($id); 36 $companyName = $company->name; 37 $company->delete(); 38 39 Alert::flash($companyName . " deleted successfully"); 40 41 return redirect()->route("dashboard.companies.index"); 42 } 31 43 }
Note:
See TracChangeset
for help on using the changeset viewer.