Feature: Creating Cart Service, Cart Events, Save For Later functionality, Adding Filament Views for viewing abandoned carts
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Core\Cart\Events;
|
||||
|
||||
use Lunar\Models\Cart;
|
||||
|
||||
class CartLineRemoved
|
||||
{
|
||||
/**
|
||||
* @param array{id: int, purchasable_type: string, purchasable_id: int, quantity: int, meta: array} $line
|
||||
* Snapshot of the removed line — the row is already deleted by the time this
|
||||
* event dispatches, so nothing here can be a fresh CartLine model instance.
|
||||
*/
|
||||
public function __construct(
|
||||
public readonly Cart $cart,
|
||||
public readonly array $line,
|
||||
) {}
|
||||
}
|
||||
Reference in New Issue
Block a user