<div>

        <!--- Modal --->

        <div wire:ignore.self
        class="modal fade"
        id="CompteTiersClModal"
        tabindex="-1"
        role="dialog"
        aria-labelledby="myLargeCompteClientModal"
        aria-hidden="true"
    >
        <div class="modal-dialog modal-dialog-centered">
            <div class="modal-content">
                <div class="modal-header">
                    <h4 class="modal-title" id="myLargeCompteClientModal">
                        <?php echo e($title_modal_cl); ?>

                    </h4>
                    <button
                        type="button"
                        class="close"
                        wire:click="CloseModalNewCompteCl"
                    >
                        ×
                    </button>
                </div>
                <form method="POST">
                <div class="modal-body">
                            <div class="row">
                                <div class="col-md-6">
                                    <div class="form-group">
                                        <label for="">Tiers - Client <span style="color:red;">*</span></label>
                                        <select  class="form-control" wire:model="tiers_id_cl"  >
                                            <option value=""> -- Select -- </option>
                                            <!-- __BLOCK__ --><?php $__currentLoopData = get_select_tiers('client'); $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $data): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                               
                                                <option value="<?php echo e($data->id); ?>"><?php echo e($data->denomination); ?></option>
                                            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?> <!-- __ENDBLOCK__ -->
                                        </select>
                                        <!-- __BLOCK__ --><?php $__errorArgs = ['tiers_id'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?>
                                            <small class="form-text text-danger"><?php echo e($message); ?></small>
                                        <?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?> <!-- __ENDBLOCK__ -->
                                    </div>
                                </div>
                                <div class="col-md-6">
                                    <div class="form-group">
                                        <label for="">Numéro compte <span style="color:red;">*</span></label>
                                        <input type="text"  class="form-control" wire:model="num_compte_cl" placeholder="41xxxxxx" maxlength="8" <?php if(!$isNew_cl): ?>  readonly <?php endif; ?>>
                                        <!-- __BLOCK__ --><?php $__errorArgs = ['num_compte_cl'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?>
                                            <small class="form-text text-danger"><?php echo e($message); ?></small>
                                        <?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?> <!-- __ENDBLOCK__ -->
                                    </div>
                                </div>
                            </div>
                            <div class="row">
                                <div class="col-md-12">
                                    <div class="form-group">
                                        <label for="">Intitulé compte <span style="color:red;">*</span></label>
                                        <input type="text" name="nom_compte" id="" class="form-control" wire:model="nom_compte_cl" placeholder="intitulé du compte" maxlength="100">
                                        <!-- __BLOCK__ --><?php $__errorArgs = ['nom_compte_cl'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?>
                                            <small class="form-text text-danger"><?php echo e($message); ?></small>
                                        <?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?> <!-- __ENDBLOCK__ -->
                                    </div>
                                </div>
                            </div>
                </div>
                <div class="modal-footer">
                    <button
                        type="button"
                        class="btn btn-secondary"
                        wire:click="CloseModalNewCompteCl"
                    >
                        Close
                    </button>
                    <button type="button" class="btn <?php if($isNew_cl): ?> btn-primary <?php else: ?> btn-success <?php endif; ?>" wire:click="saveCompteTiersCl" wire:loading.attr="disabled" style="width:28%;">
                        <div class="spinner-border spinner-border-sm"  role="status" wire:loading wire:target="saveCompteTiersCl">
                            <span class="visually-hidden"></span>
                        </div>
        
                        <div wire:loading.remove wire:target="saveCompteTiersCl">
                            <!-- __BLOCK__ --><?php if($isNew_cl): ?>  Enregistrer 
                            <?php else: ?>  Mettre à jour
                            <?php endif; ?> <!-- __ENDBLOCK__ -->
                        </div>
                    </button>
                </div>
            </form>
            </div>
        </div>
    </div>
<!-- end modal ---->

<!--- Modal --->

        <div wire:ignore.self
        class="modal fade"
        id="CompteTiersFnModal"
        tabindex="-1"
        role="dialog"
        aria-labelledby="myLargeCompteFournModal"
        aria-hidden="true"
    >
        <div class="modal-dialog modal-dialog-centered">
            <div class="modal-content">
                <div class="modal-header">
                    <h4 class="modal-title" id="myLargeCompteFournModal">
                        <?php echo e($title_modal_fn); ?>

                    </h4>
                    <button
                        type="button"
                        class="close"
                        wire:click="CloseModalNewCompteFn"
                    >
                        ×
                    </button>
                </div>
                <form method="POST">
                <div class="modal-body">
                            <div class="row">
                                <div class="col-md-6">
                                    <div class="form-group">
                                        <label for="">Tiers - Fournisseur <span style="color:red;">*</span></label>
                                        <select  class="form-control" wire:model="tiers_id_fn"  >
                                            <option value=""> -- Select -- </option>
                                            <!-- __BLOCK__ --><?php $__currentLoopData = get_select_tiers('fourn'); $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $data): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                              
                                                <option value="<?php echo e($data->id); ?>"><?php echo e($data->denomination); ?></option>
                                            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?> <!-- __ENDBLOCK__ -->
                                        </select>
                                        <!-- __BLOCK__ --><?php $__errorArgs = ['tiers_id_fn'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?>
                                            <small class="form-text text-danger"><?php echo e($message); ?></small>
                                        <?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?> <!-- __ENDBLOCK__ -->
                                    </div>
                                </div>
                                <div class="col-md-6">
                                    <div class="form-group">
                                        <label for="">Numéro compte <span style="color:red;">*</span></label>
                                        <input type="text"  class="form-control" wire:model="num_compte_fn" placeholder="40xxxxxx OU 48xxxxxx" maxlength="8" <?php if(!$isNew_fn): ?>  readonly <?php endif; ?>>
                                        <!-- __BLOCK__ --><?php $__errorArgs = ['num_compte_fn'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?>
                                            <small class="form-text text-danger"><?php echo e($message); ?></small>
                                        <?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?> <!-- __ENDBLOCK__ -->
                                    </div>
                                </div>
                            </div>
                            <div class="row">
                                <div class="col-md-12">
                                    <div class="form-group">
                                        <label for="">Intitulé compte <span style="color:red;">*</span></label>
                                        <input type="text" name="nom_compte" id="" class="form-control" wire:model="nom_compte_fn" placeholder="intitulé du compte" maxlength="100">
                                        <!-- __BLOCK__ --><?php $__errorArgs = ['nom_compte_fn'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?>
                                            <small class="form-text text-danger"><?php echo e($message); ?></small>
                                        <?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?> <!-- __ENDBLOCK__ -->
                                    </div>
                                </div>
                            </div>
                </div>
                <div class="modal-footer">
                    <button
                        type="button"
                        class="btn btn-secondary"
                        wire:click="CloseModalNewCompteFn"
                    >
                        Close
                    </button>
                    <button type="button" class="btn <?php if($isNew_fn): ?> btn-primary <?php else: ?> btn-success <?php endif; ?>" wire:click="saveCompteTiersFn" wire:loading.attr="disabled" style="width:28%;">
                        <div class="spinner-border spinner-border-sm"  role="status" wire:loading wire:target="saveCompteTiersFn">
                            <span class="visually-hidden"></span>
                        </div>
        
                        <div wire:loading.remove wire:target="saveCompteTiersFn">
                            <!-- __BLOCK__ --><?php if($isNew_fn): ?>  Enregistrer 
                            <?php else: ?>  Mettre à jour
                            <?php endif; ?> <!-- __ENDBLOCK__ -->
                        </div>
                    </button>
                </div>
            </form>
            </div>
        </div>
    </div>
<!-- end modal ---->




    <div class="profile-tab height-100-p">
        <div class="tab height-100-p">
            <ul class="nav nav-tabs customtab" role="tablist">
                <li class="nav-item">
                    <a wire:click.prevent="selectTab('client')" class="nav-link <?php echo e($tab == 'client' ? 'active' : ''); ?>" data-toggle="tab" href="#timeline" role="tab">Client</a>
                </li>
                <li class="nav-item">
                    <a wire:click.prevent="selectTab('fourn')" class="nav-link <?php echo e($tab == 'fourn' ? 'active' : ''); ?>" data-toggle="tab" href="#tasks" role="tab">Fournisseur</a>
                </li>
            </ul>
            <div class="tab-content">
                <!-- Timeline Tab start -->
                <div class="tab-pane fade <?php echo e($tab == 'client' ? 'show active' : ''); ?>" id="timeline" role="tabpanel">
                    <div class="pd-20">

                       
                        <div class="clearfix mb-20">
                            <div class="pull-right">
                                <button
                                    type="button"
                                    class="btn btn-primary btn-sm scroll-click"
                                    rel="content-y"
                                    wire:click="OpenModalNewCompteCl"
                                    
                                    ><i class="fa fa-plus"></i> Créer un Compte de Tiers
                                </button>
                            </div>
                        </div>
                           
                        

                        <?php
                            $n = 1;
                        ?>

                        <div class="row"> 

                            <div class="col-md-1">
                                <div class="input-group custom ">
                                    <select wire:model.live="per_page_cl"  class="form-control form-control-sm" >
                                        <option value="10">10</option>
                                        <option value="25">25</option>
                                        <option value="50">50</option>
                                        <option value="75">75</option>
                                        <option value="100">100</option>
                                    </select>
                                </div>
                            </div>
                            <div class="col-md-6 offset-md-5">
                                <div class="input-group custom ">
                                        <input
                                            type="text"
                                            class="form-control form-control-sm"
                                            placeholder="recherche"
                                            id="_filter"
                                            wire:model.live="search"
                                        />
                                        <div class="input-group-append custom">
                                            <span class="input-group-text"
                                                ><i class="icon-copy dw dw-search"></i
                                            ></span>
                                        </div>
                                </div>
                            </div>
                        </div>
                        <div class="table-responsive">
							<table id="table" class="table-striped mb-2" border="1" style="width:100%; font-size:15px;">
								<thead>
									<tr>
										<td align="center" style="width: 4%;"><b>#</b></td>
										<td class="pl-1" style="width: 10%;"><b>Compte</b></td>
										<td class="pl-1"><b>Intitulé</b></td>
										<td style="width: 30%;"><b>Denomination</b></td>
										<td align="center" style="width: 8%;"></td>
									</tr>
								</thead>
								<tbody>
                                   
                                    <!-- __BLOCK__ --><?php $__empty_1 = true; $__currentLoopData = $list_tiers_client; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $list): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); $__empty_1 = false; ?>
                                        <tr>
                                            <td align="center"><?php echo e($n); ?></td>
                                            <td  class="pl-1"><?php echo e($list->compte); ?></td>
                                            <td  class="pl-1"><?php echo e($list->intitule); ?></td>
                                            <td  class="pl-1"><?php echo e($list->denomination); ?></td>
                                            <td align="center"><a class="text-primary" href="#"
                                             wire:click="editCompteCompta(<?php echo e($list->id); ?>)" ><i class="dw dw-edit2"></i> edit</a
                                             ></td>
                                        </tr>

                                        <?php
                                            $n++ ;
                                        ?>
                                    <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); if ($__empty_1): ?>
                                        <tr>
                                            <td colspan="5" align="center">Aucune donnée trouvée</td>
                                        </tr>
                                    <?php endif; ?> <!-- __ENDBLOCK__ -->
									
                                    
								</tbody>
							</table>
                            <?php echo e($list_tiers_client->links()); ?>

						</div>
                    </div>
                </div>
                <!-- Timeline Tab End -->
                <!-- Tasks Tab start -->
                <div class="tab-pane fade <?php echo e($tab == 'fourn' ? 'show active' : ''); ?>" id="tasks" role="tabpanel">
                   <div class="pd-20 profile-task-wrap">
                    <div class="clearfix mb-20">
                        <div class="pull-right">
                            <button
                                type="button"
                                class="btn btn-primary btn-sm scroll-click"
                                rel="content-y"
                                wire:click="OpenModalNewCompteFn"
                                
                                ><i class="fa fa-plus"></i> Créer un Compte de Tiers
                            </button>
                        </div>
                    </div>
                       
                    

                    <?php
                        $n = 1;
                    ?>

                    <div class="row"> 

                        <div class="col-md-1">
                            <div class="input-group custom ">
                                <select wire:model.live="per_page_fn"  class="form-control form-control-sm" >
                                    <option value="10">10</option>
                                    <option value="25">25</option>
                                    <option value="50">50</option>
                                    <option value="75">75</option>
                                    <option value="100">100</option>
                                </select>
                            </div>
                        </div>
                        <div class="col-md-6 offset-md-5">
                            <div class="input-group custom ">
                                    <input
                                        type="text"
                                        class="form-control form-control-sm"
                                        placeholder="recherche"
                                        id="_filter"
                                        wire:model.live="search"
                                    />
                                    <div class="input-group-append custom">
                                        <span class="input-group-text"
                                            ><i class="icon-copy dw dw-search"></i
                                        ></span>
                                    </div>
                            </div>
                        </div>
                    </div>
                    <div class="table-responsive">
                        <table id="table" class="table-striped mb-2" border="1" style="width:100%; font-size:15px;">
                            <thead>
                                <tr>
                                    <td align="center" style="width: 4%;"><b>#</b></td>
                                    <td class="pl-1" style="width: 10%;"><b>Compte</b></td>
                                    <td class="pl-1"><b>Intitulé</b></td>
                                    <td style="width: 30%;"><b>Denomination</b></td>
                                    <td align="center" style="width: 8%;"></td>
                                </tr>
                            </thead>
                            <tbody>
                               
                                <!-- __BLOCK__ --><?php $__empty_1 = true; $__currentLoopData = $list_tiers_fourn; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $list): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); $__empty_1 = false; ?>
                                    <tr>
                                        <td align="center"><?php echo e($n); ?></td>
                                        <td  class="pl-1"><?php echo e($list->compte); ?></td>
                                        <td  class="pl-1"><?php echo e($list->intitule); ?></td>
                                        <td  class="pl-1"><?php echo e($list->denomination); ?></td>
                                        <td align="center"><a class="text-primary" href="#"
                                         wire:click="editCompteCompta(<?php echo e($list->id); ?>)" ><i class="dw dw-edit2"></i> edit</a
                                         ></td>
                                    </tr>

                                    <?php
                                        $n++ ;
                                    ?>
                                <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); if ($__empty_1): ?>
                                    <tr>
                                        <td colspan="5" align="center">Aucune donnée trouvée</td>
                                    </tr>
                                <?php endif; ?> <!-- __ENDBLOCK__ -->
                                
                                
                            </tbody>
                        </table>
                        <?php echo e($list_tiers_fourn->links()); ?>

                    </div>
                   
                   </div>
                </div>
                <!-- Tasks Tab End -->
              
            </div>
        </div>

    </div>
</div>




<?php $__env->startPush('scripts'); ?>

<script>
    	window.addEventListener('hideModalCl', event => {
					$('#CompteTiersClModal').modal('hide');
                  //  $('#modal-update-admin-lg').modal('hide');
				})

        window.addEventListener('showModalCl', event => {
					$('#CompteTiersClModal').modal('show');
				})

        window.addEventListener('hideModalFn', event => {
            $('#CompteTiersFnModal').modal('hide');
            //  $('#modal-update-admin-lg').modal('hide');
        })

        window.addEventListener('showModalFn', event => {
					$('#CompteTiersFnModal').modal('show');
				})
        
</script>
    
<?php $__env->stopPush(); ?><?php /**PATH D:\laravel_apps\big-manager\resources\views/livewire/compte-tiers.blade.php ENDPATH**/ ?>