agent.html 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109
  1. <include file="Public:header"/>
  2. <div id="main-content">
  3. <div id="top-alert" class="fixed alert alert-error" style="display: none;">
  4. <button class="close fixed" style="margin-top: 4px;">&times;</button>
  5. <div class="alert-content">警告内容</div>
  6. </div>
  7. <div id="main" class="main">
  8. <div class="main-title-h">
  9. <span class="h1-title">代理管理</span>
  10. </div>
  11. <div class="data-table table-striped">
  12. <form id="form" method="post" class="form-horizontal">
  13. <table class="">
  14. <thead>
  15. <tr>
  16. <th class="row-selected row-selected">
  17. <input class="check-all" type="checkbox"/>
  18. </th>
  19. <th class="">ID</th>
  20. <th class="">代理账号</th>
  21. <th class="">注册IP/时间</th>
  22. <th class="">三代总人数</th>
  23. <th class="">一代人数</th>
  24. <th class="">二代人数</th>
  25. <th class="">三代人数</th>
  26. <th class="">邀请码</th>
  27. <th class="">操作</th>
  28. </tr>
  29. </thead>
  30. <tbody>
  31. <notempty name="list">
  32. <volist name="list" id="vo">
  33. <tr>
  34. <td>
  35. <input class="ids" type="checkbox" name="id[]" value="{$vo.id}"/>
  36. </td>
  37. <td>{$vo.id}</td>
  38. <td>{$vo.username}</a></td>
  39. <td>
  40. <span>IP:{$vo.addip}</span><br />
  41. <span>时间:<?php echo date("Y-m-d H:i:s",$vo['addtime']);?></span>
  42. </td>
  43. <td>{$vo.all}人</td>
  44. <td>{$vo.one}人</td>
  45. <td>{$vo.two}人</td>
  46. <td>{$vo.three}人</td>
  47. <td>{$vo.invit}</td>
  48. <td>
  49. <input type="button" class="ajax-get btn btn-danger btn-xs" value="取消代理" onclick="cancelagent('{$vo['id']}');"/>
  50. </eq>
  51. </td>
  52. </tr>
  53. </volist>
  54. <else/>
  55. <td colspan="12" class="text-center empty-info"><i class="glyphicon glyphicon-exclamation-sign"></i>暂无数据</td>
  56. </notempty>
  57. </tbody>
  58. </table>
  59. </form>
  60. <div class="page">
  61. <div>{$page}</div>
  62. </div>
  63. </div>
  64. </div>
  65. </div>
  66. <include file="Public:footer" />
  67. <script type="text/javascript">
  68. function cancelagent(id) {
  69. var uid = parseInt(id);
  70. if (uid == "" || uid == null || uid <=0) {
  71. layer.alert('参数错误!');
  72. return false;
  73. }
  74. layer.load(0, {shade: [0.5,'#8F8F8F']});
  75. $.post("{:U('User/cancelagent')}", {
  76. id: uid
  77. }, function (data) {
  78. setTimeout("closetanchu()",2000);
  79. if (data.status == 1) {
  80. layer.msg(data.info, {
  81. icon: 1
  82. });
  83. setTimeout("shuaxin()",1000);
  84. } else {
  85. layer.msg(data.info, {
  86. icon: 2
  87. });
  88. }
  89. }, "json");
  90. }
  91. </script>
  92. <script type="text/javascript">
  93. function closetanchu(){
  94. layer.closeAll('loading');
  95. }
  96. function shuaxin(){
  97. window.location.href=window.location.href;
  98. }
  99. </script>
  100. <block name="script">
  101. <script type="text/javascript" charset="utf-8">
  102. //导航高亮
  103. highlight_subnav("{:U('User/agent')}");
  104. </script>
  105. </block>