<?php $__env->startSection('main-container'); ?>
<main id="main" class="main">
<?php echo $__env->make('cdn', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?>

<div class="row page-titles mx-0">

    <div class="col-sm-6 p-md-0">

        <div class="breadcrumb-range-picker">

             <h4>Edit Driver</h4>

        </div>

    </div>

    <div class="col-sm-6 p-md-0 justify-content-sm-end mt-2 mt-sm-0 d-flex">

        <a href="<?php echo e(route('drivers')); ?>">

            <button type="button" class="btns success-btn btn-sm">

                <i class="fas fa-arrow-left"></i> Back

            </button>

        </a>

    </div>

</div>



<div class="content-wrapper mt-4">

    <?php echo $__env->make('flash_msg', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?>

    <div class="row">

        <div class="col-12">

            <div class="card">

                <div class="card-body">

                    <form action="<?php echo e(route('driver.update',$driver->Id)); ?>" method="POST" class="form-sample" enctype="multipart/form-data">
                            <?php echo e(csrf_field()); ?>


                        <div class="row">

                            <div class="form-group col-lg-6">
                                <label>Driver Code<span class="text-danger">*</span></label>
                                <input type="text" class="form-control" name="code" value="<?php echo e($driver->Code); ?>" placeholder="Driver Code" required>
                                <span class="text-danger"> <?php $__errorArgs = ['code'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?><?php echo e($message); ?><?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?> </span>
                            </div>

                            <div class="form-group col-lg-6">
                                <label>Driver Name<span class="text-danger">*</span></label>
                                <input type="text" class="form-control" name="driver_name" value="<?php echo e($driver->Name); ?>" placeholder="Driver Name" required>
                                <span class="text-danger"> <?php $__errorArgs = ['driver_name'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?><?php echo e($message); ?><?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?> </span>
                            </div>

                            <div class="form-group col-lg-6">
                                <label>Mobile No.<span class="text-danger">*</span></label>
                                <input type="number" class="form-control" id="phoneno" name="mobile_no" value="<?php echo e($driver->MobileNumber); ?>" placeholder="Mobile Number" required>
                                <span class="text-danger"> <?php $__errorArgs = ['mobile_no'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?><?php echo e($message); ?><?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?> </span>
                            </div>

                            <div class="form-group col-lg-6">
                                <label>DOB<span class="text-danger">*</span></label>
                                <input type="date" class="form-control" name="dob" value="<?php echo e($driver->DateOfBirth); ?>" placeholder="Date Of Birth" required>
                                <span class="text-danger"> <?php $__errorArgs = ['dob'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?><?php echo e($message); ?><?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?> </span>
                            </div>

                            <div class="form-group col-lg-6">
                                <label>Incharge Name<span class="text-danger">*</span></label>
                                <input type="text" class="form-control" name="incharge_name" value="<?php echo e($driver->InchargeName); ?>" placeholder="Incharge Name" required>
                                <span class="text-danger"> <?php $__errorArgs = ['incharge_name'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?><?php echo e($message); ?><?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?> </span>
                            </div>

                            <div class="form-group col-lg-6">
                                <label>DL Number<span class="text-danger">*</span></label>
                                <input type="text" class="form-control" name="dl_number" value="<?php echo e($driver->DLNumber); ?>" placeholder="Dl Number" required>
                                <span class="text-danger"> <?php $__errorArgs = ['dl_number'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?><?php echo e($message); ?><?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?> </span>
                            </div>

                            <div class="form-group col-lg-6">
                                <label>DL Renewal Date<span class="text-danger">*</span></label>
                                <input type="date" class="form-control" name="dl_revewal_date" value="<?php echo e($driver->DLRenewalDate); ?>" placeholder="DL Renewal Date" required>
                                <span class="text-danger"> <?php $__errorArgs = ['dl_revewal_date'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?><?php echo e($message); ?><?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?> </span>
                            </div>

                            <div class="form-group col-lg-6">
                                <label>RTO<span class="text-danger">*</span></label>
                                <input type="text" class="form-control" name="rto" value="<?php echo e($driver->RTO); ?>" placeholder="RTO" required>
                                <span class="text-danger"> <?php $__errorArgs = ['rto'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?><?php echo e($message); ?><?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?> </span>
                            </div>

                            <div class="form-group col-lg-6">
                                <label>Aadhar File</label>
                                <input type="file" class="form-control" name="addhar_file">
                                <span class="text-danger"> <?php $__errorArgs = ['addhar_file'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?><?php echo e($message); ?><?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?> </span>
                            </div>                            

                            <div class="form-group col-lg-6">
                                <label>License File</label>
                                <input type="file" class="form-control" name="license_file">
                                <span class="text-danger"> <?php $__errorArgs = ['license_file'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?><?php echo e($message); ?><?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?> </span>
                            </div>

                            <div class="form-group col-lg-6">
                                <?php if($driver->Aadhar_file): ?>
                                <a href="<?php echo e(url($driver->Aadhar_file)); ?>" target="_blank" alt="Aadhar File" title="Aadhar File">
                                    <img src="<?php echo e(url($driver->Aadhar_file)); ?>" class="file">
                                </a>
                                <?php endif; ?>
                            </div>

                            <div class="form-group col-lg-6">
                                <?php if($driver->License_file): ?>
                                <a href="<?php echo e(url($driver->License_file)); ?>" target="_blank" alt="License File" title="License File">
                                    <img src="<?php echo e(url($driver->License_file)); ?>" class="file" >
                                </a>
                                <?php endif; ?>
                            </div>

                            <div class="form-group col-lg-12">

                                <label>Bank Details </label>

                                <textarea class="form-control ckeditor" name="bank_details" placeholder="Enter Bank Details"><?php echo e($driver->Account_info); ?></textarea>

                                <span class="text-danger"> <?php $__errorArgs = ['bank_details'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?><?php echo e($message); ?><?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?> </span>

                            </div>

                            <div class="text-center">
                                <button type="submit" class="btns primary-btn btn-sm">Update</button>
                            </div>

                        </div>

                    </form>

                </div>

            </div>

        </div>

    </div>

    

</div>

</main><!-- End #main -->

<?php $__env->stopSection(); ?>

<script src="//cdn.ckeditor.com/4.14.1/standard/ckeditor.js"></script>
<script src="https://code.jquery.com/jquery-3.5.1.min.js"></script>
<?php echo $__env->make('backend.company.layouts.main', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /home/vinecork/public_html/webdev/logisticcrm/resources/views/seller/driver/edit.blade.php ENDPATH**/ ?>