From fe1bfd1fa46dc5096ea7ada7b37745f628dca5b1 Mon Sep 17 00:00:00 2001 From: Ross Poulton Date: Mon, 7 Jul 2014 12:10:53 +1000 Subject: [PATCH] Replace django.contrib.markup with django-markdown-deux. Closes #219. --- README.rst | 3 ++- docs/install.rst | 5 +++-- helpdesk/templates/helpdesk/kb_item.html | 2 +- requirements.txt | 1 + setup.py | 4 ++-- 5 files changed, 9 insertions(+), 6 deletions(-) diff --git a/README.rst b/README.rst index 4e7f3dbf..f0e0a9d4 100644 --- a/README.rst +++ b/README.rst @@ -31,7 +31,8 @@ Dependencies (pre-flight checklist) 4. An existing WORKING Django project with database etc. If you cannot log into the Admin, you won't get this product working. 5. `pip install django-bootstrap-form` and add `bootstrapform` to `settings.INSTALLED_APPS` -6. `pip install email-reply-parser` to get smart email reply handling +6. `pip install django-markdown-deux` and add `markdown_deux` to `settings.INSTALLED_APPS` +7. `pip install email-reply-parser` to get smart email reply handling **NOTE REGARDING SQLITE AND SEARCHING:** If you use sqlite as your database, the search function will not work as diff --git a/docs/install.rst b/docs/install.rst index c35ba4e4..13e1d19a 100644 --- a/docs/install.rst +++ b/docs/install.rst @@ -39,6 +39,7 @@ Adding To Your Django Project 'django.contrib.admin', # Required for helpdesk admin/maintenance 'django.contrib.markup', # Required for helpdesk text display 'south', # Highly recommended to make database migrations simpler. + 'markdown_deux', # Required for Knowledgebase item formatting 'helpdesk', # This is new! ) @@ -87,9 +88,9 @@ Adding To Your Django Project Ideally, accessing http://MEDIA_URL/helpdesk/attachments/ will give you a 403 access denied error. -7. If it's not already installed, install ``python-markdown``:: +7. If it's not already installed, install ``django-markdown-deux`` and ensure it's in your ``INSTALLED_APPS``:: - pip install Markdown + pip install django-markdown-deux 8. If you already have a view handling your logins, then great! If not, add the following to ``settings.py`` to get your Django installation to use the login view included in ``django-helpdesk``:: diff --git a/helpdesk/templates/helpdesk/kb_item.html b/helpdesk/templates/helpdesk/kb_item.html index 6f7d4e66..b44c3169 100644 --- a/helpdesk/templates/helpdesk/kb_item.html +++ b/helpdesk/templates/helpdesk/kb_item.html @@ -1,4 +1,4 @@ -{% extends "helpdesk/public_base.html" %}{% load i18n %}{% load markup %} +{% extends "helpdesk/public_base.html" %}{% load i18n %}{% load markdown_deux_tags %} {% block helpdesk_body %}

{% blocktrans with item.title as item %}Knowledgebase: {{ item }}{% endblocktrans %}

diff --git a/requirements.txt b/requirements.txt index 0b809e40..7fa8619b 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,3 +1,4 @@ Django>1.4 django-bootstrap-form email-reply-parser +django-markdown-deux diff --git a/setup.py b/setup.py index 3b4f9ba0..582138eb 100644 --- a/setup.py +++ b/setup.py @@ -4,7 +4,7 @@ from distutils.util import convert_path from fnmatch import fnmatchcase from setuptools import setup, find_packages -version = '0.1.11' +version = '0.1.12' # Provided as an attribute, so you can append to these instead # of replicating them: @@ -133,6 +133,6 @@ setup( package_data=find_package_data("helpdesk", only_in_packages=False), include_package_data=True, zip_safe=False, - install_requires=['setuptools', 'pytz'], + install_requires=['setuptools', 'pytz', 'django-markdown-deux', 'django-bootstrap-form', 'email-reply-parser', 'django'], )