mirror of https://github.com/jumpserver/jumpserver
parent
4733d89807
commit
5594b25ae0
|
@ -163,9 +163,9 @@ $(document).ready(function () {
|
|||
}).on('click', '.btn-return', function () {
|
||||
cancelTicket();
|
||||
cancelCloseConfirm();
|
||||
setTimeout(() => {
|
||||
window.location = "{% url 'authentication:login' %}"
|
||||
}, 1000);
|
||||
clearInterval(interval);
|
||||
clearInterval(checkInterval);
|
||||
window.location = "{% url 'authentication:logout' %}"
|
||||
})
|
||||
|
||||
</script>
|
||||
|
|
|
@ -7,8 +7,11 @@ from django.contrib.sessions.backends.cache import (
|
|||
)
|
||||
from django.core.cache import cache, caches
|
||||
|
||||
from common.utils import get_logger
|
||||
from jumpserver.utils import get_current_request
|
||||
|
||||
logger = get_logger(__file__)
|
||||
|
||||
|
||||
class SessionStore(DjangoSessionStore):
|
||||
ignore_urls = [
|
||||
|
@ -23,7 +26,10 @@ class SessionStore(DjangoSessionStore):
|
|||
def save(self, *args, **kwargs):
|
||||
request = get_current_request()
|
||||
if request is None or not self.ignore_pattern.match(request.path):
|
||||
super().save(*args, **kwargs)
|
||||
try:
|
||||
super().save(*args, **kwargs)
|
||||
except Exception as e:
|
||||
logger.info(f'SessionStore save error: {e}')
|
||||
|
||||
|
||||
class RedisUserSessionManager:
|
||||
|
|
Loading…
Reference in New Issue