@extends('layouts.masterHome2')

@section('content')


 
    
    <div class="card">
               
              <!-- /.card-header -->
              <div class="card-body">
                <table id="example1" class="table table-bordered table-striped">
                  <thead>
                  
                 <tr >
                  <th style="text-align:center;vertical-align: middle;background-color:#2C4E71;color:#FFF;border-color:#0000003c;border-width: 2px;"> تاريخ نشأة السند    </th>
                  <th style="text-align:center;vertical-align: middle;background-color:#2C4E71;color:#FFF;border-color:#0000003c;border-width: 2px;"> العميل    </th>
                  <th style="text-align:center;vertical-align: middle;background-color:#2C4E71;color:#FFF;border-color:#0000003c;border-width: 2px;"> الفاتورة    </th>
                  <th style="text-align:center;vertical-align: middle;background-color:#2C4E71;color:#FFF;border-color:#0000003c;border-width: 2px;"> المبلغ    </th>
                  <th style="text-align:center;vertical-align: middle;background-color:#2C4E71;color:#FFF;border-color:#0000003c;border-width: 2px;"> ايداعات/شيكات    </th>
                  <th style="text-align:center;vertical-align: middle;background-color:#2C4E71;color:#FFF;border-color:#0000003c;border-width: 2px;"> الحسابات الاخري    </th>
                  <th style="text-align:center;vertical-align: middle;background-color:#2C4E71;color:#FFF;border-color:#0000003c;border-width: 2px;"> نظير    </th>
                  <th style="text-align:center;vertical-align: middle;background-color:#2C4E71;color:#FFF;border-color:#0000003c;border-width: 2px;"> ملاحظات    </th>                  

                 </tr>
                 </thead>
              <tbody>
                           
                @foreach( $receipts as $receipt )   
                 
                 

                 
                <tr>
                 
                  <td style="text-align:center; word-break: break-word; font-weight:900;border-color:#0000003c;font-size:18px" >{{$receipt->created_at}} </td>
                  <th style="text-align:center; word-break: break-word; font-weight:900;border-color:#0000003c;font-size:18px"> {{$receipt->client->name}}    </th>
                  <th style="text-align:center; word-break: break-word; font-weight:900;border-color:#0000003c;font-size:18px"> 
                  
                  <a   href='{{url("/invoice/details/$receipt->invoice_id")}}'  > {{$receipt->invoice_id ? "#". $receipt->invoice_id:""}} </a>  
                     
                 </th>
                  <th style="text-align:center; word-break: break-word; font-weight:900;border-color:#0000003c;font-size:18px"> {{$receipt->pay}}    </th>
                  <th style="text-align:center; word-break: break-word; font-weight:900;border-color:#0000003c;font-size:18px"> 
                  <a   href=''  > {{$receipt->cheque_id ? "#".$receipt->cheque_id:"" }} </a>    
                  
                    </th>
                    <th style="text-align:center; word-break: break-word; font-weight:900;border-color:#0000003c;font-size:18px"> {{$receipt->safe_account ? $receipt->safe_account->payment_method->name ." -- ".$receipt->safe_account->branch->name  :""}}    </th>
                  <th style="text-align:center; word-break: break-word; font-weight:900;border-color:#0000003c;font-size:18px"> {{$receipt->note1}}    </th>
                  <th style="text-align:center; word-break: break-word; font-weight:900;border-color:#0000003c;font-size:18px"> {{$receipt->note2}}    </th>
                </tr>
               @endforeach
                </tbody>
                </table>
              </div>
              <!-- /.card-body -->
            </div>  

@endsection
