To customize the code so that:
1 when a Gift Certificate is purchased and the Order is set to Pending that the GV is NOT auto-released to the Customer Balance
2 when a Gift Certificate is purchased and the Order is set to Processing that the GV IS auto-released to the Customer Balance
You could try this custom code, but you will need to test it very carefully ...
Edit the file:
/includes/modules/order_total/ot_gv.php
and around line 161 you can add the code in RED:
$gv_order_amount = $gv_order_amount * 100 / 100;
[B]// bof: Auto-Release GV to Customer Balance when order_status not set to Pending 1
if (MODULE_ORDER_TOTAL_GV_QUEUE == 'false' && $order->info['order_status'] > 1) {
//[/B] if (MODULE_ORDER_TOTAL_GV_QUEUE == 'false') {
[B]// eof: Auto-Release GV to Customer Balance when order_status not set to Pending 1
[/B] // GV_QUEUE is false so release amount to account immediately
$gv_result = $this->user_has_gv_account($_SESSION['customer_id']);
$customer_gv = false;
What this will do is check the orders_status and change the way the QUEUE works on the Gift QUEUE ...
If an Order is set to an order_status higher than Pending ( 1 ), then the Gift Certificate that is purchased is auto-added to the Customer Balance, but if the Order is set to an order_status of Pending ( 1 ), then you will need to MANUALLY release the GV to the Customer Balance ...