You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

140 lines
5.6 KiB

7 years ago
7 years ago
7 years ago
7 years ago
7 years ago
7 years ago
7 years ago
  1. <div class="page-header">
  2. <h1 class="page-title">사용자 접속 로그<small>방문통계 &gt; 사용자 접속 로그</small></h1>
  3. </div>
  4. <div class="box">
  5. <div class="box-header">
  6. <h4 class="box-title">검색 필터</h4>
  7. </div>
  8. <?=form_open(NULL, array('method'=>'get','class'=>'form-flex','autocomplete'=>'off'))?>
  9. <div data-ax-tbl class="ax-search-tbl">
  10. <div data-ax-tr>
  11. <div data-ax-td>
  12. <div data-ax-td-label>일자 검색</div>
  13. <div data-ax-td-wrap>
  14. <input class="form-control form-control-sm" name="startdate" data-toggle="datepicker" value="<?=$startdate?>">
  15. </div>
  16. <div data-ax-td-wrap>
  17. <input class="form-control form-control-sm" name="enddate" data-toggle="datepicker" value="<?=$enddate?>">
  18. </div>
  19. </div>
  20. <div data-ax-td>
  21. <div data-ax-td-label>접속 기기</div>
  22. <div data-ax-td-wrap>
  23. <label class="w-check">
  24. <input type="checkbox" name="is_mobile[]" value="N" <?=in_array('N', $is_mobile)?'checked':''?>><span>PC</span>
  25. </label>
  26. <label class="w-check">
  27. <input type="checkbox" name="is_mobile[]" value="Y" <?=in_array('Y', $is_mobile)?'checked':''?>><span>모바일</span>
  28. </label>
  29. </div>
  30. </div>
  31. <div data-ax-td>
  32. <div data-ax-td-label>IP 검색</div>
  33. <div data-ax-td-wrap>
  34. <input class="form-control" name="ip" value="<?=$ip?>" placeholder="검색할 IP를 입력하세요">
  35. </div>
  36. </div>
  37. <div data-ax-td>
  38. <div data-ax-td-wrap>
  39. <button class="btn btn-sm btn-default"><i class="far fa-search"></i> 필터적용</button>
  40. </div>
  41. </div>
  42. </div>
  43. </div>
  44. <?=form_close()?>
  45. </div>
  46. <div class="H10"></div>
  47. <div class="box">
  48. <div class="box-header">
  49. <h4 class="box-title">사용자 접속 로그</h4>
  50. <div class="box-action">
  51. <button type="button" class="btn btn-sm btn-default"><i class="far fa-file-excel"></i> Excel 다운로드</button>
  52. </div>
  53. </div>
  54. <div data-ax5grid>
  55. <table>
  56. <thead>
  57. <tr>
  58. <th class="W155">접속일자</th>
  59. <th class="W100">접속 IP</th>
  60. <th class="W100">국가</th>
  61. <th class="W200">지역</th>
  62. <th class="W100">조직</th>
  63. <th class="W200">브라우져</th>
  64. <th class="W150">접속기기</th>
  65. <th class="W100">모바일</th>
  66. <th>리퍼러</th>
  67. <th class="W120">접속 검색어</th>
  68. </tr>
  69. </thead>
  70. <tbody>
  71. <?php foreach($visit_list['list'] as $row) :?>
  72. <tr>
  73. <td class="text-center"><?=$row['sta_regtime']?></td>
  74. <td>
  75. <div class="dropdown">
  76. <button type="button" class="btn btn-link dropdown-toggle" data-toggle="dropdown"><?=$row['sta_ip']?></button>
  77. <ul class="dropdown-menu">
  78. <li><a href="">[<?=$row['sta_ip']?>] 접근금지 IP로 설정</a></li>
  79. </ul>
  80. </div>
  81. </td>
  82. <?php if($row['sta_country']) :?>
  83. <td class="text-center"><?=$row['sta_country']?></td>
  84. <td title="<?=$row['sta_addr']?>"><span class="ellipsis W200" style="display:block"><?=$row['sta_addr']?></span></td>
  85. <td title="<?=$row['sta_org']?>"><span class="ellipsis W100" style="display:block"><?=$row['sta_org']?></span></td>
  86. <?php else :?>
  87. <td class="text-center" colspan="3">
  88. <button type="button" class="btn btn-xs btn-default" data-button="get-ip-info" data-ip="<?=$row['sta_ip']?>"><i class="far fa-search"></i> 확인</button>
  89. </td>
  90. <?php endif;?>
  91. <td class="text-center"><?=$row['sta_browser']?></td>
  92. <td class="text-center"><?=$row['sta_device']?></td>
  93. <td class="text-center text-primary"><?=$row['sta_is_mobile']=='Y'?'<i class="far fa-check"></i>':''?></td>
  94. <td>
  95. <?php if($row['sta_referrer_host']) : ?>
  96. <a href="<?=$row['sta_referrer']?>" title="<?=$row['sta_referrer']?>" target="_blank"><?=$row['sta_referrer_host']?></a>
  97. <?php endif;?>
  98. </td>
  99. <td><?=$row['sta_keyword']?></td>
  100. </tr>
  101. <?php endforeach;?>
  102. </tbody>
  103. </table>
  104. </div>
  105. <div class="bottom-actions MT20">
  106. <div class="center">
  107. <?=$pagination?>
  108. </div>
  109. </div>
  110. </div>
  111. <div class="H30"></div>
  112. <script>
  113. $(function(){
  114. $('[data-button="get-ip-info"]').click(function(e){
  115. e.preventDefault();
  116. var ip = $(this).data('ip');
  117. $.ajax({
  118. url : '/ajax/tools/ip_info',
  119. type : 'POST',
  120. async:false,
  121. cache:false,
  122. data : {
  123. ip : ip
  124. },
  125. success:function(res) {
  126. location.reload();
  127. }
  128. })
  129. });
  130. });
  131. </script>