Products out of stock

How to configure and adapt Aimeos based shops as developer
Forum rules
Always add your Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
User avatar
g-trema
Posts: 5
Joined: 23 Mar 2020, 20:23

Products out of stock

Post by g-trema » 31 Mar 2020, 06:31

Hello!
is there an easy way to avoid displaying products that are out of stock?
Thank you!
PHP 7.2.28
Laravel Framework 6.18.1
Aimeos 2019.10

User avatar
aimeos
Administrator
Posts: 7836
Joined: 01 Jan 1970, 00:00

Re: Products out of stock

Post by aimeos » 01 Apr 2020, 07:22

Not directly. Stocks and products are separated because stocks are highly volatile and would prevent caching. Thus, they are added via Javascript by a separate request and that makes it more difficult to show only products that are in stock.

The "easiest" way would be to hide products via CSS in the list view depending on the stock request (which returns Javascript, so you can add your code to the template easily).
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, Image give us a star

User avatar
g-trema
Posts: 5
Joined: 23 Mar 2020, 20:23

Re: Products out of stock

Post by g-trema » 05 Apr 2020, 12:45

Okay, got it!
Thank you very much for the answer!
PHP 7.2.28
Laravel Framework 6.18.1
Aimeos 2019.10

Post Reply