|
|
@ -1,78 +1,48 @@ |
|
|
|
<template> |
|
|
|
<div |
|
|
|
class="personnel-portrait" |
|
|
|
v-loading="loading" |
|
|
|
element-loading-text="加载中..." |
|
|
|
element-loading-spinner="el-icon-loading" |
|
|
|
element-loading-background="rgba(0,0,0,0.5)" |
|
|
|
> |
|
|
|
<Tabs |
|
|
|
v-model="resultType" |
|
|
|
:list="resultTypeList" |
|
|
|
@changeVal="resultTypeChange" |
|
|
|
/> |
|
|
|
<div class="personnel-portrait" v-loading="loading" element-loading-text="加载中..." element-loading-spinner="el-icon-loading" element-loading-background="rgba(0,0,0,0.5)"> |
|
|
|
<Tabs v-model="resultType" :list="resultTypeList" @changeVal="resultTypeChange" /> |
|
|
|
<div class="screen"> |
|
|
|
<div class="txt">不满意人员画像</div> |
|
|
|
<el-select |
|
|
|
v-if="resultType == 'provinceAndSelf'" |
|
|
|
v-model="typeCondition" |
|
|
|
@change="getData" |
|
|
|
placeholder="请选择" |
|
|
|
class="select" |
|
|
|
popper-class="selectPopClass" |
|
|
|
> |
|
|
|
<el-option |
|
|
|
v-for="item in typeConditionList" |
|
|
|
:key="item.value" |
|
|
|
:label="item.label" |
|
|
|
:value="item.value" |
|
|
|
> |
|
|
|
</el-option> |
|
|
|
<el-select v-if="resultType == 'provinceAndSelf'" v-model="typeCondition" @change="getData" placeholder="请选择" class="select" popper-class="selectPopClass"> |
|
|
|
<el-option v-for="item in typeConditionList" :key="item.value" :label="item.label" :value="item.value"> </el-option> |
|
|
|
</el-select> |
|
|
|
</div> |
|
|
|
|
|
|
|
<div class="portrait"> |
|
|
|
<div class="tag yellow" v-if="gridName"> |
|
|
|
<div class="text">{{ gridName }}</div> |
|
|
|
<div :class="[gridName.length > 5 ? 'smallSize' : '', 'text']">{{ gridName }}</div> |
|
|
|
</div> |
|
|
|
<div class="tag blue" v-if="ageClassification"> |
|
|
|
<div class="text">{{ ageClassification }}</div> |
|
|
|
<div :class="[ageClassification.length > 5 ? 'smallSize' : '', 'text']">{{ ageClassification }}</div> |
|
|
|
</div> |
|
|
|
<div class="tag red" v-if="residentTagName"> |
|
|
|
<div class="text">{{ residentTagName }}</div> |
|
|
|
<div :class="[residentTagName.length > 5 ? 'smallSize' : '', 'text']">{{ residentTagName }}</div> |
|
|
|
</div> |
|
|
|
<div class="tag light" v-if="monthIncomeLevel"> |
|
|
|
<div class="text">{{ monthIncomeLevel }}</div> |
|
|
|
<div :class="[monthIncomeLevel.length > 5 ? 'smallSize' : '', 'text']">{{ monthIncomeLevel }}</div> |
|
|
|
</div> |
|
|
|
<div class="tag green" v-if="cultureName"> |
|
|
|
<div class="text">{{ cultureName }}</div> |
|
|
|
<div :class="[cultureName.length > 5 ? 'smallSize' : '', 'text']">{{ cultureName }}</div> |
|
|
|
</div> |
|
|
|
<div class="tag orange" v-if="marriageName"> |
|
|
|
<div class="text">{{ marriageName }}</div> |
|
|
|
<div :class="[marriageName.length > 5 ? 'smallSize' : '', 'text']">{{ marriageName }}</div> |
|
|
|
</div> |
|
|
|
<div class="tag purple" v-if="gender"> |
|
|
|
<div class="text"> |
|
|
|
{{ |
|
|
|
gender === "1" |
|
|
|
? "男" |
|
|
|
: gender === "2" |
|
|
|
? "女" |
|
|
|
: gender === "0" |
|
|
|
? "未知" |
|
|
|
: "" |
|
|
|
}} |
|
|
|
{{ gender === "1" ? "男" : gender === "2" ? "女" : gender === "0" ? "未知" : "" }} |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
|
|
|
|
<div class="btn" @click="gotopage"> |
|
|
|
<div> |
|
|
|
按画像匹配到同类:<span> |
|
|
|
<b>{{ matchPeopleNum ? matchPeopleNum : 0 }}</b |
|
|
|
>人</span |
|
|
|
> |
|
|
|
<div style="display: flex"> |
|
|
|
<div class="btn" @click="gotopage"> |
|
|
|
<div> |
|
|
|
按画像匹配到同类:<span> |
|
|
|
<b>{{ matchPeopleNum ? matchPeopleNum : 0 }}</b |
|
|
|
>人</span |
|
|
|
> |
|
|
|
</div> |
|
|
|
<i class="el-icon-arrow-right"></i> |
|
|
|
</div> |
|
|
|
<i class="el-icon-arrow-right"></i> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</template> |
|
|
@ -130,18 +100,13 @@ export default { |
|
|
|
this.getData(); |
|
|
|
}, |
|
|
|
gotopage() { |
|
|
|
this.$router.push( |
|
|
|
"/dataBoard/satisfactionEval/dissatisfiedPersonnel?searchParams=" + |
|
|
|
this.searchParams |
|
|
|
); |
|
|
|
this.$router.push("/dataBoard/satisfactionEval/dissatisfiedPersonnel?searchParams=" + this.searchParams); |
|
|
|
}, |
|
|
|
getDisKey() { |
|
|
|
this.$http |
|
|
|
.post("/sys/dict/data/dictlist", { dictType: "satisfaction_category" }) |
|
|
|
.then(({ data: { data } }) => { |
|
|
|
this.typeCondition = data[0].value; |
|
|
|
this.typeConditionList = data; |
|
|
|
}); |
|
|
|
this.$http.post("/sys/dict/data/dictlist", { dictType: "satisfaction_category" }).then(({ data: { data } }) => { |
|
|
|
this.typeCondition = data[0].value; |
|
|
|
this.typeConditionList = data; |
|
|
|
}); |
|
|
|
}, |
|
|
|
getData() { |
|
|
|
this.loading = true; |
|
|
@ -151,23 +116,18 @@ export default { |
|
|
|
queryType: this.resultType, |
|
|
|
category: this.resultType == "provinceAndSelf" ? this.typeCondition : null, |
|
|
|
}; |
|
|
|
this.$http |
|
|
|
.get( |
|
|
|
"/governance/satisfactionOverview/satisfactionCrowdPortrait?" + |
|
|
|
this.$paramsFormat(params) |
|
|
|
) |
|
|
|
.then(({ data: { data } }) => { |
|
|
|
this.gender = data.gender; |
|
|
|
this.marriageName = data.marriageName; |
|
|
|
this.ageClassification = data.ageClassification; |
|
|
|
this.cultureName = data.cultureName; |
|
|
|
this.gridName = data.gridName; |
|
|
|
this.monthIncomeLevel = data.monthIncomeLevel; |
|
|
|
this.residentTagName = data.residentTagName; |
|
|
|
this.matchPeopleNum = data.matchPeopleNum; |
|
|
|
this.loading = false; |
|
|
|
this.searchParams = JSON.stringify({ ...data, ...params }); |
|
|
|
}); |
|
|
|
this.$http.get("/governance/satisfactionOverview/satisfactionCrowdPortrait?" + this.$paramsFormat(params)).then(({ data: { data } }) => { |
|
|
|
this.gender = data.gender; |
|
|
|
this.marriageName = data.marriageName; |
|
|
|
this.ageClassification = data.ageClassification; |
|
|
|
this.cultureName = data.cultureName; |
|
|
|
this.gridName = data.gridName; |
|
|
|
this.monthIncomeLevel = data.monthIncomeLevel; |
|
|
|
this.residentTagName = data.residentTagName; |
|
|
|
this.matchPeopleNum = data.matchPeopleNum; |
|
|
|
this.loading = false; |
|
|
|
this.searchParams = JSON.stringify({ ...data, ...params }); |
|
|
|
}); |
|
|
|
}, |
|
|
|
}, |
|
|
|
}; |
|
|
@ -239,6 +199,10 @@ $purple: #6642fd; |
|
|
|
align-items: center; |
|
|
|
justify-content: center; |
|
|
|
border-radius: 50%; |
|
|
|
text-align: center; |
|
|
|
} |
|
|
|
.smallSize { |
|
|
|
font-size: 10px; |
|
|
|
} |
|
|
|
|
|
|
|
&:after { |
|
|
@ -359,7 +323,7 @@ $purple: #6642fd; |
|
|
|
} |
|
|
|
|
|
|
|
.btn { |
|
|
|
width: 240px; |
|
|
|
min-width: 240px; |
|
|
|
height: 46px; |
|
|
|
border: 1px solid #125aaa; |
|
|
|
border-radius: 23px; |
|
|
@ -367,7 +331,7 @@ $purple: #6642fd; |
|
|
|
font-weight: 400; |
|
|
|
color: #ffffff; |
|
|
|
line-height: 46px; |
|
|
|
display: flex; |
|
|
|
display: inline-flex; |
|
|
|
align-items: center; |
|
|
|
justify-content: space-between; |
|
|
|
padding: 0 20px; |
|
|
|