@extends('layouts.app')

@section('title','All Account Customers')

@section('content')

<div class="main-content">

                <div class="page-content">
                    <div class="container-fluid">    
                        <div class="row">
                            <div class="col-12">
                                <div class="card">
                                    <div class="card-header">
                                        <div class="row">
                                        	<div class="col-lg-2 col-md-2 mob_marg">
                                        		<a href="{{route('maintain_accounts')}}" type="submit" class="btn btn-md btn-primary w-md btn-right distance_form">Add New</a>
                                        	</div>
                                        	<div class="col-lg-3 col-md-3">
                                        		<input type="text" class="form-control" id="horizontal-firstname-input" placeholder="SEARCH BY NAME/MOBILE">
                                        	</div>
                                        	<div class="col-lg-3 col-md-3 mob_marg">
                                        		<select name="payment_method" class="form-control">
                                        			<option value="cash">Cash</option>
                                        			<option value="card">Card</option>
                                        			<option value="account">Account</option>
                                        		</select>
                                        	</div>
                                        	<div class="col-lg-2 col-md-2 col-sm-6 mob_width">
                                        		<div class="btn-group btn-group-toggle" data-toggle="buttons">
                                                  <label class="btn btn-primary active">
                                                    Search
                                                  </label>
                                                  <label class="btn btn-secondary">
                                                     Reset
                                                  </label>
                                                  
                                                </div>
                                        	</div>
                                        	<div class="col-lg-2 col-md-2 col-sm-6 mob_width">
                                        		<div class="btn-group btn-group-toggle" data-toggle="buttons">
                                           
                                                  <label class="btn btn-primary">
                                                     <i class="fa fa-file-excel"></i> Export
                                                  </label>
                                                  <label class="btn btn-secondary">
                                                     <i class="fa fa-file-pdf" aria-hidden="true"></i> Export
                                                  </label>
                                                </div>
                                        	</div>
                                        </div>
                                        
                                    </div>
                                    <div class="card-body">
        
                                        <div class="table-responsive">
                                            <table class="table table-bordered table-responsive nowrap w-100">
                                            <thead>
                                            <tr>
                                                <th>ID</th>
                                                <th>REF</th>
                                                <th>NAME</th>
                                                <th>ACTIVE</th>
                                                <th>CASH</th>
                                                <th>INVOICE</th>
                                                <th>AUTO REVIEW</th>
                                                <th>SC</th>
                                                <th>DISC PRICE</th>
                                                <th>DISC COST</th>
                                                <th>BC</th>
                                                <th>EDIT</th>
                                            </tr>
                                            </thead>
        
        
                                            <tbody>
                                                @foreach($accounts as $customers)
                                            <tr>
                                                <td>{{ $customers->record_id }}</td>
                                                <td>{{ $customers->ref_name }}</td>
                                                <td>{{ $customers->name_on_invoice }}</td>
                                                <td>{{$customers->status}}</td>
                                                <td>{{$customers->payment_method}}</td>
                                                <td>@if($customers->payment_method=='invoice') <span>Yes</span>
                                                @else
                                                    <span>No</span>
                                                @endif    
                                                </td>
                                                
                                                <td>No</td>
                                                <td>{{$customers->service_charge}}%</td>
                                                <td>{{$customers->discount_price}}%</td>
                                                <td>{{$customers->discount_cost}}%</td>
                                                <td>{{$customers->booking_charge}}%</td>
                                                <td><a href="#" class="btn btn-primary">Edit</a></td>
                                            </tr>
                                            @endforeach
                                            
                                            </tbody>
                                        </table>
                                        </div>
        
                                    </div>
                                </div>
                            </div> <!-- end col -->
                        </div> <!-- end row -->
        
                    </div> <!-- container-fluid -->
                </div>
                <!-- End Page-content -->

                
            </div>
            <!-- end main content-->

        </div>
        <!-- END layout-wrapper -->


@endsection