Rafan595 Posted September 19, 2013 Share Posted September 19, 2013 Hello, can please someone help me how to make in prices drop module shows only products where reduction is more then 10%? Thanks! Link to comment Share on other sites More sharing options...
vekia Posted September 19, 2013 Share Posted September 19, 2013 you're talking about "prices drop" module or about prices drop page with listed "specials" ? Link to comment Share on other sites More sharing options...
Rafan595 Posted September 19, 2013 Author Share Posted September 19, 2013 In source code is it: <!-- MODULE Block specials --> Link to comment Share on other sites More sharing options...
Rafan595 Posted September 22, 2013 Author Share Posted September 22, 2013 nobody knows? Link to comment Share on other sites More sharing options...
Emzed Posted September 23, 2013 Share Posted September 23, 2013 Hi, The specials block displays a random special using the getRandomSpecial function in the Products class, as opposed to the function getPricesDrop, which extracts all specials. The actual reduction value of the selected product is only extracted from the database once a random product has already been chosen from an initial database operation. Thus sorting directly from the specials block module isn't possible by default. An alternative specials module, TM Specials, actually just uses getPricesDrop to extract all the specials but only displays 6 of them in price descending order. It would be interesting to know if this method is signifcantly slower. If you don't want to modify a parameter in getPriceDrop that allows sorting by reduction as a percentage, keeping in mind that I guess you'd have to manually calculate non-percentage reductions as percentages, you could use a similar method of employing getPriceDrop and then filter and randomise downstream. To be honest, I don't know the impact on speed and whether it's worth it for a single special that you may not necessarily need/want to randomise in the first place. Link to comment Share on other sites More sharing options...
Recommended Posts