<?php if (isset($component)) { $__componentOriginal783808d09c489a73db593e82465042f2d47695ce = $component; } ?>
<?php $component = $__env->getContainer()->make(App\View\Components\PortalLayout::class, [] + (isset($attributes) ? (array) $attributes->getIterator() : [])); ?>
<?php $component->withName('portal-layout'); ?>
<?php if ($component->shouldRender()): ?>
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
<?php if (isset($attributes) && $constructor = (new ReflectionClass(App\View\Components\PortalLayout::class))->getConstructor()): ?>
<?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?>
<?php endif; ?>
<?php $component->withAttributes([]); ?>

    <section id="breadcrumbs" class="breadcrumbs">
        <div class="container">

            <div class="d-flex justify-content-between align-items-center">
                <h2>Communes</h2>
                <ol>
                    <li><a href="<?php echo e(route('portal.home')); ?>">Accueil</a></li>
                    <li>Communes</li>
                </ol>
            </div>

        </div>
    </section>

    <section id="document" class="document">
        <div class="container">

            <div class="row row-cols-2">
                <?php $__currentLoopData = $communes; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $commune): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                <div class="col mb-3 d-flex">
                    <div class="col-lg-4 d-flex section-bg">
                        <img src="<?php echo e(asset('images/communes/logos/' . Str::slug($commune->name, '-') . '.jpg')); ?>" class="rounded-circle commune-img">
                        <div class="mt-2 align-middle">
                            <a href="<?php echo e(route('portal.communes.show', $commune)); ?>" class="ms-2"><?php echo e($commune->name); ?></a>
                        </div>
                    </div>
                    <div class="col-lg-8 section-bg">
                        <div class="d-flex ">
                            <?php $__currentLoopData = $forums; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $forum): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                <?php if(in_array($commune->id, $forum->getConfirmedParticipations()->pluck('commune_id')->toArray())): ?>
                                    <div class="col-2 ms-1 bg-secondary">
                                        <a class="btn btn-secondary  w-100 h-100" href="<?php echo e(route('portal.forums.show', $forum)); ?>"><?php echo e($forum->annee); ?></a>
                                    </div>
                                <?php else: ?>
                                    <div class="col-2 ms-1"></div>
                                <?php endif; ?>
                            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                        </div>
                    </div>
                </div>
                <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
            </div>

        </div>
    </section>

 <?php echo $__env->renderComponent(); ?>
<?php endif; ?>
<?php if (isset($__componentOriginal783808d09c489a73db593e82465042f2d47695ce)): ?>
<?php $component = $__componentOriginal783808d09c489a73db593e82465042f2d47695ce; ?>
<?php unset($__componentOriginal783808d09c489a73db593e82465042f2d47695ce); ?>
<?php endif; ?><?php /**PATH /var/www/html/beta/elv3/resources/views/portal/communes/index.blade.php ENDPATH**/ ?>