|
|
@ -1,16 +1,17 @@ |
|
|
|
<template> |
|
|
|
<div class="m-subbox m-jdwgy"> |
|
|
|
<div class="table"> |
|
|
|
<el-table :data="list" v-if="currentLevelData.orgLevel != 'grid'" v-loading="loading" element-loading-background="rgba(0, 0, 0, 0.3)" max-height="190px" height="190px"> |
|
|
|
<el-table-column label="序号" type="index" width="80" /> |
|
|
|
<el-table-column prop="orgName" width="120" label="组织名称" /> |
|
|
|
<el-table-column prop="name" width="120" label="姓名" /> |
|
|
|
<el-table :data="list" v-if="currentLevelData.orgLevel != 'grid'" v-loading="loading" |
|
|
|
element-loading-background="rgba(0, 0, 0, 0.3)" max-height="190px" height="190px"> |
|
|
|
<el-table-column label="序号" type="index" width="80"/> |
|
|
|
<el-table-column prop="orgName" width="120" label="组织名称"/> |
|
|
|
<el-table-column prop="name" width="120" label="姓名"/> |
|
|
|
<el-table-column prop="gender" width="120" label="性别"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
{{ genders[scope.row.gender] }} |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column prop="age" width="120" label="年龄" /> |
|
|
|
<el-table-column prop="age" width="120" label="年龄"/> |
|
|
|
<el-table-column prop="mobile" label="电话"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
{{ $sensitive(scope.row.mobile, 3, 7) }} |
|
|
@ -18,26 +19,27 @@ |
|
|
|
</el-table-column> |
|
|
|
<el-table-column prop="operate" width="80" label="操作"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<el-button @click="handleClick(scope.row)" type="text" size="small"> 查看 </el-button> |
|
|
|
<el-button @click="handleClick(scope.row)" type="text" size="small"> 查看</el-button> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table> |
|
|
|
<el-table v-if="currentLevelData.orgLevel == 'grid'" :data="wglist" v-loading="loading" max-height="190px" height="190px"> |
|
|
|
<el-table-column label="序号" type="index" width="50" /> |
|
|
|
<el-table-column prop="name" width="140" label="微网格" /> |
|
|
|
<el-table v-if="currentLevelData.orgLevel == 'grid'" :data="wglist" v-loading="loading" max-height="190px" |
|
|
|
height="190px"> |
|
|
|
<el-table-column label="序号" type="index" width="50"/> |
|
|
|
<el-table-column prop="name" width="140" label="微网格"/> |
|
|
|
<el-table-column prop="type" width="90" label="类型"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<span :style="'color:' + scope.row.type">{{ types[scope.row.type] }}</span> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column prop="houseNum" width="90" label="户数" /> |
|
|
|
<el-table-column prop="demandNum" width="90" label="需求" /> |
|
|
|
<el-table-column prop="eventNum" width="90" label="事件" /> |
|
|
|
<el-table-column prop="importanceNum" label="重点人群" /> |
|
|
|
<el-table-column prop="safetyNum" label="安全隐患" /> |
|
|
|
<el-table-column prop="houseNum" width="90" label="户数"/> |
|
|
|
<el-table-column prop="demandNum" width="90" label="需求"/> |
|
|
|
<el-table-column prop="eventNum" width="90" label="事件"/> |
|
|
|
<el-table-column prop="importanceNum" label="重点人群"/> |
|
|
|
<el-table-column prop="safetyNum" label="安全隐患"/> |
|
|
|
<el-table-column prop="operate" width="80" label="操作"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<el-button @click="handleClick(scope.row)" type="text" size="small"> 查看 </el-button> |
|
|
|
<el-button @click="handleClick(scope.row)" type="text" size="small"> 查看</el-button> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table> |
|
|
@ -62,40 +64,46 @@ export default { |
|
|
|
list: [], |
|
|
|
wglist: [], |
|
|
|
genders: ["未知", "男", "女"], |
|
|
|
types: { red: "红", yellow: "黄", green: "绿色" }, |
|
|
|
types: {red: "红", yellow: "黄", green: "绿色"}, |
|
|
|
chooseName: {}, |
|
|
|
loading: false, |
|
|
|
}; |
|
|
|
}, |
|
|
|
watch: { |
|
|
|
peopleType(val) { |
|
|
|
this.getData(val, this.currentLevelData.orgLevel, this.currentLevelData.orgId); |
|
|
|
this.getData(); |
|
|
|
}, |
|
|
|
currentLevelData(val) { |
|
|
|
if (val.orgId) { |
|
|
|
this.getData(this.peopleType, val.orgLevel, val.orgId); |
|
|
|
this.getData(); |
|
|
|
} |
|
|
|
}, |
|
|
|
}, |
|
|
|
mounted() { |
|
|
|
if (this.currentLevelData.orgId) { |
|
|
|
this.getData(this.peopleType, this.currentLevelData.orgLevel, this.currentLevelData.orgId); |
|
|
|
this.getData(); |
|
|
|
} |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
getData(peopleType, level = "", orgId = "") { |
|
|
|
getData(level = "", orgId = "") { |
|
|
|
this.loading = true; |
|
|
|
if (level == "grid") { |
|
|
|
this.$http.get("/actual/base/streetOverview/queryPersonnelGridGroup?personnelType=" + peopleType + "&level=" + level + "&orgId=" + orgId).then(({ data: { data } }) => { |
|
|
|
this.$http.get("/actual/base/streetOverview/queryPersonnelGridGroup?personnelType=" + |
|
|
|
this.peopleType + |
|
|
|
"&level=" + this.currentLevelData.orgLevel + |
|
|
|
"&orgId=" + this.currentLevelData.orgId).then(({data: {data}}) => { |
|
|
|
this.loading = false; |
|
|
|
this.wglist = data; |
|
|
|
this.$emit( |
|
|
|
"setPoint", |
|
|
|
data.filter((item) => item.longitude && item.latitude) |
|
|
|
"setPoint", |
|
|
|
data.filter((item) => item.longitude && item.latitude) |
|
|
|
); |
|
|
|
}); |
|
|
|
} else { |
|
|
|
this.$http.get("/actual/base/streetOverview/queryPersonnelGroup?level=" + level + "&orgId=" + orgId + "&personnelType=" + peopleType).then(({ data: { data } }) => { |
|
|
|
this.$http.get("/actual/base/streetOverview/queryPersonnelGroup?level=" + |
|
|
|
this.currentLevelData.orgLevel + "&orgId=" + |
|
|
|
this.currentLevelData.orgId + "&personnelType=" + |
|
|
|
this.peopleType).then(({data: {data}}) => { |
|
|
|
this.loading = false; |
|
|
|
this.list = data.personnelInfoVOList; |
|
|
|
this.$emit("setNum", data.orgPersonnelVOList); |
|
|
@ -126,11 +134,12 @@ export default { |
|
|
|
<style lang="scss" src="@/assets/scss/dataBoard/overview/index.scss" scoped></style> |
|
|
|
<style lang="scss" src="@/assets/scss/dataBoard/table.scss" scoped></style> |
|
|
|
<style lang="scss" scoped> |
|
|
|
/deep/.table { |
|
|
|
/deep/ .table { |
|
|
|
.el-table { |
|
|
|
td { |
|
|
|
padding: 0 !important; |
|
|
|
} |
|
|
|
|
|
|
|
th { |
|
|
|
padding: 6px 0 4px !important; |
|
|
|
} |
|
|
|