diff --git a/core/core-frontend/src/assets/svg/logo_ldap.svg b/core/core-frontend/src/assets/svg/logo_ldap.svg new file mode 100644 index 0000000000..57deedf208 --- /dev/null +++ b/core/core-frontend/src/assets/svg/logo_ldap.svg @@ -0,0 +1,14 @@ + + + + + + + + + + + + + + diff --git a/core/core-frontend/src/components/icon-custom/src/Icon.vue b/core/core-frontend/src/components/icon-custom/src/Icon.vue index d5da0ecc9c..cd5c87b9e4 100644 --- a/core/core-frontend/src/components/icon-custom/src/Icon.vue +++ b/core/core-frontend/src/components/icon-custom/src/Icon.vue @@ -477,6 +477,7 @@ import lock_other_open from '@/assets/svg/lock_other_open.svg' import log from '@/assets/svg/log.svg' import logo from '@/assets/svg/logo.svg' import logo_cas from '@/assets/svg/logo_cas.svg' +import logo_ldap from '@/assets/svg/logo_ldap.svg' import logo_dingtalk from '@/assets/svg/logo_dingtalk.svg' import logo_lark from '@/assets/svg/logo_lark.svg' import logo_oauth from '@/assets/svg/logo_oauth.svg' @@ -1136,6 +1137,7 @@ const iconMap = { log: log, logo: logo, logo_cas: logo_cas, + logo_ldap: logo_ldap, logo_dingtalk: logo_dingtalk, logo_lark: logo_lark, logo_oauth: logo_oauth, diff --git a/core/core-frontend/src/views/login/index.vue b/core/core-frontend/src/views/login/index.vue index 39cfbd7e0a..8f761e3042 100644 --- a/core/core-frontend/src/views/login/index.vue +++ b/core/core-frontend/src/views/login/index.vue @@ -77,10 +77,6 @@ const rules = reactive({ }) const activeName = ref('simple') -const handleClick = tab => { - const param = { methodName: 'tabSwicther', args: tab } - xpackLoginHandler?.value.invokeMethod(param) -} const getCurLocation = () => { let queryRedirectPath = '/workbranch/index' @@ -149,11 +145,6 @@ const ldapValidate = callback => { const ldapFeedback = () => { duringLogin.value = false } -const activeType = ref('account') -const tablePaneList = ref([{ title: '普通登录', name: 'simple' }]) -const xpackLoaded = info => { - tablePaneList.value.push(info) -} const xpackLoadFail = ref(false) const loadingText = ref('登录中...') const loginContainer = ref() @@ -229,6 +220,9 @@ const loadArrearance = () => { } } } +const switchTab = (name: string) => { + activeName.value = name || 'simple' +} onMounted(async () => { loadArrearance() if (!checkPlatform()) { @@ -240,22 +234,22 @@ onMounted(async () => { } if (res.data && !adminLogin) { if (res.data === 1) { - activeName.value = 'LDAP' + activeName.value = 'ldap' preheat.value = false } else { loadingText.value = '加载中...' document.getElementsByClassName('ed-loading-text')?.length && (document.getElementsByClassName('ed-loading-text')[0]['innerText'] = loadingText.value) - nextTick(() => { - const param = { methodName: 'ssoLogin', args: res.data } - const timer = setInterval(() => { - if (xpackLoginHandler?.value.invokeMethod) { - xpackLoginHandler?.value.invokeMethod(param) - clearInterval(timer) - } - }, 1000) - }) } + nextTick(() => { + const param = { methodName: 'ssoLogin', args: res.data } + const timer = setInterval(() => { + if (xpackLoginHandler?.value.invokeMethod) { + xpackLoginHandler?.value.invokeMethod(param) + clearInterval(timer) + } + }, 1000) + }) } else { preheat.value = false } @@ -321,16 +315,44 @@ onMounted(async () => { {{ slogan || '欢迎使用 DataEase 数据可视化分析工具' }}
- + +