网格调整

This commit is contained in:
liuye
2022-07-01 17:52:34 +08:00
parent 85a52d3d9f
commit b8379ed118
3 changed files with 169 additions and 152 deletions

View File

@@ -1,16 +1,8 @@
<template> <template>
<div class="AddMerchan"> <div class="AddMerchan">
<div class="search"> <AiTopFixed>
<div class="left"> <u-search placeholder="请输入店名、店主、电话" :show-action="false" v-model="keyword" @search="current=1,getList()"/>
<AiAreaPicker v-model="areaId" :areaId="user.areaId" @select="areaSelect" :name.sync="areaName" style="color: #666"> </AiTopFixed>
<u-icon name="map-fill" color="#3192F4" size="20px" style="vertical-align: text-bottom"></u-icon>
<span style="margin-left: 4px" v-if="areaName">{{ areaName }}</span>
<span v-else>请选择</span>
<u-icon name="arrow-down" color="#666" size="28" style="margin-left: 4px" />
</AiAreaPicker>
</div>
<u-search v-model="value" placeholder:clearabled="true" placeholder="请输入姓名/身份证/手机号" :show-action="false" bg-color="#F5F5F5" search-icon-color="#999" color="#999" height="58" @search="getListInit" @clear="value='',getListInit"></u-search>
</div>
<div class="userList" v-if="list.length"> <div class="userList" v-if="list.length">
<ul v-for="(item,index) in list" :key="index"> <ul v-for="(item,index) in list" :key="index">
<li class="main"> <li class="main">
@@ -20,7 +12,7 @@
<img src="./components/img/xzh.png" alt="" class="checkbox" v-else @click="userClick(index)"> <img src="./components/img/xzh.png" alt="" class="checkbox" v-else @click="userClick(index)">
</div> </div>
<div class="userInfo"> <div class="userInfo">
<div> <!-- <div>
<img :src="item.photo" alt="" class="userImg" v-if="item.photo"> <img :src="item.photo" alt="" class="userImg" v-if="item.photo">
<img src="./components/img/user-img.png" alt="" class="userImg" v-else> <img src="./components/img/user-img.png" alt="" class="userImg" v-else>
</div> </div>
@@ -31,6 +23,18 @@
</div> </div>
<div class="idCard">{{item.idNumber && item.idNumber.replace(/^(\d{6})\d{8}(.{4}$)/g, `$1${Array(9).join('*')}$2`)}}</div> <div class="idCard">{{item.idNumber && item.idNumber.replace(/^(\d{6})\d{8}(.{4}$)/g, `$1${Array(9).join('*')}$2`)}}</div>
<div class="address">{{item.currentAreaName || '' }}{{ item.currentAddress || '' }}</div> <div class="address">{{item.currentAreaName || '' }}{{ item.currentAddress || '' }}</div>
</div> -->
<div class="item-title">
<img src="./components/img/xz.png" alt="">
<p>采苓岩茶烟酒专营店</p>
</div>
<div class="info">
<img src="./components/img/xz.png" alt="">
<div>林轶峰 18600882921</div>
</div>
<div class="info">
<img src="./components/img/xz.png" alt="">
<div>陕西省西安市新城区中山门街道168号陕西省西安市新城区中山门街道168号</div>
</div> </div>
</div> </div>
</div> </div>
@@ -39,9 +43,10 @@
</div> </div>
<AiEmpty description="暂无数据" class="emptyWrap" v-if="!list.length"></AiEmpty> <AiEmpty description="暂无数据" class="emptyWrap" v-if="!list.length"></AiEmpty>
<div style="height:70px;"></div> <div style="height:70px;"></div>
<div class="btn"> <!-- <div class="btn">
<div class="handleCheck" @click="confirm">确定选择</div> <div class="handleCheck" @click="confirm">确定选择</div>
</div> </div> -->
<div class="footer" @click="confirm">确定选择</div>
</div> </div>
</template> </template>
@@ -123,7 +128,7 @@ export default {
this.girdId = option.girdId this.girdId = option.girdId
}, },
onShow() { onShow() {
document.title = '新增责任家庭' document.title = '责任商户'
this.getList() this.getList()
}, },
onReachBottom() { onReachBottom() {
@@ -135,100 +140,92 @@ export default {
<style lang="scss" scoped> <style lang="scss" scoped>
.AddMerchan { .AddMerchan {
.search{
width: 100%;
height: 112px;
padding: 32px;
box-sizing: border-box;
background: #FFF;
display: flex;
margin-bottom: 8px;
.left{
width: calc(100% - 450px);
}
}
.userList { .userList {
width: 100%; width: 100%;
background-color: #FFFFFF ; margin-top: 24px;
ul { ul {
padding-left: 0px; padding: 0 32px 0 0;
li { li {
list-style-type: none; list-style-type: none;
.user { .user {
display: flex;
justify-content: flex-start;
padding-top: 24px;
padding-left: 32px;
height: 100%;
.checkbox{
margin-top: 20px;
margin-right: 32px;
width: 48px;
height: 48px;
}
.userInfo {
display: flex; display: flex;
justify-content: flex-start; justify-content: flex-start;
border-bottom: 1px solid #E4E5E6; padding-top: 24px;
padding-right: 48px; padding-left: 32px;
width: calc(100% - 100px); height: 100%;
.userImg { .checkbox{
margin-right: 32px; margin-top: 20px;
width: 80px; margin-right: 32px;
height: 80px; width: 48px;
border-radius: 50%; height: 48px;
} }
.info { .userInfo {
width: calc(100% - 120px); width: 100%;
padding-bottom: 32px; background: #FFF;
.name { border-radius: 16px;
display: flex; padding: 32px 24px 32px 32px;
justify-content: space-between; box-sizing: border-box;
font-size: 32px; margin-bottom: 30px;
margin-bottom: 8px; .item-title{
.user-name { margin-bottom: 32px;
font-weight: 800; img{
width: 72px;
height: 72px;
margin-right: 16px;
vertical-align: middle;
}
p{
display: inline-block;
width: 400px;
font-size: 32px;
font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
color: #000;
line-height: 32px;
}
span{
display: inline-block;
width: calc(100% - 488px);
text-align: right;
font-size: 24px;
font-family: PingFangSC-Regular, PingFang SC;
color: #999;
line-height: 24px;
}
} }
.user-tel { .info{
font-size: 26px; img{
color: #999999 ; width: 28px;
height: 28px;
margin-right: 16px;
}
div{
display: inline-block;
width: calc(100% - 44px);
word-break: break-all;
font-size: 28px;
font-family: PingFangSC-Regular, PingFang SC;
color: #333;
line-height: 40px;
vertical-align: text-top;
}
} }
} }
.idCard {
margin-bottom: 16px;
font-size: 26px;
color: #999999;
}
.address {
max-width: 100%;
word-break:break-all;
font-size: 26px;
color: #999999;
}
} }
}
}
} }
} }
} }
.btn { .footer {
position: fixed; position: fixed;
left: 0px;
bottom: 0px; bottom: 0px;
right: 0px;
width: 100%; width: 100%;
height: 120px; height: 112px;
background-color: #F3F6F9; background-color: #1365DD;
.handleCheck { line-height: 112px;
position: fixed; text-align: center;
bottom: 18px; font-size: 36px;
right: 34px; color: #FFFFFF;
width: 192px;
height: 80px;
line-height: 80px;
text-align: center;
background-color: #1365DD;
color: #FFFFFF;
}
} }
} }
</style> </style>

View File

@@ -1,5 +1,5 @@
<template> <template>
<div class="AppMerchanGrid"> <div class="AppMerchanGird">
<template v-if="isGridMember"> <template v-if="isGridMember">
<div class="pad-t32" /> <div class="pad-t32" />
<div class="select-gird" flex> <div class="select-gird" flex>
@@ -19,8 +19,10 @@
<img src="./components/img/big-user.png" alt="" v-else> <img src="./components/img/big-user.png" alt="" v-else>
</div> </div>
<div class="right"> <div class="right">
<div class="name">{{ item.name }}</div> <div class="name">{{ item.name }}
<div class="gird">{{ item.checkType == 2 ? '网格长' : '网格员' }}</div> <div class="gird">{{ item.checkType == 2 ? '网格长' : '网格员' }}</div>
<span class="family-btn" @click.stop="linkTo(`./merchanList?id=${item.id}&girdId=${userGird.id}`)">责任商户 ></span>
</div>
<p>{{ item.girdName }}</p> <p>{{ item.girdName }}</p>
</div> </div>
</div> </div>
@@ -33,7 +35,7 @@
<div class="right"> <div class="right">
<div class="name">{{ item.name }} <div class="name">{{ item.name }}
<span class="gird">{{ item.checkType == 2 ? '网格长' : '网格员' }}</span> <span class="gird">{{ item.checkType == 2 ? '网格长' : '网格员' }}</span>
<span class="family-btn" @click.stop="linkTo(`./FamilyList?id=${item.id}&girdId=${userGird.id}`)" v-if="item.checkType == 1">责任家庭 ></span> <span class="family-btn" @click.stop="linkTo(`./merchanList?id=${item.id}&girdId=${userGird.id}`)">责任商户 ></span>
</div> </div>
<p>{{ item.girdName }} </p> <p>{{ item.girdName }} </p>
</div> </div>
@@ -53,6 +55,8 @@
<script> <script>
import {mapState} from 'vuex' import {mapState} from 'vuex'
export default { export default {
name: 'AppMerchanGird',
appName: '网格构成',
data() { data() {
return { return {
dataInfo: {}, dataInfo: {},
@@ -72,8 +76,7 @@ export default {
this.handleSelectGird(this.user.gridInfo) this.handleSelectGird(this.user.gridInfo)
}, },
onShow() { onShow() {
document.title = '网格管理' document.title = '网格构成'
}, },
mounted() { mounted() {
this.getGirdUserList() this.getGirdUserList()
@@ -107,7 +110,7 @@ export default {
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.AppMerchanGrid { .AppMerchanGird {
background-color: #f5f5f5; background-color: #f5f5f5;
.title { .title {

View File

@@ -1,7 +1,10 @@
<template> <template>
<div class="merchanList"> <div class="merchanList">
<AiTopFixed>
<u-search placeholder="请输入店名、店主、电话" :show-action="false" v-model="keyword" @search="current=1,getList()"/>
</AiTopFixed>
<div class="title"> <div class="title">
<div>列表({{ total }})</div> <div>户列表({{ total }})</div>
<div v-if="list.length"> <div v-if="list.length">
<span style="font-size: 14px; color: #2979ff;" @click="changeType" v-if="edit">修改</span> <span style="font-size: 14px; color: #2979ff;" @click="changeType" v-if="edit">修改</span>
<span style="font-size: 14px; color: #2979ff;" @click="edit = true" v-else>取消</span> <span style="font-size: 14px; color: #2979ff;" @click="edit = true" v-else>取消</span>
@@ -15,8 +18,8 @@
<img src="./components/img/xz.png" alt="" class="checkbox" v-if="!item.checked" @click="userClick(index)"> <img src="./components/img/xz.png" alt="" class="checkbox" v-if="!item.checked" @click="userClick(index)">
<img src="./components/img/xzh.png" alt="" class="checkbox" v-else @click="userClick(index)"> <img src="./components/img/xzh.png" alt="" class="checkbox" v-else @click="userClick(index)">
</div> </div>
<div class="info"> <div class="item-info">
<div> <!-- <div>
<img :src="item.photo" class="userImg" v-if="item.photo"> <img :src="item.photo" class="userImg" v-if="item.photo">
<img src="./components/img/user-img.png" alt="" class="userImg" v-else> <img src="./components/img/user-img.png" alt="" class="userImg" v-else>
</div> </div>
@@ -27,6 +30,18 @@
</div> </div>
<div class="idCard">{{ item.idNumber && item.idNumber.replace(/(.{6}).*(.{4})/, "$1********$2") }}</div> <div class="idCard">{{ item.idNumber && item.idNumber.replace(/(.{6}).*(.{4})/, "$1********$2") }}</div>
<div class="address">{{ item.currentAreaName || '' }}{{ item.currentAddress || '' }}</div> <div class="address">{{ item.currentAreaName || '' }}{{ item.currentAddress || '' }}</div>
</div> -->
<div class="item-title">
<img src="./components/img/xz.png" alt="">
<p>采苓岩茶烟酒专营店</p>
</div>
<div class="info">
<img src="./components/img/xz.png" alt="">
<div>林轶峰 18600882921</div>
</div>
<div class="info">
<img src="./components/img/xz.png" alt="">
<div>陕西省西安市新城区中山门街道168号陕西省西安市新城区中山门街道168号</div>
</div> </div>
</div> </div>
</div> </div>
@@ -63,7 +78,7 @@ export default {
}) })
}, },
toAddFamily() { toAddFamily() {
uni.navigateTo({url: `./AddFamily?id=${this.userId}&girdId=${this.girdId}`}) uni.navigateTo({url: `./AddMerchan?id=${this.userId}&girdId=${this.girdId}`})
}, },
userClick(index) { userClick(index) {
this.list[index].checked = !this.list[index].checked this.list[index].checked = !this.list[index].checked
@@ -103,7 +118,7 @@ export default {
this.girdId = option.girdId this.girdId = option.girdId
}, },
onShow() { onShow() {
document.title = '责任家庭' document.title = '责任商户'
this.getList() this.getList()
uni.$on('updateList', () => { uni.$on('updateList', () => {
this.current = 1 this.current = 1
@@ -133,8 +148,7 @@ export default {
padding-bottom: 112px; padding-bottom: 112px;
ul { ul {
padding-left: 32px; padding: 0 32px;
background-color: #fff;
li { li {
list-style-type: none; list-style-type: none;
@@ -151,54 +165,57 @@ export default {
height: 48px; height: 48px;
} }
.info { .item-info {
display: flex;
justify-content: flex-start;
width: 100%; width: 100%;
background: #FFF;
.userImg { border-radius: 16px;
margin-right: 32px; padding: 32px 24px 32px 32px;
width: 80px; box-sizing: border-box;
height: 80px; margin-bottom: 30px;
border-radius: 50%; .item-title{
} margin-bottom: 32px;
img{
.userInfo { width: 72px;
width: 100%; height: 72px;
padding-right: 32px; margin-right: 16px;
border-bottom: 1px solid #E4E5E6; vertical-align: middle;
}
.name { p{
display: flex; display: inline-block;
justify-content: space-between; width: 400px;
font-size: 32px; font-size: 32px;
margin-bottom: 8px; font-family: PingFangSC-Medium, PingFang SC;
font-weight: 500;
.user-name { color: #000;
font-weight: 800; line-height: 32px;
}
.user-tel {
font-size: 26px;
color: #999999;
}
} }
span{
.idCard { display: inline-block;
margin-bottom: 16px; width: calc(100% - 488px);
font-size: 26px; text-align: right;
color: #999999; font-size: 24px;
} font-family: PingFangSC-Regular, PingFang SC;
color: #999;
.address { line-height: 24px;
max-width: 100%; }
word-break: break-all; }
margin-bottom: 18px; .info{
font-size: 26px; img{
color: #999999; width: 28px;
height: 28px;
margin-right: 16px;
}
div{
display: inline-block;
width: calc(100% - 44px);
word-break: break-all;
font-size: 28px;
font-family: PingFangSC-Regular, PingFang SC;
color: #333;
line-height: 40px;
vertical-align: text-top;
} }
} }
} }
} }
} }