wpfw_ewei_shopv2/template/web_v3/util/repeat.html
2023-02-14 19:57:32 +08:00

326 lines
16 KiB
HTML

{template '_header'}
<style>
.popover{
width:170px;
font-size:12px;
line-height: 21px;
color: #0d0706;
}
.popover span{
color: #b9b9b9;
}
.nickname{
display: inline-block;
max-width:200px;
overflow: hidden;
text-overflow:ellipsis;
white-space: nowrap;
vertical-align: middle;
}
.tooltip-inner{
border:none;
}
</style>
<div class="page-header">当前位置:<span class="text-primary">会员列表</span></div>
<div class="page-content">
<div class="fixed-header">
<div style="width:25px;"></div>
<div style="width: 250px;">粉丝</div>
<div class="flex1">等级/分组</div>
<div class="flex1">注册时间</div>
<div class="flex1">积分/余额</div>
<div class="flex1">成交</div>
<div style="width: 125px;text-align: center;">操作</div>
</div>
<form action="./index.php" method="get" class="form-horizontal table-search" role="form">
<input type="hidden" name="c" value="site"/>
<input type="hidden" name="a" value="entry"/>
<input type="hidden" name="m" value="{EWEI_SHOP_V2_MODULE_NAME}"/>
<input type="hidden" name="do" value="web"/>
<input type="hidden" name="r" value="util.repeat"/>
<div class="page-toolbar">
<span class="pull-left">
{php echo tpl_daterange('time', array('sm'=>true, 'placeholder'=>'注册时间'),true);}
</span>
<div class="input-group">
<span class="input-group-select">
<select name='followed' class='form-control'>
<option value=''>关注</option>
<option value='0' {if $_GPC['followed']=='0'}selected{/if}>未关注</option>
<option value='1' {if $_GPC['followed']=='1'}selected{/if}>已关注</option>
<option value='2' {if $_GPC['followed']=='2'}selected{/if}>取消关注</option>
</select>
</span>
<span class="input-group-select">
<select name='level' class='form-control'>
<option value=''>等级</option>
{loop $levels $level}
<option value="{$level['id']}" {if $_GPC['level']==$level['id']}selected{/if}>{$level['levelname']}</option>
{/loop}
</select>
</span>
<span class="input-group-select">
<select name='groupid' class='form-control'>
<option value=''>分组</option>
{loop $groups $group}
<option value="{$group['id']}" {if $_GPC['groupid']==$group['id']}selected{/if}>{$group['groupname']}</option>
{/loop}
</select>
</span>
<span class="input-group-select">
<select name='isblack' class='form-control'>
<option value=''>黑名单</option>
<option value='0' {if $_GPC['isblack']=='0'}selected{/if}></option>
<option value='1' {if $_GPC['isblack']=='1'}selected{/if}></option>
</select>
</span>
<input type="text" class="form-control " name="realname" value="{$_GPC['realname']}" placeholder="可搜索昵称/姓名/手机号/ID">
<span class="input-group-btn">
<button class="btn btn-primary" type="submit"> 搜索</button>
<a name="init" value="1" class="btn btn-success ">分析会员数据</a>
</span>
</div>
</div>
</form>
{if empty($list)}
<div class="panel panel-default">
<div class="panel-body empty-data">未查询到相关数据(请点击分析会员数据)</div>
</div>
{else}
<div class="row">
<div class="col-md-12">
<div class="page-table-header">
<input type="checkbox">
<div class="btn-group">
{ifp 'member.list.delete'}
<button class="btn btn-default btn-sm btn-operation" type="button" data-toggle='batch-remove' data-confirm="确认要删除?" data-href="{php echo webUrl('util/repeat/delete')}">
<i class="icow icow-shanchu1"></i> 批量删除
</button>
<!--用于处理微擎头像和昵称重复相同的问题,默认隐藏-->
<!-- <button class="btn btn-default btn-sm btn-operation" type="button" data-toggle='batch' data-href="{php echo webUrl('util/repeat/upmember')}">
<i class="icow icow-yongxinyonghu"></i> 同步会员信息
</button>-->
{/if}
</div>
</div>
<table class="table table-responsive">
<thead>
<tr>
<th style="width:25px;"></th>
<th style="width: 250px;">粉丝</th>
<th style="width: 250px;">上级分销商</th>
<th style="">等级/分组</th>
<th style="">注册时间</th>
<th style="">积分/余额</th>
<th style="">成交</th>
<th style="width: 150px;text-align: center;">操作</th>
</tr>
</thead>
<tbody>
{loop $list $row}
<tr>
<td style="position: relative; ">
<input type='checkbox' value="{$row['id']}" class="checkone"/></td>
<td style="overflow: visible">
<div rel="pop" style="display: flex" data-content=" <span>ID: </span>{$row['id']} </br>
<span>推荐人:</span> {if empty($row['agentid'])}
{if $row['isagent']==1}
总店
{else}
暂无
{/if}
{else}
{if !empty($row['agentavatar'])}
<img src='{$row['agentavatar']}' style='width:20px;height:20px;padding1px;border:1px solid #ccc' />
{/if}
[{$row['agentid']}]{if empty($row['agentnickname'])}未更新{else}{$row['agentnickname']}{/if}
{/if}
<br/>
<span>真实姓名:</span> {if empty($row['realname'])}未填写{else}{$row['realname']}{/if}
<br/>
<span>手机号:</span>{if !empty($row['mobileverify'])}{$row['mobile']}{else}未绑定{/if} <br/>
<span>是否关注:</span>{if empty($row['followed'])}
{if empty($row['unfollowtime'])}
<i>未关注</>
{else}
<i>取消关注</i>
{/if}
{else}
<i>已关注</i>
{/if} <br/>
<span>状态:</span> {if $row['isblack']==1}黑名单{else}正常{/if} ">
<img class="img-40" src="{php echo tomedia($row['avatar'])}" style='border-radius:50%;border:1px solid #efefef;' onerror="this.src='../addons/{EWEI_SHOP_V2_MODULE_NAME}/static/images/noface.png'" />
<span style="display: flex;flex-direction: column;justify-content: center;align-items: flex-start;padding-left: 5px">
<span class="nickname">
{if strexists($row['openid'],'sns_wa')}<i class="icow icow-xiaochengxu" style="color: #7586db;vertical-align: middle;" data-toggle="tooltip" data-placement="top" title="" data-original-title="来源: 小程序"></i>{/if}
{if strexists($row['openid'],'sns_qq')||strexists($row['openid'],'sns_wx')||strexists($row['openid'],'wap_user')}<i class="icow icow-app" style="color: #44abf7;vertical-align: top;" data-toggle="tooltip" data-placement="bottom" data-original-title="来源: 全网通({if strexists($row['openid'],'wap_user')}手机号注册{else}APP{/if})"></i>{/if}
{if empty($row['nickname'])}未更新{else}{$row['nickname']}{/if}
</span>
{if $row['isblack']==1}
<span class="text-danger">黑名单<i class="icow icow-heimingdan1"style="color: #db2228;margin-left: 2px;font-size: 13px;"></i></span>
{/if}
</span>
</div>
</td>
<td>
{if empty($row['agentid'])}
{if $row['isagent']==1}
总店
{else}
暂无
{/if}
{else}
{if !empty($row['agentavatar'])}
<img src='{$row['agentavatar']}' style='width:20px;height:20px;padding1px;border:1px solid #ccc' />
{/if}
[{$row['agentid']}]{if empty($row['agentnickname'])}未更新{else}{$row['agentnickname']}{/if}
{/if}
</td>
<td>{if empty($row['levelname'])}普通会员{else}{$row['levelname']}{/if}
<br/>{if empty($row['groupname'])}无分组{else}{$row['groupname']}{/if}
</td>
<td>{php echo date("Y-m-d",$row['createtime'])}<br/>{php echo date("H:i:s",$row['createtime'])}</td>
<td><span >积分: <span style="color: #5097d3">{php echo intval($row['credit1'])}</span> </span>
<br/><span>余额: <span class="text-warning">{php echo price_format($row['credit2'],2)} </span></span></td>
<td><span>订单: {$row['ordercount']}</span>
<br/><span> 金额: <span class="text-warning">{php echo floatval($row['ordermoney'])}</span></span></td>
<td style="overflow:visible;text-align: center;">
<div class="btn-group">
{ifp 'member.list.edit'}
<a class="btn btn-op btn-operation" target="_blank" href="{php echo webUrl('member/list/detail',array('id' => $row['id']));}" title="">
<span data-toggle="tooltip" data-placement="top" title="" data-original-title="会员详情">
<i class='icow icow-bianji2'></i>
</span>
</a>
{/if}
{ifp 'member.list.view'}
<a class="btn btn-op btn-operation" target="_blank" href="{php echo webUrl('member/list/view',array('id' => $row['id']));}" title="">
<span data-toggle="tooltip" data-placement="top" title="" data-original-title="查看会员">
<i class='icow icow-chakan3'></i>
</span>
</a>
{/if}
{ifp 'order.list'}
<a class="btn btn-op btn-operation" target="_blank" href="{php echo webUrl('order/list', array('searchfield'=>'member','keyword'=>$row['nickname']))}"
title=''>
<span data-toggle="tooltip" data-placement="top" title="" data-original-title="会员订单">
<i class='icow icow-dingdan2'></i>
</span>
</a>
{/if}
{ifp 'member.list.delete'}
<a class="btn btn-op btn-operation" data-toggle='ajaxRemove' href="{php echo webUrl('util/repeat/delete',array('id' => $row['id']));}" data-confirm="确定要删除该会员吗?">
<span data-toggle="tooltip" data-placement="top" title="" data-original-title="删除会员">
<i class='icow icow-shanchu1'></i>
</span>
</a>
{/if}
</div>
</td>
</tr>
{/loop}
</tbody>
<tfoot>
<tr>
<td><input type="checkbox"></td>
<td colspan="3">
<div class="btn-group">
{ifp 'member.list.delete'}
<button class="btn btn-default btn-sm btn-operation" type="button" data-toggle='batch-remove' data-confirm="确认要删除?" data-href="{php echo webUrl('util/repeat/delete')}">
<i class="icow icow-shanchu1"></i> 批量删除
</button>
{/if}
</div>
</td>
<td colspan="3" style="text-align: right">
{$pager}
</td>
</tr>
</tfoot>
</table>
</div>
</div>
{/if}
</div>
<script language="javascript">
{if $opencommission}
require(['bootstrap'], function () {
$("[rel=pop]").popover({
trigger: 'manual',
placement: 'right',
title: $(this).data('title'),
html: 'true',
content: $(this).data('content'),
animation: false
}).on("mouseenter", function () {
var _this = this;
$(this).popover("show");
$(this).siblings(".popover").on("mouseleave", function () {
$(_this).popover('hide');
});
}).on("mouseleave", function () {
var _this = this;
setTimeout(function () {
if (!$(".popover:hover").length) {
$(_this).popover("hide")
}
}, 100);
});
});
{/if}
$('.btn-success ').click(function () {
var _this = $(this);
tip.confirm("确定重新分析会员数据吗?", function () {
_this.attr('stop', 1).text("操作中...");
$.post(biz.url('util/repeat/init'), function (ret) {
if(ret.status==1){
tip.msgbox.suc("操作成功");
setTimeout(function () {
location.reload();
},1000);
}else{
tip.msgbox.err(ret.result.message);
}
}, 'json')
});
})
</script>
{template '_footer'}