mirror of
https://github.com/kevin-DL/LaravelShoppingcart.git
synced 2026-01-17 13:14:58 +00:00
Update CartItem.php
Save options value in updateFromArray function
This commit is contained in:
@@ -211,7 +211,7 @@ class CartItem implements Arrayable
|
||||
$this->name = array_get($attributes, 'name', $this->name);
|
||||
$this->price = array_get($attributes, 'price', $this->price);
|
||||
$this->priceTax = $this->price + $this->tax;
|
||||
$this->options = new CartItemOptions(array_get($attributes, 'options', []));
|
||||
$this->options = new CartItemOptions(array_get($attributes, 'options', $this->options));
|
||||
|
||||
$this->rowId = $this->generateRowId($this->id, $this->options->all());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user