How can I output either the word "products" or the single product name?
I’ve tried about every different iteration of this and I get “Your template contains placeholders we can't replace. No problem, de-select that option to view a preview.” when I try to preview
All of these output correctly as template tags if I remove the conditional
Is this the Shopify Fulfilled Order Metric? If so, it looks like you’re missing an “s” from fulfillment (should be fulfillments), and you also need to access the first item of fulfillments to get line_items, so it should look like this:
Thank you for the clarification! Both of those snippets work in my testing for the Shopify Delivered Order Metric. What if you tried using the “Item Count” field instead of the size of the line_items array? So
{% if event|lookup:’Item Count’ > 1 %}...{% endif %}
Additionally, if you print the size of the line_items array under fulfillment, is it correctly outputting the length of the array? I would check that to see if it’s isolated to the ‘size’ function.
Last piece, you could try explicitly casting the output of size to an int by using floatadd:0:
{% if event.extra.fulfillment.line_items|size|floatadd:0 > 1 %}…
If none of those work, I can report this as a bug for our team to look into
None of those work, all the same error (which is actually no error, I only see it because I opened up the dev console), this is all I see, it was super confusing
I’m also editing a text only email in the source code which maybe is where the bug is here