index.vue 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192
  1. <template>
  2. <div style="position: relative; height: 100%;">
  3. <div class="header">
  4. <Tags :tags.sync="tags" />
  5. </div>
  6. <rolemembers-list :item="item" v-if="tags[1].show"></rolemembers-list>
  7. <permission-detail :item="item" v-if="tags[0].show"></permission-detail>
  8. </div>
  9. </template>
  10. <script>
  11. import Tags from "@/components/tags/index.vue";
  12. import PermissionDetail from './permissionDetail';
  13. import RolemembersList from './rolemembersList';
  14. export default {
  15. props: {
  16. item: Object,
  17. },
  18. components: { Tags, RolemembersList, PermissionDetail },
  19. data() {
  20. return {
  21. tags: [
  22. {
  23. label: '权限详情',
  24. value: '0',
  25. show: true,
  26. },
  27. {
  28. label: '成员列表',
  29. value: '1',
  30. show: false,
  31. }
  32. ],
  33. }
  34. },
  35. mounted(){
  36. },
  37. methods:{
  38. Show1(){
  39. this.detailShow = true;
  40. this.memberShow = false;
  41. },
  42. Show2(){
  43. this.detailShow = false;
  44. this.memberShow = true;
  45. },
  46. }
  47. }
  48. </script>
  49. <style lang="less" scoped>
  50. .header {
  51. text-align: left;
  52. padding: 15px;
  53. font-size: 25px;
  54. .roleDetail{
  55. width: 100px;
  56. height: 35px;
  57. line-height: 20px;
  58. border-radius: 20px;
  59. background-color: #FFFFFF;
  60. color: #C8C8C8;
  61. font-size: 14px;
  62. text-align: center;
  63. padding: 5px;
  64. }
  65. .roleDetail:focus {
  66. background-color: #2EA8E6;
  67. color: #FFFFFF;
  68. }
  69. .roleMember {
  70. width: 100px;
  71. height: 35px;
  72. line-height: 20px;
  73. border-radius: 20px;
  74. background-color: #FFFFFF;
  75. color: #C8C8C8;
  76. font-size: 14px;
  77. text-align: center;
  78. padding: 5px;
  79. }
  80. .roleMember:focus {
  81. background-color: #2EA8E6;
  82. color: #FFFFFF;
  83. }
  84. }
  85. </style>