router/index.js里面修改了几个详细页面的权限对应到系统管理的按钮当中了
在对应的index.vue中修改了对应的路由信息
已经全部可以跳转到详情页面了,不管是admin用户还是zhangshu用户
| | |
| | | "js-beautify": "1.13.0", |
| | | "js-cookie": "3.0.1", |
| | | "jsencrypt": "3.0.0-rc.1", |
| | | "node-sass": "^4.14.1", |
| | | "nprogress": "0.2.0", |
| | | "quill": "1.3.7", |
| | | "screenfull": "5.0.2", |
| | |
| | | "eslint-plugin-vue": "7.2.0", |
| | | "lint-staged": "10.5.3", |
| | | "runjs": "4.4.2", |
| | | "sass": "1.32.13", |
| | | "sass-loader": "10.1.1", |
| | | "sass": "^1.62.0", |
| | | "sass-loader": "^8.0.2", |
| | | "script-ext-html-webpack-plugin": "2.1.5", |
| | | "svg-sprite-loader": "5.1.1", |
| | | "vue-template-compiler": "2.6.12" |
| | |
| | | isRelogin.show = false |
| | | store.dispatch('GenerateRoutes').then(accessRoutes => { |
| | | // 根据roles权限生成可访问的路由表 |
| | | console.log(accessRoutes) |
| | | router.addRoutes(accessRoutes) // 动态添加可访问路由表 |
| | | console.log(router) |
| | | next({ ...to, replace: true }) // hack方法 确保addRoutes已完成 |
| | | }) |
| | | }).catch(err => { |
| | |
| | | ] |
| | | }, |
| | | { |
| | | path: '/family/note1', |
| | | path: '/familymodel/Property', |
| | | component: Layout, |
| | | permissions: ['family:note:list'], |
| | | |
| | | hidden: true, |
| | | permissions: ['familymodel:property:info'], |
| | | |
| | | |
| | | children: [ |
| | | { |
| | | path: 'propertyInfo/:id(\\d+)', |
| | | component: () => import('@/views/note/propertyInfo'), |
| | | name: 'propertyInfo', |
| | | meta: { title: '查询详情'} |
| | | meta: { title: '家庭资产查询详情', activeMenu: '/familymodel/zfProperty' } |
| | | } |
| | | ] |
| | | }, |
| | | //家大事记的详情 |
| | | { |
| | | path: '/family1/bignote', |
| | | path: '/familymodel/bignote', |
| | | component: Layout, |
| | | // permissions: [], |
| | | permissions: ['family1:bignote:list'], |
| | | hidden: true, |
| | | permissions: ['familymodel:bignote:list'], |
| | | |
| | | children: [ |
| | | { |
| | | path: 'familyeventInfo/:id(\\d+)', |
| | | component: () => import('@/views/bignote/familyeventInfo'), |
| | | name: 'familyeventInfo', |
| | | meta: { title: '查询详情'} |
| | | meta: { title: '家大事记查询详情',activeMenu: '/familymodel/zfEvent'} |
| | | } |
| | | ] |
| | | }, |
| | | //通讯录详情 |
| | | { |
| | | path: '/familymodel/Contact', |
| | | component: Layout, |
| | | // permissions: [], |
| | | hidden: true, |
| | | permissions: ['familymodel:contact:info'], |
| | | |
| | | children: [ |
| | | { |
| | | path: 'contactsInfo/:id(\\d+)', |
| | | component: () => import('@/views/contacts/contactsInfo'), |
| | | name: 'contactsInfo', |
| | | meta: { title: '通讯录查询详情',activeMenu: '/familymodel/zfContact'} |
| | | } |
| | | ] |
| | | }, |
| | | //家庭设备 |
| | | { |
| | | path: '/familymodel/Device', |
| | | component: Layout, |
| | | // permissions: [], |
| | | hidden: true, |
| | | permissions: ['familymodel:device:info'], |
| | | |
| | | children: [ |
| | | { |
| | | path: 'equipmentInfo/:id(\\d+)', |
| | | component: () => import('@/views/device/equipmentInfo'), |
| | | name: 'equipmentInfo', |
| | | meta: { title: '家庭设备查询详情',activeMenu: '/familymodel/zfDevice'} |
| | | } |
| | | ] |
| | | }, |
| | | //编辑个人信息 |
| | | { |
| | | path: '/self/self', |
| | |
| | | type="text" |
| | | icon="el-icon-edit" |
| | | @click="handleUpdate(scope.row)" |
| | | v-hasPermi="['system:role:edit']" |
| | | v-hasPermi="['familymodel:bignote:list']" |
| | | >修改</el-button> |
| | | <el-button |
| | | size="mini" |
| | |
| | | @click="handleDelete(scope.row)" |
| | | v-hasPermi="['system:role:remove']" |
| | | >删除</el-button> |
| | | <el-dropdown size="mini" @command="(command) => handleCommand(command, scope.row)" v-hasPermi="['system:role:edit']"> |
| | | <el-dropdown size="mini" @command="(command) => handleCommand(command, scope.row)" v-hasPermi="['familymodel:bignote:list']"> |
| | | <el-button size="mini" type="text" icon="el-icon-d-arrow-right" @click="handleCheck(scope.row)">查看详情</el-button> |
| | | |
| | | </el-dropdown> |
| | |
| | | /** 查看详细信息 */ |
| | | handleCheck(row){ |
| | | const id = row.id; |
| | | this.$router.push("/family/zfEvent/bignote/familyeventInfo/" + id); |
| | | this.$router.push("/familymodel/bignote/familyeventInfo/" + id); |
| | | }, |
| | | /** 修改按钮操作 */ |
| | | handleUpdate(row) { |
| | |
| | | let jd = true |
| | | |
| | | this.$router.push({ |
| | | path:"/family/zfEvent/bignote/familyeventInfo/" + id, |
| | | path:"/familymodel/bignote/familyeventInfo/" + id, |
| | | query:{ |
| | | detail:jd |
| | | } |
| | |
| | | /** 查看详细信息 */ |
| | | handleCheck(row){ |
| | | const id = row.id; |
| | | this.$router.push("/tongxunlu/contacts/contactsInfo/" + id); |
| | | this.$router.push("/familymodel/Contact/contactsInfo/" + id); |
| | | }, |
| | | /** 修改按钮操作 */ |
| | | handleUpdate(row) { |
| | |
| | | let jd = true |
| | | |
| | | this.$router.push({ |
| | | path:"/tongxunlu/contacts/contactsInfo/" + id, |
| | | path:"/familymodel/Contact/contactsInfo/" + id, |
| | | query:{ |
| | | detail:jd |
| | | } |
| | |
| | | /** 查看详细信息 */ |
| | | handleCheck(row){ |
| | | const id = row.id; |
| | | this.$router.push("/jiatingshebei/device/equipmentInfo/" + id); |
| | | this.$router.push("/familymodel/Device/equipmentInfo/" + id); |
| | | }, |
| | | /** 修改按钮操作 */ |
| | | handleUpdate(row) { |
| | |
| | | let jd = true |
| | | |
| | | this.$router.push({ |
| | | path:"/jiatingshebei/device/equipmentInfo/" + id, |
| | | path:"/familymodel/Device/equipmentInfo/" + id, |
| | | query:{ |
| | | detail:jd |
| | | } |
| | |
| | | type="text" |
| | | icon="el-icon-edit" |
| | | @click="handleUpdate(scope.row)" |
| | | v-hasPermi="['system:role:edit']" |
| | | v-hasPermi="['familymodel:property:info']" |
| | | >修改</el-button> |
| | | <el-button |
| | | size="mini" |
| | |
| | | @click="handleDelete(scope.row)" |
| | | v-hasPermi="['system:role:remove']" |
| | | >删除</el-button> |
| | | <el-dropdown size="mini" @command="(command) => handleCommand(command, scope.row)" v-hasPermi="['system:role:edit']"> |
| | | <el-dropdown size="mini" @command="(command) => handleCommand(command, scope.row)" v-hasPermi="['familymodel:property:info']"> |
| | | <el-button size="mini" type="text" icon="el-icon-d-arrow-right" @click="handleCheck(scope.row)">查看详情</el-button> |
| | | |
| | | </el-dropdown> |
| | |
| | | /** 查看详细信息 */ |
| | | handleCheck(row){ |
| | | const id = row.id; |
| | | this.$router.push("/family/property/note1/propertyInfo/" + id); |
| | | this.$router.push("/familymodel/property/propertyInfo/" + id); |
| | | }, |
| | | /** 修改按钮操作 */ |
| | | handleUpdate(row) { |
| | |
| | | let jd = true |
| | | |
| | | this.$router.push({ |
| | | path:"/family/property/note1/propertyInfo/" + id, |
| | | path:"/familymodel/property/propertyInfo/" + id, |
| | | query:{ |
| | | detail:jd |
| | | } |
| | |
| | | <template> |
| | | </template> |
| | | |
| | | <script> |
| | | </script> |
| | | |
| | | <style> |
| | | </style> |
| | | <template> |
| | | <div class="app-container"> |
| | | <!-- 回到顶部--> |
| | | <el-backtop :bottom="150" :right="30"> |
| | |
| | | }; |
| | | </script> |
| | | |
| | | <style> |
| | | <style scoped> |
| | | /*.uoloadSty {*/ |
| | | /* width:110px;*/ |
| | | /* height:110px;*/ |
| | |
| | | /*}*/ |
| | | |
| | | .el-icon-top { |
| | | background: url("src/assets/icons/top.png"); |
| | | background: url(""); |
| | | } |
| | | |
| | | |
| | |
| | | css: { |
| | | loaderOptions: { |
| | | sass: { |
| | | sassOptions: { outputStyle: "expanded" } |
| | | sassOptions: { outputStyle: "expanded" }, |
| | | |
| | | } |
| | | } |
| | | }, |