I have a bundled Product that contains 3 virtual products as options.
I have an observer that is listening to an event when an item is added to the cart and I'm having a hard time figuring out how to get the option information that I selected when looking at the product: the start of the observer looks like this:
public function checkSubscriptionHierarchy(Varien_Event_Observer $observer) {
$event = $obse开发者_C百科rver->getEvent();
$product = $event->getProduct();
...
the call to $product->getSku() returns the sku of the bundle product. I'd love to be able to grab the sku of the option that I selected, but cannot figure out how to do that.
Thanks!
I dealt with this by listening to event: checkout_cart_product_add_after
and getting the info off the QuoteItem which worked out.
精彩评论