Hi
We operate both a wholesale and retail business from the same web site. Currently Magento supports a percentage discount on the retail price using catalog price rules: this is very easy to set up (thanks!)
We have created hidden categories “Retail minus 10%”, “retail minus 20%”, ‘Retail minus 30%” etc with appropriate price rules, and then added products to each category based on our margins.
But some wholesale customers are special: we give them “Cost plus 20%” (or whatever) across a range of products. It would be very handy to have this as an option on the catalog price rules.
I rummaged in the source code for an hour or so but it looks like there is no simple way to extend the pricing rules with our own custom ones. Either creating an event, or making little subclasses for by_percent, to_percent etc with the option to dynamically load others would allow us to create any price rule we liked…
no… the code is written with a lot of switch/case statements in a not-very-extensible way.
the only way to create this functionality would be to edit the core code, which I’m reluctant to do because magento is still under rapid development. I have put in a feature request with a suggestion that they refactor it using dynamically loadable methods to make it extensible