Skip to content
Permalink
Browse files

Reporting: Fix add_url_filter fallback

django-1.8 deprecated referencing views as strings in the url(), so we
need to import the fallback view and referencing the view function
directly.
  • Loading branch information...
AlexanderS committed Jun 17, 2019
1 parent ad2b80f commit 766c136f134bf4f66351c8ab6fca1f11a987cc8a
Showing with 2 additions and 1 deletion.
  1. +2 −1 src/lib/Bcfg2/Reporting/templatetags/bcfg2_tags.py
@@ -11,6 +11,7 @@
from datetime import datetime, timedelta
from Bcfg2.Reporting.utils import filter_list
from Bcfg2.Reporting.models import Group
from Bcfg2.Reporting.views import render_history_view

register = template.Library()

@@ -213,7 +214,7 @@ class AddUrlFilter(template.Node):
def __init__(self, filter_name, filter_value):
self.filter_name = filter_name
self.filter_value = filter_value
self.fallback_view = 'Bcfg2.Reporting.views.render_history_view'
self.fallback_view = render_history_view

def render(self, context):
link = '#'

0 comments on commit 766c136

Please sign in to comment.
You can’t perform that action at this time.