diff --git a/src/views/projectFront/safetyEducation/addCourse.vue b/src/views/projectFront/safetyEducation/addCourse.vue index d6966f75..27203c0b 100644 --- a/src/views/projectFront/safetyEducation/addCourse.vue +++ b/src/views/projectFront/safetyEducation/addCourse.vue @@ -31,7 +31,7 @@ - - - + {{ $t('message.safetyEducation.clickUpload') }} @@ -399,7 +399,9 @@ export default { mounted(){ // console.log(process.env.NODE_ENV) - this.ruleForm.classifyId=parseInt(this.classifyId) + if(this.classifyId != ''){ + this.ruleForm.classifyId=parseInt(this.classifyId) + } this.styleType = this.$store.state.userInfo.styleType console.log(this.styleType) if(this.eduId==''){ @@ -415,6 +417,16 @@ export default { } }, + // watch:{ + // 'ruleForm.classifyId':{ + // handler(newVal,oldVal){ + // if(newVal!=oldVal){ + // this.getClassifyList() + // } + // }, + // deep:true, + // } + // }, methods: { //生成二维码 createQRcode(index){ @@ -624,6 +636,12 @@ export default { getClassifyList() { educationClassifyListApi({sn: this.ruleForm.projectSn}).then(result => { this.classifyList = result.result; + // console.log('this.classifyList',this.classifyList) + // this.classifyList.find((item)=>{ + // if(this.classifyId == item.id){ + // this.ruleForm.classifyId = item.classifyName + // } + // }) }) }, handleSizeChange(value) {