Jump to content

[Resolved] Adding personalised content, from Public Note Content, to customer emails


BooJewels

Recommended Posts

I'm just setting up my new CC6 store, with Al's help and am just fine tuning the details before it goes live.

One of the things I habitually do [with my current CC3 store] is put personal comments (about the order, I don't usually insult them) in the order complete e-mail - I type in the "Comments to customer" area and check the 'inform customer' box.

CC6 looks to do something similar, in that in the notes section of orders, it states alongside the 'Public Note Content' box that customers can see these notes and they're appended to order notifications.

I've set up my e-mail templates and signature and sending them to myself with a mock order, all appears well, except the content of the Public Note Content box isn't included.  I wondered if I needed to include a macro in the e-mail template to allow this, but there doesn't appear to be one.

Any ideas what am I missing or have failed to engage? 

Whilst I've sent up the order completed email to include some details of the order, many of my orders (as most are for gifts) require personal attention and instructions following, so I like to confirm that I've followed their specific requests.

Link to comment
Share on other sites

Thanks both.  All this stuff just makes me realise how little I know.  I've been on a steep learning curve this last few days.

If I don't put anything in the 'note to customer' box, presumably, if I don't put any further text around the macro in the template, it will just leave a blank line?

Link to comment
Share on other sites

Can I please ask a supplementary question, based on something I read in a @bsmither post from a few years ago - I'm hoping that it will give me a way of working something.

Because, as discussed above, I like personal confirmatory comments about an order to go out when the order is complete, I'd also like a copy of that message for my records (I know the detail is still in the notes).

If I understand it correctly, if I set up myself another admin log-in, and when logged in as that, in the settings choose to have the "Order status for admin email notifications" set to 'Order complete', then I'd also get a copy of that message to the email address used for that 'admin' which would still be me. 

Would that work as I'm interpreting?

Link to comment
Share on other sites

I think what you need is to add blind copy code to order.class.php for the emails you want a copy of. Here's the code for case self::ORDER COMPLETE

				/* no need to send this email for digital only orders */
				if (!$this->_skip_order_complete_email && $this->_email_enabled && ($content = $mailer->loadContent('cart.order_complete', $order_summary['lang'])) !== false) {
					$this->assignOrderDetails();
					$mailer->ClearBCCs(); $mailer->AddBCC($this->_notifyAdmins());
					$mailer->sendEmail($this->_order_summary['email'], $content);
					unset($content);
				}

				break;

$mailer->ClearBCCs(); $mailer->AddBCC($this->_notifyAdmins()); has been added

Link to comment
Share on other sites

@Dirty Butter  Many thanks, that has done the trick and is a more elegant solution than my earlier suggestion. 

I was a smidge bamboozled initially, as a message arrived to the wrong e-mail address, but of course I had used that as a customer and the message is a blind copy, not addressed to my admin mailbox.

Thank you kindly, much appreciated.

Link to comment
Share on other sites

Glad to be of help! The thanks really needs to go to Bsmither, who has helped me with lots of edits like this that make the whole program work to suit my needs. Please understand that all such edits will be lost when you upgrade CC. I always put comments before and after the edited code, so I can merge them into the upgrade. I use BeyondCompare4 to see the difference between the new stock CC upgrade and my own version, but there are other good file difference software apps available.

Link to comment
Share on other sites

16 hours ago, Dirty Butter said:

Please understand that all such edits will be lost when you upgrade CC

I'm hoping, once I get this site working properly, not to update again for a while.  But I do keep a note of what I've done.  I don't have the luxury of time to perpetually update stuff, so once it's working, I intend to leave it be for a while.  But thanks for the heads up.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...