Browse Source

合并featuredev

V1.0
PLUTO 2 years ago
parent
commit
5c3204e2eb
  1. 148
      src/views/dataBoard/overview/components/jdwgy.vue

148
src/views/dataBoard/overview/components/jdwgy.vue

@ -1,16 +1,7 @@
<template> <template>
<div class="m-subbox m-jdwgy"> <div class="m-subbox m-jdwgy">
<div class="table"> <div class="table">
<el-table <el-table :data="list" v-if="currentLevelData.orgLevel != 'grid' && peopleType != 'staffDepartment'" v-loading="loading" element-loading-background="rgba(0, 0, 0, 0.3)" max-height="190px" height="190px">
:data="list"
v-if="
currentLevelData.orgLevel != 'grid' && peopleType != 'staffDepartment'
"
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 label="序号" type="index" width="80" />
<el-table-column prop="orgName" width="120" label="组织名称" /> <el-table-column prop="orgName" width="120" label="组织名称" />
<el-table-column prop="name" width="120" label="姓名" /> <el-table-column prop="name" width="120" label="姓名" />
@ -27,82 +18,38 @@
</el-table-column> </el-table-column>
<el-table-column prop="operate" width="80" label="操作"> <el-table-column prop="operate" width="80" label="操作">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button @click="handleClick(scope.row)" type="text" size="small"> <el-button @click="handleClick(scope.row)" type="text" size="small"> 查看</el-button>
查看</el-button
>
</template> </template>
</el-table-column> </el-table-column>
<template slot="empty"> <template slot="empty">
<div <div style="width: 100%; height: 100%; text-align: center; padding-top: 50px; color: #ffffff">
style=" <img width="268px" height="128px" src="~@/assets/images/overview/zanwu.png" />
width: 100%;
height: 100%;
text-align: center;
padding-top: 50px;
color: #ffffff;
"
>
<img
width="268px"
height="128px"
src="~@/assets/images/overview/zanwu.png"
/>
<div class="zanwuText">暂无数据</div> <div class="zanwuText">暂无数据</div>
</div> </div>
</template> </template>
</el-table> </el-table>
<!-- 单位/组织 --> <!-- 单位/组织 -->
<el-table <el-table :data="unitList" v-if="currentLevelData.orgLevel != 'grid' && peopleType === 'staffDepartment'" v-loading="loading" element-loading-background="rgba(0, 0, 0, 0.3)" max-height="190px" height="190px">
:data="unitList"
v-if="
currentLevelData.orgLevel != 'grid' &&
peopleType === 'staffDepartment'
"
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 label="序号" type="index" width="80" />
<el-table-column prop="departmentName" label="单位名称" /> <el-table-column prop="departmentName" label="单位名称" />
<el-table-column prop="departmentDuty" label="职责" /> <el-table-column prop="departmentDuty" label="职责" />
<el-table-column prop="deptType" label="单位类型" /> <el-table-column prop="deptType" label="单位类型" />
<el-table-column prop="totalUser" label="总人数" /> <el-table-column prop="totalUser" label="总人数" />
<template slot="empty"> <template slot="empty">
<div <div style="width: 100%; height: 100%; text-align: center; padding-top: 50px; color: #ffffff">
style=" <img width="268px" height="128px" src="~@/assets/images/overview/zanwu.png" />
width: 100%;
height: 100%;
text-align: center;
padding-top: 50px;
color: #ffffff;
"
>
<img
width="268px"
height="128px"
src="~@/assets/images/overview/zanwu.png"
/>
<div class="zanwuText">暂无数据</div> <div class="zanwuText">暂无数据</div>
</div> </div>
</template> </template>
</el-table> </el-table>
<el-table <el-table v-if="currentLevelData.orgLevel == 'grid'" :data="wglist" v-loading="loading" max-height="190px" height="190px">
v-if="currentLevelData.orgLevel == 'grid'" <el-table-column label="序号" type="index" width="80" />
: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="name" width="140" label="组织名称" />
<el-table-column prop="type" width="90" label="类型"> <el-table-column prop="type" width="90" label="类型">
<template slot-scope="scope"> <template slot-scope="scope">
<span :style="'color:' + scope.row.type">{{ <span :style="'color:' + scope.row.type">{{ types[scope.row.type] }}</span>
types[scope.row.type]
}}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="houseNum" width="90" label="户数" /> <el-table-column prop="houseNum" width="90" label="户数" />
@ -112,26 +59,12 @@
<el-table-column prop="safetyNum" label="安全隐患" /> <el-table-column prop="safetyNum" label="安全隐患" />
<el-table-column prop="operate" width="80" label="操作"> <el-table-column prop="operate" width="80" label="操作">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button @click="handleClick(scope.row)" type="text" size="small"> <el-button @click="handleClick(scope.row)" type="text" size="small"> 查看</el-button>
查看</el-button
>
</template> </template>
</el-table-column> </el-table-column>
<template slot="empty"> <template slot="empty">
<div <div style="width: 100%; height: 100%; text-align: center; padding-top: 50px; color: #ffffff">
style=" <img width="268px" height="128px" src="~@/assets/images/overview/zanwu.png" />
width: 100%;
height: 100%;
text-align: center;
padding-top: 50px;
color: #ffffff;
"
>
<img
width="268px"
height="128px"
src="~@/assets/images/overview/zanwu.png"
/>
<div class="zanwuText">暂无数据</div> <div class="zanwuText">暂无数据</div>
</div> </div>
</template> </template>
@ -194,41 +127,21 @@ export default {
this.loading = true; this.loading = true;
if (this.currentLevelData.orgLevel == "grid") { if (this.currentLevelData.orgLevel == "grid") {
const personType = this.ifUnit ? "unit" : this.peopleType; const personType = this.ifUnit ? "unit" : this.peopleType;
this.$http this.$http.get("/actual/base/streetOverview/queryPersonnelGridGroup?personnelType=" + personType + "&level=" + this.currentLevelData.orgLevel + "&orgId=" + this.currentLevelData.orgId).then(({ data: { data } }) => {
.get( this.loading = false;
"/actual/base/streetOverview/queryPersonnelGridGroup?personnelType=" + this.wglist = data;
personType + this.$emit(
"&level=" + "setPoint",
this.currentLevelData.orgLevel + data.filter((item) => item.longitude && item.latitude)
"&orgId=" + );
this.currentLevelData.orgId });
)
.then(({ data: { data } }) => {
this.loading = false;
this.wglist = data;
this.$emit(
"setPoint",
data.filter((item) => item.longitude && item.latitude)
);
});
} else { } else {
this.$http this.$http.get("/actual/base/streetOverview/queryPersonnelGroup?level=" + this.currentLevelData.orgLevel + "&orgId=" + this.currentLevelData.orgId + "&personnelType=" + this.peopleType).then(({ data: { data } }) => {
.get( this.loading = false;
"/actual/base/streetOverview/queryPersonnelGroup?level=" + this.list = data.personnelInfoVOList;
this.currentLevelData.orgLevel + this.unitList = data.departmentInfoVOList ? data.departmentInfoVOList : [];
"&orgId=" + this.$emit("setNum", data.orgPersonnelVOList);
this.currentLevelData.orgId + });
"&personnelType=" +
this.peopleType
)
.then(({ data: { data } }) => {
this.loading = false;
this.list = data.personnelInfoVOList;
this.unitList = data.departmentInfoVOList
? data.departmentInfoVOList
: [];
this.$emit("setNum", data.orgPersonnelVOList);
});
} }
}, },
handleClick(item) { handleClick(item) {
@ -238,6 +151,7 @@ export default {
path: "/homeDetails/index", path: "/homeDetails/index",
query: { query: {
id: item.id, id: item.id,
typeB: this.peopleType,
}, },
}); });
} else { } else {
@ -255,11 +169,7 @@ export default {
}, },
}; };
</script> </script>
<style <style lang="scss" src="@/assets/scss/dataBoard/overview/index.scss" scoped></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" src="@/assets/scss/dataBoard/table.scss" scoped></style>
<style lang="scss" scoped> <style lang="scss" scoped>
/deep/ .table { /deep/ .table {

Loading…
Cancel
Save