index.vue 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102
  1. <template>
  2. <div class="testExamine">
  3. <div class="testTit">
  4. <div class="teaLis">
  5. <div
  6. class="teal"
  7. @click="cutPage(2)"
  8. :class="[pType == 2 ? 'Tbor' : '']"
  9. >
  10. 专任教师
  11. </div>
  12. <div
  13. class="teal"
  14. @click="cutPage(1)"
  15. :class="[pType == 1 ? 'Tbor' : '']"
  16. >
  17. 班主任
  18. </div>
  19. </div>
  20. <div style="margin-right: 100px;">
  21. <el-select v-model="cutTable" placeholder="请选择">
  22. <el-option
  23. v-for="item in cutTabOpts"
  24. :key="item.value"
  25. :label="item.label"
  26. :value="item.value"
  27. >
  28. </el-option>
  29. </el-select>
  30. </div>
  31. </div>
  32. <div class="testCon">
  33. <targetPage :pType="pType" v-if="cutTable == 0"></targetPage>
  34. <personPage :pType="pType" v-if="cutTable == 1"></personPage>
  35. </div>
  36. </div>
  37. </template>
  38. <script>
  39. import personPage from "./conpoments/personPage.vue";
  40. import targetPage from "./conpoments/targetPage";
  41. export default {
  42. components: {
  43. personPage,
  44. targetPage
  45. },
  46. data() {
  47. return {
  48. pType: 2,
  49. cutTable: 0,
  50. cutTabOpts: [
  51. {
  52. value: 0,
  53. label: "按指标"
  54. },
  55. {
  56. value: 1,
  57. label: "按人员"
  58. }
  59. ]
  60. };
  61. },
  62. methods: {
  63. cutPage(e) {
  64. this.pType = e;
  65. }
  66. }
  67. };
  68. </script>
  69. <style scoped>
  70. .testExamine {
  71. width: 100%;
  72. min-width: calc(150px * 10);
  73. min-height: 100%;
  74. padding: 10px;
  75. box-sizing: border-box;
  76. background-color: #fff;
  77. }
  78. .testExamine > .testTit {
  79. height: 100px;
  80. display: flex;
  81. justify-content: space-between;
  82. align-items: center;
  83. }
  84. .teaLis {
  85. display: flex;
  86. }
  87. .teal {
  88. padding: 10px 20px;
  89. cursor: pointer;
  90. }
  91. .Tbor {
  92. border-bottom: 2px rgba(54, 129, 252, 1) solid;
  93. font-weight: 600;
  94. }
  95. .testCon {
  96. box-sizing: border-box;
  97. padding: 20px;
  98. }
  99. </style>