| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282 |
- <include file="public@header"/>
- </head>
- <body>
- <div class="wrap js-check-wrap">
- <ul class="nav nav-tabs">
- <li class="active"><a>单身推荐列表</a></li>
- </ul>
- <div class="qrcode">
- <form class="well form-inline margin-top-20" method="post" onsubmit="return false;">
- <span>生成参数</span>
- <input class="form-control" id="url" type="text" name="url" style="width: 400px;" placeholder="请填写生成参数:如用户地址">
-
- <input type="button" class="btn btn-primary" onclick="makeQrcode()" value="生成二维码"/>
- <span class="qrcode">
- <a title="点击放大" data-href="">
- </a>
- </span>
- </form>
- </div>
- <form class="well form-inline margin-top-20" method="post" action="{:url('user/recommend/index')}">
- 用户ID:
- <input class="form-control" type="text" name="uid" style="width: 200px;" value="{:input('request.uid')}"
- placeholder="请输入用户ID">
- 关键字:
- <input class="form-control" type="text" name="keyword" style="width: 200px;" value="{:input('request.keyword')}" placeholder="用户名/昵称/真实姓名/手机">
- <input type="submit" class="btn btn-primary" value="搜索"/>
- <a class="btn btn-default" href="{:url('user/recommend/index')}">清空</a>
- <a class="btn btn-warning" href="{:url('user/recommend/export')}">导出</a>
- <a class="btn btn-danger" onclick="doDelete()">批量删除</a>
- </form>
- <form method="post" class="js-ajax-form">
- <div class="table-actions">
- <button class="btn btn-primary btn-sm js-ajax-submit" style="width: 88px; background-color: #d9534f; border-color: #d9534f;" type="submit" data-action="{:url('AdminIndex/totuijian',array('no'=>0))}" onclick="return confirm('确定取消单身推荐吗?')" data-subcheck="true">取消单身推荐
- </button>
- </div>
- <table class="table table-hover table-bordered">
- <thead>
- <tr>
- <th><input type="checkbox" class="js-check-all" data-direction="x" data-checklist="js-check-x">全选</th>
- <th>ID</th>
- <th>账号</th>
- <th>{:lang('NICENAME')}</th>
- <th>真实姓名</th>
- <th>爱心</th>
- <!-- <th>级别</th>
- <th>积分</th>
- <th>余额</th> -->
- <th style="text-align: center;">是否推荐</th>
- <th style="text-align: center;">来源</th>
- <!--<th>{:lang('AVATAR')}</th>-->
- <!--<th>{:lang('EMAIL')}</th>-->
- <th>手机</th>
- <th>网址</th>
- <th>{:lang('REGISTRATION_TIME')}</th>
- <th>{:lang('LAST_LOGIN_TIME')}</th>
- <!--<th>{:lang('LAST_LOGIN_IP')}</th>-->
- <th>{:lang('STATUS')}</th>
- <th>{:lang('ACTIONS')}</th>
- </tr>
- </thead>
- <tbody>
- <php>
- $user_statuses=array("0"=>lang('USER_STATUS_BLOCKED'),"1"=>lang('USER_STATUS_ACTIVATED'),"2"=>lang('USER_STATUS_UNVERIFIED'));
- </php>
- <foreach name="list" item="vo">
- <tr>
- <td><input type="checkbox" class="js-check" data-yid="js-check-y" data-xid="js-check-x" name="ids[]"
- value="{$vo.id}" title="ID:{$vo.id}"></td>
- <td>{$vo.id}</td>
- <td>{$vo['user_login']?$vo['user_login']:($vo['mobile']?$vo['mobile']:lang('THIRD_PARTY_USER'))}
- </td>
- <td>{$vo['user_nickname']?$vo['user_nickname']:lang('NOT_FILLED')}</td>
- <td>{$vo['real_name']?$vo['real_name']:lang('NOT_FILLED')}</td>
- <!--<td><img width="25" height="25" src="{:url('user/public/avatar',array('id'=>$vo['id']))}"/></td>-->
- <!--<td>{$vo.user_email}</td>-->
- <!-- <td>v{$vo.level}</td>
- <td>{$vo.score}</td>
- <td>{$vo.balance}</td> -->
- <td>{$vo['redheart']}</td>
- <!--<td>v{$vo.wechat_account}</td>-->
- <td style="text-align: center;">
- <switch name="vo.is_tuijian">
-
- <case value="1">
- <span style="color: blue">是</span>
- </case>
- <case value="0">
- <span style="color: red">否</span>
- </case>
-
- </switch>
- </td>
- <!-- <td style="text-align: center;color: #c11f1f"> -->
- <td style="text-align: center;">
- <switch name="vo.is_books">
- <case value="1"><span style="color:blue">单身推荐活动</span> </case>
-
- <case value="0"><span style="color:#d9534f">本站用户</span></case>
- </switch>
- </td>
- <td>{$vo.mobile}</td>
- <td><span class="label label-primary copy-btn copy" data-url="{:url('/weixin/member/home?id=','','',true)}{$vo.id}">复制</span></td>
- <td>{:date('Y-m-d H:i',$vo['create_time'])}</td>
- <td>{:date('Y-m-d H:i',$vo['last_login_time'])}</td>
- <!--<td>{$vo.last_login_ip}</td>-->
- <td>
- <switch name="vo.user_status">
- <case value="0">
- <span class="label label-danger">已冻结</span>
- </case>
- <case value="1">
- <span class="label label-success">{$user_statuses[$vo['user_status']]}</span>
- </case>
- <case value="2">
- <span class="label label-warning">{$user_statuses[$vo['user_status']]}</span>
- </case>
- </switch>
- </td>
- <td>
- <a class="btn btn-xs btn-primary" href="{:url('adminIndex/edit',array('id'=>$vo['id']))}">编辑</a>
- <neq name="vo.id" value="1">
- <empty name="vo.user_status">
- <a class="btn btn-xs btn-success js-ajax-dialog-btn"
- href="{:url('adminIndex/cancelban',array('id'=>$vo['id']))}"
- data-msg="{:lang('ACTIVATE_USER_CONFIRM_MESSAGE')}">{:lang('ACTIVATE_USER')}</a>
- <else/>
- <a class="btn btn-xs btn-warning js-ajax-dialog-btn"
- href="{:url('adminIndex/ban',array('id'=>$vo['id']))}"
- data-msg="确认冻结该用户?">冻结</a>
- </empty>
- <else/>
- <a class="btn btn-xs btn-warning disabled">冻结</a>
- </neq>
- <a class="btn btn-xs btn-danger" href="{:url('adminIndex/accountadd',array('id'=>$vo['id']))}">爱心充值</a>
- </td>
- </tr>
- </foreach>
- </tbody>
- </table>
- <div class="pagination">{$page}</div>
- </form>
- </div>
- <script src="__STATIC__/js/admin.js"></script>
- <script src="__STATIC__/js/clipboard.min.js"></script>
- <script>
- function reloadPage(win) {
- win.location.reload();
- }
- /**
- * 生成二维啊
- * @returns {boolean}
- */
- function makeQrcode() {
- var url = $("#url").val();
- if(url == '' || url == null){
- showMsg('请填写生成参数');
- return false;
- }
- // 生成处理
- $(".qrcode a").html("二维码生成中...");
- $.post('/user/recommend/makeQrcode', {url: url}, function(res){
- if(res.code == 'success'){
- showMsg(res.message);
- $(".qrcode a").attr('data-href', res.data.qrcode);
- $(".qrcode a").html('<img src="'+res.data.qrcode+'" width="48" height="48"/>');
- }else{
- $(".qrcode a").html("");
- showMsg(res.message);
- }
- },'json');
- }
- $(function () {
- var copyText = '';
- var copyBox = new ClipboardJS('.copy',{
- text: function (e) {
- if(copyText=='' || copyText == null){
- showMsg('暂无复制内容');
- return false;
- }
- return copyText;
- }
- });
- copyBox.on("success",function(e){
- console.log(e);
- showMsg('复制成功');
- });
- copyBox.on("error",function(e){
- showMsg('复制失败');
- });
- $(".copy-btn").click(function(){
- copyText = $(this).attr('data-url');
- });
- $(".qrcode a").click(function(){
- var url = $(this).attr('data-href');
- if(url){
- imagePreviewDialog(url);
- }
- })
- setCookie("refersh_time", 3);
- Wind.use('ajaxForm', 'artDialog', 'iframeTools', function () {
- //批量冻结
- $('#js-batch-delete').click(function (e) {
- var ids = [];
- $("input[name='ids[]']").each(function () {
- if ($(this).is(':checked')) {
- ids.push($(this).val());
- }
- });
- if (ids.length == 0) {
- return false;
- }
- ids = ids.join(',');
- /*art.dialog.open("/user/admin_index/del.html?ids="+ids, {
- title: "批量冻结",
- width: "300px",
- close : function () {
- art.dialog.open.origin.location.reload();
- }
- });*/
- });
- //end
- });
- });
- </script>
- <script>
- function doDelete() {
- // Wind.use('artDialog', function () {
- var ids = [];
- $(".js-check:checked").each(function () {
- var id = $(this).val();
- if (id > 0) {
- ids.push(id);
- }
- });
- if (ids.length <= 0) {
- showMsg('请先选择操作项');
- return false;
- }
- if(confirm('确定批量删除选择项?不可恢复')){
- $.post('/user/admin_index/del',{id:ids},function(res){
- if(res.code == 1){
- showMsg(res.msg);
- setTimeout(function () {
- location.reload();
- }, 800)
- }else{
- showMsg(res.msg);
- }
- },"json")
- }
- // });
- }
- /* function showMsg(msg, time){
- time = time? time : 1000;
- art.dialog({
- content: msg,
- icon: 'warning'
- });
- setTimeout(function () {
- }, time)
- }*/
- </script>
- </body>
- </html>
|