简体   繁体   English

如何在Magento中检索废弃的购物车项目详细信息

[英]how to retrieve Abandoned cart Item details in Magento

I am writing an REST API in Magento to retrieve the Abandoned cart Item details. 我在Magento中编写REST API,以检索“遗弃的购物车商品”详细信息。 I can able to retrieve Abandoned cart details ( like user email, name and date.) In that I would like to get the product details ? 我可以检索被遗弃的购物车详细信息(例如用户电子邮件,名称和日期。),我想获取产品详细信息吗? Please find the below code , currently I am using it. 请找到以下代码,目前我正在使用它。 from this How can I retrieve product details also ? 从中我还可以如何检索产品详细信息?

$collection = Mage::getResourceModel('reports/quote_collection');
$collection->prepareForAbandonedReport(); 
$output = $collection->load()->toArray();

The above code working fine with abandoned cart user details. 上面的代码可以很好地处理废弃的购物车用户详细信息。

Thanks 谢谢

It seems to be easy to get details. 获取细节似乎很容易。 But I haven't found how to get options 但是我还没有找到如何获得选择权的方法

$quotes = Mage::getResourceModel('reports/quote_collection');
    foreach ($quotes as $quote) {
        $cart_items = $quote->getItemsCollection()->getItems();
        foreach ($cart_items as $item) {
            print_r($item->getData());
        }
    }

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM