title: Get application name in Django model
body: <p>The following is the model for a Django app. Let the app be called MyApp. The idea is for every app to have it's folder under the MEDIA_ROOT.</p>
  
  <pre><code>class MyModel(models.Model):
      .... #Other fields
      datoteka = models.FileField(upload_to = 'MyApp',null = True)
  </code></pre>
  
  <p>Is there a way to get the name of the app from somewhere and remove the hardcoded <code>MyApp</code>.</p>
  
  <p><a href="https://stackoverflow.com/q/6000205/1214214">This</a> is a similar question, however I have no access to the request object in the model.</p>