|
|
@ -96,7 +96,7 @@ export default { |
|
|
SD: { |
|
|
SD: { |
|
|
label: "template.gsp.MJYLQSQD.sd", |
|
|
label: "template.gsp.MJYLQSQD.sd", |
|
|
type: "input", |
|
|
type: "input", |
|
|
disabled:true, |
|
|
|
|
|
|
|
|
disabled: true, |
|
|
fillType: "actFill", |
|
|
fillType: "actFill", |
|
|
}, |
|
|
}, |
|
|
sywzmc: { |
|
|
sywzmc: { |
|
|
@ -215,31 +215,63 @@ export default { |
|
|
mounted() { |
|
|
mounted() { |
|
|
}, |
|
|
}, |
|
|
methods: { |
|
|
methods: { |
|
|
onSelectBlur(val) { |
|
|
|
|
|
|
|
|
init(val) { |
|
|
if (val.key == 'sywzmc') { |
|
|
if (val.key == 'sywzmc') { |
|
|
let tmp = [] |
|
|
|
|
|
_.forEach(_.filter(this.gyjlOptionsOld, function (o) { |
|
|
|
|
|
return o.remark.indexOf(val.value) > -1; |
|
|
|
|
|
}), function (item) { |
|
|
|
|
|
tmp.push({ label: item.dictLabel, value: item.dictValue }) |
|
|
|
|
|
}) |
|
|
|
|
|
this.gyjlOptions = tmp |
|
|
|
|
|
|
|
|
this.filterGyjl(val, false) |
|
|
|
|
|
} |
|
|
|
|
|
if (val.key == 'gyjl') { |
|
|
|
|
|
this.filterGynd(val, false) |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
onSelectBlur(val) { |
|
|
|
|
|
if (val.key == 'sywzmc' && !val.type != 'cancel') { |
|
|
|
|
|
this.filterGyjl(val, true) |
|
|
|
|
|
} |
|
|
|
|
|
if (val.key == 'gyjl' && !val.type != 'cancel') { |
|
|
|
|
|
this.filterGynd(val, true) |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
filterGyjl(val, reset) { |
|
|
|
|
|
let tmp = [] |
|
|
|
|
|
_.forEach(_.filter(this.gyjlOptionsOld, function (o) { |
|
|
|
|
|
if (o.remark && o.remark != '') { |
|
|
|
|
|
let _index = _.findIndex(o.remark.split(','), function (r) { |
|
|
|
|
|
return r == val.value; |
|
|
|
|
|
}) |
|
|
|
|
|
return _index > -1 ? true : false; |
|
|
|
|
|
} else { |
|
|
|
|
|
return false; |
|
|
|
|
|
} |
|
|
|
|
|
}), function (item) { |
|
|
|
|
|
tmp.push({ label: item.dictLabel, value: item.dictValue }) |
|
|
|
|
|
}) |
|
|
|
|
|
this.gyjlOptions = tmp |
|
|
|
|
|
if (reset) { |
|
|
this.gyndOptions = [] |
|
|
this.gyndOptions = [] |
|
|
this.$refs.baseInfoRef.batchUpdateFormData({ |
|
|
this.$refs.baseInfoRef.batchUpdateFormData({ |
|
|
gyjl: '', |
|
|
|
|
|
xynd: '', |
|
|
|
|
|
|
|
|
gyjl: ' ', |
|
|
|
|
|
xynd: ' ', |
|
|
}); |
|
|
}); |
|
|
} |
|
|
} |
|
|
if (val.key == 'gyjl') { |
|
|
|
|
|
let tmp = [] |
|
|
|
|
|
_.forEach(_.filter(this.gyndOptionsOld, function (o) { |
|
|
|
|
|
return o.remark.indexOf(val.value) > -1; |
|
|
|
|
|
}), function (item) { |
|
|
|
|
|
tmp.push({ label: item.dictLabel, value: item.dictValue }) |
|
|
|
|
|
}) |
|
|
|
|
|
this.gyndOptions = tmp |
|
|
|
|
|
|
|
|
}, |
|
|
|
|
|
filterGynd(val, reset) { |
|
|
|
|
|
let tmp = [] |
|
|
|
|
|
_.forEach(_.filter(this.gyndOptionsOld, function (o) { |
|
|
|
|
|
if (o.remark && o.remark != '') { |
|
|
|
|
|
let _index = _.findIndex(o.remark.split(','), function (r) { |
|
|
|
|
|
return r == val.value; |
|
|
|
|
|
}) |
|
|
|
|
|
return _index > -1 ? true : false; |
|
|
|
|
|
} else { |
|
|
|
|
|
return false; |
|
|
|
|
|
} |
|
|
|
|
|
}), function (item) { |
|
|
|
|
|
tmp.push({ label: item.dictLabel, value: item.dictValue }) |
|
|
|
|
|
}) |
|
|
|
|
|
this.gyndOptions = tmp |
|
|
|
|
|
if (reset) { |
|
|
this.$refs.baseInfoRef.batchUpdateFormData({ |
|
|
this.$refs.baseInfoRef.batchUpdateFormData({ |
|
|
xynd: '', |
|
|
|
|
|
|
|
|
xynd: ' ', |
|
|
}); |
|
|
}); |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
@ -253,7 +285,7 @@ export default { |
|
|
}).then(response => { |
|
|
}).then(response => { |
|
|
this.gyjlOptionsOld = response.rows |
|
|
this.gyjlOptionsOld = response.rows |
|
|
if (this.formData.sywzmc && this.formData.sywzmc !== '') { |
|
|
if (this.formData.sywzmc && this.formData.sywzmc !== '') { |
|
|
this.onSelectBlur({ key: 'sywzmc', value: this.formData.sywzmc }) |
|
|
|
|
|
|
|
|
this.init({ key: 'sywzmc', value: this.formData.sywzmc }) |
|
|
} |
|
|
} |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
@ -267,7 +299,7 @@ export default { |
|
|
}).then(response => { |
|
|
}).then(response => { |
|
|
this.gyndOptionsOld = response.rows |
|
|
this.gyndOptionsOld = response.rows |
|
|
if (this.formData.gyjl && this.formData.gyjl !== '') { |
|
|
if (this.formData.gyjl && this.formData.gyjl !== '') { |
|
|
this.onSelectBlur({ key: 'gyjl', value: this.formData.gyjl }) |
|
|
|
|
|
|
|
|
this.init({ key: 'gyjl', value: this.formData.gyjl }) |
|
|
} |
|
|
} |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
|