diff --git a/src/views/modules/communityService/worklog/workLogForm.vue b/src/views/modules/communityService/worklog/workLogForm.vue index 223120606..8d3fdeb06 100644 --- a/src/views/modules/communityService/worklog/workLogForm.vue +++ b/src/views/modules/communityService/worklog/workLogForm.vue @@ -30,10 +30,7 @@ label-width="150px" style="display: block" prop="serviceType"> - { - if (s.serviceType === this.formData.serviceType){ - this.disabled = s.enabled - } - }) this.getGridList(type) this.formType = type if (type === 'edit'){ this.formData = row this.getDemandUserList(this.formData.gridId) + this.serviceTypeList.forEach(s => { + if (s.serviceType === this.formData.serviceType){ + this.disabled = s.enabled === 1 ? true : false + } + }) + if (!this.disabled){ + this.formData.serviceType = '' + } } this.endLoading() }, @@ -324,6 +324,7 @@ export default { resetData () { this.demandUserList = [] this.optionsG = [] + this.disabled = false this.formData = { serviceType: 0, gridId: '',