Check Inventory Quantity for a Specific Inventory Location

ali303
Tourist
10 0 4

Hi. I run a store which holds physical stock and fulfils the vast majority of our orders from a single UK warehouse. However, we have multiple Locations setup on our store so that we can check and display the live inventory from some of our main suppliers that are provided via various API feeds from their end.

 

The main problem I am having is setting up various Flow automations that only check the inventory level at our UK warehouse Location, and ignore the inventory levels at all other Locations. 

 

For example, one our suppliers has thousands of SKUs. We hold a lot of their stock here in the UK warehouse (with availability displayed on our front end product pages as "UK warehouse"). However, for SKUs that we don't have physically have stock of, we display the inventory availability at the supplier's warehouse to inform customers that they can still order these items, but there might be a little wait for them while we order the item(s) in especially for them (availability is displayed on our front end product pages as "our EU warehouse").

 

The primary Flow I am trying to create is one that recognises that these special order items have arrived at our UK warehouse (i.e. stock is booked in via a Transfer) from the supplier's warehouse, but in doing so ignores the supplier's warehouse live stock level (which is almost always greater than zero). This Flow would then notify our warehouse team that the inventory has arrived and is then queued for dispatch to the customer later that day.

 

For example, once the inventory Transfer is booked in, the Flow would need to check:

Inventory Quantity at our UK warehouse only is greater than or equal to zero.

So far, no matter which lineItems field I try to use on Flow, it factors in the inventory of the variant at all Locations when checking this availability. As a result, if the supplier has stock but we do not, the variant is still marked as available due to the overall inventory quantity being greater than zero (i.e. if our inventory is -1 and the supplier's is 20, the overall inventory quantity is 19).

 

So far, what I have been able to come up with is:

 

"line items item fulfillment service location name is equal to UK Warehouse"

"inventory levels item location name is equal to UK Warehouse"
"line items item variant inventory quantity is greater than or equal to 0"

 

It is the final line that seems to be causing issues, as the Flow activity log shows that this line is checking the total inventory quantity available, as opposed to the inventory quantity at the item location of "UK Warehouse".

 

Apologies if I've written this in a way that sounds more complicated than it is! I am sure there is a straightforward answer (i.e. a field or variant that I have missed) and I would imagine that a solution to this issue would be quite useful for shop owners who allow customers to back order items that are only available at supplier warehouses, as opposed to the shop owner's warehouse.

 

Thanks in advance for any help or suggestions!

Replies 10 (10)

DaveMcV
Shopify Staff
88 28 25

Hi Ali303,

 

I reached out to you privately to ask for some more context to help debug this.

 

Thanks!

DaveMcV | Flow Development Manager @ Shopify
- Finding Flow useful? Leave us a review
- Need Flow help? Check out our help docs.
- Building for Flow? Check out Flow's dev docs.

gentryalan
Visitor
1 0 1

Were you able to find a resolution for this? I have a similar situation for a store in NY with multiple warehouses and a store.

paul_n
Shopify Staff
1021 133 243

There are a lot of different ways that merchants might want to manage low stock or out of stock processes in their store. We recently published a new template to the Flow Template Library that shows how to show and hide products if all of its variants are out of stock at a single location. It makes use of a tag to track whether it was already out of stock, and then you can check the current inventory using Flow's conditions. This template can be adapted to fit any number of scenarios.

Paul_N | Flow Product Manager @ Shopify
- Finding Flow useful? Leave us a review
- Need Flow help? Check out our help docs.
- Building for Flow? Check out Flow's dev docs.
DariusWS
Shopify Partner
84 1 19

@paul_n Thank you! It was exactly what I was looking for.

 

P.S. Url doesnt work

paul_n
Shopify Staff
1021 133 243
Great. About the URL, what didn't work? It does require you to login to
your store and if you have multiple stores to choose a store. Once you do
that, it should open the template library in Flow to that template.
Paul_N | Flow Product Manager @ Shopify
- Finding Flow useful? Leave us a review
- Need Flow help? Check out our help docs.
- Building for Flow? Check out Flow's dev docs.
DariusWS
Shopify Partner
84 1 19

My fault. That shop didn't have FLOW APP. So url was not informative: There’s no page at this address. 

DariusWS
Shopify Partner
84 1 19

@paul_n Another issue I found using FLOW app. When using same template you shared I would like to make multiple warehouse check. For example if qty in warehouseX is 0 and warehouseZ is more then 0 add tag. Simple task, but... App Freeze each time try to add extra condition. No error msg, nothing. It is problem with my account permissions maybe? Could you help? store: worldcondomsstore

DariusWS_0-1658474520883.png

 

cybko
Shopify Partner
38 0 7

No matter what I do, whether I try "start with" or put the whole name in, it always fails the condition

I've asked it to look at ones beginning with Y, it finds one beginning with Y but still marks it as false

paul_n
Shopify Staff
1021 133 243

Most likely you've set up some other part of your condition incorrectly. I can't tell though because there isn't enough detail in your post. If you could provide a screenshot showing all of the condition that would be helpful, along with what your data looks like. 

Paul_N | Flow Product Manager @ Shopify
- Finding Flow useful? Leave us a review
- Need Flow help? Check out our help docs.
- Building for Flow? Check out Flow's dev docs.
cybko
Shopify Partner
38 0 7

You were right. I flipped some conditions around and it fixed it. I edited my reply as the example I put in was a working version.