M2A Relation Display Not Showing Properly
- Dominant language
- TypeScript
- Stars
- 37.9k
- Forks
- 4.9k
- Avg merge
- 3d 21h
- Merged PRs (30d)
- 36
Description
### To Reproduce
1. Create 3 collections:
* `collection_one` with `name` field (set as display template)
* `collection_two` with `title` field (set as display template)
* `collection_three`

2. Configure M2A relation on `collection_three`:
* Select the Related Collections: `collection_one`, `collection_two`
* Interface: Leave it empty as default
* Display: Choose "Related Values"
3. Create items:
* Add records in `collection_one` (e.g., `{name: "Ahmed"}`)
* Add records in `collection_two` (e.g., `{title: "Admin"}`)
4. Link records in `collection_three`
### Describe the Bug
What you will notice after the steps you have done is the following:
Interface works perfectly thanks to the recent PR ([https://github.com/directus/directus/pull/24503]()):

But it's not working properly in the display:

And if you added the related values manually in the display tab for example like this:
`{{collection}}: {{item:collection_one}} {{item:collection_two}}`
it shows like this:

Expected Result:
Same as the interface, it should show the collection name then the "display template" for the collection which is in our case `title` or `name`
### Directus Version
v11.8.0
### Hosting Strategy
Self-Hosted (Docker Image)
### Database
*No response*
Contributor guide
Assessment
This issue has not been assessed yet.