{{-- Name: user.partials.comments Author: AL Created: 2015-10-13 Updated by: Description: User comments writing and listing --}} @extends('partials.box') @section($content_id) {!! Form::open(['method' => 'POST', 'class' => 'form-horizontal', 'action' => 'UserCommentController@store']) !!}
{!! Form::label('comment', Lang::get('user.comment.content'), ['class' => 'col-md-2 control-label']) !!}
{!! Form::textarea('comment', old('comment'), ['class' => 'form-control', 'rows' => '4']) !!} {!! $errors->first('comment', ':message') !!}
{!! Form::label('sticky', Lang::get('user.comment.sticky'), ['class' => 'col-md-2 control-label']) !!}
{!! Form::checkbox('sticky', 1, false) !!}
{!! Form::submit(Lang::get('user.comment.save_comment'), ['class' => 'btn btn-primary pull-right']) !!}
{!! Form::text('user', $user->id, ['hidden' => 'hidden']) !!} {!! Form::close() !!}
@foreach ($data as $comment)
{{ $comment->created_at }} {{ Lang::get('user.comment.by') }} {{ $comment->author->first_name }}

{!! nl2br($comment->content) !!}

{!! Form::open(['class' => 'pull-right margin-left delete-form', 'route' => ['admin.comment.user.destroy', $comment->id]]) !!} {!! Form::submit(Lang::get('userComment.delete'), ['class' => 'btn btn-danger' ,'data' => 'delete-confirm']) !!} {!! Form::close() !!}
@endforeach
@stop