HomePage.vue 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113
  1. <template>
  2. <el-container class="user">
  3. <el-aside>
  4. <div class="logo">
  5. <p><b>后台管理系统</b></p>
  6. </div>
  7. <lt-menu v-if="data&&data.menuWrappers.length" v-bind:data="data.menuWrappers"></lt-menu>
  8. </el-aside>
  9. <el-container>
  10. <el-header class="clearfix">
  11. <div class="title fl">
  12. <h2>机构名称</h2>
  13. <lt-badge class="green">试用中</lt-badge>
  14. </div>
  15. <div class="userInfo fr">
  16. <img src="" alt="">
  17. <span class="username">用户名</span>
  18. <lt-badge class="green">已认证</lt-badge>
  19. </div>
  20. </el-header>
  21. <div class="block">控制台</div>
  22. <el-main>
  23. <trial-user></trial-user>
  24. </el-main>
  25. </el-container>
  26. </el-container>
  27. </template>
  28. <script>
  29. import LtMenu from './Menu.vue';
  30. import LtBadge from '@base/LtBadge.vue';
  31. import TrialUser from '@components/user/TrialUser.vue';
  32. import api from '@api/index.js';
  33. export default {
  34. name: 'homepage',
  35. components: {
  36. 'lt-badge': LtBadge,
  37. 'lt-menu': LtMenu,
  38. 'trial-user': TrialUser
  39. },
  40. data: function () {
  41. return {
  42. data: null
  43. }
  44. },
  45. created() {
  46. // api.getAccessdMenu().then((res) => {
  47. // if (res.data.code == '0') {
  48. // const data = res.data.data;
  49. // this.data = data;
  50. // }
  51. // }).catch((error) => {
  52. // console.log(error);
  53. // })
  54. }
  55. }
  56. </script>
  57. <style lang="less" scoped>
  58. @import '../../less/common.less';
  59. .user {
  60. height: 100%;
  61. }
  62. .logo {
  63. background: @userBase;
  64. p {
  65. font-size: 18px;
  66. line-height: 40px;
  67. }
  68. }
  69. .title {
  70. h2 {
  71. display: inline-block;
  72. line-height: 60px;
  73. font-size: 18px;
  74. }
  75. }
  76. .userInfo {
  77. }
  78. .block {
  79. height: 40px;
  80. width: 100%;
  81. background: #fff;
  82. box-shadow: 0px 1px 2px #c9c9c9;
  83. line-height: 40px;
  84. }
  85. .el-menu-item.is-active {
  86. color: @userBase;
  87. }
  88. .el-main {
  89. background: #dee2ea;
  90. width: 100%;
  91. height: 100%;
  92. padding: 0;
  93. }
  94. .el-container[data-v-2c8bad12] {
  95. height: 100%;
  96. }
  97. </style>