Files
dots-bot-api/app/Http/Controllers/API/v2/CartController.php
T
KKlochko 4a4d5e7335 Add Cart model, resource and its API, Pivot table with Items.
Update Items model to have relationship with cart.
2023-06-15 17:43:59 +03:00

68 lines
1.1 KiB
PHP

<?php
namespace App\Http\Controllers\API\v2;
use App\Http\Requests\StoreCartRequest;
use App\Http\Requests\UpdateCartRequest;
use App\Http\Resources\API\v2\CartResource;
use App\Models\Cart;
class CartController extends Controller
{
/**
* Display a listing of the resource.
*/
public function index()
{
//
}
/**
* Show the form for creating a new resource.
*/
public function create()
{
//
}
/**
* Store a newly created resource in storage.
*/
public function store(StoreCartRequest $request)
{
//
}
/**
* Display the specified resource.
*/
public function show(Cart $cart)
{
return new CartResource($cart);
}
/**
* Show the form for editing the specified resource.
*/
public function edit(Cart $cart)
{
//
}
/**
* Update the specified resource in storage.
*/
public function update(UpdateCartRequest $request, Cart $cart)
{
//
}
/**
* Remove the specified resource from storage.
*/
public function destroy(Cart $cart)
{
//
}
}