mirror of
https://github.com/jumpserver/jumpserver.git
synced 2025-12-20 19:12:54 +00:00
* feat: 在登录页面添加CAS/OpenID等第三方登录链接;不再自动跳转登录地址;统一开源/企业版登录页面; * feat: 登录页面<忘记密码>链接,不限制第三方用户; 在忘记密码页面进行判断与限制 * feat: 登录页面<忘记密码>链接,不限制第三方用户; 在忘记密码页面进行判断与限制 (2) * fix: 调整样式 Co-authored-by: Bai <bugatti_it@163.com> Co-authored-by: Orange <orangemtony@gmail.com>
30 lines
1.0 KiB
Python
30 lines
1.0 KiB
Python
# -*- coding: utf-8 -*-
|
|
#
|
|
from django.templatetags.static import static
|
|
from django.conf import settings
|
|
from django.utils.translation import gettext_lazy as _
|
|
|
|
|
|
def jumpserver_processor(request):
|
|
# Setting default pk
|
|
context = {
|
|
'DEFAULT_PK': '00000000-0000-0000-0000-000000000000',
|
|
'LOGO_URL': static('img/logo.png'),
|
|
'LOGO_TEXT_URL': static('img/logo_text.png'),
|
|
'LOGIN_IMAGE_URL': static('img/login_image.png'),
|
|
'FAVICON_URL': static('img/facio.ico'),
|
|
'LOGIN_CAS_LOGO_URL': static('img/login_cas_logo.png'),
|
|
'JMS_TITLE': 'JumpServer',
|
|
'VERSION': settings.VERSION,
|
|
'COPYRIGHT': 'FIT2CLOUD 飞致云' + ' © 2014-2020',
|
|
'SECURITY_COMMAND_EXECUTION': settings.SECURITY_COMMAND_EXECUTION,
|
|
'SECURITY_MFA_VERIFY_TTL': settings.SECURITY_MFA_VERIFY_TTL,
|
|
'FORCE_SCRIPT_NAME': settings.FORCE_SCRIPT_NAME,
|
|
'SECURITY_VIEW_AUTH_NEED_MFA': settings.SECURITY_VIEW_AUTH_NEED_MFA,
|
|
'LOGIN_CONFIRM_ENABLE': settings.LOGIN_CONFIRM_ENABLE,
|
|
}
|
|
return context
|
|
|
|
|
|
|