1
0
Fork 0

Adding card controller for administrators

This commit is contained in:
Henrik Hautakoski 2022-01-08 16:39:04 +01:00
parent b09bed4a34
commit 086bd81702
2 changed files with 47 additions and 0 deletions

View file

@ -0,0 +1,22 @@
<?php
namespace App\Http\Controllers\Admin;
use App\Models\Card;
use App\Http\Controllers\Controller;
class CardController extends Controller
{
public function index()
{
return view("admin.card.index");
}
public function destroy(Card $card)
{
$card->delete();
return redirect()->route('admin.card.index');
}
}