Commit f59ddfc7 authored by ztf's avatar ztf

修改选择项目代号组件

parent d10750bb
......@@ -12,7 +12,7 @@
v-for="item in projectCodeOptions"
:key="item.dictKey"
:label="item.label"
:value="item.value"
:value="item"
/>
</el-select>
</div>
......@@ -43,11 +43,17 @@ export default {
value(newVal) {
if (newVal) {
this.projectCode = newVal
if (newVal === 'QH4' || newVal === 'QH6') {
}
},
'form.projectType': {
immediate: true,
deep: true,
handler: function(val) {
if (val === 'ScienceClass') {
this.form.subSystem = ''
this.form.ownSubSystem = ''
this.form.ownedEquipment = ''
} else if (newVal === 'QH3') {
} else if (val === 'ModelDevelop') {
this.form.subject = ''
}
}
......@@ -84,15 +90,17 @@ export default {
return {
value: row.dictKey,
label: row.dictValue,
dictKey: row.dictKey
dictKey: row.dictKey,
parentKey: row.parentKey
}
})
}
})
},
handleChange(val) {
this.$emit('input', val)
handleChange(item) {
this.$emit('input', item.value)
this.form.projectType = item.parentKey
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment