choose-subject-dialog.vue 1.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. <template>
  2. <el-dialog
  3. append-to-body
  4. v-if="dialogVisible"
  5. title="选择自选专业"
  6. :visible.sync="dialogVisible"
  7. :close-on-click-modal ="false"
  8. width="70%"
  9. >
  10. <subject-choice :course0="course0" :course1="course1" :year="year" ></subject-choice>
  11. <span slot="footer" class="dialog-footer">
  12. <el-button type="primary" @click="cancel">确 定</el-button>
  13. </span>
  14. </el-dialog>
  15. </template>
  16. <script>
  17. import SubjectChoice from'@/views/career/subject/subjectChoice'
  18. export default {
  19. components: {
  20. SubjectChoice
  21. },
  22. inject: ['optionalMajors'],
  23. data() {
  24. return{
  25. dialogVisible:false,
  26. course0: '',
  27. year: '',
  28. course1: '',
  29. }
  30. },
  31. methods: {
  32. open(course0, course1,year) {
  33. this.dialogVisible = true
  34. this.year = year
  35. this.course0 = course0
  36. this.course1 = course1
  37. },
  38. cancel() {
  39. this.dialogVisible = false
  40. this.optionalMajors()
  41. this.$emit('chooseReally',)
  42. }
  43. }
  44. }
  45. </script>
  46. <style scoped>
  47. </style>