How to trigger actions based on order item quantity in Shopify Flow?

How to trigger actions based on order item quantity in Shopify Flow?

BogdanOasa
Shopify Partner
6 0 4

Is there a way to trigger an action based on how many items were in the order? 

I saw order.lineItems - but no size/quantity/totalCount or something similar

Thanks!

Replies 4 (4)

ShikhaPant
Shopify Partner
32 4 4

You can try liquid size function  for the same somthing like 

 

{% assign my_array = order.lineItems %}
{{ my_array.size }}

 

If helpful then please Like and Accept Solution.
Want to modify or Customize your theme Hire me.
Feel free to contact me on [email protected] regarding any help
BogdanOasa
Shopify Partner
6 0 4

How would I do that in Shopify Flow? Is there a way to write your own logic in conditions?

ShikhaPant
Shopify Partner
32 4 4

If you ae using https://apps.shopify.com/flow?shpxid=e0ac7cd4-BC61-4197-FC05-8C44768EE440 app than you need to talk to shopify as they will best guide you , as it is there app. 

If helpful then please Like and Accept Solution.
Want to modify or Customize your theme Hire me.
Feel free to contact me on [email protected] regarding any help

G-L
Shopify Staff (Retired)
29 4 10

There is a Flow template that uses the correct value, and you might draw inspiration from it: Get notified about irregularly large order quantities.

It references the Order. currentSubtotalLineItemsQuantity field which should do what you look for. 

To learn more visit the Shopify Help Center or the Community Blog.