Reputation: 25
I am trying to create a site for financial purpose. I have two models "Company" and "Reports". Reports model has a foreign key linked to Company. I want to render contents of Company and Reports in a single template in a detail view. When i try to render only one of the model's content is shown not both.. Is there any solution to this?
Upvotes: 0
Views: 70
Reputation: 536
It's hard giving a better example without more details but it would look something like this...
{{ reports_object.company_foreignkey.company_field }}
Upvotes: 2