IMMREX7
<?php $__env->startSection('content'); ?>
<?php $__currentLoopData = $folders; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $var): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
<div class="row clearfix">
<div class="col-lg-12 col-md-12 col-sm-12">
<div class="card">
<div class="header">
<h2><strong>Gallery : Pictures taken from <?php echo e($var->folderName); ?> Folder</strong></h2>
</div>
<div class="body">
<div id="aniimated-thumbnials" class="list-unstyled row clearfix">
<?php
if(count($folders->items()) > 1)
$gal_images = \App\Gallery::where('idSchool', '=', $student->idSchool)->where('idFolder',$var->idFolder)->paginate(4)->items();
else
$gal_images = \App\Gallery::where('idSchool', '=', $student->idSchool)->where('idFolder',$var->idFolder)->get();
?>
<?php $__currentLoopData = $gal_images; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $value): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
<div class="col-xl-3 col-lg-4 col-md-6 col-sm-12 m-b-20"> <a href="<?php echo e(asset('storage/schools/'.$value->idSchool.'/galleries/'.$value->folder->folderName.'/'.$value->image)); ?>">
<img class="img-fluid img-thumbnail" src="<?php echo e(asset('storage/schools/'.$value->idSchool.'/galleries/'.$value->folder->folderName.'/'.$value->image)); ?>" alt=""> </a> </div>
<?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
</div>
<?php if(count($folders->items()) > 1): ?>
<?php if(\App\Gallery::where('idSchool', '=', $student->idSchool)->where('idFolder',$var->idFolder)->count() > 4): ?>
<ul class="body pagination pagination-primary"><li class="page-item active"><a class="page-link" href="<?php echo e(url('student/gallery-folder').'/'.$var->idFolder); ?>">View All Images</a></li></ul>
<?php endif; ?>
<?php endif; ?>
</div>
</div>
</div>
</div>
<?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
<?php if(count($folders->items()) > 1): ?>
<?php
$lastIndex = 15 + $folders->currentPage();
if($lastIndex > $folders->lastPage())
$lastPage = $folders->lastPage();
$startIndex = $folders->currentPage();
?>
<ul class="body pagination pagination-primary">
<?php if($folders->currentPage() > 1): ?>
<li class="page-item"><a class="page-link" href="<?php echo e($folders->previousPageUrl()); ?>">Previous</a></li>
<?php endif; ?>
<?php for($i = $startIndex ; $i < $lastIndex; $i++): ?>
<li class="page-item <?php if($i == $folders->currentPage()) echo 'active';?>"><a class="page-link" href="<?php echo e($folders->url($i)); ?>"><?php echo e($i); ?></a></li>
<?php endfor; ?>
<li class="page-item"><a class="page-link" href="<?php echo e($folders->nextPageUrl()); ?>">Next</a></li>
</ul>
<?php endif; ?>
<?php $__env->stopSection(); ?>
<?php $__env->startSection('script'); ?>
<script>
$(function () {
$('#aniimated-thumbnials').lightGallery({
thumbnail: true,
selector: 'a'
});
});
</script>
<?php $__env->stopSection(); ?>
<?php echo $__env->make('students.student_layout', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>
Copyright © 2021 -