@extends('main')

@section('css')
<link href="{{ asset('/css/bootstrapValidator.min.css')}}" rel="stylesheet">
<link href="{{ asset('plugins/datatables/css/jquery.dataTables.css')}}" rel="stylesheet">
@endsection

@section('content')
<div class="container">
   <ol class="breadcrumb cust-breadcrumb">
 <li><a href="{{url('/')}}">Home</a></li>
              <li><a href="{{url('/messages')}}">Messages</a></li>
              <li class="active">Trash</li>
  </ol>
            <div class="row">

  <div class="clearfix"></div>
                @if (Session::get('error_msg'))
                  <div class="col-md-12">
                    <div class="alert alert-danger">
                       <button type="button" class="close" data-dismiss="alert" aria-label="Close">
                         <span aria-hidden="true">&times;</span>
                       </button>
                        {{Session::get('error_msg')}}
                    </div>
                  </div>
                @endif
                @if (Session::get('succ_msg'))
                  <div class="col-md-12">
                    <div class="alert alert-success">
                       <button type="button" class="close" data-dismiss="alert" aria-label="Close">
                         <span aria-hidden="true">&times;</span>
                       </button>
                        {{Session::get('succ_msg')}}
                    </div>
                  </div>
                @endif


</div>
         <section class="body-content"> 
  <div class="row">
        @include("left_menu")
        <div class="col-sm-9 light-pannel">

<div class="rt-panel-block">
<div class="my-profiles-block"> 
 <div id="render-here">
          </div>
      <div id="render-this">    
<div class="inbox-block">
<div class="row">
<div class="col-lg-8 col-sm-6 col-md-7 col-xs-6"><h1 class="innerpage-heading">Trash</h1></div>
<div class="col-lg-4 col-sm-6 col-md-5 col-xs-6">
<div class="inbox-action-btns">

<button class="btn delete-btn" id="delete_message">Delete forever</button>

</div>

</div>
</div>
            <div class="row">

  <div class="clearfix"></div>
                @if (Session::get('error_msg'))
                  <div class="col-md-12">
                    <div class="alert alert-danger">
                       <button type="button" class="close" data-dismiss="alert" aria-label="Close">
                         <span aria-hidden="true">&times;</span>
                       </button>
                        {{Session::get('error_msg')}}
                    </div>
                  </div>
                @endif
                @if (Session::get('succ_msg'))
                  <div class="col-md-12">
                    <div class="alert alert-success">
                       <button type="button" class="close" data-dismiss="alert" aria-label="Close">
                         <span aria-hidden="true">&times;</span>
                       </button>
                        {{Session::get('succ_msg')}}
                    </div>
                  </div>
                @endif


</div>
</div>
<div class="inbox-content-block">

<div class="table-responsive visible-360">
<div class="table-bordered zui-table zui-table-rounded table">
   <form name="deleteMessageForm" id="deleteMessageForm" action="{{url('messages/delete/for_ever')}}" method="post">
<input type="hidden" name="_token" value="{{ csrf_token() }}">
 <table id="users-trash-table" class="table table-condensed table-bordered">
                    <thead>
                      <tr>
                         <th class="width-10"><div class="search_input"><input type="checkbox" name="select_all_check" id="select_all_check"><label></label></div></th>
          <th class="width-15">Sender / Sent to</th>
                     
                        <th class="width-60">Subject</th>
                        <th class="width-15">Date</th>
                      </tr>
                    </thead>
                  </table>
</form>
                 
</div></div>
           </div>
</div>
</div>
</div>  

</div>
    <div id="compose_message_modal" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
        <div class="modal-dialog">
        <div class="modal-content">
        <div class="modal-header">
            <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
            <h4 class="modal-title">Compose Message</h4>
        </div>
        <div class="modal-body">
          <form class="form-horizontal" method="post" id="composeMessageForm" name="composeMessageForm" action="{{url('message/compose')}}">
              <input type="hidden" name="_token" value="{{ csrf_token() }}">
              <input type="hidden" name="sel_to_prof_id" id="sel_to_prof_id">
              <div class="form-group">
                <label class="col-sm-2 control-label" >To<span class="reqired-val">*</span></label>
                <div class="col-sm-10">
                    <input type="text" name="to" id="to" class="form-control" data-bv-field="subject">
                </div>
              </div>
              <div class="form-group">
                <label class="col-sm-2 control-label" >Subject<span class="reqired-val">*</span></label>
                <div class="col-sm-10">
                    <input type="text" name="subject" id="Subject" class="form-control" data-bv-field="subject">
                </div>    
              </div>
              <div class="form-group">
                <label class="col-sm-2 control-label" >Message<span class="reqired-val">*</span></label>
                <div class="col-sm-10">
                    <textarea name="message" id="message" class="form-control" rows="10"></textarea>
                </div>    
              </div>
              <div class="form-group">
                <div class="col-sm-2"></div>
                  <div class="col-md-10">
                      <button data-dismiss="modal" class="btn-close btn delete-btn clear_form pull-right" type="button">Close</button>
                      <button type="submit" value="Submit" class="btn compose-btn">Send</button>
                  </div>
              </div>
          </form>          
        </div><!-- End of Modal body -->
        </div><!-- End of Modal content -->
        </div><!-- End of Modal dialog -->
    </div><!-- End of Profile Image Modal -->        
 </section>
</div>
@endsection
@section('js')
<script src="{{ asset('js/bootstrapValidator.min.js')}}"></script>
<script src="{{ asset('js/bootbox.js')}}"></script>
<script src="{{ asset('plugins/datatables/js/jquery.dataTables.js')}}"></script>
<script src="{{ asset('js/typeahead_0.11.js')}}"></script>
<script src="{{ asset('js/handlebars.js')}}"></script>
<script src="{{ asset('js/validation.js')}}"></script>
<script src="{{ asset('js/messages_js.js')}}"></script>
@endsection
