title: How can I introspect properties and model fields in Django?
body: <p>I am trying to get a list of all existing model fields and properties for a given object. Is there a clean way to instrospect an object so that I can get a dict of fields and properties.</p>
  
  <pre><code>class MyModel(Model)
      url = models.TextField()
  
      def _get_location(self):
          return "%s/jobs/%d"%(url, self.id)
  
      location = property(_get_location)
  </code></pre>
  
  <p>What I want is something that returns a dict that looks like this:</p>
  
  <pre><code>{
    'id' : 1,
    'url':'http://foo',
    'location' : 'http://foo/jobs/1'
  }   
  </code></pre>
  
  <p>I can use <code>model._meta.fields</code> to get the model fields, but this doesn't give me things that are properties but not real DB fields.</p>