How to update multiple invoices array.

Solution We can use the foreach to update the multiple invoices array. On the constructor use the function On the execute function foreach each invoice and set the value. So through this, we can update multiple invoices. Thank you.

Published
Categorized as Magento

How to fix issue related to the calendar

When we click on the calendar first and select some date. After that when we click anywhere on the page the calendar will be opened. To fix, this issue we need to write CSS for the main div of the calendar field.Position: relative; By this, we can fix the issue.

Published
Categorized as Magento

Why can’t one switch back to the default mode on Magento 2?

To switch back to default mode, open:- app/etc/env.php And change:- ‘MAGE_MODE’ => ‘developer’, Back to:- ‘MAGE_MODE’ => ‘default’, And re-deploy static files again. reference:https://magento.stackexchange.com/questions/112523/why-cant-one-switch-back-to-the-default-mode-on-magento-2

Published
Categorized as Magento

Load price phtml file in magento2

we have to get product price HTML using Magento 2 below way, we have to create a block Vendor\Module\Block\Product. PHP and get your product object and call the below function in your template file. protected $resultLayout; public function __construct(\Magento\Framework\View\Result\Layout $resultLayout) {$this->resultLayout = $resultLayout;} public function getProductPriceHtml(\Magento\Catalog\Model\Product $product){/** @var \Magento\Framework\Pricing\Render $priceRender */$priceRender = $this->resultLayout->getLayout()->getBlock(\Magento\Framework\Pricing\Render::class);if (!$priceRender) {$priceRender… Continue reading Load price phtml file in magento2

Published
Categorized as Magento