Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Contributor Mike Jolley

    (@mikejolley)

    These are the events that fire the email:

    // Triggers for this email
    		add_action( 'woocommerce_order_status_pending_to_processing_notification', array( $this, 'trigger' ) );
    		add_action( 'woocommerce_order_status_pending_to_completed_notification', array( $this, 'trigger' ) );
    		add_action( 'woocommerce_order_status_pending_to_on-hold_notification', array( $this, 'trigger' ) );
    		add_action( 'woocommerce_order_status_failed_to_processing_notification', array( $this, 'trigger' ) );
    		add_action( 'woocommerce_order_status_failed_to_completed_notification', array( $this, 'trigger' ) );
    		add_action( 'woocommerce_order_status_failed_to_on-hold_notification', array( $this, 'trigger' ) );

    If it was pending, and you make it complete, its considered new and is to be expected. Pending = unpaid.

    Thread Starter JosvdV

    (@josvdv)

    Thanks for the quick reply and for the enlightenment!

    A further question if I may: when would the completed email be sent?
    I miss the technical knowledge I guess. Do I understand it right that I should change the status first from pending to something else before setting it to completed to get the completed email sent out?

    Hope you can help me out just a bit more.

    Plugin Contributor Mike Jolley

    (@mikejolley)

    Completed is sent out when you change a pending or failed order to processing, completed or on hold.

    Thread Starter JosvdV

    (@josvdv)

    Ok, maybe that is a language thing?
    I read in your last reply that Completed is sent when I change pending (or failed) to completed (or to processing, or to on hold)?
    But under 2. You say from pending to complete = new order email in stead of completed email? I get confused…

    I would have thought Completed would mean something like all paid for & done or something like that. So that would be the kind of email sent when order marked as Completed.

    Plugin Contributor Mike Jolley

    (@mikejolley)

    If the order is PENDING, the admin has not been notified. So if you change it to something else it IS a new order.

    Thread Starter JosvdV

    (@josvdv)

    thank you for your patience & advice
    Have a great day!
    Jos

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Woocommerice – wrong email sent (new order email sent on status completed)’ is closed to new replies.