Serve files with Django.
Find a file
2012-12-10 11:43:41 +01:00
demo Refs #16 - Improved documentation for Nginx optimizations (references to demo project). Refs #18 - Moved temporary_media_root utility from demoproject.download.tests to django_downloadview.test. 2012-12-10 11:05:28 +01:00
django_downloadview Refs #16 - Improved documentation for Nginx optimizations (references to demo project). Refs #18 - Moved temporary_media_root utility from demoproject.download.tests to django_downloadview.test. 2012-12-10 11:05:28 +01:00
docs Refs #8, refs #9, refs #12 - Introduced links to alteratives: django-sendfile, django-private-files, django-protected-files. 2012-12-10 11:38:04 +01:00
.gitignore Introduced project's placeholders. Work in progress. 2012-08-27 12:00:17 +02:00
AUTHORS Reviewed documentation. Preparing first public release. 2012-12-04 11:47:37 +01:00
buildout.cfg Reviewed documentation. Preparing first public release. 2012-12-04 11:47:37 +01:00
CHANGELOG Back to development: 1.1 2012-12-04 12:58:32 +01:00
INSTALL Reviewed documentation. Preparing first public release. 2012-12-04 11:47:37 +01:00
LICENSE Introduced project's placeholders. Work in progress. 2012-08-27 12:00:17 +02:00
Makefile Improved demo project: provided initial data and a simple homepage with some links. 2012-12-04 12:21:45 +01:00
MANIFEST.in Reviewed documentation. Preparing first public release. 2012-12-04 11:47:37 +01:00
README Refs #16 - Improved documentation for Nginx optimizations (references to demo project). Refs #18 - Moved temporary_media_root utility from demoproject.download.tests to django_downloadview.test. 2012-12-10 11:05:28 +01:00
setup.py Reviewed documentation. Preparing first public release. 2012-12-04 11:47:37 +01:00
VERSION Fixed development version number. 2012-12-10 11:43:41 +01:00

###################
Django-DownloadView
###################

Django-DownloadView provides (class-based) generic download views for Django.

Example, in some urls.py:

.. code-block:: python

   from django.conf.urls import url, url_patterns
   from django_downloadview import ObjectDownloadView
   from demoproject.download.models import Document  # A model with a FileField


   # ObjectDownloadView inherits from django.views.generic.BaseDetailView.
   download = ObjectDownloadView.as_view(model=Document, file_field='file')

   url_patterns = ('',
       url('^download/(?P<slug>[A-Za-z0-9_-]+)/$', download, name='download'),
   )
 

**********
Ressources
**********

* online documentation: http://django-downloadview.readthedocs.org
* PyPI page: http://pypi.python.org/pypi/django-downloadview
* code repository: https://github.com/benoitbryon/django-downloadview
* bugtracker: https://github.com/benoitbryon/django-downloadview/issues