New answers tagged

1

Magento does NOT save any 404 requests anywhere. If you want to track 404 requests, check 404 Error Logger extension and it's FREE.


0

Try this patch: https://github.com/magento/magento2/files/4060889/fix-checkout-form-validation.txt To read how to apply patches with composer, continue here: https://www.integer-net.com/magento-2-javascript-bundling-setup-default/ Also, can you share what version of Magento you are on?


1

bottom toolbar amount is hiding from style-m.css if you want to quickly check the toolbar amount in the bottom then you can do this in same file (list.phtml) by style tag. <style> .products.wrapper ~ .toolbar .toolbar-amount { display:block; } .toolbar-amount { display: none; } </style> but include css in phtml file is not a good ...


2

The tool-bar is already available at the bottom of products. it is hide using CSS. You can remove display:none and it will start showing. please see attached screen shot. If you want to hide top toolbar-amount you can use: .toolbar-amount { display: none; } .products.wrapper~.toolbar .toolbar-amount { display: block; }


0

Override template Magento_Catalog:product/list.phtml in your theme (app/design/frontend/[vendor]/[your-theme]/Magento_Catalog/templates/product/list.phtml). From here you can move toolbar block wherever you want. <?= $block->getToolbarHtml() ?>


0

Please follow the below URL. hope it useful for you. https://www.tigren.com/billing-under-shipping-address-m2/ if you still need to change just let me know.


2

This is not because of the developer mode and Yes this will also happen on your production if you did composer update or take pull of this code-base Here is bit of explanation, bin/magento setup:upgrade is required when module version in code-base is different to that module's version in database bin/magento setup:upgrade will run install-update(schema/...


1

For language dropdown getChildHtml('store_language') ?> The language dropdown will be shown if you create a store view from the admin panel. For store_switcher getChildHtml('store_switcher') ?> The store dropdown will be shown if you create a store from the admin panel.


0

Please Follow these steps: rm -rf generated/code/[VendorName]/[ModuleName] bin/magento se:di:co This generates the interceptor files for your module.


0

Have you tried adding your value in CompositeConfigProvider <?xml version="1.0"?> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd"> <type name="Magento\Checkout\Model\CompositeConfigProvider"> <arguments> <...


0

The error shows because of You have defined the <referenceContainer name="page.wrapper"> at the start of the file and not added the end tag of this node like </referenceContainer> So add the end tag or remove this tag if this not needed.


0

The issue was because I was not understanding the routes feature properly. In this module I declared 2 routes. One for the view and one for the add to cart. I was using the same url and expecting the add to cart to work when I needed to go to url/cart. I forgot that when using the url it will default to Index.php. I had a file Cart.php in the same directory ...


0

composer require magento/magento2-functional-testing-framework:"2.3.13" allure-framework/allure-codeception:"1.3.0" allure-framework/allure-phpunit:"1.2.3" --dev This is the smallest composer update to make unit tests work for M2.3.1 community edition. If you (for some reason like me) want composer.lock to have minimal changes and minimal affection on other ...


0

First check if email communication is disabled or not. Store -> Configuration -> Advanced -> System -> Mail Sending Settings -> Disable Email Communications should be no After that you can check Mageplaza SMTP log if it exists and /var/log/mail.log


1

