mirror of
https://github.com/bitinflow/accounts.git
synced 2026-03-13 13:35:52 +00:00
Update Orders.php
This commit is contained in:
@@ -10,7 +10,7 @@ class Orders
|
|||||||
{
|
{
|
||||||
//
|
//
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get orders from user.
|
* Get orders from user.
|
||||||
*
|
*
|
||||||
@@ -33,18 +33,11 @@ class Orders
|
|||||||
/**
|
/**
|
||||||
* Create a new order.
|
* Create a new order.
|
||||||
*
|
*
|
||||||
* @param array $order_items
|
|
||||||
* @param array $attributes
|
* @param array $attributes
|
||||||
* @param bool $checkout optional checkout it directly
|
|
||||||
* @return object|false
|
* @return object|false
|
||||||
*/
|
*/
|
||||||
public function create(array $order_items = [], array $attributes = [], bool $checkout = false): object|false
|
public function create(array $attributes = []): object|false
|
||||||
{
|
{
|
||||||
$attributes = array_merge($attributes, [
|
|
||||||
'order_items' => $order_items,
|
|
||||||
'checkout' => $checkout
|
|
||||||
]);
|
|
||||||
|
|
||||||
return $this->user->asPaymentsUser('POST', 'orders', $attributes)->data;
|
return $this->user->asPaymentsUser('POST', 'orders', $attributes)->data;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user