From 9f39c5951ee461c24bf008b41c689d82a3ed6dbf Mon Sep 17 00:00:00 2001 From: Leandro Roberto Date: Sat, 16 Feb 2019 21:13:34 -0200 Subject: [PATCH] corrige teste de app do sapl --- sapl/base/views.py | 2 +- sapl/rules/apps.py | 3 ++- sapl/templates/app_frontend.html | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/sapl/base/views.py b/sapl/base/views.py index 7fadad141..97fa87d38 100644 --- a/sapl/base/views.py +++ b/sapl/base/views.py @@ -81,7 +81,7 @@ def time_refresh_log_test(request): def app_frontend_view(request, app_frontend): if app_frontend not in ( - 'sessao', + 'sessao_online', ): raise Http404 diff --git a/sapl/rules/apps.py b/sapl/rules/apps.py index 677383084..28ff9a2b6 100644 --- a/sapl/rules/apps.py +++ b/sapl/rules/apps.py @@ -259,7 +259,8 @@ def cria_usuarios_padrao(): def send_signal_for_websocket_time_refresh(inst, action): - if hasattr(inst, '_meta') and inst._meta.app_config.name[:4] == 'sapl': + if hasattr(inst, '_meta') and not inst._meta.app_config.name is None and \ + inst._meta.app_config.name[:4] == 'sapl': # um mensagem não deve ser enviada se é post_save mas originou se de # revision_pre_delete_signal diff --git a/sapl/templates/app_frontend.html b/sapl/templates/app_frontend.html index 879c42f5a..a19a62392 100644 --- a/sapl/templates/app_frontend.html +++ b/sapl/templates/app_frontend.html @@ -1,4 +1,4 @@ -{% extends "base.html" %} +{% extends "index.html" %} {% load render_bundle from webpack_loader %} {% block webpack_loader_css %}