jucedupp Posted February 26, 2016 Share Posted February 26, 2016 Hi there I have been looking for this all over. In PaymentModule class, the order confirmation mail is sent. I am not looking for that. My problem is that I have certain products that are free (basically a club membership that they will pay for at a later date). Now here is the issue. On a 0 value order, the client receives TWO emails: 1) Order confirmation email - OK, I want the customer to receive that. 2) Payment confirmation - NOT OK, since no money traded hands, and no payments were made, the customer should NOT receive a "Payment Confirmation" email. Where is the payment confirmation email sent from? It is NOT in PaymentModule. Thanks J Link to comment Share on other sites More sharing options...
roja45 Posted February 26, 2016 Share Posted February 26, 2016 It's calling the same validateOrder method on the PaymentModule class, just from the different route. $this->_checkFreeOrder() around line 218 in the OrderController, it will validate the order as any other payment module, passing in the paid status, and triggering the email. Link to comment Share on other sites More sharing options...
bellini13 Posted February 26, 2016 Share Posted February 26, 2016 actually it is in PaymentModule // Set the order status $new_history = new OrderHistory(); $new_history->id_order = (int)$order->id; $new_history->changeIdOrderState((int)$id_order_state, $order, true); $new_history->addWithemail(true, $extra_vars); Link to comment Share on other sites More sharing options...
jucedupp Posted February 26, 2016 Author Share Posted February 26, 2016 It's calling the same validateOrder method on the PaymentModule class, just from the different route. $this->_checkFreeOrder() around line 218 in the OrderController, it will validate the order as any other payment module, passing in the paid status, and triggering the email. Thank you, sir. After a long struggle you were the only one able to point me in the right direction. Link to comment Share on other sites More sharing options...
bellini13 Posted February 27, 2016 Share Posted February 27, 2016 well, in reality I gave you the answer to your question. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now