mirror of
https://gitlab2.federez.net/re2o/re2o
synced 2024-11-27 15:12:25 +00:00
Fix backward compatibility for logs view
This commit is contained in:
parent
4f9bf2d211
commit
9d925c4b17
2 changed files with 6 additions and 6 deletions
10
logs/urls.py
10
logs/urls.py
|
@ -37,6 +37,11 @@ urlpatterns = [
|
||||||
views.revert_action,
|
views.revert_action,
|
||||||
name="revert-action",
|
name="revert-action",
|
||||||
),
|
),
|
||||||
|
url(
|
||||||
|
r"(?P<application>\w+)/(?P<object_name>\w+)/(?P<object_id>[0-9]+)$",
|
||||||
|
views.history,
|
||||||
|
name="history",
|
||||||
|
),
|
||||||
url(
|
url(
|
||||||
r"(?P<object_name>\w+)/(?P<object_id>[0-9]+)$",
|
r"(?P<object_name>\w+)/(?P<object_id>[0-9]+)$",
|
||||||
views.detailed_history,
|
views.detailed_history,
|
||||||
|
@ -46,10 +51,5 @@ urlpatterns = [
|
||||||
url(r"^stats_models/$", views.stats_models, name="stats-models"),
|
url(r"^stats_models/$", views.stats_models, name="stats-models"),
|
||||||
url(r"^stats_users/$", views.stats_users, name="stats-users"),
|
url(r"^stats_users/$", views.stats_users, name="stats-users"),
|
||||||
url(r"^stats_actions/$", views.stats_actions, name="stats-actions"),
|
url(r"^stats_actions/$", views.stats_actions, name="stats-actions"),
|
||||||
url(
|
|
||||||
r"(?P<application>\w+)/(?P<object_name>\w+)/(?P<object_id>[0-9]+)$",
|
|
||||||
views.history,
|
|
||||||
name="history",
|
|
||||||
),
|
|
||||||
url(r"^stats_search_machine/$", views.stats_search_machine_history, name="stats-search-machine"),
|
url(r"^stats_search_machine/$", views.stats_search_machine_history, name="stats-search-machine"),
|
||||||
]
|
]
|
||||||
|
|
|
@ -603,7 +603,7 @@ def history(request, application, object_name, object_id):
|
||||||
except LookupError:
|
except LookupError:
|
||||||
raise Http404(_("No model found."))
|
raise Http404(_("No model found."))
|
||||||
|
|
||||||
can_view, instance = get_history_object(get_history_object, model, object_name, object_id)
|
can_view, instance = get_history_object(request, model, object_name, object_id)
|
||||||
if not can_view:
|
if not can_view:
|
||||||
return instance
|
return instance
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue