I have found several ways online but none seem to work. Does anyone know how to add the customer email to the grid for orders in Magento 1.4
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
copy
app/code/core/Mage/Adminhtml/Block/Sales/Order/Grid.php
to
app/code/local/Mage/Adminhtml/Block/Sales/Order/Grid.php
then under the following line
$collection = Mage::getResourceModel($this->_getCollectionClass());add
$collection->getSelect()->joinLeft(array('sfo'=>'sales_flat_order'),'sfo.entity_id=main_table.entity_id',array('sfo.customer_email'));then in the _prepareColumns() method add
note. you will need to add a ‘filter_index’ to all calls to addColumn pointing to main_table.field_name