Browse Source

侧边栏修改样式

lipengtao 6 years ago
parent
commit
70c2d2e07a

+ 1 - 1
src/layout/TheHeader.vue

@ -21,7 +21,7 @@
21 21
                <a href="center.html#/myDemands"><el-dropdown-item>我的需求</el-dropdown-item></a>
22 22
                <a href="center.html#/companyInformation" v-if="bindCompany"><el-dropdown-item>我的企业</el-dropdown-item></a>
23 23
                <a href="center.html#/attentionCollect"><el-dropdown-item>关注收藏</el-dropdown-item></a>
24
                <a href="center.html#/modifyPassword"><el-dropdown-item>账户设置</el-dropdown-item></a>
24
                <a href="center.html#/index"><el-dropdown-item>账户设置</el-dropdown-item></a>
25 25
                <div @click="logout"><el-dropdown-item divided>退出登录</el-dropdown-item></div>
26 26
              </el-dropdown-menu>
27 27
            </el-dropdown>

+ 11 - 2
src/pages/center/router/index.js

@ -51,9 +51,18 @@ const constantRouterMap = [
51 51
      {
52 52
        path: '/modifyPassword',
53 53
        alwaysShow: true,
54
        component: (resolve) => require(['../views/modifyPassword'], resolve),
54
        component: (resolve) => require(['../views/modifyPassword/index'], resolve),
55 55
        name: 'modifyPassword',
56
        meta: { title: '修改密码' }
56
        meta: { title: '账户设置' },
57
        redirect: { name: 'index' },
58
        children: [
59
          {
60
            path: '/index',
61
            component: (resolve) => require(['../views/modifyPassword/modifyPassword'], resolve),
62
            name: 'index',
63
            meta: { title: '修改密码' }
64
          }
65
        ]
57 66
      }
58 67
    ]
59 68
  }

+ 1 - 1
src/pages/center/views/common/Sidebar/index.vue

@ -1,7 +1,7 @@
1 1
<template>
2 2
  <el-menu
3 3
    mode="vertical"
4
    :default-openeds="['personalCenter', 'myBusiness']"
4
    :default-openeds="['personalCenter', 'myBusiness', 'modifyPassword']"
5 5
    :show-timeout="200"
6 6
    :default-active="$route.path">
7 7
    <sidebar-item v-for="route in routes" :key="route.name" :item="route" :base-path="route.path"></sidebar-item>

+ 3 - 0
src/pages/center/views/modifyPassword/index.vue

@ -0,0 +1,3 @@
1
<template>
2
    <router-view></router-view>
3
</template>

src/pages/center/views/modifyPassword.vue → src/pages/center/views/modifyPassword/modifyPassword.vue