Skip to content

product-sorting

Auto Added by WPeMatico

Magento 2.4.3-p1 custom sort by option with custom entity id not working

I have created a custom sorting option distance in magento 2.4.3-p1 and sort the collection with custom sorted entity ids di.xml `<type name=”MagentoCatalogModelConfig”> <plugin name=”catalog_config_plugin” type=”SunarcNearByProductPluginConfig” /> </type>` <preference for=”MagentoCatalogBlockProductProductListToolbar” type=”SunarcNearByProductBlockCatalogProductProductListToolbar” /> <type name=”MagentoElasticsearchModelResourceModelFulltextCollectionSearchCriteriaResolver”> <plugin name=”ajourquin_unset_es_order” type=”SunarcNearByProductPluginElasticsearchModelResourceModelFulltextCollectionSearchCriteriaResolver” /> </type> appcodeSunarcNearByProductPluginconfig.php… Read More »Magento 2.4.3-p1 custom sort by option with custom entity id not working

Magento 2 – Custom sort order not working properly

I have created a custom plugin for sorting options for high to low & low to high price. High to low sort works fine but “low to high” sort order not showing correct results. app/code/Digital/CustomSort/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”>… Read More »Magento 2 – Custom sort order not working properly