Skip to content

Some Confirmation Emails Do Not Display Product Details

I’ve been experiencing this issue for a while. Some of the confirmation emails do not display the product details.

There are no errors in the PHP logs, so I suspect it might be a condition-related problem.

Is there any way to debug how the email renders the product details?

This is normal confirm email.

normal

This is missing product detail email.

problem

I don’t think this will help much, but here is my email template.

<!--@subject {{trans "Your %store_name order confirmation" store_name=$store.frontend_name}} @-->
<!--@vars {
"var CustomVariable1|raw":"Get Findercode",
"var order_data.customer_name":"Guest Customer Name",
"var store.frontend_name":"Customer Name",
"var is_pickup_order":"Check if order is a pickup order",
"var store_email |raw":"Defined Email Address for this type of mails",
"var store_phone |raw":"Defined Phone Number in the Store Information",
"var store_hours |raw":"Defined Opening Hours Phone Number in the Store Information",
"var order.increment_id |raw":"Order Id",
"var created_at_formatted":"Order Created At (datetime)",
"var order_data.email_customer_note|escape|nl2br":"Email Order Note",
"var formattedBillingAddress|raw":"Billing Address",
"var order_data.is_not_virtual":"Check if shipment exists",
"var pickupAddress|raw":"Pickup Location Address",
"var formattedShippingAddress|raw":"Customer Shipping Address",
"var payment_html|raw":"Payment Details",
"var order.shipping_description":"Shipping Description",
"var shipping_msg":"Shipping message",
"layout handle="sales_email_order_items" order=$order":"Order Items Grid",
"var order_id": "Order DB Id"

} @-->

{{template config_path="design/email/header_template"}}

<table style="width: 100%; ">
    <tr>
        <td>
            <h1 style="color:#000; font-size: 70px; margin: 10px 0px;">Thank you</h1>
            <h2 style="color:#000; font-size: 20px; margin: 10px 0px; letter-spacing: 1.5px;">for ordering from Eastern Serenity.</h2>
        </td>
    </tr>
    <tr class="email-summary">
        <td>
            <strong style="color: black; font-size: 20px; margin-top: 25px; margin-bottom: 5px; ">{{trans 'CONFIRMATION OF YOUR ORDER ON <span class="no-link">%created_at</span>' created_at=$created_at_formatted |raw}}</strong >
            <p style="font-size: 20px; margin-top: 0; margin-bottom: 10px;  padding-bottom: 10px; color:#000;"><span class="no-link">{{var CustomVariable1}}</span></p>
            <p style="line-height: 1.1;  font-size: 20px; margin-top: 0; color:#000;">{{trans 'Order <span class="no-link">#%increment_id</span>' increment_id=$order.increment_id |raw}}</p>
            
        </td>
    </tr>
    <tr class="email-information">
        <td>
            {{depend order_data.email_customer_note}}
            <table class="message-info">
                <tr>
                    <td>
                        {{var order_data.email_customer_note|escape|nl2br}}
                    </td>
                </tr>
            </table>
            {{/depend}}
            <table class="order-details">
                <tr>
                    {{depend order_data.is_not_virtual}}
                    <td class="address-details">
                        <h3>{{trans "Shipping Info"}}</h3>
                        {{if is_pickup_order}}
                        <h4>{{trans "Pickup Location"}}</h4>
                        <p>{{var pickupAddress|raw}}</p>
                        <h4>{{trans "Recipient Address"}}</h4>
                        {{/if}}
                        <p>{{var formattedShippingAddress|raw}}</p>
                    </td>
                    {{/depend}} 
                    {{depend order_data.is_not_virtual}}
                    <td class="method-info">
                        <h3>{{trans "Shipping Method"}}</h3>
                        <p>{{var order.shipping_description}}</p>
                        {{if shipping_msg}}
                        <p>{{var shipping_msg}}</p>
                        {{/if}}
                    </td>
                    {{/depend}}
                </tr>
            </table>
            {{layout handle="sales_email_order_items" order_id=$order_id area="frontend"}}
        </td>
    </tr>
    <tr>
        <td style="min-height:30px; height: 30px;"> </td>
    </tr>

    <tr>
        <td>
            <table style="width: 100%; ">
                <tr>
                    <td>
                           <p style="font-size: 18px;">Once your package ships we will send an email with a link to track your order. You are supporting small and family businesses that produce unique items in very small quantities. Your support changes lives.<p><br>
                            <span style="color: black; font-size: 18px;">Thank you!</span><br>
                            <strong style="color: black; font-size: 18px;">The Eastern Serenity Team</strong><br><br>
<div style="text-align: center;">
                    <a href="https://www.xx.com/xx-xx.html"><img style="width: 80% !important;" src="{{store url=""}}pub/media/wysiwyg/Email/xx.jpg" alt="Apparel"
                    title="Apparel"/></a> </div>
                    </td>
                </tr>
                <tr style="align-items: center;">
                    <td style="text-align: center;">
                        <a style="font-weight: bold; color: black; display: inline-block; width: fit-content; padding: 10px 20px; font-size: 18px; text-align: center;"
                        href="https://www.xxx.com/">
                        easternserenity.com
                        </a>
                    </td>
                </tr>
                <tr style="align-items: center;">
                    <td style="text-align: center; padding-top: 20px;">
                        <a style="background-color: #000; color: white; padding: 14px 100px; text-align: center; font-size: 18px; display: inline-block;" href="https://www.xxx.com/" target="_blank">SHOP NOW</a>
                    </td>
                </tr>
            </table>
        </td>
    </tr>
</table>

{{template config_path="design/email/footer_template"}}