index.vue 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133
  1. <template>
  2. <div id="index">
  3. <el-row>
  4. <el-col :span="24" class="info">
  5. <el-col :span="24" class="top">
  6. <heads></heads>
  7. </el-col>
  8. <el-col :span="24" class="main">
  9. <div class="w_1200">
  10. <el-col :span="4" class="mainMenu">
  11. <menus @setRight="setRight"></menus>
  12. </el-col>
  13. <el-col :span="19" class="mainMess">
  14. <top :title="topTitle" v-if="cpt && cpt != ''"></top>
  15. <div style="padding:10px">
  16. <component :is="cpt"></component>
  17. </div>
  18. </el-col>
  19. </div>
  20. </el-col>
  21. <el-col :span="24" class="foot">
  22. <foot></foot>
  23. </el-col>
  24. </el-col>
  25. </el-row>
  26. </div>
  27. </template>
  28. <script>
  29. /* eslint-disable vue/no-unused-components */
  30. import menus from './menuInfo.vue';
  31. import top from './lefttop.vue';
  32. import role from './role/index.vue';
  33. import permission from './permission/index.vue';
  34. import adminUser from './adminUser/index.vue';
  35. import vip from './vip/index.vue';
  36. import user from './user/index.vue';
  37. import duijiehui from './duijiehui/index.vue';
  38. import enterpriseProduct from './enterpriseProduct/index.vue';
  39. import enterpriseTrans from './enterpriseTrans/index.vue';
  40. import technical from './technical/index.vue';
  41. import roadshow from './roadshow/index.vue';
  42. import guestInter from './guestInter/index.vue';
  43. import dictionary from './dictionary/index.vue';
  44. import business from './business/index.vue';
  45. import manager from './manager/index.vue';
  46. import bindWx from './bindWx/index.vue';
  47. import notice from './notice/index.vue';
  48. import productSolicit from './productSolicit/index.vue';
  49. import updatepwd from './xiugai/xiugai.vue';
  50. import Journ from './Journ/index.vue';
  51. import heads from '@/layout/userCenter/heads.vue';
  52. import foot from '@/layout/live/foot.vue';
  53. import { mapState, createNamespacedHelpers } from 'vuex';
  54. export default {
  55. name: 'index',
  56. props: {},
  57. components: {
  58. heads,
  59. foot,
  60. role,
  61. permission,
  62. adminUser,
  63. vip,
  64. user,
  65. duijiehui,
  66. enterpriseProduct,
  67. enterpriseTrans,
  68. technical,
  69. roadshow,
  70. guestInter,
  71. dictionary,
  72. business,
  73. manager,
  74. bindWx,
  75. notice,
  76. productSolicit,
  77. menus,
  78. top,
  79. updatepwd,
  80. Journ,
  81. },
  82. data: function() {
  83. return {
  84. cpt: 'updatepwd',
  85. topTitle: '',
  86. };
  87. },
  88. created() {},
  89. methods: {
  90. setRight(menu) {
  91. let { name, cpt } = menu;
  92. this.$set(this, `topTitle`, name);
  93. this.$set(this, `cpt`, cpt);
  94. },
  95. },
  96. computed: {
  97. ...mapState(['user']),
  98. pageTitle() {
  99. return `${this.$route.meta.title}`;
  100. },
  101. },
  102. metaInfo() {
  103. return { title: this.$route.meta.title };
  104. },
  105. };
  106. </script>
  107. <style lang="less" scoped>
  108. .w_1200 {
  109. // width: 80%;
  110. width: 1200px;
  111. margin: 0 auto;
  112. }
  113. .info {
  114. background-color: #e9edf6;
  115. }
  116. .main {
  117. min-height: 834px;
  118. margin: 15px 0;
  119. }
  120. .mainMenu {
  121. width: 20%;
  122. min-height: 834px;
  123. background-color: #fff;
  124. }
  125. .mainMess {
  126. float: right;
  127. min-height: 834px;
  128. background-color: #fff;
  129. }
  130. </style>