Files
studiobeve.no/application/views/pages/manage-booking-cancelled.php
T
Astral04andClaude Sonnet 4.6 2183c8aff2 guest booking self-management feature + layout fixes
- add manage_token column to bookings (DB migration done)
- generate unique token per booking, include manage link in confirmation emails (no/en/hu)
- new routes: manage-booking, manage-booking-process, manage-booking-cancel
- new views: manage-booking.php, manage-booking-cancelled.php
- 24h cutoff enforcement for cancel/modify; emails sent to guest + studio CC
- fix manage-booking step 3 float layout (overflow:auto BFC clearfix)
- fix booking page time slot overflow: bookingResultsWrapper 378px -> 360px

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-02-28 16:01:12 +01:00

45 lines
2.1 KiB
PHP

<?php
// Determine subpage from the booking's service type to pick correct skeleton
$serviceIds = unserialize($booking->service_ids);
$subpage = 'barber';
if(is_array($serviceIds) && !empty($serviceIds)){
$firstService = $this->Service_model->getServiceById($serviceIds[0]);
if($firstService) $subpage = $firstService->service_type;
}
if($subpage == 'beauty'){
include(getcwd().'/application/views/includes/beauty-skeleton-top.php');
} else {
include(getcwd().'/application/views/includes/barber-skeleton-top.php');
}
$messages = array(
'no' => 'Din bestilling den <strong>'.$booking->booking_date.'</strong> kl. <strong>'.date('H:i', strtotime($booking->booking_start_time)).'</strong> med <strong>'.$worker->worker_name.'</strong> er avbestilt.',
'en' => 'Your booking on <strong>'.$booking->booking_date.'</strong> at <strong>'.date('H:i', strtotime($booking->booking_start_time)).'</strong> with <strong>'.$worker->worker_name.'</strong> has been cancelled.',
'hu' => 'A <strong>'.$booking->booking_date.'</strong> <strong>'.date('H:i', strtotime($booking->booking_start_time)).'</strong>-os foglalásod <strong>'.$worker->worker_name.'</strong>-nál törölve lett.',
);
$titles = array(
'no' => 'Bestilling avbestilt',
'en' => 'Booking cancelled',
'hu' => 'Foglalás törölve',
);
$lang = $selectedLang;
$msg = isset($messages[$lang]) ? $messages[$lang] : $messages['en'];
$title = isset($titles[$lang]) ? $titles[$lang] : $titles['en'];
?>
<div class="bookingContainer" style="min-height:400px; padding:20px;">
<div class="bookingThankYouTitle"><?php echo $title; ?></div>
<div class="bookingThankYouMessageTitle" style="margin-top:15px;"><?php echo $msg; ?></div>
</div>
<?php
if($subpage == 'beauty'){
include(getcwd().'/application/views/includes/beauty-skeleton-bottom.php');
} else {
include(getcwd().'/application/views/includes/barber-skeleton-bottom.php');
}
?>