collapse.blade.php 1.4 KB

123456789101112131415161718192021222324
  1. <div class="collapse widget-comments mb-20" id="comments-{{ $comment_source_type }}-{{ $comment_source_id }}" data-source_type="{{ $comment_source_type }}" data-source_id="{{ $comment_source_id }}">
  2. <div class="widget-comment-list"></div>
  3. @if(Auth()->check())
  4. <div class="widget-comment-form row">
  5. <form class="col-md-12" >
  6. <div class="form-group">
  7. <textarea name="content" placeholder="写下你的评论" class="form-control" id="comment-{{ $comment_source_type }}-content-{{ $comment_source_id }}"></textarea>
  8. </div>
  9. </form>
  10. <div class="col-md-12 text-right">
  11. @if(!$hide_cancel )
  12. <a href="#" class="text-muted collapse-cancel" data-collapse_id="comments-{{ $comment_source_type }}-{{ $comment_source_id }}">取消</a>
  13. @endif
  14. <button type="submit" class="btn btn-primary btn-sm ml-10 comment-btn" id="{{ $comment_source_type }}-comment-{{ $comment_source_id }}-btn" data-token="{{ csrf_token() }}" data-source_id="{{ $comment_source_id }}" data-source_type="{{ $comment_source_type }}" data-to_user_id="0">提交评论</button>
  15. </div>
  16. </div>
  17. @else
  18. <div class="widget-comment-form row">
  19. <div class="col-md-12">
  20. 请先 <a href="{{ route('auth.user.login') }}">登录</a> 后评论
  21. </div>
  22. </div>
  23. @endif
  24. </div>