2022-01-22 15:11:07 +08:00
|
|
|
<template>
|
|
|
|
|
<div class="Organization">
|
|
|
|
|
<div class="title">网格人员</div>
|
2022-02-15 17:32:02 +08:00
|
|
|
<div class="user-content" v-for="(item, index) in dataInfo.parentGirdMembers" :key="index" @click="viewUser(item.wxUserIdId)">
|
2022-02-11 10:53:43 +08:00
|
|
|
<div>
|
|
|
|
|
<!-- <image :src="item.photo" alt="" mode="aspectFill" v-if="item.photo" /> -->
|
|
|
|
|
<img :src="item.photo" alt="" v-if="item.photo">
|
|
|
|
|
<img src="./components/img/big-user.png" alt="" v-else>
|
|
|
|
|
</div>
|
2022-01-22 15:11:07 +08:00
|
|
|
<div class="right">
|
2022-02-10 15:21:08 +08:00
|
|
|
<div class="name">
|
2022-05-05 17:19:30 +08:00
|
|
|
<AiOpenData v-if="item.wxUserId" type="userName" :openid="item.wxUserId"/>
|
2022-02-10 15:21:08 +08:00
|
|
|
</div>
|
2022-05-05 17:19:30 +08:00
|
|
|
<div flex class="spb">
|
|
|
|
|
<div class="gird" v-text="item.checkType == 2 ? '网格长' : '网格员'"/>
|
|
|
|
|
<div class="gird dark" v-text="item.label"/>
|
|
|
|
|
</div>
|
|
|
|
|
<p>{{ item.girdName }}</p>
|
2022-01-22 15:11:07 +08:00
|
|
|
</div>
|
|
|
|
|
</div>
|
2022-02-15 17:32:02 +08:00
|
|
|
<div class="user-content user-item" v-for="(item, index) in dataInfo.girdMembers" :key="index" @click="viewUser(item.wxUserIdId)">
|
2022-05-05 17:19:30 +08:00
|
|
|
<div>
|
2022-02-11 10:53:43 +08:00
|
|
|
<!-- <image :src="item.photo" alt="" mode="aspectFill" v-if="item.photo" /> -->
|
|
|
|
|
<img :src="item.photo" alt="" v-if="item.photo">
|
|
|
|
|
<img src="./components/img/big-user.png" alt="" v-else>
|
|
|
|
|
</div>
|
2022-01-22 15:11:07 +08:00
|
|
|
<div class="right">
|
2022-02-10 11:55:22 +08:00
|
|
|
<div class="name">
|
2022-05-05 17:19:30 +08:00
|
|
|
<div flex>
|
|
|
|
|
<AiOpenData v-if="item.wxUserId" type="userName" :openid="item.wxUserId"/>
|
|
|
|
|
<div class="gird dark" v-text="item.label"/>
|
|
|
|
|
</div>
|
|
|
|
|
<span class="gird">{{ item.checkType == 2 ? '网格长' : '网格员' }}</span>
|
|
|
|
|
<span class="num" v-if="item.checkType == 1">家庭数({{ item.residentNumber }})</span>
|
2022-02-07 17:42:52 +08:00
|
|
|
</div>
|
|
|
|
|
<div class="gird-name">
|
2022-05-05 17:19:30 +08:00
|
|
|
<span class="text">{{ item.girdName }}</span>
|
2022-02-15 17:32:02 +08:00
|
|
|
<span class="family-btn" @click.stop="toFamily(item)" v-if="item.checkType == 1">责任家庭 ></span>
|
2022-01-22 15:11:07 +08:00
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
2022-05-05 17:19:30 +08:00
|
|
|
<AiEmpty description="暂无数据" class="emptyWrap"
|
|
|
|
|
v-if="dataInfo.parentGirdMembers && !dataInfo.parentGirdMembers.length && !dataInfo.girdMembers.length"></AiEmpty>
|
2022-01-22 15:11:07 +08:00
|
|
|
<div class="pad-b112"></div>
|
|
|
|
|
</div>
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
<script>
|
2022-05-05 17:19:30 +08:00
|
|
|
import {mapActions} from 'vuex'
|
|
|
|
|
|
2022-01-22 15:11:07 +08:00
|
|
|
export default {
|
|
|
|
|
data() {
|
|
|
|
|
return {
|
|
|
|
|
userGird: {},
|
|
|
|
|
dataInfo: {},
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
props: ['params'],
|
|
|
|
|
onShow() {
|
|
|
|
|
document.title = '网格管理'
|
2022-02-15 16:20:44 +08:00
|
|
|
uni.$on('updateList', () => {
|
|
|
|
|
this.current = 1
|
|
|
|
|
this.getGirdUserList()
|
|
|
|
|
})
|
2022-01-22 15:11:07 +08:00
|
|
|
},
|
|
|
|
|
mounted() {
|
|
|
|
|
this.userGird = this.params
|
|
|
|
|
this.getGirdUserList()
|
|
|
|
|
uni.$on('goback', (res) => {
|
|
|
|
|
this.userGird = res
|
|
|
|
|
this.getGirdUserList()
|
2022-05-05 17:19:30 +08:00
|
|
|
})
|
2022-01-22 15:11:07 +08:00
|
|
|
},
|
|
|
|
|
methods: {
|
2022-02-15 17:07:05 +08:00
|
|
|
...mapActions(['injectJWeixin', 'wxInvoke']),
|
2022-01-22 15:11:07 +08:00
|
|
|
getGirdUserList() {
|
|
|
|
|
this.$http.post(`/app/appgirdmemberinfo/listGirdMemberByGirdId?girdId=${this.userGird.id}`).then((res) => {
|
|
|
|
|
if (res.code == 0) {
|
|
|
|
|
this.dataInfo = res.data
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
},
|
|
|
|
|
linkTo(url) {
|
|
|
|
|
uni.navigateTo({url})
|
2022-02-07 17:42:52 +08:00
|
|
|
},
|
|
|
|
|
viewUser(userId) {
|
2022-02-15 17:07:05 +08:00
|
|
|
this.injectJWeixin('openUserProfile').then(() => {
|
|
|
|
|
this.wxInvoke([
|
|
|
|
|
'openUserProfile',
|
|
|
|
|
{
|
|
|
|
|
type: 1,
|
|
|
|
|
userid: userId,
|
|
|
|
|
},
|
|
|
|
|
() => 0,
|
|
|
|
|
])
|
|
|
|
|
})
|
2022-02-09 10:45:52 +08:00
|
|
|
},
|
|
|
|
|
toFamily(item) {
|
|
|
|
|
uni.navigateTo({url: `./FamilyList?id=${item.id}&girdId=${this.userGird.id}`})
|
2022-01-22 15:11:07 +08:00
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
}
|
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
<style lang="scss" scoped>
|
|
|
|
|
.Organization {
|
|
|
|
|
background-color: #f5f5f5;
|
2022-05-05 17:19:30 +08:00
|
|
|
|
|
|
|
|
.title {
|
2022-01-22 15:11:07 +08:00
|
|
|
font-size: 38px;
|
|
|
|
|
font-family: PingFangSC-Semibold, PingFang SC;
|
|
|
|
|
font-weight: 600;
|
|
|
|
|
color: #333;
|
|
|
|
|
line-height: 52px;
|
|
|
|
|
padding-left: 32px;
|
|
|
|
|
margin-bottom: 32px;
|
|
|
|
|
}
|
2022-05-05 17:19:30 +08:00
|
|
|
|
|
|
|
|
.user-content {
|
2022-01-22 15:11:07 +08:00
|
|
|
width: calc(100% - 64px);
|
|
|
|
|
margin: 0 0 32px 32px;
|
|
|
|
|
background-color: #fff;
|
|
|
|
|
padding: 32px;
|
|
|
|
|
box-sizing: border-box;
|
|
|
|
|
display: flex;
|
2022-05-05 17:19:30 +08:00
|
|
|
|
|
|
|
|
img {
|
2022-01-22 15:11:07 +08:00
|
|
|
width: 200px;
|
|
|
|
|
height: 200px;
|
|
|
|
|
margin-right: 32px;
|
|
|
|
|
}
|
2022-05-05 17:19:30 +08:00
|
|
|
|
|
|
|
|
image {
|
2022-01-22 15:11:07 +08:00
|
|
|
width: 200px;
|
|
|
|
|
height: 200px;
|
|
|
|
|
margin-right: 32px;
|
|
|
|
|
}
|
2022-05-05 17:19:30 +08:00
|
|
|
|
|
|
|
|
.right {
|
2022-01-22 15:11:07 +08:00
|
|
|
width: 100%;
|
2022-05-05 17:19:30 +08:00
|
|
|
|
|
|
|
|
.name {
|
2022-01-22 15:11:07 +08:00
|
|
|
font-size: 32px;
|
|
|
|
|
font-family: PingFangSC-Medium, PingFang SC;
|
|
|
|
|
font-weight: 500;
|
|
|
|
|
color: #333;
|
|
|
|
|
line-height: 44px;
|
|
|
|
|
margin-bottom: 12px;
|
|
|
|
|
}
|
2022-05-05 17:19:30 +08:00
|
|
|
|
|
|
|
|
.gird {
|
2022-01-22 15:11:07 +08:00
|
|
|
display: inline-block;
|
|
|
|
|
line-height: 44px;
|
|
|
|
|
background: #E8EFFF;
|
|
|
|
|
border-radius: 8px;
|
|
|
|
|
padding: 0 8px;
|
|
|
|
|
font-size: 26px;
|
|
|
|
|
font-family: PingFangSC-Regular, PingFang SC;
|
|
|
|
|
color: #26F;
|
|
|
|
|
margin-bottom: 12px;
|
2022-05-05 17:19:30 +08:00
|
|
|
|
|
|
|
|
&.dark {
|
|
|
|
|
color: #fff;
|
|
|
|
|
background: #26f;
|
|
|
|
|
margin-left: 16px;
|
|
|
|
|
}
|
2022-01-22 15:11:07 +08:00
|
|
|
}
|
2022-05-05 17:19:30 +08:00
|
|
|
|
|
|
|
|
p {
|
2022-01-22 15:11:07 +08:00
|
|
|
font-size: 26px;
|
|
|
|
|
font-family: PingFangSC-Regular, PingFang SC;
|
|
|
|
|
color: #666;
|
|
|
|
|
line-height: 36px;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
2022-05-05 17:19:30 +08:00
|
|
|
|
|
|
|
|
.user-item {
|
|
|
|
|
img {
|
2022-01-22 15:11:07 +08:00
|
|
|
width: 96px;
|
|
|
|
|
height: 96px;
|
|
|
|
|
border-radius: 50%;
|
|
|
|
|
}
|
2022-05-05 17:19:30 +08:00
|
|
|
|
|
|
|
|
image {
|
2022-01-22 15:11:07 +08:00
|
|
|
width: 96px;
|
|
|
|
|
height: 96px;
|
|
|
|
|
border-radius: 50%;
|
|
|
|
|
}
|
2022-05-05 17:19:30 +08:00
|
|
|
|
|
|
|
|
.gird {
|
2022-01-22 15:11:07 +08:00
|
|
|
display: inline-block;
|
|
|
|
|
margin-left: 16px;
|
2022-05-05 17:19:30 +08:00
|
|
|
margin-bottom: 0 !important;
|
2022-01-22 15:11:07 +08:00
|
|
|
}
|
2022-05-05 17:19:30 +08:00
|
|
|
|
|
|
|
|
.name {
|
|
|
|
|
margin-bottom: 8px !important;
|
2022-01-22 15:11:07 +08:00
|
|
|
}
|
|
|
|
|
}
|
2022-05-05 17:19:30 +08:00
|
|
|
|
|
|
|
|
.family-btn {
|
2022-01-22 15:11:07 +08:00
|
|
|
font-size: 26px;
|
|
|
|
|
font-family: PingFangSC-Regular, PingFang SC;
|
|
|
|
|
color: #3975C6;
|
|
|
|
|
line-height: 36px;
|
|
|
|
|
float: right;
|
|
|
|
|
}
|
2022-05-05 17:19:30 +08:00
|
|
|
|
|
|
|
|
.num {
|
2022-02-07 17:42:52 +08:00
|
|
|
font-size: 26px;
|
|
|
|
|
font-family: PingFangSC-Regular, PingFang SC;
|
|
|
|
|
line-height: 36px;
|
|
|
|
|
float: right;
|
|
|
|
|
}
|
2022-05-05 17:19:30 +08:00
|
|
|
|
|
|
|
|
.pad-b112 {
|
2022-01-22 15:11:07 +08:00
|
|
|
padding-bottom: 112px;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
</style>
|