fix: 多语言切换显示按钮权限标识判断
This commit is contained in:
@@ -8,6 +8,7 @@ import useAppStore from '@/store/modules/app';
|
|||||||
import useUserStore from '@/store/modules/user';
|
import useUserStore from '@/store/modules/user';
|
||||||
import useAlarmStore from '@/store/modules/alarm';
|
import useAlarmStore from '@/store/modules/alarm';
|
||||||
import useLockedStore from '@/store/modules/locked';
|
import useLockedStore from '@/store/modules/locked';
|
||||||
|
import { hasPermissions } from '@/plugins/auth-user';
|
||||||
const { isFullscreen, toggle } = useFullscreen();
|
const { isFullscreen, toggle } = useFullscreen();
|
||||||
const { t, changeLocale, optionsLocale } = useI18n();
|
const { t, changeLocale, optionsLocale } = useI18n();
|
||||||
const lockedStore = useLockedStore();
|
const lockedStore = useLockedStore();
|
||||||
@@ -107,8 +108,7 @@ function fnChangeLocale(e: any) {
|
|||||||
<a-dropdown
|
<a-dropdown
|
||||||
placement="bottom"
|
placement="bottom"
|
||||||
:trigger="['click', 'hover']"
|
:trigger="['click', 'hover']"
|
||||||
v-perms:has="['system:setting:i18n']"
|
v-if="appStore.i18nOpen && hasPermissions(['system:setting:i18n'])"
|
||||||
v-if="appStore.i18nOpen"
|
|
||||||
>
|
>
|
||||||
<a-button size="small" type="default">
|
<a-button size="small" type="default">
|
||||||
{{ t('i18n') }}
|
{{ t('i18n') }}
|
||||||
|
|||||||
Reference in New Issue
Block a user