Small fix to the order status update. No file attached. Seems I kept getting my order status updated to a value to "4" every time an order was made, depending on your site this may correspond to say "Processing". On a default install of OSC it doesn't correspond to anything.
Anyway, after some work and testing I found the problem lies in beanstream_cdn.php or usd.
Change:
================================
function after_process() {
global $insert_id;
tep_db_query("insert into " . TABLE_ORDERS_STATUS_HISTORY . "
(orders_id, orders_status_id, date_added, customer_notified, comments) values ('" .$insert_id . "', '4', now(), '0', 'payment confirmed')");
tep_db_query("update " . TABLE_ORDERS . " set orders_status = 4 where orders_id = ".$insert_id."");
return false;
}
================================
TO THIS:
================================
function after_process() {
global $insert_id;
tep_db_query("insert into " . TABLE_ORDERS_STATUS_HISTORY . "
(orders_id, orders_status_id, date_added, customer_notified, comments) values ('" .$insert_id . "', '". (int)MODULE_PAYMENT_BEANSTREAM_CDN_ORDER_STATUS_ID ."', now(), '0', 'payment confirmed')");
tep_db_query("update " . TABLE_ORDERS . " set orders_status = ".(int)MODULE_PAYMENT_BEANSTREAM_CDN_ORDER_STATUS_ ID." where orders_id = ".$insert_id."");
return false;
}
================================
Attached is the above note only.
More...





LinkBack URL
About LinkBacks









Bookmarks