Skip to content

Product Filter Count Showing Wrong Count After Custom Product Collection – Magento Layered Navigation

I have applied custom filter on product collection to hide certain products from listing page. I have used below event for same <event name=”catalog_product_collection_load_after”> <observer name=”abc_productrestriction_collectionfilter” instance=”AbcProductRestrictionObserverFrontendCatalogCollectionFilter” /> </event> and in the observer, I am removing the product from collection… Read More »Product Filter Count Showing Wrong Count After Custom Product Collection – Magento Layered Navigation

How to make custom customer attribute filterable in the customer grid?

I’ve made a patch and this is the code for creating my customer custom attribute: public function apply() { $this->moduleDataSetup->getConnection()->startSetup(); /** @var CustomerSetup $customerSetup */ $customerSetup = $this->customerSetupFactory->create([‘setup’ => $this->moduleDataSetup]); $customerEntity = $customerSetup->getEavConfig()->getEntityType(Customer::ENTITY); $attributeSetId = $customerEntity->getDefaultAttributeSetId(); $attributeSet = $this->attributeSetFactory->create(); $attributeGroupId… Read More »How to make custom customer attribute filterable in the customer grid?

Jslayout in adminhtml area

I have custom menu item created in “Content” named AskQuestion. Apparently, there is controller and routing for it. All left to do is to make jslayout output some simple text. How do I do this?