forked from github/dataease
perf: 飞书扫码登录样式优化
This commit is contained in:
parent
9e75cacd6d
commit
db62421454
@ -67,3 +67,16 @@ export const setColorName = (obj, keyword: string, key?: string, colorKey?: stri
|
|||||||
}
|
}
|
||||||
obj[colorKey] = null
|
obj[colorKey] = null
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export const getQueryString = (name: string) => {
|
||||||
|
const reg = new RegExp('(^|&)' + name + '=([^&]*)(&|$)', 'i')
|
||||||
|
const r = window.location.search.substr(1).match(reg)
|
||||||
|
if (r != null) {
|
||||||
|
return unescape(r[2])
|
||||||
|
}
|
||||||
|
return null
|
||||||
|
}
|
||||||
|
|
||||||
|
export const isLarkPlatform = () => {
|
||||||
|
return !!getQueryString('state') && !!getQueryString('code')
|
||||||
|
}
|
||||||
|
@ -16,6 +16,7 @@ import { logoutHandler } from '@/utils/logout'
|
|||||||
import DeImage from '@/assets/login-desc-de.png'
|
import DeImage from '@/assets/login-desc-de.png'
|
||||||
import elementResizeDetectorMaker from 'element-resize-detector'
|
import elementResizeDetectorMaker from 'element-resize-detector'
|
||||||
import PreheatImage from '@/assets/preheat.png'
|
import PreheatImage from '@/assets/preheat.png'
|
||||||
|
import { isLarkPlatform } from '@/utils/utils'
|
||||||
const { wsCache } = useCache()
|
const { wsCache } = useCache()
|
||||||
const appStore = useAppStoreWithOut()
|
const appStore = useAppStoreWithOut()
|
||||||
const userStore = useUserStoreWithOut()
|
const userStore = useUserStoreWithOut()
|
||||||
@ -129,7 +130,7 @@ const showLoginImage = computed<boolean>(() => {
|
|||||||
const checkPlatform = () => {
|
const checkPlatform = () => {
|
||||||
const flagArray = ['/casbi', 'oidcbi']
|
const flagArray = ['/casbi', 'oidcbi']
|
||||||
const pathname = window.location.pathname
|
const pathname = window.location.pathname
|
||||||
if (!flagArray.some(flag => pathname.includes(flag))) {
|
if (!flagArray.some(flag => pathname.includes(flag)) && !isLarkPlatform()) {
|
||||||
cleanPlatformFlag()
|
cleanPlatformFlag()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
2
de-xpack
2
de-xpack
@ -1 +1 @@
|
|||||||
Subproject commit 91e4019972ec96f7f672bb5da2156f54ca9d72ea
|
Subproject commit 723bb9ff960159769673ac58982f07b18e6aa181
|
Loading…
Reference in New Issue
Block a user