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'),
|
path('chatnewmessage/', views.savenewchatmessage, name='api-savechatmessage'),
|
||||||
# MIGRATION
|
# MIGRATION
|
||||||
path('migrateagencyusers/<int:pk>', views.migrateAgencyUsers, name="api-migrateagencyusers"),
|
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 login, logout
|
||||||
|
from django.contrib.auth import update_session_auth_hash
|
||||||
|
from django.contrib.sessions.models import Session
|
||||||
|
|
||||||
@api_view(['GET', ])
|
@api_view(['GET', ])
|
||||||
def test(request):
|
def test(request, uid):
|
||||||
return redirect('users-logout')
|
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!
|
# Nach zehn Stunden läuft der Cookie ab!
|
||||||
# TASK: Zehn stunden auto-auslog einmal checken Sekunden!
|
# 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
|
# FOR SUMMERNOTE ORIGIN
|
||||||
X_FRAME_OPTIONS = 'ALLOWALL'
|
X_FRAME_OPTIONS = 'ALLOWALL'
|
||||||
|
|
@ -115,7 +115,7 @@ MIDDLEWARE = [
|
||||||
|
|
||||||
ROOT_URLCONF = 'digitaleagentur.urls'
|
ROOT_URLCONF = 'digitaleagentur.urls'
|
||||||
|
|
||||||
CSRF_COOKIE_SECURE = False
|
#CSRF_COOKIE_SECURE = False
|
||||||
|
|
||||||
TEMPLATES = [
|
TEMPLATES = [
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -37,4 +37,5 @@ django-simple-captcha==0.5.13
|
||||||
auditlog3==1.0.1
|
auditlog3==1.0.1
|
||||||
filetype==1.0.7
|
filetype==1.0.7
|
||||||
Authlib==0.15.3
|
Authlib==0.15.3
|
||||||
xmltodict==0.12.0
|
xmltodict==0.12.0
|
||||||
|
django-user-sessions==1.7.1
|
||||||
|
|
@ -271,23 +271,24 @@
|
||||||
|
|
||||||
<!-- ALERT_AREA -->
|
<!-- ALERT_AREA -->
|
||||||
<!-- Nav Item - Alerts -->
|
<!-- 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">
|
<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 -->
|
<!-- Counter - Alerts -->
|
||||||
<span class="badge badge-danger badge-counter" id="notificationcounter"></span>
|
<!--<span class="badge badge-danger badge-counter" id="notificationcounter"></span>
|
||||||
</a>
|
</a>-->
|
||||||
<!-- Dropdown - Alerts -->
|
<!-- Dropdown - Alerts -->
|
||||||
|
<!--
|
||||||
<div class="dropdown-list dropdown-menu dropdown-menu-right shadow animated--grow-in" aria-labelledby="alertsDropdown" id="allnotificationsarea">
|
<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">
|
<h6 class="dropdown-header bg-success text-white">
|
||||||
Benachrichtigungen
|
Benachrichtigungen
|
||||||
</h6>
|
</h6>-->
|
||||||
<!-- ITEMS -->
|
<!-- ITEMS -->
|
||||||
<span id="notification_items"></span>
|
<!--<span id="notification_items"></span>-->
|
||||||
<!-- ITEMS END -->
|
<!-- ITEMS END -->
|
||||||
<a class="dropdown-item text-center small text-gray-500" href="{% url 'showallnotificaions' %}">Alle Benachrichtigungen ansehen</a>
|
<!--<a class="dropdown-item text-center small text-gray-500" href="{% url 'showallnotificaions' %}">Alle Benachrichtigungen ansehen</a>
|
||||||
</div>
|
</div>-->
|
||||||
</li>
|
<!--/li>-->
|
||||||
<style type="text/css">
|
<style type="text/css">
|
||||||
{% getonlinestatuscolor request.user as onlinecolor %}
|
{% getonlinestatuscolor request.user as onlinecolor %}
|
||||||
.roundimg_base {
|
.roundimg_base {
|
||||||
|
|
@ -297,16 +298,19 @@
|
||||||
box-shadow: 0px 0px 4px 5px {{onlinecolor}};
|
box-shadow: 0px 0px 4px 5px {{onlinecolor}};
|
||||||
}
|
}
|
||||||
</style>
|
</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 -->
|
<!-- Nav Item - User Information -->
|
||||||
|
<!--
|
||||||
<li class="nav-item dropdown no-arrow">
|
<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">
|
<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 class="mr-2 d-none d-lg-inline text-gray-600 small">{{request.user.first_name}} {{request.user.last_name}}
|
||||||
</span>
|
</span>
|
||||||
<img id="userbaseprofilepicture" class="img-profile roundimg_base ml-2" src="{{ request.user.profile.get_photo_url }}">
|
<img id="userbaseprofilepicture" class="img-profile roundimg_base ml-2" src="{{ request.user.profile.get_photo_url }}">
|
||||||
</a>
|
</a>-->
|
||||||
<!-- Dropdown - User Information -->
|
<!-- 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="#/">
|
<a class="dropdown-item" onclick="javascript:changeOnlineStatus(0)" href="#/">
|
||||||
<i class="fas fa-circle mr-2" style="color: green"></i>
|
<i class="fas fa-circle mr-2" style="color: green"></i>
|
||||||
Online
|
Online
|
||||||
|
|
@ -323,13 +327,14 @@
|
||||||
<i class="fas fa-circle mr-2" style="color: grey"></i>
|
<i class="fas fa-circle mr-2" style="color: grey"></i>
|
||||||
Offline anzeigen
|
Offline anzeigen
|
||||||
</a>
|
</a>
|
||||||
|
-->
|
||||||
<div class="dropdown-divider"></div>
|
<!--<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({{user.pk}})" href="{% url 'orga-single' user.pk %}">
|
||||||
<a class="dropdown-item" onclick="userGoToSettings()" href="#/">
|
<a class="dropdown-item" onclick="userGoToSettings()" href="#/">
|
||||||
<i class="fas fa-user fa-sm fa-fw mr-2 text-gray-400"></i>
|
<i class="fas fa-user fa-sm fa-fw mr-2 text-gray-400"></i>
|
||||||
Einstellungen
|
Einstellungen
|
||||||
</a>
|
</a>
|
||||||
|
|
||||||
<a class="dropdown-item" onclick="userGoToNotification()" href="#/">
|
<a class="dropdown-item" onclick="userGoToNotification()" href="#/">
|
||||||
<i class="fas fa-bell fa-sm fa-fw mr-2 text-gray-400"></i>
|
<i class="fas fa-bell fa-sm fa-fw mr-2 text-gray-400"></i>
|
||||||
Benachrichtigungen
|
Benachrichtigungen
|
||||||
|
|
@ -343,9 +348,9 @@
|
||||||
<i class="fas fa-sign-out-alt fa-sm fa-fw mr-2 text-gray-400"></i>
|
<i class="fas fa-sign-out-alt fa-sm fa-fw mr-2 text-gray-400"></i>
|
||||||
Abmelden
|
Abmelden
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>-->
|
||||||
</li>
|
<!--</li>-->
|
||||||
</ul>
|
<!--</ul>-->
|
||||||
</nav>
|
</nav>
|
||||||
|
|
||||||
<!-- End of Topbar -->
|
<!-- End of Topbar -->
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue