Hi all.

I am developing a Commerce store that adds products to the cart without combining quantities:

//Add line item to cart w/ no combining. 
commerce_cart_product_add($user->uid, $line_item, FALSE);

This means multiple line items may have the same SKU. As a result of this, implementing quantity breaks using tools such as the commerce_price_table are a bit challenging. I thought that the condition in this module that totals products together of a certain type may work but it will not. I needed the granularity of SKU level totals and have it span multiple line items.

I have implemented this condition and it seems to be working rather well. Its very similar to the product type total BUT looks at the SKU instead.

In the comment following this post I will attach my patch for anyone that may find value in this type of condition. If useful maybe it can make its way into this module.

Thanks.

Nick Selvaggio
http://nickgs.com

CommentFileSizeAuthor
#1 SKU_Quantity_Total-1427726-1.patch4.2 KBnickgs

Comments

nickgs’s picture

StatusFileSize
new4.2 KB

Attached is my patch.

Thanks.

Nick Selvaggio
http://nickgs.com