title: Django model of a rent contract using Generic Foreign Key
body: <p>I'm trying to model a rent contract in Django and use the admin form to insert and modify it.
  Both owner and tenant can be companies (VAT number) or individuals (no VAT number). Companies and individuals are stored in two different models (Company and Individual).</p>
  
  <p>I'm trying to solve this problem using Generic Foreign Key but I'm not able to show the tenant name in the admin page, only an integer field not friendly at all.</p>
  
  <p>gestimm is the name of the app and that's my oversimplified models:</p>
  
  <pre><code># my gestimm/models.py
  #
  from django.contrib.contenttypes.fields import GenericForeignKey
  from django.contrib.contenttypes.models import ContentType
  from django.db import models
  
  
  class Individual(models.Model):
      name = models.CharField(max_length=100, help_text='Name')
  
      def __str__(self):
          return self.name
  
  
  class Company(models.Model):
      name = models.CharField(max_length=100, help_text='Name')
  
      def __str__(self):
          return self.name
  
  
  class Contract(models.Model):
      description = models.CharField(max_length=30)
      start = models.DateField()
      stop = models.DateField()
  
      def __str__(self):
          return self.description
  
  
  class Tenant(models.Model):
      limit = models.Q(app_label='gestimm', model='individual') | models.Q(app_label='gestimm', model='company')
      contract = models.ForeignKey(Contract, on_delete=models.CASCADE,
                                   null=True, blank=True)
      content_type = models.ForeignKey(ContentType, on_delete=models.PROTECT,
                                       help_text='Tenant', null=True,
                                       limit_choices_to=limit)
      object_id = models.PositiveIntegerField(null=True)
      tenant = GenericForeignKey('content_type', 'object_id')
  </code></pre>
  
  <p>How I tried to solve the problem:</p>
  
  <pre><code># my gestimm/admin.py
  #
  from django.contrib import admin
  
  from .models import Individual, Company, Contract, Tenant
  
  
  class TenantInline(admin.StackedInline):
      model = Tenant
      extra = 1
  
  
  class ContractAdmin(admin.ModelAdmin):
      inlines = [TenantInline]
  
  
  admin.site.register(Individual)
  admin.site.register(Company)
  admin.site.register(Contract, ContractAdmin)
  </code></pre>
  
  <p>I found some old discussions but none of the proposed solutions worked.</p>