Jump to content

  • You cannot start a new topic
  • You cannot reply to this topic

Do Not Show "in Stock" On Product Page. Rate Topic   - - - - -

 
  • jimmyod
  • Senior Member
  • Members
  • Join Date: 24-Apr 12
  • 449 posts

Posted 02 August 2014 - 04:27 PM #1

Availability: In stock

I have to "Enable inventory tracking" but I do not want to show the "In stock" message. I can prob. just delete from language translations, but what about the "Availability part? From any templates?

Update: I found Design-themes-basic-templates-common-product_data.tpl and deleted the"Availability" (line 344) and this works but may not be the best way, huh?

 
  • eComLabs
  • CS-Cart Expert
  • Authorized Reseller
  • Join Date: 27-Jan 14
  • 19693 posts

Posted 04 August 2014 - 07:37 AM #2

To disable this feature for the product template only, please open the /design/themes/THEME/templates/blocks/product_templates/default_template.tpl file and replace:

{include file="common/product_data.tpl" product=$product separate_buttons=$separate_buttons|default:true but_role="big" but_text=__("add_to_cart")}

with:

{include file="common/product_data.tpl" product=$product separate_buttons=$separate_buttons|default:true but_role="big" but_text=__("add_to_cart") show_product_amount=false}

And clear the cache

GET A FREE QUOTE | CS-Cart Add-ons | CS-Cart Licenses | CS-Cart Development | CS-Cart Design | Server Configuration | UniTheme and YOUPI
CS-Cart                USD 345     Multi-Vendor              USD 1250    CS-Cart RU                         24500 руб.
CS-Cart Ultimate  USD 775     CS-Cart + YOUPI      USD 545      CS-Cart RU + UniTheme    36000 руб.


 
  • jimmyod
  • Senior Member
  • Members
  • Join Date: 24-Apr 12
  • 449 posts

Posted 04 August 2014 - 11:57 AM #3

To disable this feature for the product template only, please open the /design/themes/THEME/templates/blocks/product_templates/default_template.tpl file and replace:

{include file="common/product_data.tpl" product=$product separate_buttons=$separate_buttons|default:true but_role="big" but_text=__("add_to_cart")}

with:

{include file="common/product_data.tpl" product=$product separate_buttons=$separate_buttons|default:true but_role="big" but_text=__("add_to_cart") show_product_amount=false}

And clear the cache

Thanks, but this change made the product page blank.

 
  • eComLabs
  • CS-Cart Expert
  • Authorized Reseller
  • Join Date: 27-Jan 14
  • 19693 posts

Posted 04 August 2014 - 02:00 PM #4

Thanks, but this change made the product page blank.


What CS-Cart version do you use?

GET A FREE QUOTE | CS-Cart Add-ons | CS-Cart Licenses | CS-Cart Development | CS-Cart Design | Server Configuration | UniTheme and YOUPI
CS-Cart                USD 345     Multi-Vendor              USD 1250    CS-Cart RU                         24500 руб.
CS-Cart Ultimate  USD 775     CS-Cart + YOUPI      USD 545      CS-Cart RU + UniTheme    36000 руб.


 
  • jimmyod
  • Senior Member
  • Members
  • Join Date: 24-Apr 12
  • 449 posts

Posted 04 August 2014 - 02:58 PM #5

What CS-Cart version do you use?

v4.1.5
My bad...forgot to cc.
Thank you :grin:

 
  • eComLabs
  • CS-Cart Expert
  • Authorized Reseller
  • Join Date: 27-Jan 14
  • 19693 posts

Posted 05 August 2014 - 07:50 AM #6

You are welcome!

GET A FREE QUOTE | CS-Cart Add-ons | CS-Cart Licenses | CS-Cart Development | CS-Cart Design | Server Configuration | UniTheme and YOUPI
CS-Cart                USD 345     Multi-Vendor              USD 1250    CS-Cart RU                         24500 руб.
CS-Cart Ultimate  USD 775     CS-Cart + YOUPI      USD 545      CS-Cart RU + UniTheme    36000 руб.


 

Posted 24 August 2014 - 02:58 AM #7

Thanks for this - it helped me too. But a supplementary question: what line of code (and where) do I change to also remove the 'In Stock' from products when in Products List.

 
  • gurdji
  • Junior Member
  • Members
  • Join Date: 25-May 10
  • 49 posts

Posted 10 February 2019 - 02:52 PM #8

There is any setting/easier option (except altering the code) to hide in Stock" On Product Page on newer cs cart version eg. current version cs cart 4.9.3?



 
  • imago
  • Senior Member
  • Members
  • Join Date: 18-Oct 18
  • 461 posts

Posted 10 February 2019 - 05:38 PM #9

In views/products/view.tpl

change

show_product_amount=true

to

show_product_amount=false



 
  • amdowney
  • Senior Member
  • Members
  • Join Date: 22-Oct 14
  • 252 posts

Posted 17 February 2019 - 09:13 AM #10

How would one go about having it show 'Availability: Good Stock' for anything set to 'do not track'?


Stores: CCTV Kits & www.jmtb.co.uk