title: django admin - populate field with callable
body: <p>I can't find a single example of anyone doing this apart from this example, which doesn't help me other than to know where the code needs to sit.</p>
  
  <p><a href="https://stackoverflow.com/questions/5014044/how-to-prepopulate-userprofile-fields-in-the-django-admin">How to prepopulate UserProfile fields in the Django admin?</a></p>
  
  <p>so this is my code</p>
  
  <pre><code>class QuoteMaterial(models.Model):
      name = models.CharField(_('name'), max_length=255)
      content = models.TextField(_('content'),
                             help_text=_('A static priced item used when doing a job. Selectable when creating a quote. '))
      price = models.DecimalField(_('price'), max_digits=6, help_text="not sure if this is before or after VAT yet", decimal_places=2, default="0.00")
  
      def get_companies():
          return CompanyProfile.objects.filter(user=request.user)
  
      company = models.ForeignKey(CompanyProfile, default=get_companies) 
  </code></pre>
  
  <p>If its not obvious, im trying in the admin section to populate a dropdown with the available companies that belong to the user that is logged in. </p>
  
  <p>my problem is that i dont know how to pass the request object to "get_companies". anyone know of any examples.</p>