[Skip to main content](#vessel-content)

#   Is this possible? No quantity when out of date

##

- **[gasoline](/forum/user/6454-gasoline "View gasoline's Profile")**
- [![gasoline's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar6454.jpg)](/forum/user/6454-gasoline "View gasoline's Profile") Topic Author
- [ Offline](/forum/user/6454-gasoline)
- Still searching ...

Less More

- Posts: 247
- Thank you received: 9
-
-
-
- [](https://gasoline.nl)
-

3 years 6 months ago [\#351906](#351906) by [gasoline](/forum/user/6454-gasoline "View gasoline's Profile")  *[Is this possible? No quantity when out of date](/forum/26-product-category-display/906436-is-this-possible-no-quantity-when-out-of-date#351906 "-- HikaShop version -- : 4.7.2 -- Joomla version -- : 4.3.1 -- PHP version -- : 8.1  Hi, My client sells courses. So you can subscribe during a certain period. I show the number of available spaces (quantity available) on the website. But when the subscription period is over I display button CLOSED but the quantity is still shown. Can I set it up like when subscription period closes that quantity is also not displayed anymore?")* was created by *[gasoline](/forum/user/6454-gasoline "View gasoline's Profile")*

-- HikaShop version -- : 4.7.2
-- Joomla version -- : 4.3.1
-- PHP version -- : 8.1

Hi,
My client sells courses. So you can subscribe during a certain period.
I show the number of available spaces (quantity available) on the website. But when the subscription period is over I display button CLOSED but the quantity is still shown. Can I set it up like when subscription period closes that quantity is also not displayed anymore?

[ ![howtodoit.png](/forum/attachment/57086) ](/forum/attachment/57086 "howtodoit.png")

---

I'll keep on trying!

- [ ![howtodoit.png](/forum/attachment/57086) ](/forum/attachment/57086 "howtodoit.png") [ ](/forum/attachment/57086?download=1 "howtodoit.png")

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI2LXByb2R1Y3QtY2F0ZWdvcnktZGlzcGxheS85MDY0MzYtaXMtdGhpcy1wb3NzaWJsZS1uby1xdWFudGl0eS13aGVuLW91dC1vZi1kYXRlP3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86584
- Thank you received: 14325
-
-

3 years 6 months ago [\#351913](#351913) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Is this possible? No quantity when out of date](/forum/26-product-category-display/906436-is-this-possible-no-quantity-when-out-of-date#351913 "-- HikaShop version -- : 4.7.2 -- Joomla version -- : 4.3.1 -- PHP version -- : 8.1  Hi, My client sells courses. So you can subscribe during a certain period. I show the number of available spaces (quantity available) on the website. But when the subscription period is over I display button CLOSED but the quantity is still shown. Can I set it up like when subscription period closes that quantity is also not displayed anymore?")*

Hi,

When you edit both files product / quantity and product / add_to_cart_ajax via the menu Display&gt;Views, you can find the line: Code:

if($end_date &gt; 0 &amp;&amp; $end_date &lt; $now) {

Add the line: Code:

$this-&gt;row-&gt;product_stock_message = '&amp;nbsp;';

after it and it should do what you want.

The following user(s) said Thank You: [gasoline](/forum/user/6454-gasoline "View gasoline's Profile")

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI2LXByb2R1Y3QtY2F0ZWdvcnktZGlzcGxheS85MDY0MzYtaXMtdGhpcy1wb3NzaWJsZS1uby1xdWFudGl0eS13aGVuLW91dC1vZi1kYXRlP3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[gasoline](/forum/user/6454-gasoline "View gasoline's Profile")**
- [![gasoline's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar6454.jpg)](/forum/user/6454-gasoline "View gasoline's Profile") Topic Author
- [ Offline](/forum/user/6454-gasoline)
- Still searching ...

Less More

- Posts: 247
- Thank you received: 9
-
-
-
- [](https://gasoline.nl)
-

3 years 6 months ago [\#351921](#351921) by [gasoline](/forum/user/6454-gasoline "View gasoline's Profile")  Replied by *[gasoline](/forum/user/6454-gasoline "View gasoline's Profile")* on topic *[Is this possible? No quantity when out of date](/forum/26-product-category-display/906436-is-this-possible-no-quantity-when-out-of-date#351921 "-- HikaShop version -- : 4.7.2 -- Joomla version -- : 4.3.1 -- PHP version -- : 8.1  Hi, My client sells courses. So you can subscribe during a certain period. I show the number of available spaces (quantity available) on the website. But when the subscription period is over I display button CLOSED but the quantity is still shown. Can I set it up like when subscription period closes that quantity is also not displayed anymore?")*

> nicolas wrote: Hi,
>
> When you edit both files product / quantity and product / add\_to\_cart\_ajax via the menu Display&gt;Views, you can find the line:
>
> Code:
>
> if($end_date &gt; 0 &amp;&amp; $end_date &lt; $now) {
>
>
>
> Add the line: Code:
>
> $this-&gt;row-&gt;product_stock_message = '&amp;nbsp;';
>
>
>
> after it and it should do what you want.

You'r a hero. Thanks for the fast respons.

This message contains confidential information

---

I'll keep on trying!

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI2LXByb2R1Y3QtY2F0ZWdvcnktZGlzcGxheS85MDY0MzYtaXMtdGhpcy1wb3NzaWJsZS1uby1xdWFudGl0eS13aGVuLW91dC1vZi1kYXRlP3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

Board Categories HikaShop Install &amp; Update Product &amp; Category Display Content Creation Sales and Orders Orders management Reports &amp; Statistics Customers Checkout Payment Methods Shipping Methods Import &amp; Export (CSV, XLS…) Specific Features Affilation Taxes Wishlist Vote Carousel &amp; Slider Mass Actions Filters &amp; Search Discount &amp; Coupon Feature Request Integrations Showcase General Talk about HikaShop Development HikaShop 3.0 Beta Translation Commercial Jobs HikaShop Components HikaMarket Market: Feature requests Market: How to? Market: Bug Report HikaSerial General talk about HikaSerial Serial: Bug Report Serial: How to? Support en Français de HikaSerial (French Support) HikaSubscription HikaAuction Auction: Feature requests Auction: How to? Auction: Bug report Hikashop around the world Support en Français (French Support) Russian FAQ. Курс выживания с Hikashop. Частые вопросы и о Расширения Hikashop Наши сайты на Hikashop 日本語版サポート(Japanese Support) Thai German Archives Bug Report How to?

[](/forum/topics/feed/mode-topics?format=feed&type=rss)

Time to create page: 0.049 seconds

[Powered by](/forum/credits) [Kunena Forum](https://www.kunena.org)