You should not use object manager. You can now use the account management api to create customers very easily. Try this way: <?php /** * @category Magento 2 * @author Mattia Kozianowski */ declare(strict_types=1); namespace Vendor\Module; use Magento\Customer\Api\Data\CustomerInterface; /** * Class CreateCustomer * * @package Vendor\...


0

You can try below to resolved this issue: lib/internal/Magento/Framework/Data/Collection/AbstractDb.php public function getSize() { if ($this->_totalRecords === null) { $itemCount = count($this->_items); if ($this->_totalRecords === null || ($itemCount > 0 && $itemCount !== $this->_totalRecords)) { $sql = $this-...


1

Your plugin is correct but it is not picked up by the magento interception system because the Elasticsearch Client class is not instantiated via ObjectManager. it is instantiated using the good old new Client(...) approach. See it in Elasticsearch\ClientBuilder::instantiate(). Plugins work only for classes that go through the object manager to get ...


1

Using variables in the template like this not work? {{config path="trans_email/ident_general/name"}} For example {{config path="general/store_information/email"}}


2

app/design/frontend/Vendor/theme-name/Magento_Customer/layout/customer_account_create.xml <?xml version="1.0"?> <page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="1column" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd"> <body> <referenceBlock name="...


1

I think the problem is the store_id, website_id being zero. At least in Magento 1, a customer associated to the admin website could not login in the frontend. It was there just for creating orders associated to him/her in the backend. I wrote a few more words about it (but for magento 1) in here: Customer Associated with the Admin Store But you can simply ...


0

Try this code :- $collection = $this->productFactory->create(); $collection->addAttributeToFilter('status', array('eq' => 1));


2

When ko render specified template it using current context, which is item in your case. If current item has no property custom_variable_data you will se an error like that one: If you want to call a parent property (minicart property) you can access it using the $parent context like this: <span data-bind="html: $parent.custom_variable_data"></span&...


0

Try to use addAttributeToFilter with or condition $collection->addAttributeToFilter('attribute_code', array( array('finset'=> array('237')), array('finset'=> array('238')), array('finset'=> array('239')), ) );


0

On the Admin menu, select Stores > Configuration under Settings. Then in the left panel select Sales > Sales. Scroll down you will find a heading named Minimum Advertised Price under that set Enable MAP as No. Then Flush Magento Cache. Hope it will


2

we are create three form fields. <field name="customer_id" formElement="select" component="Vendorename_Modulename/js/components/select-customer" > <argument name="data" xsi:type="array"> <item name="config" xsi:type="array"> <item name="filterOptions" xsi:type="boolean">true</item> ...


0

Vendor/Module/etc/product_types.xml <?xml version="1.0"?> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Catalog:etc/product_types.xsd"> <type name="custom_product_type_code" label="Custom Product Type Label" modelInstance="Vendor\Module\Model\Product\Type"> &...


2

Please try to update below line in your customer_account_index.xml <move element="customer_account_dashboard_top" destination="content" before="-" /> Hope this will help you!


2

Magento includes this feature in its Magento2.3 version. It simplifies the Magento’s installation and upgrade processes. Previously we had to write the database script for each version of the module. Various scripts were required for different operations on the database. Declarative schema helps Magento to simplify module upgradation procedures. Natively ...


0

By default result will be ASC order i.e oldest order first If you need the latest order, You need to set DESC order in search Criteria You can try below code: index.php/rest/V1/orders?searchCriteria=all&searchCriteria[sortOrders][0][field]=entity_id&searchCriteria[sortOrders][0][direction]=DESC Hope above will help!


0

Instead of "headless" think of it as "faceless"--in that the backend still exists, but the content is displayed via API (or similar) elsewhere, instead of necessarily on a dedicated, Magento website. It's the marketing babillage du jour for a relatively old and unremarkable concept.


2

You can get active stores using following way: <?php namespace Vendor\Module\Controller\Index; use Magento\Framework\App\Action\Context; use Magento\Store\Model\ResourceModel\Store\CollectionFactory; class Index extends \Magento\Framework\App\Action\Action { /** * @var CollectionFactory */ protected $collectionFactory; /** ...


0

Check below code to get the stores by the current website, namespace Vendor\Module\Block; class YourFile extends \Magento\Framework\View\Element\Template { public function __construct( \Magento\Framework\View\Element\Template\Context $context, \Magento\Store\Model\StoreManagerInterface $storeManager, \Magento\Store\Model\...


0

This article covers it in a simple manner: https://www.coredna.com/blogs/headless-commerce


0

You can save and display information with Ajax using Magento's default way, for that you need change/replace /app/code/Vendor/Module/Controller/Index/Save.php & /app/code/Vendor/Module/view/frontend/templates/view.phtml files. /app/code/Vendor/Module/Controller/Index/Save.php <?php namespace Vendor\Module\Controller\Index; use Magento\Framework\...


0

you can get the product lists Using SearchCriteria in REST API. http://local-magento.com/rest/V1/products/?searchCriteria[filter_groups][0][filters][0][field]=category_id&searchCriteria[filter_groups][0][filters][0][value]=<category-id>&searchCriteria[filter_groups][0][filters][0][condition_type]=eq&searchCriteria[filter_groups][1][filters]...


0

Please check the following link it will help you: Magento 2 Vue Storefront


0

Please put below code to your UI file. <form> ... <fieldset> ... <hidden name="hidden_example"> <settings> <value>hidden value</value> </settings> </hidden> </fieldset> </form> Hope it works! and if you want to pass value ...


0

run this command php bin/magento setup:db-declaration:generate-whitelist --module-name=VendorName_ModuleName then change this <column xsi:type="text" name="description" nullable="false" comment="Description"/> and finally run this command php bin/magento setup:upgrade


0

I think the problem is nullable="false" your setting the column should not be null and you are setting its default value to null, so, here you are creating a conflict for an interpreter I guess. Try the below code and let us know the result. <column xsi:type="text" name="description" nullable="true" default="NULL" comment="Description"/>


1

If anybody stumbles across this in the future. Based on Pritam Info 24's answer we modified our Price.php class to also include the formatting for the tiered prices as such: <?php /** * Copyright © 2016 Magento. All rights reserved. * See COPYING.txt for license details. */ namespace Company\MyModle\Ui\DataProvider\Product\Modifier; use Magento\...


