0

I have used the below code its not working.

di.xml file:

< config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd"> < type name="Magento\Catalog\Pricing\Render\FinalPriceBox"> < plugin name="customization_finalpricebox" type="Checkout\Customization\Plugin\FinalPriceBox"/> < /type> < /config>

Plugin file code: FinalPriceBox.php

namespace Checkout\Customization\Plugin;

class FinalPriceBox
{
function aroundToHtml($subject, callable $proceed)
{

    if($subject->getSaleableItem()->getHidePrice()==1){
        return '';
    }else{
        return $proceed();
    }

}

}

0

You can try this via custom code or using a third-party extension.

Not the answer you're looking for? Browse other questions tagged or ask your own question.