How to make the email get a different template depending on variation purchased
-
Hi,
I discovered you plugin and it seems to have a great potential. Please add documentation for Woocommerce and do a proofreading of all the documentation with a professional translator, there are many typos that lower the trust on your plugin. Also make a tutorial video on how to use plugin with Woocommerce. The documentation needs some love. I say this so you can have more sales ??
My issue: I sell digital products, only variations. I’d like that each time a customer purchases variation A, template A PDF is sent with the complete order email. If customer purchases variation B, Template B PDF is sent with the complete order email.
Can this be achieved? If so, how?
Where do need to paste the shortcode of the templates so that the PDF is attached to the complete order email? Because if I go to Wocommerce > Settings > Emails, Woocommerce tells on the ‘?’ near the fields that only a few default placeholders are available for the Footer and Additional Content fields.
Thanks, let me know and if this is possible I will purchase the plugin (testing the Free version now).
-
Hi,
Thank you for suggestions. We will try to give more attention to documentation. WooCommerce was added not long time ago so it was not yet fully introduced, however in nearest time we must release updated video tutorials with E2Pdf usage and WooCommerce also will be included.
As about your request. If you need to directly send attachment of variable product and not “download” link, you must be able to use
[e2pdf-attachment id="1"]
shortcode inside “Additional content” of “Completed order” email. It will be applied for all product variations, however if you need to split and use different templates for different variation products, you must be able to setup it by setting “dataset” with “id” of variation as:[e2pdf-attachment id="1" dataset="134"]
[e2pdf-attachment id="2" dataset="135"]
. In this case E2Pdf will generate attachment only if variation with this ID purchased and will use Template ID from “id” attribute.https://prnt.sc/xjippr
https://prnt.sc/xjir9tP.S. E2Pdf Template must be connected to “WooCommerce” extension and “Variations” item.
We remain at your service.
Sorry for the delay Oleksandr.
I guess it’s impossible to test if your second proposed solution works with the Free version as it only allows to create one template, right?
If I buy the 5 templates version and your solution doesn’t work even if you helped out on setting it up, would I be later refunded? If it works of course I want to stick with your plugin.
Thanks,
AbelYes, you are correct. You will need License Key which allows at least 2 Templates.
We have 14 Days Money Back Guarantee so we will refund if plugin will not meet your needs without questions. You can just create refund request on our Help Desk or notify us here with some details so we can identify your payment to refund.
We remain at your service.
Thanks Oleksandr I will give it a try.
Thanks Oleksandr I will give it a try.
Do you know if there is any way to test the PDF attachment on the complete order email without making a real purchase in WC?
I have set sandbox Paypal but it does only send the email to the customer. As the email is a tester account from Paypal, I can only acces Paypal email notification in the Dev Portal but not to the real email address.
Thanks,
AbelRegarding WooCommerce documentation here: https://docs.woocommerce.com/document/woocommerce-order-status-control/
By default, WooCommerce will only auto-complete paid orders for products that are both Virtual and Downloadable, assuming that the shop needs to fulfill/ship any orders that don’t meet these criteria.
However you must be able to change order status to “Completed” directly from backend while viewing “Order”.
We remain at your service.
Hi Oleksandr,
As about your request. If you need to directly send attachment of variable product and not “download” link, you must be able to use [e2pdf-attachment id=”1″] shortcode inside “Additional content” of “Completed order” email. It will be applied for all product variations
I tried with a live purchase with only one Template for the moment, The PDF is properly attached. But… it’s very confusing finding the proper tags on the ‘Map Field’ (also the window is very small and cannot be resized).
I need to know the tags for:
– The Order Date (when the Purchase Completed was made).
– The Client Name and Surname.
– The Product Name
– The Product Variation.however if you need to split and use different templates for different variation products, you must be able to setup it by setting “dataset” with “id” of variation as: [e2pdf-attachment id=”1″ dataset=”134″] [e2pdf-attachment id=”2″ dataset=”135″]. In this case E2Pdf will generate attachment only if variation with this ID purchased and will use Template ID from “id” attribute.
Because each product has a different ID for each variation, the solution that you propose here is not feasible. If I have 100 products with 4 variations, does this mean that I need to add 400 tags on the ‘Additonal Content’ form?? As you can imagine this is not feasible.
Plese check these two images:
https://drive.google.com/file/d/1bYgxt1iBdKR_pLo2IFaSl_eK3DcqR4aW/view?usp=sharing
https://drive.google.com/file/d/1kQVu9EWCDh6QCSTDBmwhWfiDR_BVcXoe/view?usp=sharingAs you can see the ID for each variation is different, BUT the custom product attribute values is only 4. Check:
https://drive.google.com/file/d/1308wJ9HOJXthPOMFvcIIPihkLm-pMOYb/view?usp=sharing
So my question is: How to add a E2Pdf tag that checks if the product variation purchased is MP3, PRO, PREMIUM or Unlimited. Can this be done somehow? This way I will only need to add 4 tags in the Additional Content form even if I have 2.000 products
Thanks,
Abel-
This reply was modified 4 years, 1 month ago by
Abel Bascunana.
Hi,
Do you have high resolution? We didn’t get any complaints yet about no possibility to use Visual Mapper. https://prnt.sc/xupkvy. We will check if we can release some improvements to current Visual Mapper version until new version will be released.
1.
[e2pdf-wc-order key="get_date_completed"]
, to format date it must be used [e2pdf-format-date] shortcode wrapper as follows:[e2pdf-format-date format="d.m.Y"][e2pdf-wc-order key="get_date_completed"][/e2pdf-format-date]
2. It must be one of the following shortcodes:
[e2pdf-wc-order key="get_billing_first_name"]
[e2pdf-wc-order key="get_billing_last_name"]
OR
[e2pdf-wc-order key="get_shipping_first_name"]
[e2pdf-wc-order key="get_shipping_last_name"]
3.
[e2pdf-wc-product key="post_title"]
– will output product title with variation
[e2pdf-wc-product key="post_title" parent="true"]
– will output product title4. Here it will be need to understand which meta key used for needed attribute. In our case it’s “attribute_template” https://prnt.sc/xupvlt and shortcode will be:
[e2pdf-wc-product key="attribute_template" meta="true"]
——————-
Yes, using 400 shortcodes is not feasible. Can you please clarify so we can try find a solution: do you need to generate different templates depending on “attribute” (MP3, PRO, PERMIUM, UNLIMITED only)? or also depending on which product purchased by your customer?
We remain at your service.
Fantastic Oleksandr thanks a lot for the shortcodes.
About the visual mapper, I don’t know, it feels lacking some height, the more real state to see more tags so that I don’t have to scroll too much the better. You need to scroll too much currently and if you want to go up again to find a tag that you thought that was interesting you get a bit lost.
4. Here it will be need to understand which meta key used for needed attribute. In our case it’s “attribute_template” https://prnt.sc/xupvlt and shortcode will be: [e2pdf-wc-product key=”attribute_template” meta=”true”]
——————-
Yes, using 400 shortcodes is not feasible. Can you please clarify so we can try find a solution: do you need to generate different templates depending on “attribute” (MP3, PRO, PERMIUM, UNLIMITED only)? or also depending on which product purchased by your customer?
Yes, I only need 4 templates for 4 attributes (I will later add an ‘Exclusive’ variation so it will be 5).
When a customer adds a song to the cart, is mandatory that he selects one of the four licenses (variations): MP3, PRO, PREMIUM, UNLIMITED). When he completes the order, a PDF is sent depending on one of these four licenses that he purchased. (for example with MP3 license there is a 10k stream limit on Spotify, with PRO it’s 100k, etc)
So you are right, I need to attach to the customer email a different template depending on the “attribute”.Thanks,
AbelThank you for clarification. We have in our todo list already the point to update “Visual Mapper” so we will keep in mind your notes and will try to make it more comfortable in use.
As about the task, we are now reviewing the possibility to complete it as currently standard shortcodes do not support it. We hope to get back to you with solution on next week as we need to review all possibilities and it could require to prepare update to plugin to add its support.
We remain at your service.
-
This reply was modified 4 years, 1 month ago by
E2Pdf.
Thanks very much Oleksandr, I’ll await for your news next week much appreciated.
Hi, we just released RC version 1.13.30 with support of “attributes” conditions. You can apply update now by turning on updates from “E2Pdf.com”. Option can be enabled at “E2Pdf” -> “Settings” -> “Release Candidate Builds” (https://prnt.sc/y1liz0). After enabling this option you must be able check for updates at “Dashboard” -> “Updates” and update plugin as usual to version 1.13.30.
It’s recommended to turn off this option after update.
After update you must be able to use such shortcodes inside “Additional content” of WooCommerce email as:
[e2pdf-attachment id="119" attribute_pa_name-license="PRO"]
[e2pdf-attachment id="120" attribute_pa_name-license="MP3"]
* where “name-license” is the slug of attribute (https://prnt.sc/y1mbxp). It must be replaced with your attribute slug. Keep attention on the definition of value (PRO) as it’s case-sensitive.
We also found issue with render product attributes inside PDF with meta=”true” attribute usage as it outputs the slug instead of value, so it was added support additional shortcode. The usage inside E2Pdf Template must look like this now:
[e2pdf-wc-product key="pa_name-license" attribute="true"]
* where “name-license” is your attribute slug.
New shortcode still not available inside “Visual Mapper”, however we will include it in nearest time.
Let us know please if you will be success with solving the task. Thank you.
We remain at your service.
Hi Oleksandr, this is awesome!
One question before attempting to implement this:
We said that to avoid having to enter many ‘ids’ on the WC ‘Additional Content’ email template section, as this would imply adding hundreds of shortcodes if you have hundreds of products- to add only the attributes on the ‘Additional content’ WC email template, that’s without the ‘id’ part.
So instead of:
[e2pdf-attachment id=”119″ attribute_pa_name-license=”PRO”]
it should be:
[e2pdf-attachment attribute_pa_name-license=”PRO”]
This way I will only add MP3, PRO, PREMIUM, UNLIMITED and EXCLUSIVE template shortcodes and I will cover all the licenses for the hundreds of products that I may have.
Does it make sense? What would happen if I don’t add the ‘id’ part?
Let me know thanks a lot,
Abel
Hi,
“id” attribute in shortcode is definition of the E2Pdf Template to use and not the product/variation ID. In example above it will be used #119 Template ID for products that have attribute set to “PRO”, and #120 Template ID for products that have attribute set to “MP3”.
We remain at your service.
Sorry my bad I’ve been adding WC products lately and my head had a shortcircuit ??
Fantastic Oleksandr I will try tonight and let you know, much appreciated!
-
This reply was modified 4 years, 1 month ago by
- The topic ‘How to make the email get a different template depending on variation purchased’ is closed to new replies.