diff --git a/src/Order/Order.php b/src/Order/Order.php index 0974b3d..25d78bc 100644 --- a/src/Order/Order.php +++ b/src/Order/Order.php @@ -47,6 +47,7 @@ * @property \Carbon\Carbon|null processed_at * @property int amount_refunded * @property int amount_charged_back + * @property array|null metadata * @property \Laravel\Cashier\Order\OrderItemCollection items * @property \Laravel\Cashier\Refunds\RefundCollection refunds * @@ -72,6 +73,7 @@ class Order extends Model 'credit_used' => 'int', 'total_due' => 'int', 'processed_at' => 'datetime', + 'metadata' => 'array', 'created_at' => 'datetime', 'updated_at' => 'datetime', ]; diff --git a/src/Order/OrderItem.php b/src/Order/OrderItem.php index c5e0e1f..0b1cf0e 100644 --- a/src/Order/OrderItem.php +++ b/src/Order/OrderItem.php @@ -25,6 +25,7 @@ * @property mixed $id * @property Order $order * @property mixed $order_id + * @property array|null metadata * * @method static create(array $array) * @method static make(array $array) @@ -47,6 +48,7 @@ class OrderItem extends Model implements InvoicableItem 'tax_percentage' => 'float', 'orderable_id' => 'int', 'process_at' => 'datetime', + 'metadata' => 'array', ]; protected $guarded = []; diff --git a/src/Refunds/Refund.php b/src/Refunds/Refund.php index 1c0cfd2..07545cb 100644 --- a/src/Refunds/Refund.php +++ b/src/Refunds/Refund.php @@ -28,6 +28,7 @@ * @property \Laravel\Cashier\Refunds\RefundItemCollection items * @property Order order * @property Order originalOrder + * @property array|null metadata */ class Refund extends Model { @@ -37,6 +38,7 @@ class Refund extends Model protected $casts = [ 'total' => 'int', + 'metadata' => 'array', ]; /** diff --git a/src/Refunds/RefundItem.php b/src/Refunds/RefundItem.php index 3e1bfc2..f047bb7 100644 --- a/src/Refunds/RefundItem.php +++ b/src/Refunds/RefundItem.php @@ -24,6 +24,7 @@ * @property string description * @property array description_extra_lines * @property OrderItem originalOrderItem + * @property array|null metadata * * @method static create(array $array) * @method static make(array $array) @@ -45,6 +46,7 @@ class RefundItem extends Model 'subtotal' => 'int', 'tax' => 'int', 'total' => 'int', + 'metadata' => 'array', ]; /** diff --git a/src/Subscription.php b/src/Subscription.php index cb279b7..651ba56 100644 --- a/src/Subscription.php +++ b/src/Subscription.php @@ -45,6 +45,7 @@ * @property float cycle_progress * @property float cycle_left * @property string $currency + * @property array|null metadata */ class Subscription extends Model implements InteractsWithOrderItems, PreprocessesOrderItems, AcceptsCoupons, IsRefundable { @@ -67,6 +68,7 @@ class Subscription extends Model implements InteractsWithOrderItems, Preprocesse 'cycle_started_at' => 'datetime', 'cycle_ends_at' => 'datetime', 'ends_at' => 'datetime', + 'metadata' => 'array', ]; /**