liuchen864 1 year ago
parent
commit
eb446a3de2
  1. 2
      src/layout/Layout.vue
  2. 4
      src/layout/components/UserInfo/src/UserInfo.vue
  3. 17
      src/views/Login/components/LoginForm.vue
  4. 4
      src/views/Profile/Index.vue
  5. 4
      src/views/system/menu/index.vue

2
src/layout/Layout.vue

@ -59,7 +59,7 @@ export default defineComponent({
<Backtop></Backtop>
<Setting></Setting>
{/* <Setting></Setting> */}
</section>
)
}

4
src/layout/components/UserInfo/src/UserInfo.vue

@ -64,10 +64,10 @@ const toDocument = () => {
<Icon icon="ep:tools" />
<div @click="toProfile">{{ t('common.profile') }}</div>
</ElDropdownItem>
<ElDropdownItem>
<!-- <ElDropdownItem>
<Icon icon="ep:menu" />
<div @click="toDocument">{{ t('common.document') }}</div>
</ElDropdownItem>
</ElDropdownItem> -->
<ElDropdownItem divided @click="loginOut">
<Icon icon="ep:switch-button" />
<div>{{ t('common.loginOut') }}</div>

17
src/views/Login/components/LoginForm.vue

@ -15,6 +15,17 @@
<LoginFormTitle style="width: 100%" />
</el-form-item>
</el-col>
<el-col :span="24" style="padding-right: 10px; padding-left: 10px">
<el-form-item v-if="loginData.tenantEnable === 'true'" prop="tenantName">
<el-input
v-model="loginData.loginForm.tenantName"
:placeholder="t('login.tenantNamePlaceholder')"
:prefix-icon="iconHouse"
link
type="primary"
/>
</el-form-item>
</el-col>
<el-col :span="24" style="padding-right: 10px; padding-left: 10px">
<el-form-item prop="username">
<el-input
@ -60,17 +71,17 @@
:title="t('login.login')"
class="w-[100%]"
type="primary"
@click="getCode()"
@click="handleLogin"
/>
</el-form-item>
</el-col>
<Verify
<!-- <Verify
ref="verify"
:captchaType="captchaType"
:imgSize="{ width: '400px', height: '200px' }"
mode="pop"
@success="handleLogin"
/>
/> -->
</el-row>
</el-form>
</template>

4
src/views/Profile/Index.vue

@ -22,9 +22,9 @@
<el-tab-pane :label="t('profile.info.resetPwd')" name="resetPwd">
<ResetPwd />
</el-tab-pane>
<el-tab-pane :label="t('profile.info.userSocial')" name="userSocial">
<!-- <el-tab-pane :label="t('profile.info.userSocial')" name="userSocial">
<UserSocial />
</el-tab-pane>
</el-tab-pane> -->
</el-tabs>
</div>
</el-card>

4
src/views/system/menu/index.vue

@ -84,6 +84,7 @@ import { handleTree } from '@/utils/tree'
import * as MenuApi from '@/api/system/menu'
import MenuForm from './MenuForm.vue'
import { CACHE_KEY, useCache } from '@/hooks/web/useCache'
import { getInfo } from '@/api/login'
defineOptions({ name: 'SystemMenu' })
@ -107,6 +108,9 @@ const getList = async () => {
try {
const data = await MenuApi.getMenuList(queryParams)
list.value = handleTree(data)
let userInfo = await getInfo()
wsCache.set(CACHE_KEY.USER, userInfo)
wsCache.set(CACHE_KEY.ROLE_ROUTERS, userInfo.menus)
} finally {
loading.value = false
}

Loading…
Cancel
Save