Magento的 - 获得registred客户
问题描述:
的公司名称我用这个代码:Magento的 - 获得registred客户
$customerCollection = Mage::getResourceModel('customer/customer_collection')
->addNameToSelect()
->addAttributeToSelect('email')
->joinAttribute('postcode', 'customer_address/company', 'default_billing', null, 'left')
->joinAttribute('postcode', 'customer_address/postcode', 'default_billing', null, 'left')
->joinAttribute('billing_city', 'customer_address/city', 'default_billing', null, 'left')
->joinAttribute('billing_region', 'customer_address/region', 'default_billing', null, 'left')
->joinAttribute('billing_country_id', 'customer_address/country_id', 'default_billing', null, 'left');
如何我也得到一个registred客户的公司名称?
感谢。
答
检查,如果属性名是真正的“公司”
joinAttribute('company', 'customer_address/company', 'default_billing', null, 'left')
谢谢,它的工作原理;) – Bizboss 2010-12-23 12:19:55