Browse Source

bug#373 转议题时间分类可以修改

feature
mk 2 years ago
parent
commit
481501447b
  1. 33
      src/views/modules/communityService/measure/info.vue
  2. 12
      src/views/modules/shequzhili/issue/cpts/issue-detail.vue
  3. 11
      src/views/modules/visual/cpts/line-chart.vue

33
src/views/modules/communityService/measure/info.vue

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

12
src/views/modules/shequzhili/issue/cpts/issue-detail.vue

@ -14,6 +14,8 @@
/> />
</h3> </h3>
<div class="m-detail-main"> <div class="m-detail-main">
<el-row>
<el-col :span="11">
<div class="m-info"> <div class="m-info">
<div <div
:class="[ :class="[
@ -230,8 +232,8 @@
<div class="line" @click="handleToEvaluation">查看全部</div> <div class="line" @click="handleToEvaluation">查看全部</div>
</div> </div>
</div> </div>
</el-col>
<div class="m-line"> <el-col :span="13"> <div class="m-line">
<div class="stat"> <div class="stat">
<div class="stat-item"> <div class="stat-item">
<!-- <div> <!-- <div>
@ -268,7 +270,11 @@
<div v-if="issueChartData.length > 0" class="m-chart"> <div v-if="issueChartData.length > 0" class="m-chart">
<line-chart :list="issueChartData" /> <line-chart :list="issueChartData" />
</div> </div>
</div> </div></el-col>
</el-row>
</div> </div>
<!-- <!--
显示关闭 显示关闭

11
src/views/modules/visual/cpts/line-chart.vue

@ -43,6 +43,7 @@ export default {
return { return {
iniLoading: false, iniLoading: false,
id, id,
myChart:{}
}; };
}, },
watch: { watch: {
@ -80,7 +81,7 @@ export default {
initCharts(date, data, data1) { initCharts(date, data, data1) {
console.log(this.id); console.log(this.id);
let div = document.getElementById(this.id); let div = document.getElementById(this.id);
let myChart = echarts.init(div); this.myChart = echarts.init(div);
var option = { var option = {
tooltip: { tooltip: {
trigger: "axis", trigger: "axis",
@ -166,10 +167,14 @@ export default {
}, },
], ],
}; };
myChart.setOption(option); this.myChart.setOption(option);
window.addEventListener("resize", () => myChartPieLeft.resize(), false); window.addEventListener("resize", () => this.myChart.resize());
}, },
}, },
beforeDestroy() {
window.removeEventListener('resize', this.myChart.resize);
}
}; };
</script> </script>

Loading…
Cancel
Save