@extends('layouts.app')

@section('content')
<div class="card card-outline-info">
    @if($ureq->status==0)
  <div class="card-header">
      <h4 class="m-b-0 text-white">Send Complaint Reply</h4>
  </div>
  <div class="card-body">
    <div class="x_content">
            {!! Form::open(['method' => 'POST','id'=> 'register_frm', 'data-parsley-validate'=>'', 'url' => [url('/users/sendcomplaintreply')]]) !!}
            <div class="row">
                <div class="col-md-12">
                    <div class="form-group">
                        {!! Form::label('message', 'Message*', ['class' => 'control-label']) !!}
                        {!! Form::textarea('message','' , ['class' => 'form-control form-control-normal', 'placeholder' => 'Your reply....']) !!}
                        <p class="help-block"></p>
                        @if($errors->has('message'))
                            <p class="help-block error">
                                {{ $errors->first('message') }}
                            </p>
                        @endif
                    </div>
                </div>
            </div>
        </div>
        <div class="ln_solid"></div>
        <div class="form-group">
          <div class="col-md-6 col-sm-6 col-xs-12 col-md-offset-3">
            <input type="hidden" name="id" value="{{$ureq->id}}">
            <button type="submit" class="btn btn-success">Reply</button>
          </div>
        </div>
    {!! Form::close() !!}
    </div>
    @endif
  </div>
<div class="card">
    <div class="card-body">





                                    <div class="card-body pt-0">
                                        <div class="card b-all shadow-none">
                                            <div class="card-body">
                                                <h3 class="card-title mb-0">{{$ureq->subject}}</h3>
                                            </div>
                                            <div>
                                                <hr class="mt-0">
                                            </div>
                                            <div class="card-body">
                                                <div class="d-flex mb-5">
                                                    <div class="pl-2">
                                                        <h4 class="mb-0">From: {{$ureq->from_username}}</h4>
                                                        <small class="text-muted">{{$ureq->created_at}}</small>
                                                    </div>
                                                </div>
                                                <p>{{$ureq->curr_message}}</p>
                                            </div>
                                            <div>
                                                <hr class="mt-0">
                                            </div>
                                            <div class="card-body">
                                                <div class="d-flex mb-5">
                                                    <div class="pl-2">
                                                        <h4 class="mb-0">From: Support</h4>
                                                        <small class="text-muted">{{$ureq->reply_date}}</small>
                                                    </div>
                                                </div>
                                                <p>{{$ureq->curr_reply}}</p>
                                            </div>
                                            <div>
                                                <hr class="mt-0">
                                            </div>
                                            <div class="card-body">
                                                <div class="d-flex mb-5">
                                                    <div class="pl-2">
                                                        <h4 class="mb-0">Previous Messages</h4>
                                                    </div>
                                                </div>
                                                <p>{!!nl2br($ureq->past_message, true)!!}</p>
                                            </div>
                                        </div>
                                    </div>


    </div>
</div>
<div class="modal fade" id="loadModalAjax" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" style="display: none;" aria-hidden="true">
  <div class="modal-dialog modal-lg" role="document">
    <div class="modal-content">
    </div>
    <!-- /.modal-content -->
   </div>
  <!-- /.modal-dialog -->
</div>
</div>

@stop

@section('javascript')
@endsection
