DsionStep1.vue 2.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. <template>
  2. <div class="dsion-step1">
  3. <div style="padding: 24px" class="flex">
  4. <div class="w-1/2">
  5. <div class="text-[20px] text-bold">分班学生范围</div>
  6. <div class="flex mt-8 items-center">
  7. <div class="w-[100px]">
  8. <span class="text-[#ff0000]">*</span>
  9. 年级:
  10. </div>
  11. <Select style="width: 100%" v-model:value="state.gradeId" :options="state.gradeOptions" />
  12. </div>
  13. <div class="flex mt-4 items-center">
  14. <div class="w-[100px]">
  15. <span class="text-[#ff0000]">*</span>
  16. 招生类型:
  17. </div>
  18. <Select
  19. style="width: 100%"
  20. v-model:value="state.enrollType"
  21. :options="state.enrollTypeOptions"
  22. />
  23. </div>
  24. <div class="flex mt-8">
  25. <div class="w-[100px]"> </div>
  26. <div> 已录取学生人数“xxx”人;已分班学生人数“xxx”人 </div>
  27. </div>
  28. </div>
  29. <div class="w-1/2 ml-4">
  30. <div class="text-[20px] text-bold">分班基本规则</div>
  31. <div class="flex mt-8">
  32. <Checkbox.Group v-model:value="state.checkboxItem" :options="state.checkedOptions" />
  33. </div>
  34. <div class="flex mt-2">
  35. <Radio.Group v-model:value="state.radioItem" :options="state.radioOptions" />
  36. </div>
  37. </div>
  38. </div>
  39. </div>
  40. </template>
  41. <script setup lang="ts">
  42. import { Select, Checkbox, Radio } from 'ant-design-vue';
  43. import { onMounted, reactive } from 'vue';
  44. import { requestMagicApi } from '/@/api/magicApi';
  45. import { getDataOption } from '/@/api/system/dic';
  46. const state = reactive({
  47. gradeId: '',
  48. enrollType: '',
  49. checkboxItem: [],
  50. gradeOptions: [],
  51. enrollTypeOptions: [],
  52. radioItem: '',
  53. checkedOptions: [
  54. { label: '使每班的男女生性别比例比较均衡', value: '0' },
  55. { label: '使每班的学生成绩/年龄比例比较均衡', value: '1' },
  56. { label: '使每班的学生来源比例比较均衡', value: '2' },
  57. { label: '使每班的住宿类型比例比较均衡', value: '3' },
  58. { label: '使姓名相同的学生分到不同的班级', value: '4' },
  59. { label: '专业分班有限制条件时按高值分配', value: '5' },
  60. ],
  61. radioOptions: [
  62. { label: '使同专业班级人数比例比较均衡', value: '0' },
  63. { label: '使同专业班级一个班级排满在排下一个班级', value: '1' },
  64. ],
  65. });
  66. onMounted(async () => {
  67. state.gradeOptions = await requestMagicApi({ url: 'baseData/grade/option' });
  68. state.enrollTypeOptions = await getDataOption({ code: 'enroll_type' });
  69. });
  70. </script>
  71. <style lang="less" scoped>
  72. .dsion-step1 {
  73. margin: 24px auto;
  74. background-color: @component-background;
  75. border-radius: 16px;
  76. width: 1000px;
  77. }
  78. </style>