<?php $__env->startSection('content'); ?>
<?php if(session('success')): ?>
<div class="alert alert-primary alert-dismissible" role="alert">
    <?php echo e(session('success')); ?>

    <button type="button" class="btn-close" data-bs-dismiss="alert" aria-label="Close">
    </button>
</div>
<?php endif; ?>
<div class="content-wrapper">
    <div class="container-xxl flex-grow-1 container-p-y">
        <h4 class="fw-bold py-3 mb-4 px-3">
            <span class="text-muted fw-light"><a
                    href="<?php echo e(route($parent_named_route.'.index')); ?>"><?php echo e($module_name); ?></a>
                /</span> Edit
        </h4>
        <div class="row">
            <div class="col-md-12">
                <div class="card mb-4">
                    <div class="card-body">
                        <form action="<?php echo e(route('hours.edit', ['id' => $hour->id])); ?>" class="mb-3" method="POST">
                            <?php echo csrf_field(); ?>
                            <div>
                                <label for="defaultFormControlInput" class="form-label">Clubs</label>
                                <select name="club_id" class="form-control" id="defaultFormControlInput" aria-describedby="defaultFormControlHelp">
                                    <?php $__currentLoopData = $clubs; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $club): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                    <option value="<?php echo e($club->id); ?>" <?php echo e($hour->club_id == $club->id ? 'selected' : ''); ?>><?php echo e($club->name); ?></option>
                                    <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                </select>
                            </div>

                            <div>
                                <label for="defaultFormControlInput" class="form-label">Day</label>
                                <select name="day" class="form-control" id="defaultFormControlInput" aria-describedby="defaultFormControlHelp">
                                    <?php $__currentLoopData = $days; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $key => $day): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                    <option value="<?php echo e($key); ?>" <?php echo e($hour->day == $key ? 'selected' : ''); ?>><?php echo e($day); ?></option>
                                    <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                </select>
                            </div>

                            <div>
                                <label class="form-label">Opening Time</label>
                                <input
                                    name="opening_time"
                                    type="time"
                                    class="form-control"
                                    value="<?php echo e(\Carbon\Carbon::createFromFormat('H:i:s', $hour->opening_time)->format('H:i')); ?>"
                                    aria-describedby="defaultFormControlHelp" />

                                <?php if($errors->has('opening_time')): ?>
                                <span class="text-danger"><?php echo e($errors->first('opening_time')); ?></span>
                                <?php endif; ?>
                            </div>

                            <div>
                                <label class="form-label">Closing Time</label>
                                <input
                                    name="closing_time"
                                    type="time"
                                    class="form-control"
                                    value="<?php echo e(\Carbon\Carbon::createFromFormat('H:i:s', $hour->closing_time)->format('H:i')); ?>"
                                    aria-describedby="defaultFormControlHelp" />
                                <?php if($errors->has('closing_time')): ?>
                                <span class="text-danger"><?php echo e($errors->first('closing_time')); ?></span>
                                <?php endif; ?>
                            </div>

                            <div class="demo-inline-spacing">
                                <input type="submit" class="btn btn-primary move-right" value="Update" />
                            </div>
                        </form>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <!-- / Content -->
    <?php $__env->stopSection(); ?>

    <?php $__env->startSection('scripts'); ?>
    <?php $__env->stopSection(); ?>
<?php echo $__env->make('layouts.master', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /home/democmolds1/public_html/projects/pblink_admin_2024/resources/views/pages/hour/edit.blade.php ENDPATH**/ ?>