Hi Guys
I use the Orders model to create orders from a plugin.
I have been using CreateOrderHead() successfully for a while until it seems it broke in 3.2.14?
administrator\components\com_virtuemart\models\orders.php around line 2508
$orderTable -> bindChecknStore($_orderData);
$db = JFactory::getDBO();
$_orderID = $db->insertid();
$_orderID doesn't return a virtuemart_order_id.
I updated administrator\components\com_virtuemart\models\orders.php around line 2508 to
$orderTable -> bindChecknStore($_orderData);
$db = JFactory::getDBO();
$_orderID = $orderTable->virtuemart_order_id;
Now it works for me again,
regards
Eliot
Thank you, yes that is the right pattern to use. I add it to the core
Hi Milbo,
little typo:
$_orderID = $orderTable->virtuemart_order_id;;
$_orderID = $orderTable->virtuemart_order_id;
might be better.
cu, diri