{ "info": { "author": "Martin Brochhaus", "author_email": "mbrochh@gmail.com", "bugtrack_url": null, "classifiers": [], "description": "Django Document Library\n=======================\n\nA Django application to manage multilingual documents and display them on your\nsite in a downloads section.\n\nComes with a django-cms apphook and is based on django-filer.\n\n\nInstallation\n------------\n\nIf you want to install the latest stable release from PyPi::\n\n $ pip install django-document-library\n\nIf you feel adventurous and want to install the latest commit from GitHub::\n\n $ pip install -e git://github.com/bitmazk/django-document-library.git#egg=document_library\n\nAdd ``document_library`` to your ``INSTALLED_APPS``::\n\n INSTALLED_APPS = (\n ...,\n 'document_library',\n )\n\nRun the migrations::\n\n ./manage.py migrate document_library\n\n\nAdmin inline\n------------\n\nYou can attach documents to any model. To make things easier, you can add\na tabular inline to your model's admin which allows to attach documents.\n\nIn your project's ``models.py`` or any file that get's loaded early, do the\nfollowing::\n\n from yourapp.admin import YourAdmin\n from object_attachments.admin import ObjectAttachmentInline\n\n YourAdmin.inlines = YourAdmin.inlines[:] + [ObjectAttachmentInline]\n\n\nTemplatetags\n------------\n\n\nget_files_for_documents\n+++++++++++++++++++++++\n\nUse this templatetag in order to render all files for a given document::\n\n {% load document_library_tags %}\n {% get_files_for_document document as files %}\n {% for file in files %}\n
{{ file.name|default:file.original_filename }}
\n {% endfor %}\n\n\nget_frontpage_documents\n+++++++++++++++++++++++\n\nUse this templatetag if you want to render a list of documents on your\nfrontpage::\n\n {% load document_library_tags %}\n {% get_frontpage_documents as documents %}\n