I have created one module and it has system configuration on the admin side, where the admin has the functionality to enable/disable the module. As per system configuration, I need to hide the price from every place on the front end.
i.e. "catalog, category, wish-list, a related product, up-sell products, cart, checkout, orders, email, account dashboard, etc.."
from everywhere I need to hide the price if the module is enabled.
Is there any global file for the price which can be overridden and add the code for hiding price?
I found one file, But if we override \Magento\Catalog\Pricing\Render\FinalPriceBox
and change in wrapResult()
function, it works but it will affect only product page and home page not for wish-list and other places.
how can I achieve
this functionality? Is anyone have any idea about it?