diff --git a/src/components/Table/ListTable/TableAction/LeftSide.vue b/src/components/Table/ListTable/TableAction/LeftSide.vue index 55bf48119..98b14018c 100644 --- a/src/components/Table/ListTable/TableAction/LeftSide.vue +++ b/src/components/Table/ListTable/TableAction/LeftSide.vue @@ -91,7 +91,7 @@ export default { return { defaultMoreActions: [ { - title: this.$t('BatchDelete'), + title: this.$t('DeleteSelected'), name: 'actionDeleteSelected', has: this.hasBulkDelete, icon: 'fa fa-trash-o', diff --git a/src/layout/components/NavHeader/index.vue b/src/layout/components/NavHeader/index.vue index f749cf130..4c2c42da0 100644 --- a/src/layout/components/NavHeader/index.vue +++ b/src/layout/components/NavHeader/index.vue @@ -162,6 +162,7 @@ export default { & > > > .svg-icon { color: #FFF !important; + font-size: 16px; } & > > > .el-badge { @@ -174,25 +175,18 @@ export default { border: none; } } - } - - .header-item { - padding-left: 8px; - padding-right: 8px; - & > > > i { color: #FFF; font-size: 16px; + + &.el-icon-arrow-down { + font-size: 13px; + } } & > > > i.el-dialog__close.el-icon-close { color: #7c7e7f; } - - & > > > .svg-icon { - color: #FFF; - font-size: 16px; - } } } } diff --git a/src/layout/components/Page/index.vue b/src/layout/components/Page/index.vue index c8fb7b645..438e85a53 100644 --- a/src/layout/components/Page/index.vue +++ b/src/layout/components/Page/index.vue @@ -23,6 +23,7 @@ import PageHeading from './PageHeading' import PageContent from './PageContent' import UserConfirmDialog from '@/components/Apps/UserConfirmDialog/index.vue' +import { toSentenceCase } from '@/utils/common' export default { name: 'Page', @@ -49,7 +50,12 @@ export default { }, computed: { iTitle() { - return this.title || this.$route.meta.title + let title = this.title || this.$route.meta.title + if (!title) { + title = this.$t('NoTitle') + } + title = toSentenceCase(title) + return title }, gobackDisabled() { if (this.$route.path.endsWith('dashboard')) { diff --git a/src/router/console/accounts.js b/src/router/console/accounts.js index 706d37597..fed664845 100644 --- a/src/router/console/accounts.js +++ b/src/router/console/accounts.js @@ -1,5 +1,6 @@ import i18n from '@/i18n/i18n' import empty from '@/layout/empty' +import store from '@/store' export default [ { @@ -116,10 +117,12 @@ export default [ path: 'account-push', component: empty, redirect: '', + name: 'AccountPush', meta: { app: 'accounts', name: 'AccountPushList', - resource: 'pushaccountautomation' + resource: 'pushaccountautomation', + hidden: () => store.getters.publicSettings.LITE }, children: [ { @@ -190,6 +193,7 @@ export default [ meta: { title: i18n.t('AccountGatherList'), app: 'accounts', + hidden: () => store.getters.publicSettings.LITE, licenseRequired: true }, children: [ @@ -259,10 +263,10 @@ export default [ { path: 'account-change-secret', component: empty, - redirect: '', meta: { title: i18n.t('AccountChangeSecret'), app: 'accounts', + hidden: () => store.getters.publicSettings.LITE, licenseRequired: true }, children: [ @@ -335,6 +339,7 @@ export default [ title: i18n.t('AccountBackup'), app: 'accounts', resource: 'accountbackupautomation', + hidden: () => store.getters.publicSettings.LITE, licenseRequired: true }, children: [ diff --git a/src/router/console/acls.js b/src/router/console/acls.js index fb80f1398..0c6555f41 100644 --- a/src/router/console/acls.js +++ b/src/router/console/acls.js @@ -1,5 +1,6 @@ import i18n from '@/i18n/i18n' import empty from '@/layout/empty' +import store from '@/store' const globalSubmenu = () => import('@/layout/globalOrg.vue') @@ -54,6 +55,7 @@ export default [ title: i18n.t('AssetAclList'), licenseRequired: true, app: 'acls', + hidden: () => store.getters.publicSettings.LITE, resource: 'loginassetacl' }, children: [ @@ -149,6 +151,7 @@ export default [ licenseRequired: true, app: 'acls', disableOrgsChange: true, + hidden: () => store.getters.publicSettings.LITE, resource: 'connectmethodacl' }, children: [ @@ -189,6 +192,7 @@ export default [ title: i18n.t('UserLoginAclList'), app: 'acls', resource: 'loginacl', + hidden: () => store.getters.publicSettings.LITE, disableOrgsChange: true }, children: [ diff --git a/src/store/modules/settings.js b/src/store/modules/settings.js index 8ffa003e7..e7746a364 100644 --- a/src/store/modules/settings.js +++ b/src/store/modules/settings.js @@ -10,7 +10,7 @@ const state = { fixedHeader: fixedHeader, sidebarLogo: sidebarLogo, tagsView: tagsView, - publicSettings: null, + publicSettings: {}, hasValidLicense: false, themeColors: JSON.parse(localStorage.getItem('themeColors')) || {} } diff --git a/src/utils/startup.js b/src/utils/startup.js index 4634dc398..f6b10926f 100644 --- a/src/utils/startup.js +++ b/src/utils/startup.js @@ -35,9 +35,10 @@ async function checkLogin({ to, from, next }) { async function getPublicSetting({ to, from, next }, isOpen) { // 获取Public settings const publicSettings = store.getters.publicSettings - if (!publicSettings || !isOpen) { + if (!publicSettings || Object.keys(publicSettings).length === 0 || !isOpen) { await store.dispatch('settings/getPublicSettings', isOpen) } + console.log('Get public setting done') } async function refreshCurrentOrg() { @@ -163,7 +164,6 @@ export async function startup({ to, from, next }) { await getPublicSetting({ to, from, next }, true) await checkLogin({ to, from, next }) await onI18nLoaded() - console.log('...') await getPublicSetting({ to, from, next }, false) await changeCurrentViewIfNeed({ to, from, next }) await changeCurrentOrgIfNeed({ to, from, next })