Hi I’m making a plugin and I’m using this API to add notes to orders: https://help.shopify.com/en/api/reference/orders/order#update-2019-07
I was wondering if there is any way to add some formatting to the note so I can do something like this:
Key: Value,
Key: Value,
Key: Value,
Rather than Key: Value, Key: Value, Key: Value,
I tried the note attributes, but that is visible to the customer and we don’t want this to be visible to the customer. Thanks!
Hi @nicksrc , You just need to be pass \r\n on your content , to manage data on next line. hope it will helpful for you.
Thanks
Hi @CloudPlug24 ,
This solution does not work for me. Do you know another way to do this?
Thanks
I could handle this by removing an hyphen in my for loop :
{%- for lineItems_item in order.lineItems -%}
{%- for metafields_item in lineItems_item.variant.metafields -%}
{%- if metafields_item.namespace == 'namespace' and metafields_item.key == 'key' %}
{{ lineItems_item.variant.sku }} : {{ metafields_item.value }}
{%- endif -%}
{%- endfor -%}
{%- endfor %}
The if statement has no hyphen at the end to add a breaking line at the end of each line.
Order Notes
How would this be edited to replace ## with a line break?