Change defult order status from pending payment to on hold
-
Hey,
The plugin automaticlly puts the order on the status “pending payment”
It makes me a problem with me email sending becuase My email is only sent to payment who is on the status “on hold”I found a simple hook to change the cash on delivery gateway option from to “pending payment” to “on hold” –
add_filter( ‘woocommerce_cod_process_payment_order_status’, ‘change_cod_payment_order_status’, 10, 2 );
function change_cod_payment_order_status( $order_status, $order ) {
return ‘on-hold’;
}Can you please tell me how to edit this hook to support your gateway and change all orders made by your gateway to the status “on hold”?
Thank you in advance
The topic ‘Change defult order status from pending payment to on hold’ is closed to new replies.