title: Deleting inline item fails due to None id
body: <p>I have a quote model that has quoteitems as a related field.</p>
  
  <pre><code>class BusinessQuote(models.Model):
      id = models.AutoField(primary_key=True)
      client = models.ForeignKey(BusinessClient, null=True, on_delete=models.SET_NULL)
      site = models.ForeignKey(BusinessSite, null=True, on_delete=models.SET_NULL)
      ...
  </code></pre>
  
  <p>and</p>
  
  <pre><code>class BusinessQuoteitem(models.Model):
      id = models.AutoField(primary_key=True)
      quote = models.ForeignKey(BusinessQuote, null=True, on_delete=models.CASCADE)
      job = models.ForeignKey(BusinessJobtask, blank=True, null=True, on_delete=models.SET_NULL)
      ordered = models.IntegerField(default=0)
      ...
  </code></pre>
  
  <p>They are displayed in admin as inlines</p>
  
  <pre><code>class InlineQuoteItems(admin.TabularInline):
      model = BusinessQuoteitem
      extra = 0
      formfield_overrides = { ... }
  
  class QuoteAdmin(admin.ModelAdmin):
      list_display = ['id', 'date', 'client', 'site', 'tradename', 'total',     'converted']
      list_filter = ['tradename', 'client', ]
      inlines = [InlineQuoteItems]
  
  admin.site.register(BusinessQuote,QuoteAdmin)
  </code></pre>
  
  <p>when I try and delete an inline item I'm getting the following error:</p>
  
  <pre><code>Exception Type: TypeError
  Exception Value: %d format: a number is required, not NoneType
  Exception Location: /home/.../business/models.py in __str__, line 237
  </code></pre>
  
  <p>Line 237 relates to:</p>
  
  <pre><code>def __str__(self):
      return "%d" % (self.id)
  </code></pre>
  
  <p>Whats confusing is that this has normally worked out the box so I'm at a loss as to what could cause the inline delete to fail.</p>
  
  <p>I am doing some javascript on the fields prior to submitting which totals the inline items and updates the invoice total but it doesn't touch id fields and as its client-side I cannot see it being an influence.   </p>