- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-25-2020
11:00 AM
09-25-2020
11:00 AM
Hello all,
I have a created a custom grid in admin ,
I want to assign custom attributes from customer to one of the column in the grid , I can get the value of attribute from customer repository but how can I pass it to collection?
Any help appreciated.
Thank You.
Solved! Go to Solution.
Labels:
1 ACCEPTED SOLUTION
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-26-2020
06:06 AM
09-26-2020
06:06 AM
Hello all,
I have resolved this by joining my collection with table
`customer_entity_varchar`
$customerEav = $collection->getTable('customer_entity_varchar'); $collection->getSelect()->join( array('customereav'=>$customerEav), '`order`.customer_id = customereav.entity_id AND customereav.attribute_id=214', ['custom_attribute' => 'customereav.value']);
hope this helps you as well.
Thank You.
2 REPLIES 2
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-26-2020
06:06 AM
09-26-2020
06:06 AM
Hello all,
I have resolved this by joining my collection with table
`customer_entity_varchar`
$customerEav = $collection->getTable('customer_entity_varchar'); $collection->getSelect()->join( array('customereav'=>$customerEav), '`order`.customer_id = customereav.entity_id AND customereav.attribute_id=214', ['custom_attribute' => 'customereav.value']);
hope this helps you as well.
Thank You.
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-07-2021
05:07 AM
05-07-2021
05:07 AM
Re: Assign custom attribute values to grid collection
Thanks a lot
Solved my problem