reportlist.html 5.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172
  1. <include file="public@header"/>
  2. <style type="text/css">
  3. .textArea textarea{
  4. width:90%;padding:3%;height:80%;margin:0 auto;margin-top:30px;
  5. margin-left: 2%;
  6. }
  7. .textArea_btn{
  8. text-align: right;
  9. margin-top: 30px;
  10. }
  11. .textArea_btn input{
  12. margin-right: 30px;
  13. }
  14. </style>
  15. </head>
  16. <body>
  17. <div class="wrap">
  18. <ul class="nav nav-tabs">
  19. <li class="active"><a >视频举报列表</a></li>
  20. </ul>
  21. <form class="well form-inline margin-top-20" method="post" action="{:url('Video/reportlist')}">
  22. 状态:
  23. <select class="form-control" name="status" style="width: 200px;">
  24. <option value="">全部</option>
  25. <option value="0" <if condition="input('request.status') eq '0'">selected</if> >处理中</option>
  26. <option value="1" <if condition="input('request.status') eq '1'">selected</if>>已处理</option>
  27. </select>&nbsp; &nbsp;
  28. 提交时间:
  29. <input type="text" name="start_time" class="js-bootstrap-date form-control" value="{:input('request.start_time')}" autocomplete="off" placeholder="开始时间">-
  30. <input type="text" name="end_time" class="js-bootstrap-date form-control" value="{:input('request.end_time')}" autocomplete="off" placeholder="结束时间">&nbsp; &nbsp;
  31. 关键字:
  32. <input class="form-control" type="text" name="keyword" style="width: 200px;" value="{:input('request.keyword')}"
  33. placeholder="会员ID">
  34. <input type="submit" class="btn btn-primary" value="搜索">
  35. <a class="btn btn-danger" href="{:url('Admin/Video/reportlist')}">清空</a>
  36. </form>
  37. <form method="post" class="js-ajax-form" >
  38. <table class="table table-hover table-bordered">
  39. <thead>
  40. <tr>
  41. <th align="center">ID</th>
  42. <th>举报人</th>
  43. <th>被举报人</th>
  44. <th>被举报视频ID</th>
  45. <th>举报内容</th>
  46. <th>状态</th>
  47. <th>提交时间</th>
  48. <th>处理时间</th>
  49. <th align="center">{:lang('ACTIONS')}</th>
  50. </tr>
  51. </thead>
  52. <tbody>
  53. <php>$status=array("0"=>"处理中","1"=>"已处理", "2"=>"审核失败");</php>
  54. <foreach name="lists" item="vo">
  55. <tr>
  56. <td align="center">{$vo.id}</td>
  57. <td>{$vo['userinfo']['user_nicename']} ( {$vo['uid']} )</td>
  58. <td>{$vo['touserinfo']['user_nicename']} ( {$vo['touid']} )</td>
  59. <td>{$vo['videoid']}</td>
  60. <td><?php echo nl2br($vo['content']);?></td>
  61. <td>{$status[$vo['status']]}</td>
  62. <td>{:date('Y-m-d H:i:s',$vo['addtime'])}</td>
  63. <td>
  64. <if condition="$vo['status'] eq '0'" >
  65. 处理中
  66. <else/>
  67. {:date('Y-m-d H:i:s',$vo['uptime'])}
  68. </if>
  69. </td>
  70. <td align="center">
  71. <a class="btn btn-xs btn-primary" href="javascript:void(0)" onclick="videoListen({$vo['videoid']})" >观看视频</a>
  72. <if condition="$vo['status'] eq '0'" >
  73. <a class="btn btn-xs btn-danger js-ajax-delete" href="{:url('Video/setstatus',array('id'=>$vo['id']))}" data-msg="您确定要标记处理吗?" >标记处理</a>
  74. </if>
  75. <if condition="$vo['video_isdel'] neq '1'">
  76. <a class="btn btn-xs btn-danger " href="javascript:void (0)" onclick="xiajia({$vo['videoid']})" >下架视频</a>
  77. </if>
  78. <a href="{:url('Video/report_del',array('id'=>$vo['id']))}" class="btn btn-xs btn-danger js-ajax-delete" data-msg="您确定要删除吗?">删除举报</a>
  79. </td>
  80. </tr>
  81. </foreach>
  82. </tbody>
  83. </table>
  84. <div class="pagination">{$page}</div>
  85. </form>
  86. </div>
  87. <script src="__STATIC__/js/admin.js"></script>
  88. <script src="__STATIC__/layer/layer.js"></script>
  89. <script type="text/javascript">
  90. var xiajia_status=0;
  91. function xiajia(id){
  92. var p={$p};
  93. layer.open({
  94. type: 1,
  95. title:"是否确定将该视频下架",
  96. skin: 'layui-layer-rim', //加上边框
  97. area: ['30%', '30%'], //宽高
  98. content: '<div class="textArea"><textarea id="xiajia_reason" maxlength="50" placeholder="请输入下架原因,最多50字" /> </div><div class="textArea_btn" ><input type="button" id="xiajia" value="下架" onclick="xiajia_submit('+id+','+p+')" /><input type="button" id="cancel" onclick="layer.closeAll();" value="取消" /></div>'
  99. });
  100. }
  101. function xiajia_submit(id,p){
  102. var reason=$("#xiajia_reason").val();
  103. if(xiajia_status==1){
  104. return;
  105. }
  106. xiajia_status=1;
  107. $.ajax({
  108. url: '/admin/video/setXiajia.html',
  109. type: 'POST',
  110. dataType: 'json',
  111. data: {id:id,reason: reason},
  112. success:function(data){
  113. var code=data.code;
  114. if(code!=0){
  115. layer.msg(data.msg);
  116. return;
  117. }
  118. xiajia_status=0;
  119. $("#xiajia").attr("disabled",true);
  120. layer.msg("下架成功",{icon: 1,time:1000},function(){
  121. layer.closeAll();
  122. location.href='/admin/video/reportlist.html&p='+p;
  123. });
  124. },
  125. error:function(e){
  126. $("#xiajia").attr("disabled",false);
  127. console.log(e);
  128. }
  129. });
  130. }
  131. </script>
  132. <script type="text/javascript">
  133. function videoListen(id){
  134. layer.open({
  135. type: 2,
  136. title: '观看视频',
  137. shadeClose: true,
  138. shade: 0.8,
  139. area: ['500px', '750px'],
  140. content: '/admin/Video/video_listen.html&id='+id
  141. });
  142. }
  143. </script>
  144. </body>
  145. </html>