查看店员

This commit is contained in:
yerz
2021-09-22 12:37:46 +08:00
parent 9625bd3d64
commit 6f238c978b
3 changed files with 56 additions and 28 deletions
+1 -1
View File
@@ -25,7 +25,7 @@ Page({
this.setData({
userInfo: res
})
if(res.group_id == 2 || res.group_id == 3){
if(res.group_id == 2 || res.group_id == 3 || res.group_id == 4){
let list=[
{
icon:'icon-renyuanguanli',
+1 -1
View File
@@ -55,7 +55,7 @@ Page({
this.setData({
noData: true
})
} else if (this.data.list.length == res.data.total) {
} else if (this.data.list.length == res.data.total && this.data.list.length>20) {
this.setData({
end: true
})
+54 -26
View File
@@ -18,36 +18,64 @@
</view>
</view>
<view class="pl30">
<view class="mt20 font-22 relative">
<i class="iconfont icon-renyuanguanli mr10"></i>人员管理
<view bindtap="optAddStaff" class="absolute right-0 box-middle pt10 pb10 pl10 pr30 space-nowrap bg-333 font-22 color-fff ulib-rl750"><i class="iconfont mr5 icon-jia"></i>添加人员</view>
</view>
</view>
<view class="mt10 inner30">
<view class="pl40 pr40 pt30 pb30 bg-fff box-shadow-000-10-10 ulib-r10" wx:if="{{!noData}}">
<view class="fn-flex font-22 text-center color-666">
<view class="fn-flex-item">店员</view>
<view class="fn-flex-item">操作</view>
<block wx:if="{{userInfo.group_id==2}}">
<view class="pl30">
<view class="mt20 font-22 relative">
<i class="iconfont icon-renyuanguanli mr10"></i>人员管理
<view bindtap="optAddStaff" class="absolute right-0 box-middle pt10 pb10 pl10 pr30 space-nowrap bg-333 font-22 color-fff ulib-rl750"><i class="iconfont mr5 icon-jia"></i>添加人员</view>
</view>
<block wx:for="{{list}}" wx:key='index'>
<view class="relative pt30 pb30 pr250 bbs-1-eb last-b-none {{item.status==1?'':'opacity-50'}}">
<view class="text-nowrap">
<image class='img-50x50 bds-1-eb ulib-r750 text-middle' lazy-load="{{true}}" mode="scaleToFill" src="{{imgUrl}}common/default-head.jpg"></image>
<text class="pl10 text-middle font-28">{{item.uname}}</text>
<!-- <text class="pl10 text-middle font-28">{{item.mobile}}</text> -->
</view>
<view class="absolute right-0 box-middle">
<view class="inline-block bg-333 mr20 pt5 pb5 pl10 pr10 font-22 color-fff ulib-r750" bindtap="putAppEmployees" data-index="{{index}}"><i class="iconfont icon-zanting mr5"></i>{{item.status == 1?'暂停':'开启'}}</view>
<view class="inline-block bg-333 pt5 pb5 pl10 pr10 font-22 color-fff ulib-r750" bindtap="deleteAppEmployees" data-index="{{index}}"><i class="iconfont icon-shanchu mr5"></i>删除</view>
</view>
</view>
</block>
</view>
<view class="mt10 inner30">
<view class="pl40 pr40 pt30 pb30 bg-fff box-shadow-000-10-10 ulib-r10" wx:if="{{!noData}}">
<view class="fn-flex font-22 text-center color-666">
<view class="fn-flex-item">店员</view>
<view class="fn-flex-item">操作</view>
</view>
<block wx:for="{{list}}" wx:key='index'>
<view class="relative pt30 pb30 pr250 bbs-1-eb last-b-none {{item.status==1?'':'opacity-50'}}">
<view class="text-nowrap">
<image class='img-50x50 bds-1-eb ulib-r750 text-middle' lazy-load="{{true}}" mode="scaleToFill" src="{{imgUrl}}common/default-head.jpg"></image>
<text class="pl10 text-middle font-28">{{item.uname}}</text>
<!-- <text class="pl10 text-middle font-28">{{item.mobile}}</text> -->
</view>
<view class="absolute right-0 box-middle">
<view class="inline-block bg-333 mr20 pt5 pb5 pl10 pr10 font-22 color-fff ulib-r750" bindtap="putAppEmployees" data-index="{{index}}"><i class="iconfont icon-zanting mr5"></i>{{item.status == 1?'暂停':'开启'}}</view>
<view class="inline-block bg-333 pt5 pb5 pl10 pr10 font-22 color-fff ulib-r750" bindtap="deleteAppEmployees" data-index="{{index}}"><i class="iconfont icon-shanchu mr5"></i>删除</view>
</view>
</view>
</block>
</view>
<lcb-listmore isLoading='{{loading}}' isEnd='{{end}}' isNoData='{{noData}}'></lcb-listmore>
<lcb-listmore isLoading='{{loading}}' isEnd='{{end}}' isNoData='{{noData}}'></lcb-listmore>
</view>
</view>
</block>
<block wx:elif="{{userInfo.group_id==3 || userInfo.group_id==4}}">
<view class="pl30">
<view class="mt20 font-22 relative">
<i class="iconfont icon-renyuanguanli mr10"></i>人员管理
</view>
</view>
<view class="mt10 inner30">
<view class="pl40 pr40 pt30 pb30 bg-fff box-shadow-000-10-10 ulib-r10" wx:if="{{!noData}}">
<view class="fn-flex font-22 text-center color-666">
<view class="fn-flex-item text-left">店员</view>
</view>
<block wx:for="{{list}}" wx:key='index'>
<view class="relative pt30 pb30 pr30 bbs-1-eb last-b-none {{item.status==1?'':'opacity-50'}}">
<view class="text-nowrap">
<image class='img-50x50 bds-1-eb ulib-r750 text-middle' lazy-load="{{true}}" mode="scaleToFill" src="{{imgUrl}}common/default-head.jpg"></image>
<text class="pl10 text-middle font-28">{{item.uname}}</text>
<!-- <text class="pl10 text-middle font-28">{{item.mobile}}</text> -->
</view>
</view>
</block>
</view>
<lcb-listmore isLoading='{{loading}}' isEnd='{{end}}' isNoData='{{noData}}'></lcb-listmore>
</view>
</block>
</view>
<lcb-footer></lcb-footer>