| | |
| | | <div class="layout-navbars-breadcrumb-user pr15" :style="{ flex: layoutUserFlexNum }"> |
| | | <el-dropdown :show-timeout="70" :hide-timeout="50" trigger="click" @command="onComponentSizeChange"> |
| | | <div class="layout-navbars-breadcrumb-user-icon"> |
| | | <i class="iconfont icon-ziti" :title="$t('message.user.title0')"></i> |
| | | <i class="myiconfont icon-ziti" :title="$t('message.user.title0')"></i> |
| | | </div> |
| | | <template #dropdown> |
| | | <el-dropdown-menu> |
| | |
| | | </template> |
| | | |
| | | <script setup lang="ts" name="layoutBreadcrumbUser"> |
| | | import { defineAsyncComponent, ref, computed, reactive, onMounted } from 'vue'; |
| | | import { useRouter } from 'vue-router'; |
| | | import { ElMessageBox, ElMessage } from 'element-plus'; |
| | | import screenfull from 'screenfull'; |
| | | import { useI18n } from 'vue-i18n'; |
| | | import { ElMessage, ElMessageBox } from 'element-plus'; |
| | | import { storeToRefs } from 'pinia'; |
| | | import { useUserInfo } from '/@/stores/userInfo'; |
| | | import { useThemeConfig } from '/@/stores/themeConfig'; |
| | | import other from '/@/utils/other'; |
| | | import { Session, Local } from '/@/utils/storage'; |
| | | import { clearAccessTokens } from '/@/utils/request'; |
| | | import screenfull from 'screenfull'; |
| | | import { computed, defineAsyncComponent, onMounted, reactive, ref } from 'vue'; |
| | | import { useI18n } from 'vue-i18n'; |
| | | import { useRouter } from 'vue-router'; |
| | | import { IS_ALARM_PUSH_ENABLE } from '/@/constants'; |
| | | import { useThemeConfig } from '/@/stores/themeConfig'; |
| | | import { useUserInfo } from '/@/stores/userInfo'; |
| | | import other from '/@/utils/other'; |
| | | import { clearAccessTokens } from '/@/utils/request'; |
| | | import { Local } from '/@/utils/storage'; |
| | | // 引入组件 |
| | | const UserNews = defineAsyncComponent(() => import('/@/layout/navBars/breadcrumb/userNews.vue')); |
| | | const Search = defineAsyncComponent(() => import('/@/layout/navBars/breadcrumb/search.vue')); |
| | |
| | | }, |
| | | }) |
| | | .then(async () => { |
| | | console.log('🚀 ~ reload',); |
| | | // 清除缓存/token等 |
| | | clearAccessTokens(); |
| | | // 使用 reload 时,不需要调用 resetRoute() 重置路由 |
| | |
| | | themeConfig.value.globalComponentSize = size; |
| | | Local.set('themeConfig', themeConfig.value); |
| | | initI18nOrSize('globalComponentSize', 'disabledSize'); |
| | | console.log('🚀 ~ reload',); |
| | | |
| | | window.location.reload(); |
| | | }; |
| | | //通知中心 |