post.blade.php 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. <table class="table">
  2. <caption>
  3. {{-- 분류/정렬/목록 수 --}}
  4. @include('mobile.board.component.tab')
  5. </caption>
  6. <tbody>
  7. {{-- 공지사항 --}}
  8. @include('mobile.board.component.notice')
  9. {{-- 일반 게시글 --}}
  10. @if($posts->total > 0)
  11. @foreach($posts->list as $row)
  12. <tr>
  13. <td>
  14. <div class="row">
  15. <div class="col col-md-10">
  16. <p>
  17. @if($boardMeta->use_category && $row->categoryName)
  18. <label>
  19. <a href="{{ $listURL }}?category={{ $row->board_category_id }}" rel="search">
  20. [{{ $row->categoryName }}]
  21. </a>
  22. </label>
  23. @endif
  24. @if($row->is_secret)
  25. <a href="{{ $row->viewURL }}" hreflang="ko" referrerpolicy="origin" type="text/html">
  26. <i class="fas fa-lock"></i> 비밀글입니다.
  27. </a>
  28. @elseif($row->isBlame)
  29. <i class="fas fa-ban"></i> <del>{{ $row->subject }}</del>
  30. @else
  31. <a href="{{ $row->viewURL }}" hreflang="ko" referrerpolicy="origin" type="text/html">{{ $row->subject }}</a>
  32. @endif
  33. @if($row->comment_rows > 0)
  34. <var>[{{ $row->comment_rows }}]</var>
  35. @endif
  36. @if($row->file_rows > 0)
  37. <i class="fas fa-save"></i>
  38. @endif
  39. @if($row->link_rows > 0)
  40. <i class="fas fa-external-link-alt"></i>
  41. @endif
  42. @if($row->image_rows > 0)
  43. <i class="fas fa-image"></i>
  44. @endif
  45. @if($row->isNew)
  46. <span class="badge bg-warning text-dark">New</span>
  47. @endif
  48. @if($row->isHot)
  49. <span class="badge bg-danger">Hot</span>
  50. @endif
  51. </p>
  52. <ul>
  53. <li>{{ $row->user->name }}</li>
  54. <li>{{ $row->createdAt }}</li>
  55. <li>조회 {{ $row->hit }}</li>
  56. <li>추천 {{ $row->like }}</li>
  57. </ul>
  58. </div>
  59. @if($row->thumbnail)
  60. <div class="col-3 col-md-2 align-self-center">
  61. <div class="thumbnail">
  62. <img src="{{ $row->thumbnail }}" class="img-fluid rounded" alt="{{ $row->subject }}" onerror="this.src='{{ NO_IMAGE_NORMAL_SRC }}"/>
  63. </div>
  64. </div>
  65. @endif
  66. </div>
  67. </td>
  68. </tr>
  69. @endforeach
  70. @else
  71. <tr>
  72. <td class="p-5 text-center">
  73. 게시글이 존재하지 않습니다.
  74. </td>
  75. </tr>
  76. @endif
  77. </tbody>
  78. </table>
  79. @if($posts->total > 0)
  80. <div class="pagination">
  81. {{ $posts->list->onEachSide($params->pageCount)->links('mobile.board.component.pagination') }}
  82. </div>
  83. @endif