Developer forum

Forum » Ecommerce - Standard features » Descrease count in right stock location

Descrease count in right stock location

Jonas Krarup Dam
Reply

Hi,

 

I have set up a test-site, where I created a website in Danish, with a language layer in Swedish.

I have created two stock-locations, DK and SE.

I have set the default Stock Location in website settings->ecommerce for both sites.

I have created a product in both danish and swedish, I have set stock directly on the product, and I have added rows to the "stock" for each location.

Since I have set the default stock location for the website, I would expect stock to decrease on the DK stock location when I complete orders on the DK site, and to decrease on the SE location when I complete orders on the SE site.

 

However, stock is being decreased directly on the product. 

How do I get the stock to decrease on the right stock location? can I set it on the order or something?

 

/Jonas


Replies

 
Nicolai Pedersen
Reply

Hi Jonas

Good description - thank you! Will need to have someone look into this, so will get back.

BR Nicolai

 
Morten Buhl Dynamicweb Employee
Morten Buhl
Reply

Hi Jonas

Try not setting stock directly on the product and instead only on the stock locations. That way stock it correctly decreased on the location corresponding to website settings

/Morten

 
Jonas Krarup Dam
Reply

It seems that I cannot empty the stock field on the product - see attached movie called stock-UI.

 

When I set stock to null on the DB, and complete an order, it just doesn't decrease - see attached movie called Stock db

 

Did I fuck it up?

/Jonas

 
Morten Buhl Dynamicweb Employee
Morten Buhl
Reply

It shouldn't be necessary to set the main stock to NULL. If stock exists in a stock location it should be used first. That's what I'm seeing on 9.7 anyway, what version are you on?

/Morten

 
Jonas Krarup Dam
Reply

I'm on 9.6.10 - I've set up a copy of my test here:

http://hotelchocolat.jkd.se.1stweb-dev.net/produkter-1/shop/eskor/h-boks

 

Danish url: 

http://hotelchocolat.jkd.1stweb-dev.net/

---------

I've only set up the one product in swedish, and with stock on stock locations.

 

/Jonas

 
Morten Buhl Dynamicweb Employee
Morten Buhl
Reply

Your setup looks correct, so it's probably a version thing. Try upgrading to latest release. If that doesn't fix it submit a case to support with a download link so we can get a local version up and running for debugging

 

/Morten

 

You must be logged in to post in the forum