1

Magento 2.4.4 + 2.4.5 has made changes to Email templates: https://developer.adobe.com/commerce/frontend-core/guide/templates/email-migration/

I'm working on the upgrade to 2.4.5 and this depend section is no longer working:

{{depend order.getIsNotVirtual()}}
   <div class="ampdf-address-section-item">
       <p class="ampdf-title ampdf-text">{{trans "Shipping Address"}}</p>
       <p class="ampdf-text">{{var formattedShippingAddress|raw}}</p>
   </div>
{{/depend}}

How do I translate this into the new 2.4.4-2.4.5 requirement?

1 Answer 1

5

In Magento 2.4.5, email template format is change. So please check the below condition

{{depend order_data.is_not_virtual}}
   <div class="ampdf-address-section-item">
       <p class="ampdf-title ampdf-text">{{trans "Shipping Address"}}</p>
       <p class="ampdf-text">{{var formattedShippingAddress|raw}}</p>
   </div>
{{/depend}}

I hope it will help you. If any issue let me know.

1
  • Yup it works, thanks! I just wish I didnt have to guess what the syntax is. If they wrote it all out in documentation, that would be great.
    – PaulM
    Aug 25, 2022 at 16:03

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.