Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
So - a return contains line items, just like an order. When creating a view of line items it's currently not possible to create a relationship to the parent return entity under which each line item exists.
It appears this can be done by traversing through the junction table provided by the line item reference field, in combination with the views_handler_relationship_entity_reverse core views handler.
Patch coming soon.
Comment | File | Size | Author |
---|---|---|---|
#2 | commerce_rma-views-relationship-li-to-return-2609682-1.patch | 2.67 KB | chrisolof |
Comments
Comment #2
chrisolof CreditAttribution: chrisolof commentedAttached patch adds a relationship in views from the line item to the return entity referencing it.
Comment #3
Kleinast CreditAttribution: Kleinast as a volunteer commentedPatch did'nt apply correctly on the rc2 version, but code add manualy seem work perfectly.
Save my day, thx.
Comment #4
chrisolof CreditAttribution: chrisolof commentedGlad to hear it worked Kleinast! If you try applying it to 7.x-2.x-dev and it works for you feel free to mark it RTBC so we can get this in the next release.
Also - I'm switching the issue version back to dev branch since that's where this patch is intended to land (and that's what it is rolled against).