Score:1

Show the Quantity field on the product page but hide it on the catalog page

sa flag

I created an "ABC Book" product, whose URL is https://example.com/product/1. I added the Quantity field from Administration > Commerce > Configuration > Order item types > Default > Manage form display > Add to cart.

The field appears on the product details page (https://example.com/product/1).

I created a view to display all products on a page (https://example.com/shop). The field also appears on the view.

How can I hide the field on https://example.com/shop, but still show it on https://example.com/product/1?

Score:0
br flag

You may find the views documentation useful

If I understand your question correctly, you may either set, for you view:

  1. a different display under the view setting format, content and then set up the right fields you want to show on the product display configuration
  2. On the view settings, again under the format sections use the fields settings, and then directly select the fields you want do display in the view
Ravi avatar
sa flag
There is no specific field for quantity. I have created a view mode for products, let's say its name is "teaser". I am using this teaser mode to display in the view (shop). But there is no quantity field to control its visibility.
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.