B2B Customer Price modification

Hello,

I need to build some custom price logic. On the customer I have a field, lets say 5 which means this customer has 5% reduction from the standard pricelist. It is not a campaign, and should not be displayed as such.

A general B2B pricelist for market “Sweden” will allow this reduction to take place.
A pricelist for just this customer is already reduced and should not allow the reduction in price.

I have some CustomData stored on the PriceList to tell me if a reduction is allowed for this pricelist or not.

Is there any way to achieve this in Litium 8, other than implementing my own PriceCalculator (not decorator)?

I don’t think I can do it with a decorator, because the prices returned from standard PriceCalculator does not say from which price list they came, which is what i need to be able to determine if I am allowed to modify the price or not.

I have trouble decompiling the standard PriceCalculatorImpl into working code, so I will have to ask for the source code from Litium to be able to make my own.

Before I do that, could there be another way?

Litium version: 8

In the decorator you can use parents GetPriceLists method and find from which price list the price is collected. Can it be a solution?

I don’t think so. That method would return more than one valid price list.

Say if the channel has a general B2B price list for all customers, and then ontop of that this customer has their own pricelist with cheaper prices.

Would not the GetPriceLists() return both of them, because they are both valid/active for customer?

Yes but you can compare the price that you get and the price that these price lists have and find which price list is used for the calculation.

1 Like

Hm… I will have to think about that one, thanks for the idea!

I will compare the pros and cons of that vs the full implementation. I start work on this next week so I have some time to decide :slight_smile:

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.