|
|
@ -306,9 +306,9 @@ |
|
|
|
> |
|
|
|
<el-option |
|
|
|
v-for="item in serviceOptiondList" |
|
|
|
:key="item.value" |
|
|
|
:label="item.label" |
|
|
|
:value="item.value" |
|
|
|
:key="item.id" |
|
|
|
:label="item.name" |
|
|
|
:value="item.id" |
|
|
|
> |
|
|
|
</el-option> |
|
|
|
</el-select> |
|
|
@ -622,10 +622,11 @@ export default { |
|
|
|
} |
|
|
|
}, |
|
|
|
handleServiceChange(type, val) { |
|
|
|
console.log(val); |
|
|
|
if (val === "social_org") { |
|
|
|
if (type === "add") this.getServiceuserList(val, "add_demand"); |
|
|
|
else this.getServiceuserList(val, "query_demand"); |
|
|
|
} else this.getServiceuserList(val, ""); |
|
|
|
} else this.getServiceuserList(val,this.form.categoryCode); |
|
|
|
}, |
|
|
|
async handleGridChange(val) { |
|
|
|
console.log("网格改变了", val); |
|
|
@ -641,12 +642,6 @@ export default { |
|
|
|
} |
|
|
|
}, |
|
|
|
|
|
|
|
handleServiceChange(type, val) { |
|
|
|
if (val === "social_org") { |
|
|
|
if (type === "add") this.getServiceuserList(val, "add_demand"); |
|
|
|
else this.getServiceuserList(val, "query_demand"); |
|
|
|
} else this.getServiceuserList(val, ""); |
|
|
|
}, |
|
|
|
|
|
|
|
handleAdd(addType) { |
|
|
|
this.addType = addType; |
|
|
@ -660,7 +655,6 @@ export default { |
|
|
|
async formatRowForm(addType) { |
|
|
|
this.addType = addType; |
|
|
|
const { form: row } = this; |
|
|
|
|
|
|
|
if (addType == "look") { |
|
|
|
this.finishServiceTime = |
|
|
|
(row.serviceStartTime && [ |
|
|
@ -680,7 +674,7 @@ export default { |
|
|
|
this.form.score = 5; |
|
|
|
} |
|
|
|
if (addType == "appoint" && row.serviceType) { |
|
|
|
const type = row.serviceType == "social_org" ? "add_demand" : ""; |
|
|
|
const type = row.categoryCode || "" |
|
|
|
await this.getServiceuserList(row.serviceType, type); |
|
|
|
} |
|
|
|
if (addType == "edit") { |
|
|
@ -936,22 +930,21 @@ export default { |
|
|
|
}, |
|
|
|
|
|
|
|
async getServiceuserList(serviceType, query) { |
|
|
|
if (!serviceType) return false; |
|
|
|
if (!serviceType) return; |
|
|
|
const { demandUserId } = this.form; |
|
|
|
const params = { |
|
|
|
serviceName: "", |
|
|
|
serviceType: serviceType, |
|
|
|
queryPurpose: query, |
|
|
|
serviceTypeId: query, |
|
|
|
serverOrgType: serviceType, |
|
|
|
businessType: "resi_service", |
|
|
|
}; |
|
|
|
await this.$http |
|
|
|
.post("/governance/userdemand/servicelist", params) |
|
|
|
.post("/actual/base/serviceitem/listServerOrg", params) |
|
|
|
.then(({ data: res }) => { |
|
|
|
if (res.code !== 0) { |
|
|
|
return this.$message.error(res.msg); |
|
|
|
} else { |
|
|
|
this.serviceOptiondList = res.data.filter( |
|
|
|
(item) => item.value != demandUserId |
|
|
|
); |
|
|
|
this.serviceOptiondList.push(...res.data) |
|
|
|
console.log( this.serviceOptiondList ); |
|
|
|
} |
|
|
|
}) |
|
|
|
.catch(() => { |
|
|
|