Since there are (possibly) multiple Detail
for each Intervention
, you need to iterate over those individual instances of Detail
if you want to render them for each Intervention
.
See the docs and examples at Many-to-many relationships | Django documentation | Django
(For clarity, using the reverse of a ForeignKey relationship works effectively the same as a many-to-many. See Related objects reference | Django documentation | Django)