
<?php $__env->startSection('title'); ?>
Clients 
<?php $__env->stopSection(); ?>
<?php $__env->startSection('brand'); ?>
menu-item-active
<?php $__env->stopSection(); ?>
<?php $__env->startSection('css'); ?>
<link rel="stylesheet" href="http://cdn.bootcss.com/toastr.js/latest/css/toastr.min.css">
<link rel="stylesheet" href="https://cdn.datatables.net/1.10.24/css/jquery.dataTables.min.css">
<?php $__env->stopSection(); ?>
<?php $__env->startSection('content'); ?>
<div class="content d-flex flex-column flex-column-fluid" id="kt_content">
    <!--begin::Subheader-->
    <div class="subheader py-2 py-lg-4 subheader-solid" id="kt_subheader">
        <div class="container-fluid d-flex align-items-center justify-content-between flex-wrap flex-sm-nowrap">
            <!--begin::Info-->
            <div class="d-flex align-items-center flex-wrap mr-2">
                <!--begin::Page Title-->
                <h5 class="text-dark font-weight-bold mt-2 mb-2 mr-5">Dashboard</h5>
                <!--end::Page Title-->
                <!--begin::Actions-->
                <div class="subheader-separator subheader-separator-ver mt-2 mb-2 mr-4 bg-gray-200"></div>
                <h6 class="text-dark font-weight-bold mt-2 mb-2 mr-5">Clients</h6>
                <!--end::Actions-->
            </div>
            <!--end::Info-->
        </div>
    </div>
    <!--end::Subheader-->
    <!--begin::Entry-->
    <div class="d-flex flex-column-fluid">
        <!--begin::Container-->
        <div class="container">
            <!--begin::Dashboard-->
            <!--begin::Row-->
            <div class="row">
                <div class="col-lg-12">
                    <div class="card card-custom">
					 	<div class="card-header">
						    <div class="card-title">
						   		<h3 class="card-label">All Clients List</h3>
						    </div>

						    <div class="card-toolbar">
							   	<ul class="nav nav-bold nav-pills ml-auto">
								    <li class="nav-item">
								    	 <!-- Add Logo-->
					                    <button type="button" class="btn btn-primary" data-toggle="modal" data-target="#exampleModalLong">
					                        <i class="flaticon2-plus-1 icon-lg"></i> Add New Clients
					                    </button>

					                    <!-- Modal-->
					                    <div class="modal fade" id="exampleModalLong" data-backdrop="static" tabindex="-1" role="dialog" aria-labelledby="staticBackdrop" aria-hidden="true">
					                        <div class="modal-dialog" role="document">
					                            <div class="modal-content">
					                                <div class="modal-header">
					                                    <h5 class="modal-title" id="exampleModalLabel">Create New Clients</h5>
					                                    <button type="button" class="close" data-dismiss="modal" aria-label="Close">
					                                        <i aria-hidden="true" class="ki ki-close"></i>
					                                    </button>
					                                </div>
					                                <div class="modal-body">
					                                   	<form action="<?php echo e(url('admin/post/logo')); ?>" method="POST" enctype="multipart/form-data">
					                                   		<?php echo csrf_field(); ?>
					                                   		<div class="form-group">
																<label>Clients Photo</label>
																<div></div>
																<div class="custom-file">
																	<input type="file" class="custom-file-input" id="customFile" name="logo" id="profile-img"/>
																	<label class="custom-file-label" for="customFile">Choose file</label>
																	<img src="" id="profile-img-tag" width="200px" style="padding-top: 5px;" />
																</div>
															</div>
															<div class="form-group">
																<button type="button" class="btn btn-light-primary font-weight-bold" data-dismiss="modal">Close</button>
					                                    		<button type="submit" class="btn btn-primary font-weight-bold">Submit</button>
															</div>
														</form>
					                                </div>
					                            		
					                            </div>
					                        </div>
					                    </div>
								    </li>
							   </ul>
							</div>
						</div>
						<div class="card-body">
						  	<!--begin: Search Form-->
										<!--begin: Datatable-->
										<table id="usertable" class="table table-bordered table-striped">
											<thead>
												<tr>
													<th>Order ID</th>
													<th>Photo</th>
													<th>Status</th>
													<th>Action</th>
												</tr>
											</thead>
											<tbody>
												<?php
													$i = 1;
												?>
												<?php $__currentLoopData = $all_logo; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $logo): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
												<tr>
													<td><?php echo e($i++); ?></td>
													<td style="background: #555555;"><img src="<?php echo e(asset('uploads/logo')); ?>/<?php echo e($logo->logo); ?>" alt="" width="80px;"></td>
													<td>
														<?php if($logo->status == 0): ?>
														<a href="#statusModal<?php echo e($logo->id); ?>" data-toggle="modal" class="btn btn-success"  ><i class="fas fa-toggle-off icon-md"></i>Active
					                                    </a>
														<?php else: ?>
														<a href="#statusModal<?php echo e($logo->id); ?>" data-toggle="modal" class="btn btn-danger"  ><i class="fas fa-toggle-on icon-md"></i></i> Deactive
					                                    </a>
														<?php endif; ?>
													</td>
													<td>
					                                    <a href="#editModal<?php echo e($logo->id); ?>" data-toggle="modal" class="btn btn-warning"  ><i class="flaticon2-edit icon-lg"></i> Edit
					                                    </a>
					                                    <a href="#deleteModal<?php echo e($logo->id); ?>" data-toggle="modal" class="btn btn-danger"><i class="flaticon2-rubbish-bin-delete-button icon-lg"></i> Delete
					                                    </a>
													</td>
											</tr>
