¨4.0.1¨
This commit is contained in:
@@ -2,24 +2,28 @@
|
||||
|
||||
namespace Modules\Wishlist\Http\Controllers;
|
||||
|
||||
use Illuminate\Http\Response;
|
||||
|
||||
class WishlistController
|
||||
{
|
||||
/**
|
||||
* Store a newly created resource in storage.
|
||||
*
|
||||
* @return \Illuminate\Http\Response
|
||||
* @return Response
|
||||
*/
|
||||
public function store()
|
||||
{
|
||||
if (! auth()->user()->wishlistHas(request('productId'))) {
|
||||
if (!auth()->user()->wishlistHas(request('productId'))) {
|
||||
auth()->user()->wishlist()->attach(request('productId'));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Destroy resources by the given id.
|
||||
*
|
||||
* @param string $productId
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function destroy($productId)
|
||||
|
||||
Reference in New Issue
Block a user