index.vue 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101
  1. <template>
  2. <div class="m-container">
  3. <h2>
  4. <el-page-header @back="onCancel"
  5. content="乐团修改"></el-page-header>
  6. </h2>
  7. <div class="m-core">
  8. <!-- navMenu -->
  9. <el-tabs v-model="activeIndex"
  10. type="card"
  11. @tab-click="handleClick">
  12. <el-tab-pane label="基本信息"
  13. v-if="permission('/resetTeaming/teamBaseInfo')"
  14. name="1">
  15. <teamBaseInfo v-if="activeIndex == 1" />
  16. </el-tab-pane>
  17. <el-tab-pane label="缴费调整"
  18. v-if="permission('/resetTeaming/resetSound')"
  19. name="2">
  20. <resetSound v-if="activeIndex == 2" />
  21. </el-tab-pane>
  22. <el-tab-pane label="班级调整"
  23. v-if="permission('/resetTeaming/resetClass')"
  24. name="3">
  25. <resetClass v-if="activeIndex == 3" />
  26. </el-tab-pane>
  27. <el-tab-pane label="新增排课"
  28. v-if="permission('/resetTeaming/coursePlan')"
  29. name="4">
  30. <coursePlan :teamid='teamid'
  31. v-if="activeIndex == 4" />
  32. <!-- <lookCourse /> -->
  33. </el-tab-pane>
  34. <!-- <el-tab-pane label="新增小班课"
  35. name="5">
  36. <improvement :teamid='teamid' />
  37. </el-tab-pane> -->
  38. </el-tabs>
  39. </div>
  40. </div>
  41. </template>
  42. <script>
  43. import teamBaseInfo from '@/views/teamBuild/components/teamBaseInfo'
  44. import resetSound from '@/views/resetTeaming/components/resetSound'
  45. import resetClass from '@/views/teamDetail/components/resetClass'
  46. import coursePlan from '@/views/teamBuild/teamSeting/components/coursePlan'
  47. import lookCourse from '@/views/teamBuild/teamSeting/components/lookCourse'
  48. import improvement from '@/views/teamBuild/teamSeting/components/improvementClass'
  49. import { permission } from '@/utils/directivePage'
  50. export default {
  51. components: { teamBaseInfo, resetSound, resetClass, coursePlan, lookCourse, improvement },
  52. data () {
  53. return {
  54. activeIndex: '1',
  55. teamid: '',
  56. // permissionStatus: {
  57. // teamBaseInfo: true,
  58. // resetSound: true,
  59. // resetClass: true,
  60. // resetSound: true,
  61. // coursePlan: true,
  62. // }
  63. Fsearch: null,
  64. Frules: null
  65. }
  66. },
  67. created () {
  68. this.activeIndex = sessionStorage.getItem('resetCode') || '1';
  69. this.teamid = this.$route.query.id;
  70. if (this.$route.query.search) {
  71. this.Fsearch = this.$route.query.search;
  72. }
  73. if (this.$route.query.rules) {
  74. this.Frules = this.$route.query.rules
  75. }
  76. },
  77. beforeDestroy () {
  78. sessionStorage.setItem('setStep', 0)
  79. sessionStorage.setItem('resetCode', 1)
  80. },
  81. mounted () {
  82. let obj = {}
  83. obj.name = this.activeIndex
  84. this.handleClick(obj)
  85. }, methods: {
  86. onCancel () {
  87. this.$router.push({ path: '/business/teamDetail', query: { search: this.Fsearch, rules: this.Frules } })
  88. },
  89. handleClick (val) {
  90. this.activeIndex = val.name
  91. },
  92. permission (str) {
  93. return permission(str)
  94. }
  95. },
  96. }
  97. </script>
  98. <style lang="scss">
  99. </style>