I expect this result.

expect result

in catalog_product_view.xml I add wrapper container for the add-in that container 2 blocks. Price and Add to cart button block.

<container name="product.price.wrapper" label="Product Price Wrapper"
           as="product-price-wrapper" htmlTag="div" htmlClass="product-price-wrapper" />

I used customizable options in my products, so i moved 2 blocks

<move element="product.info.options.wrapper.bottom" destination="product.price.wrapper"/>
<move element="product.info.price" destination="product.price.wrapper"/>

and moved the custom wrapper container product.price.wrapper after Customizable Options on the product page.

<move element="product.price.wrapper" destination="product.info.form.options" after="-"/>

So, I have a bug - if I change Customizable Options to the Tiers I do not see the product.info.price block, only button but not button block what I moved product.info.options.wrapper.bottom block with add to cart functionality this is the button in container product.info.form.content.

How to make this functionality more flexible? Since now the problem is that my changes are tied to the Customizable Options functionality and not to all price blocks and buy buttons on the page.

  • How price should be displayed when there are multiple tier prices? All along side button? Feb 4, 2022 at 13:01
  • @piyush_systematix I don't understand the question, could you explain more? Feb 4, 2022 at 13:04
  • You mentioned that your code is not working when product has tier prices. I want to know how should prices should be printed when a product has tier prices. Feb 4, 2022 at 13:06
  • @piyush_systematix By default Magento 2 displays either the price for tier price with quantity 1 or the price specified in the Price attribute. (without taxes or with taxes, depending on configurations). That's fine for me Feb 4, 2022 at 13:14


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.