Jump to content

Include more details in Payment Received email


graham_w

Recommended Posts

Hi, i'm looking to add more details into the payment received email. I've copied across the order confirmation template, however it isn't including any of these details.

I had a bit of a look around and it looks like it requires changes to /classes/order.class.php but I tried a few things and what I was doing didn't work. Can anyone point me in the direction of what needs changing to make this email content include the required data ?

Alternatively, how can I change the email that gets sent when the order status is changed to  "Processing" ?

Thanks

Graham

Link to comment
Share on other sites

The version cc628 will make available all the same data found in the Order Confirmation email contents to the Order Complete email contents.

So, let's review the process.

You can open the Order Confirmation email contents in the editor and switch the editor to Source mode. This makes it easier to copy to the clipboard easier.

Then, open the Order Complete email contents in the editor and switch the editor to Source mode. Delete everything but then paste the contents into the editor and Save.

Then, be sure to click the illuminated button in the upper-right corner to Clear the Cache.

Make a test order, then in admin, move that order to Completed.

Link to comment
Share on other sites

Thanks for that. I'm trying to get more details into the email that's sent when the order is moved to Processing. 

So someone places an order which has no shipping included because it's too difficult to calculate for bulky items, payment gateway is print order form. 

The order is received, the store calculates the shipping and modifies the order with the shipping cost. 

What I'm trying to do is then when the order is moved to Processing, it sends an email with all of the order confirmation details and the now added shipping cost along with payment details to the buyer. 

When I copy the details to the order payment email which is sent when the order is set to processing, obviously the data is not made available to this email by default. How can I make it available to this email? Or change the email that is sent when I change the order to processing so these order details are included?

Thank you taking the time to assist.

Link to comment
Share on other sites

If you were to use an external database utility, and look at the database table CubeCart_order_summary, you would see most everything about the order. (In CubeCart_order_inventory, you would see most things about the items.) (There are a few other details in other tables.)

Of note, you will see 'shipping' (cost), 'ship_method' and ship_product'. Once you save the edited details about the order, the contents in the tables are updated.

Then, when an email is sent, those new/updated details are included: {$DATA.shipping}, etc.

However, payment gateways have a way of telling CubeCart that an Order Confirmation email has already been sent, and if that has happened, a second one will not be sent. With the POF gateway, in the admin settings screen, is a checkbox that will enable the sending of that order confirmation email immediately upon completing the checkout sequence.

If you uncheck that box, then the POF will not send that initial confirmation email, and will report to CubeCart that "already_sent" is false. So, when moving this order to Processing, no matter how many times you move it out of and back into processing, an email gets sent each time.

NOTE: Moving an order to Processing will have CubeCart send its standard Order Confirmation contents. I believe you are wanting to send the POF's custom email contents (which you can see in the module's folder/skin/print.tpl).

If so, that will require some thought on how to do that.

Be back soon.

Link to comment
Share on other sites

Well, I was off the mark... The POF module does, in fact, send CubeCat's standard Order Confirmation email contents. It is the module's user-printable page that CubeCart displays after completing the checkout process that is "custom".

So, I think as mentioned above, unchecking that checkbox will allow you to send the email when moving the order to Processing.

 

Link to comment
Share on other sites

You are correct, that gives the expected email now.

Is there a way to turn off the payment confirmation email when moving to processing ? The way we are using it, the order has not been paid for when we move it to processing so that email is not required now.

Thank you for your help, and apologise if I haven't been very clear with my request.

Link to comment
Share on other sites

That seems to allow the payment received email and stop the order confirmation email. Was hoping to allow only the order confirmation email and stop the payment received email.

Thanks

On second thoughts, it's all good, I can make the two emails work. Thank you again for your help.

Link to comment
Share on other sites

In that same file, just a few lines above the edit, is the statement that tells CubeCart that the order's payment status is Success.

Undo the previous edit, and make this edit:

From:

$order->paymentStatus(Order::PAYMENT_SUCCESS, $cart_order_id);

To:

// $order->paymentStatus(Order::PAYMENT_SUCCESS, $cart_order_id);

 

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...