From: hernani Date: Wed, 12 May 2010 21:54:08 +0000 (+0000) Subject: Fix OSQA 100, show revision number in the powered bi osqa link, in title attribute. X-Git-Tag: live~888 X-Git-Url: https://git.openstreetmap.org./osqa.git/commitdiff_plain/b13db888b5d29f75c9e29d1d4e732769428ac911 Fix OSQA 100, show revision number in the powered bi osqa link, in title attribute. git-svn-id: http://svn.osqa.net/svnroot/osqa/trunk@241 0cfe37f9-358a-4d5e-be75-b63607b5c754 --- diff --git a/forum/context.py b/forum/context.py index f7139ac..1059332 100644 --- a/forum/context.py +++ b/forum/context.py @@ -1,5 +1,6 @@ from forum import settings from django.conf import settings as djsettings + def application_settings(context): my_settings = { 'APP_TITLE' : settings.APP_TITLE, @@ -18,6 +19,9 @@ def application_settings(context): 'WIKI_ON':settings.WIKI_ON, 'OSQA_SKIN':djsettings.OSQA_DEFAULT_SKIN, 'APP_FAVICON':settings.APP_FAVICON, + 'OSQA_VERSION': settings.OSQA_VERSION, + 'ADMIN_MEDIA_PREFIX': djsettings.ADMIN_MEDIA_PREFIX, + 'SVN_REVISION': settings.SVN_REVISION, } return {'settings':my_settings} diff --git a/forum/settings/__init__.py b/forum/settings/__init__.py index 6351ece..5306aa7 100644 --- a/forum/settings/__init__.py +++ b/forum/settings/__init__.py @@ -5,8 +5,10 @@ from forms import ImageFormWidget from django.forms.widgets import Textarea from django.utils.translation import ugettext_lazy as _ from django.conf import settings as djsettings +from django.utils.version import get_svn_revision -OSQA_VERSION = Setting('OSQA_VERSION', "Development Version") +OSQA_VERSION = "Development Build" +SVN_REVISION = get_svn_revision(djsettings.SITE_SRC_ROOT) SETTINGS_PACK = Setting('SETTINGS_PACK', "default") APP_URL = djsettings.APP_URL FORUM_SCRIPT_ALIAS = djsettings.FORUM_SCRIPT_ALIAS diff --git a/forum/skins/default/templates/footer.html b/forum/skins/default/templates/footer.html index 518318d..907669a 100644 --- a/forum/skins/default/templates/footer.html +++ b/forum/skins/default/templates/footer.html @@ -20,7 +20,7 @@ {% endspaceless %}

- + powered by OSQA

diff --git a/forum/skins/default/templates/users/info.html b/forum/skins/default/templates/users/info.html index ef20ad5..38cab07 100644 --- a/forum/skins/default/templates/users/info.html +++ b/forum/skins/default/templates/users/info.html @@ -4,6 +4,7 @@ {% load humanize %} {% load smart_if %} {% load i18n %} +{% load markup %} {% load user_tags %}
{{view_user.username}} @@ -104,7 +105,7 @@
{% if view_user.about %} - {{view_user.about|safe}} + {{view_user.about|markdown}} {% endif %}