mirror of
https://github.com/opdavies/glassboxx-sdk-php.git
synced 2025-02-17 22:50:48 +00:00
Allow for easily sending multiple order items
This allows for the sending of multiple items in a single order, by adding a new `OrderItem` class and moving all of the order item specific fields from the `Order` to an individual item. These can then be assigned to an order using the `withOrderItems()` method as an array of order items. Fixes #19
This commit is contained in:
parent
0ed99797f5
commit
ae766763b2
9 changed files with 86 additions and 53 deletions
|
@ -60,8 +60,6 @@ class TestCase extends \PHPUnit\Framework\TestCase
|
|||
$order->method('getCurrencyCode')->willReturn('GBP');
|
||||
$order->method('getCustomer')->willReturn($this->getMockCustomer());
|
||||
$order->method('getOrderNumber')->willReturn('abc123');
|
||||
$order->method('getPrice')->willReturn(7.99);
|
||||
$order->method('getSku')->willReturn('this-is-the-first-sku');
|
||||
|
||||
return $order;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue