|  | @@ -1,32 +1,45 @@
 | 
	
		
			
				|  |  |  <template>
 | 
	
		
			
				|  |  | -    <el-dialog
 | 
	
		
			
				|  |  | -      append-to-body
 | 
	
		
			
				|  |  | -      v-if="dialogVisible"
 | 
	
		
			
				|  |  | -      title="选择自选专业"
 | 
	
		
			
				|  |  | -      :visible.sync="dialogVisible"
 | 
	
		
			
				|  |  | -      :before-close="handlerClose"
 | 
	
		
			
				|  |  | -      :close-on-click-modal ="false"
 | 
	
		
			
				|  |  | -      width="70%"
 | 
	
		
			
				|  |  | -    >
 | 
	
		
			
				|  |  | -      <subject-choice :course0="course0" :course1="course1" :year="year" ></subject-choice>
 | 
	
		
			
				|  |  | -      <span slot="footer" class="dialog-footer">
 | 
	
		
			
				|  |  | +  <el-dialog
 | 
	
		
			
				|  |  | +    append-to-body
 | 
	
		
			
				|  |  | +    v-if="dialogVisible"
 | 
	
		
			
				|  |  | +    title="选择自选专业"
 | 
	
		
			
				|  |  | +    :visible.sync="dialogVisible"
 | 
	
		
			
				|  |  | +    :before-close="handlerClose"
 | 
	
		
			
				|  |  | +    :close-on-click-modal="false"
 | 
	
		
			
				|  |  | +    width="70%"
 | 
	
		
			
				|  |  | +  >
 | 
	
		
			
				|  |  | +    <subject-choice :course0="course0" :course1="course1" :year="year" :readonly="readonly"></subject-choice>
 | 
	
		
			
				|  |  | +    <span slot="footer" class="dialog-footer">
 | 
	
		
			
				|  |  |          <el-button type="primary" @click="cancel">确 定</el-button>
 | 
	
		
			
				|  |  |        </span>
 | 
	
		
			
				|  |  | -    </el-dialog>
 | 
	
		
			
				|  |  | +  </el-dialog>
 | 
	
		
			
				|  |  |  </template>
 | 
	
		
			
				|  |  |  <script>
 | 
	
		
			
				|  |  | -import SubjectChoice from'@/views/career/subject/subjectChoice'
 | 
	
		
			
				|  |  | +import SubjectChoice from '@/views/career/subject/subjectChoice'
 | 
	
		
			
				|  |  | +
 | 
	
		
			
				|  |  |  export default {
 | 
	
		
			
				|  |  |    components: {
 | 
	
		
			
				|  |  |      SubjectChoice
 | 
	
		
			
				|  |  |    },
 | 
	
		
			
				|  |  | -  inject: ['optionalMajors'],
 | 
	
		
			
				|  |  | +  inject: {
 | 
	
		
			
				|  |  | +    optionalMajors: {
 | 
	
		
			
				|  |  | +      default: function() {
 | 
	
		
			
				|  |  | +        // default - empty function
 | 
	
		
			
				|  |  | +      }
 | 
	
		
			
				|  |  | +    }
 | 
	
		
			
				|  |  | +  },
 | 
	
		
			
				|  |  | +  props: {
 | 
	
		
			
				|  |  | +    readonly: {
 | 
	
		
			
				|  |  | +      type: Boolean,
 | 
	
		
			
				|  |  | +      default: false
 | 
	
		
			
				|  |  | +    }
 | 
	
		
			
				|  |  | +  },
 | 
	
		
			
				|  |  |    data() {
 | 
	
		
			
				|  |  | -    return{
 | 
	
		
			
				|  |  | -      dialogVisible:false,
 | 
	
		
			
				|  |  | +    return {
 | 
	
		
			
				|  |  | +      dialogVisible: false,
 | 
	
		
			
				|  |  |        course0: '',
 | 
	
		
			
				|  |  |        year: '',
 | 
	
		
			
				|  |  | -      course1: '',
 | 
	
		
			
				|  |  | +      course1: ''
 | 
	
		
			
				|  |  |      }
 | 
	
		
			
				|  |  |    },
 | 
	
		
			
				|  |  |    methods: {
 | 
	
	
		
			
				|  | @@ -34,7 +47,7 @@ export default {
 | 
	
		
			
				|  |  |        console.log('res')
 | 
	
		
			
				|  |  |        this.cancel()
 | 
	
		
			
				|  |  |      },
 | 
	
		
			
				|  |  | -    open(course0, course1,year) {
 | 
	
		
			
				|  |  | +    open(course0, course1, year) {
 | 
	
		
			
				|  |  |        this.dialogVisible = true
 | 
	
		
			
				|  |  |        this.year = year || ''
 | 
	
		
			
				|  |  |        this.course0 = course0
 |