batch-step.vue 3.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. <template>
  2. <view class="p-30 fx-col gap-30">
  3. <view class="bg-gradient-to-r from-primary-deep to-primary-light px-20 py-30 rounded-lg">
  4. <view class="text-white font-bold">我的成绩</view>
  5. <view class="mt-20 fx-row fx-bet-cen text-white text-2xs">
  6. <text>省份:{{ userSnapshot.provinceName }}</text>
  7. <text>专业类别:{{ userSnapshot.examMajorName }}</text>
  8. <text>总分:{{ model.score }}</text>
  9. </view>
  10. </view>
  11. <view class="text-center mt-50">(二)选择填报批次</view>
  12. <view class="fx-col gap-20 mt-20">
  13. <view @click="handleBatchSelect(item)" v-for="item in batchList"
  14. class="bg-gradient-to-b from-sky-100 to-white px-30 py-50 fx-row fx-bet-cen mx-card">
  15. <view class="flex-1 fx-col">
  16. <view class="fx-row items-center">
  17. <text class="text-xl mr-10 batch-name">{{ item.name }}</text>
  18. <uv-tags v-if="item.recommand" text="重点推荐" type="error" shape="circle" size="mini"/>
  19. </view>
  20. <view class="text-2xs mt-20">{{ item.tips }}</view>
  21. </view>
  22. <view class="fx-col ai-cen">
  23. <uv-button type="primary" shape="circle" class="pointer-events-none"
  24. color="linear-gradient(to right, var(--primary-deep-color),var(--primary-light-color))"
  25. custom-style="height: 32px; border: none;" text="智能填报"/>
  26. <!-- <text class="f-tips f10 mt5">可填{{ getCollegeLimit(item.batch) }}所院校</text>-->
  27. </view>
  28. </view>
  29. </view>
  30. </view>
  31. </template>
  32. <script setup>
  33. import {watch} from 'vue';
  34. import {useInjectVoluntaryForm} from "@/pages/voluntary/hooks/useVoluntaryFormInjection";
  35. import {useInjectUserSnapshot} from "@/pages/ie/hooks/useUserSnapshotInjection";
  36. import {useInjectVoluntaryAssistant} from "@/pages/voluntary/hooks/useVoluntaryAssistantInjection";
  37. import {useInjectVoluntaryStep} from "@/pages/voluntary/hooks/useVoluntaryStepInjection";
  38. const {currentStep} = useInjectVoluntaryStep()
  39. const {model, batch, batchList, loadBatchList} = useInjectVoluntaryForm()
  40. const {userSnapshot} = useInjectUserSnapshot()
  41. const {handleForward} = useInjectVoluntaryAssistant()
  42. const handleBatchSelect = (item) => {
  43. batch.value = item
  44. handleForward()
  45. }
  46. watch(currentStep, step => {
  47. if (step == 1) loadBatchList()
  48. })
  49. // getCollegeLimit(batch) {
  50. // const match = this.voluntaryData?.batches?.find(b => b.batch == batch)
  51. // return match?.groups
  52. // }
  53. </script>
  54. <style lang="scss" scoped>
  55. .batch-name {
  56. position: relative;
  57. z-index: 10;
  58. &::before {
  59. position: absolute;
  60. left: 0;
  61. bottom: 0;
  62. content: ' ';
  63. width: 66rpx;
  64. height: 10rpx;
  65. border-radius: 5rpx;
  66. background: linear-gradient(to right, #FFD423, #FFFFFF);
  67. z-index: -1;
  68. }
  69. }
  70. </style>