raus die maus aus dem hexenhaus
This commit is contained in:
parent
d9d41248dd
commit
f5db4926ee
|
|
@ -13,6 +13,6 @@ urlpatterns = [
|
|||
path('chatnewmessage/', views.savenewchatmessage, name='api-savechatmessage'),
|
||||
# MIGRATION
|
||||
path('migrateagencyusers/<int:pk>', views.migrateAgencyUsers, name="api-migrateagencyusers"),
|
||||
path('test/', views.test, name="api-test"),
|
||||
|
||||
# EXTERNAL FROM NC
|
||||
path('logout/<str:uid>', views.test, name="api-test"),
|
||||
]
|
||||
|
|
@ -91,6 +91,11 @@ def migrateAgencyUsers(request, pk):
|
|||
|
||||
|
||||
from django.contrib.auth import login, logout
|
||||
from django.contrib.auth import update_session_auth_hash
|
||||
from django.contrib.sessions.models import Session
|
||||
|
||||
@api_view(['GET', ])
|
||||
def test(request):
|
||||
return redirect('users-logout')
|
||||
def test(request, uid):
|
||||
user = User.objects.get(username=uid)
|
||||
[s.delete() for s in Session.objects.all() if s.get_decoded().get('_auth_user_hash') == user.get_session_auth_hash()]
|
||||
return JsonResponse({'res' : 'ok'})
|
||||
|
|
|
|||
Binary file not shown.
|
|
@ -25,10 +25,10 @@ BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
|
|||
|
||||
# Nach zehn Stunden läuft der Cookie ab!
|
||||
# TASK: Zehn stunden auto-auslog einmal checken Sekunden!
|
||||
SESSION_COOKIE_AGE = 8*60*60
|
||||
SESSION_COOKIE_AGE = 100*60*60
|
||||
|
||||
|
||||
CHANNELS_PRESENCE_MAX_AGE = 30
|
||||
#CHANNELS_PRESENCE_MAX_AGE = 30
|
||||
|
||||
# FOR SUMMERNOTE ORIGIN
|
||||
X_FRAME_OPTIONS = 'ALLOWALL'
|
||||
|
|
@ -115,7 +115,7 @@ MIDDLEWARE = [
|
|||
|
||||
ROOT_URLCONF = 'digitaleagentur.urls'
|
||||
|
||||
CSRF_COOKIE_SECURE = False
|
||||
#CSRF_COOKIE_SECURE = False
|
||||
|
||||
TEMPLATES = [
|
||||
{
|
||||
|
|
|
|||
|
|
@ -37,4 +37,5 @@ django-simple-captcha==0.5.13
|
|||
auditlog3==1.0.1
|
||||
filetype==1.0.7
|
||||
Authlib==0.15.3
|
||||
xmltodict==0.12.0
|
||||
xmltodict==0.12.0
|
||||
django-user-sessions==1.7.1
|
||||
|
|
@ -271,23 +271,24 @@
|
|||
|
||||
<!-- ALERT_AREA -->
|
||||
<!-- Nav Item - Alerts -->
|
||||
<li class="nav-item dropdown no-arrow mx-1">
|
||||
<!--<li class="nav-item dropdown no-arrow mx-1">
|
||||
<a class="nav-link dropdown-toggle" onclick="changeNewNotToViewed()" id="alertsDropdown" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
<i class="fas fa-bell fa-fw"></i>
|
||||
<i class="fas fa-bell fa-fw"></i>-->
|
||||
<!-- Counter - Alerts -->
|
||||
<span class="badge badge-danger badge-counter" id="notificationcounter"></span>
|
||||
</a>
|
||||
<!--<span class="badge badge-danger badge-counter" id="notificationcounter"></span>
|
||||
</a>-->
|
||||
<!-- Dropdown - Alerts -->
|
||||
<!--
|
||||
<div class="dropdown-list dropdown-menu dropdown-menu-right shadow animated--grow-in" aria-labelledby="alertsDropdown" id="allnotificationsarea">
|
||||
<h6 class="dropdown-header bg-success text-white">
|
||||
Benachrichtigungen
|
||||
</h6>
|
||||
</h6>-->
|
||||
<!-- ITEMS -->
|
||||
<span id="notification_items"></span>
|
||||
<!--<span id="notification_items"></span>-->
|
||||
<!-- ITEMS END -->
|
||||
<a class="dropdown-item text-center small text-gray-500" href="{% url 'showallnotificaions' %}">Alle Benachrichtigungen ansehen</a>
|
||||
</div>
|
||||
</li>
|
||||
<!--<a class="dropdown-item text-center small text-gray-500" href="{% url 'showallnotificaions' %}">Alle Benachrichtigungen ansehen</a>
|
||||
</div>-->
|
||||
<!--/li>-->
|
||||
<style type="text/css">
|
||||
{% getonlinestatuscolor request.user as onlinecolor %}
|
||||
.roundimg_base {
|
||||
|
|
@ -297,16 +298,19 @@
|
|||
box-shadow: 0px 0px 4px 5px {{onlinecolor}};
|
||||
}
|
||||
</style>
|
||||
<div class="topbar-divider d-none d-sm-block"></div>
|
||||
<!--<div class="topbar-divider d-none d-sm-block"></div>-->
|
||||
<!-- Nav Item - User Information -->
|
||||
<!--
|
||||
<li class="nav-item dropdown no-arrow">
|
||||
<a class="nav-link dropdown-toggle" href="#" id="userDropdown" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
<span class="mr-2 d-none d-lg-inline text-gray-600 small">{{request.user.first_name}} {{request.user.last_name}}
|
||||
</span>
|
||||
<img id="userbaseprofilepicture" class="img-profile roundimg_base ml-2" src="{{ request.user.profile.get_photo_url }}">
|
||||
</a>
|
||||
</a>-->
|
||||
<!-- Dropdown - User Information -->
|
||||
<div class="dropdown-menu dropdown-menu-right shadow animated--grow-in" aria-labelledby="userDropdown">
|
||||
|
||||
<!--<div class="dropdown-menu dropdown-menu-right shadow animated--grow-in" aria-labelledby="userDropdown">
|
||||
|
||||
<a class="dropdown-item" onclick="javascript:changeOnlineStatus(0)" href="#/">
|
||||
<i class="fas fa-circle mr-2" style="color: green"></i>
|
||||
Online
|
||||
|
|
@ -323,13 +327,14 @@
|
|||
<i class="fas fa-circle mr-2" style="color: grey"></i>
|
||||
Offline anzeigen
|
||||
</a>
|
||||
|
||||
<div class="dropdown-divider"></div>
|
||||
<!--<a class="dropdown-item" onclick="userGoToSettings({{user.pk}})" href="{% url 'orga-single' user.pk %}">-->
|
||||
-->
|
||||
<!--<div class="dropdown-divider"></div>-->
|
||||
<!--<a class="dropdown-item" onclick="userGoToSettings({{user.pk}})" href="{% url 'orga-single' user.pk %}">
|
||||
<a class="dropdown-item" onclick="userGoToSettings()" href="#/">
|
||||
<i class="fas fa-user fa-sm fa-fw mr-2 text-gray-400"></i>
|
||||
Einstellungen
|
||||
</a>
|
||||
|
||||
<a class="dropdown-item" onclick="userGoToNotification()" href="#/">
|
||||
<i class="fas fa-bell fa-sm fa-fw mr-2 text-gray-400"></i>
|
||||
Benachrichtigungen
|
||||
|
|
@ -343,9 +348,9 @@
|
|||
<i class="fas fa-sign-out-alt fa-sm fa-fw mr-2 text-gray-400"></i>
|
||||
Abmelden
|
||||
</a>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
</div>-->
|
||||
<!--</li>-->
|
||||
<!--</ul>-->
|
||||
</nav>
|
||||
|
||||
<!-- End of Topbar -->
|
||||
|
|
|
|||
Loading…
Reference in New Issue