Upgrades Questions on upgrading to version 6.x.
Version 6.x > Upgrades > Ecommerce CustomShoppingCartInfoProvider View modes: 
User avatar
Member
Member
Peter - 12/18/2011 9:33:08 PM
   
Ecommerce CustomShoppingCartInfoProvider
Hi,
we have upgraded to 6.0 and lot of things have changed in the custom ecommerce providers.

In version 5.0 in our custom ecommerce provider we used EvaluateShoppingCartContent(object shoppingCart, bool evaluateForInvoice) method in which we added an extra row in the shopping cart content table with some negative amounts as a credit for some products.

In version 6.0, the overload for this method has been removed. We tried to override the EvaluateContentInternal(ShoppingCartInfo cart) with some success, however the shopping cart totals are not recalculated. What would you suggest we could use for this?

Thanks,
Peter

User avatar
Member
Member
Peter - 12/19/2011 9:27:38 PM
   
RE:Ecommerce CustomShoppingCartInfoProvider
Add on to my previous post.

We also tried override the following

protected override void EvaluateShoppingCartInternal(ShoppingCartInfo cart)
{
base.EvaluateShoppingCartInternal(cart);
}


But this method is never called.

User avatar
Member
Member
kentico_michal - 1/2/2012 3:26:54 AM
   
RE:Ecommerce CustomShoppingCartInfoProvider
Hello,

The default implementation of the EvaluateShoppingCart method is divided into four methods (EvaluateShoppingCartItems, EvaluateContent, EvaluateContentTaxes, EvaluateShippingTaxes). As their names imply, the first one evaluates shopping cart items, recalculates discounts and taxes of all shoppping cart items by executing the ShoppingCartItemInfoProvider.EvaluateShoppingCartItem method for all shopping cart items. The EvaluateContent method recalculates shopping cart content table. The EvaluateContentTaxes method creates content taxes summary table and the EvaluateShippingTaxes method creates shipping taxes summary table.

Kentico CMS 6.0 provides a new customization model. For more information I would like to point you to the following blog: E-commerce 6 - New customization model

Best regards,
Michal Legen