New answers tagged

0

create layout file in your custom module as below path: {vendor}/{Module}/view/frontend/layout/catalog_product_view_type_simple.xml <?xml version="1.0"?> <page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd"> <body> <...


1

I came across the same problem. The var mixin method (in the answer above) won't work because there is a 'return storage.post' in the file. The way I did it was the following: app/code/Vendor/Module/view/frontend/requirejs-config.js var config = { config: { mixins: { 'Magento_Checkout/js/model/shipping-save-processor/default': { '...


1

Add this line in di.xml <preference for="\Magento\Framework\Mail\Template\TransportBuilder" type="Vendorname\Modulename\Model\Mail\Template\TransportBuilder" /> Vendorname\Modulename\Model\Mail\Template TransportBuilder.php <?php namespace Vendorname\Modulename\Model\Mail\Template; use Magento\Framework\App\TemplateTypesInterface; use Magento\...


0

I can't comment on existing posts because i'm missing reputation or something like that, so i'm going to do it this way for the sake of clarity. Aren't the last 2 steps, in guerinteed_mike's answer, just for Magento Cloud? To my knowledge, they use the .magento.app.yml file for configuring the server environment on their own hosting platform.


2

Try this <preference for="Magento\Framework\Mail\Template\TransportBuilder" type="Vendor\Module\Plugin\Mail\Template\TransportBuilder"/> now in your TransportBuilder.php namespace Vendor\Module\Plugin\Mail\Template\TransportBuilder; class TransportBuilder extends Magento\Framework\Mail\Template\TransportBuilder{ }


0

app/code/Vendor/Module/etc/di.xml <?xml version="1.0"?> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd"> <preference for="Magento\CatalogInventory\Helper\Stock" type="Vendor\Module\Helper\Magento\CatalogInventory\Stock" /> </config> ...


1

I think the code you have highlighted looks looks OK. Make sure that your module.xml file is declaring Magento_CatalogInventory as a dependancy. <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Module/etc/module.xsd"> <module name="Vendor_Module" > <sequence> ...


0

Classy Llama did a good job on an article that shows multiple situations and how to override template files in each of them. https://www.classyllama.com/blog/template-override-m2 It helped me when I came to this thread looking for answers.


0

in your app/code/Vendor_name/MOdule_name/etc/di.xml <?xml version="1.0"?> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd"> <preference for="Magento\Directory\Block\Data" type="Vendor_name\Module_name\Block\Data" /> </config> and ...


0

i got the solution for the error : customracking.lengh can not bind using knockout so i update the function in the file : Magento\Checkout\CustomerData\DefaultItem.php protected function getCustomRacking() { $data = array('0'=>array('label'=>'test','value'=>'123'),'1'=>array('label'=>'hello','value'=>'456')); return ...


3

override in theme file location : app/design/frontend/Magento/luma/Magento_Checkout/web/template/minicart/item/default.html After changes in default.html file, we have to deploy static file using command, php bin/magento setup:static-content:deploy -f php bin/magento cache:clean php bin/magento cache:flush


0

My mistake, top in Form.php i needed to change use Magento\CatalogSearch\Model\Advanced; to use Vendor\Module\Model\Advanced;


Top 50 recent answers are included