From: Aleksander Ɓukasz Date: Tue, 14 Jan 2014 10:39:40 +0000 (+0100) Subject: mil site: knowledge base support X-Git-Url: https://git.mdrn.pl/edumed.git/commitdiff_plain/5f5eb12589286034863d1f381746e533d648666c?ds=inline;hp=-c mil site: knowledge base support --- 5f5eb12589286034863d1f381746e533d648666c diff --git a/edumed/milurls.py b/edumed/milurls.py index 3ad16c7..b68f1ba 100644 --- a/edumed/milurls.py +++ b/edumed/milurls.py @@ -1,7 +1,7 @@ from django.conf.urls import include, url, patterns from fnpdjango.utils.urls import i18n_patterns -from .views import mil_home_view, mil_contact_view +from .views import mil_home_view, mil_contact_view, mil_knowledge_base_view urlpatterns = i18n_patterns('', @@ -9,7 +9,9 @@ urlpatterns = i18n_patterns('', url(r'^kompetencje/', include('curriculum.urls')), url(r'^wez-udzial/', include('comment.urls')), url(r'^zglos/', include('contact.urls')), - url(r'^kontakt/$', mil_contact_view, name='mil_contact') + url(r'^kontakt/$', mil_contact_view, name='mil_contact'), + url(r'^bazawiedzy/(?P.*)$', mil_knowledge_base_view, + name="knowledge_base"), ) handler404 = 'edumed.views.mil_404_view' diff --git a/edumed/templates/base_mil.html b/edumed/templates/base_mil.html index 45422e4..674ee43 100644 --- a/edumed/templates/base_mil.html +++ b/edumed/templates/base_mil.html @@ -17,7 +17,7 @@
  • {% trans 'Competencies' %}
  • {% trans 'Take Part' %}
  • {% if request.LANGUAGE_CODE == 'pl' %} -
  • Baza wiedzy
  • +
  • Baza wiedzy
  • {% endif %}
  • {% trans 'Contact' %}
  • {% lang_switcher %}
  • diff --git a/edumed/views.py b/edumed/views.py index a6c1aa6..5ac002b 100755 --- a/edumed/views.py +++ b/edumed/views.py @@ -26,5 +26,8 @@ def mil_404_view(request): def mil_contact_view(request): return flatpage(request, url = '/kontakt_mil/' if request.LANGUAGE_CODE == 'pl' else '/contact_mil/') +def mil_knowledge_base_view(request, url): + return flatpage(request, url = 'bazawiedzy/' + url) + class AvatarlessProfileEditView(ProfileEditView): form_class = AvatarlessEditProfileForm