<!-- Status Update -->
<div class="modal fade" id="statusModal<?php echo e($logo->id); ?>" tabindex="-1" role="dialog" aria-labelledby="exampleModalLongTitle" aria-hidden="true">
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-header state modal-primary">

            </div>
            <div class="modal-body m-auto">
                <h5 class="modal-title" id="exampleModalLongTitle">Are You Sure for Change Status?</h5>
            </div>
            <div class="modal-footer">
            	<?php if($logo->status == 0): ?>
                <a href="<?php echo e(url('admin/logo/status')); ?>/<?php echo e($logo->id); ?>" class="btn btn-danger">Deactive</a>
                <?php else: ?>
                <a href="<?php echo e(url('admin/logo/status')); ?>/<?php echo e($logo->id); ?>" class="btn btn-danger">Active</a>
                <?php endif; ?>
                <button type="button" class="btn btn-secondary" data-dismiss="modal">Cancel</button>
            </div>
        </div>
    </div>
</div>
<!-- Delete -->
<div class="modal fade" id="deleteModal<?php echo e($logo->id); ?>" tabindex="-1" role="dialog" aria-labelledby="exampleModalLongTitle" aria-hidden="true">
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-header state modal-primary">

            </div>
            <div class="modal-body m-auto">
                <h5 class="modal-title" id="exampleModalLongTitle">Are you sure you want to delete ?</h5>
            </div>
            <div class="modal-footer">
                <a href="<?php echo e(url('admin/logo/delete')); ?>/<?php echo e($logo->id); ?>" class="btn btn-danger">Delete</a>
                <button type="button" class="btn btn-secondary" data-dismiss="modal">Cancel</button>
            </div>
        </div>
    </div>
</div>

<!-- Edit -->
<div class="modal fade " id="editModal<?php echo e($logo->id); ?>" tabindex="-1" role="dialog" aria-labelledby="exampleModalLongTitle" aria-hidden="true">
    <div class="modal-dialog modal-dialog-scrollable" role="document">
        <div class="modal-content">
            <div class="modal-header state modal-primary">
                <h5 class="modal-title" id="exampleModalLongTitle">Are you sure you want to Edit ?</h5>
                <button type="button" class="btn btn-warning" data-dismiss="modal"><i class="fas fa-times"></i></button>
            </div>
            <div class="modal-body">
                <form action="<?php echo e(url('admin/update/logo')); ?>" method="POST" enctype="multipart/form-data">
	           		<?php echo csrf_field(); ?>
	           		<div class="form-group">
						<label>Clients Photo</label>
						<div></div>
						<div class="custom-file">
							<input type="file" class="custom-file-input" id="customFile" name="logo" id="profile-img"/>
							<input type="hidden" class="custom-file-input" id="customFile" name="id" id="profile-img" value="<?php echo e($logo->id); ?>" />
							<label class="custom-file-label" for="customFile">Choose file</label>
							<img src="" id="profile-img-tag" width="200px" style="padding-top: 5px;" />
						</div>
						<div>
							<img src="<?php echo e(asset('uploads/logo')); ?>/<?php echo e($logo->logo); ?>" width="100px;" alt="">
						</div>
					</div>
					<div class="form-group">
						<button type="button" class="btn btn-light-primary font-weight-bold" data-dismiss="modal">Close</button>
	            		<button type="submit" class="btn btn-primary font-weight-bold">Update</button>
					</div>
				</form>
            </div>
        </div>
    </div>
</div>
												<?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
											</tbody>
										</table>
										<!--end: Datatable-->
						</div>
					</div>
                </div>
            </div>
            <!--end::Row-->
            <!--end::Dashboard-->
        </div>
        <!--end::Container-->
    </div>
    <!--end::Entry-->
</div>

<?php $__env->stopSection(); ?>
<?php $__env->startSection('js'); ?>

<script type="text/javascript" charset="utf8" src="https://cdn.datatables.net/1.10.25/js/jquery.dataTables.js"></script>

<script src="http://cdn.bootcss.com/toastr.js/latest/js/toastr.min.js"></script>

<?php echo Toastr::message(); ?>

<?php if(Session::has('message')): ?>
toastr.options =
{
"closeButton" : true,
"progressBar" : true
}
  toastr.success("<?php echo e(session('message')); ?>");
<?php endif; ?>
<?php if(Session::has('message')): ?>
toastr.options =
{
"closeButton" : true,
"progressBar" : true
}
  toastr.error("<?php echo e(session('message')); ?>");
<?php endif; ?>
<script>
    $(function () {
            $("#usertable").DataTable({
                "responsive": true,
                "autoWidth": false,
            });
    });
</script>
<script type="text/javascript">
        function readURL(input) {
            if (input.files && input.files[0]) {
                var reader = new FileReader();
                
                reader.onload = function (e) {
                    $('#profile-img-tag').attr('src', e.target.result);
                }
                reader.readAsDataURL(input.files[0]);
            }
        }
        $("#profile-img").change(function(){
            readURL(this);
        });
</script>
<?php $__env->stopSection(); ?>

<?php echo $__env->make('layouts.dashboard', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /home/shininga322/demo.shiningapparels.com/resources/views/admin/logo/create.blade.php ENDPATH**/ ?>