cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

CPQ Pricing based on Product Hierarchy

0 Likes
845

This question is for SAP Solutions Config 2.0 with SAP Hybris Commerce 6.4, wherein the PRODH value is determined from the price for configured product.

de.hybris.platform.sap.productconfig.runtime.ssc.impl.ConfigurationContextAndPricingWrapperImpl

protected IItemInfo getItemPricingContext(final KBKey kbKey)

Here the configurators product hierarchy attribute is used to determine the PRODH, PRODH1, ZZPRODH2,ZZPROH3,ZZPRODH4.

The problem being here is now this need to be changed to retrieve it from the ConfigModel i.e configuration created using this configurator product like config.getRootInstance().getCstic("PRODH") and subsequent hierarchy is calculated based on cstic PRODH value.

I am really confused about the flow where to plug this logic to get the pricing for the configured product correctly.

Tried to include it in, ConfigurationContextAndPricingWrapperImpl.preparePricingContext but this does not get called while performing reverse configuration, it gets called only while the start of configuration of product when there is no product hierarchy available.

Also tried to include to include it in ConfigurationContextAndPricingWrapperImpl.processPrice, here I extracted the pricingcontext included my PRODH values but there is no price coming at all after this change.

Can you please help as in where we can include our logic to get the cpq pricing calculation to pick up the appropriate PRODH value induced?

Accepted Solutions (1)

Accepted Solutions (1)

0 Likes

Have resolved this. Please find the approach.

https://help.sap.com/viewer/d048886b27c9483987c0455c2aa4adee/3.1.0.0/en-US/1c1aed547262426ca9e2d876f...

Using the above we have introduced a PRP type with java implementation in ECC in table UELIMP and UEAIMP.

Then we create PRODH, PRODH1, ZZPROD2 etc in UEAATT table of ECC.

In the java implementation include the logic to addAttributeBindings for the above attributes.

Answers (0)