by default address id is been added at time of address creation
when checking out of cart from bank transfer mode address_id null error occurs
and stop futher procedure from executing...
C:\xampp\htdocs\laracom\app\Shop\Orders\Repositories\OrderRepository.php
* Create the order
*
* @param array $params
* @return Order
* @throws OrderInvalidArgumentException
*/
public function createOrder(array $params) : Order
{
try {
$order = $this->create($params);
$orderRepo = new OrderRepository($order);
$orderRepo->buildOrderDetails(Cart::content());
event(new OrderCreateEvent($order));
return $order;
} catch (QueryException $e) {
throw new OrderInvalidArgumentException($e->getMessage(), 500, $e);
}
}
"SQLSTATE[23000]: Integrity constraint violation: 1048 Column 'address_id' cannot be null (SQL: insert into orders
(reference
, courier_id
, customer_id
, address_id
, order_status_id
, payment
, discounts
, total_products
, total
, total_paid
, total_shipping
, tax
, updated_at
, created_at
) values (50ee7968-3c89-4496-9b26-3b04ac3bd204, 1, 14, , 2, enquiry orders, 0, 50.00, 21.00, 0, 0, 0.00, 2019-04-20 10:20:32, 2019-04-20 10:20:32)) ◀"