3

In mageto2, you can not cancel an order which is at Hold status. If you want then you first need to changes order status to UnHold then you can cancel.


0

I assume you are using a custom Module name "Company_MyModule" step 1) Create requirejs-config.js under app/code/Company/MyModule/view/frontend/ File : app/code/Company/MyModule/view/frontend/requirejs-config.js var config = { config: { mixins: { 'Magento_Swatches/js/swatch-renderer': {'Company_MyModule/js/swatch-...


0

You can directly select the options by url - https://domain.com/test8.html#319=662&322=685 https://domain.com/test8.html#super_attribute1=option-value&super_attribute2=option-value So you can use that concept and implement.


0

You can call JS and PHTML file from your custom module layout file: /app/code/Vendor/Module/view/frontend/layout/module_index_index.xml <?xml version="1.0"?> <page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../../lib/internal/Magento/Framework/View/Layout/etc/page_configuration.xsd" ...


0

VendoreName/ModuleName/view/frontend/layout default_head_blocks.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"> <head> <script src="VendoreName_ModuleName::js/our_module_js_file_name.js" /> ...


0

Add category URL rewrite manually. Follow these steps Marketing > URL Rewrites > Add New URL Rewtie > [ Choose 'For Category' ] > Save This will fix your issue. Don't need to add 150k+ products again.


0

Magento fires 2 events in ajaxSubmit method event catalogCategoryAddToCartRedirect in code $('body').trigger('catalogCategoryAddToCartRedirect', eventData); fired if you set redirect to cart after add product configuration to true The other one is contentUpdated in code $(self.options.minicartSelector).trigger('contentUpdated') if minicart is enabled. You ...


0

Firstly check what type of currencies is you paypal account accepting PayPal currency setup Secondly kindly provide us with PayPal request payload (without any sensitive data) Either currency is not properly set in payload or your account do not accept the currency. Might be both.


1

It was not there in 2.3 when I needed it. I think they have now removed the config to not regenerate on save... as this was recommended never to be off. I had speed issues with my script to fix and with some modules I tried. elgentos/regenerate-catalog-urls is the module to use being fast, flexible and reliable. From the readme... This extension ...


0

we fixed this issue by setting fielddata=true for the category_ids field after every reindex. After every reindex fielddata values are reset. so we were written a script which set fielddata=true for the particular field after every reindex.


Top 50 recent answers are included