PluginProbe
Fluent Booking – The Ultimate Appointments Scheduling, Events Booking, Events Calendar Solution / 1.5.21
Fluent Booking – The Ultimate Appointments Scheduling, Events Booking, Events Calendar Solution v1.5.21
2.4.0 2.3.0 2.2.5 2.2.0 2.1.2 2.1.1 trunk 1.10.0 1.10.01 1.10.02 1.5.0 1.5.01 1.5.02 1.5.1 1.5.10 1.5.20 1.5.21 1.5.22 1.5.23 1.5.24 1.5.25 1.6.0 1.7.0 1.7.1 1.7.2 All 33 releases
fluent-booking / app / Views / public / bookings.php

bookings.php in Fluent Booking – The Ultimate Appointments Scheduling, Events Booking, Events Calendar Solution 1.5.21, at app/Views/public/bookings.php

129 lines 7.2 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php defined( 'ABSPATH' ) || exit; ?>
2
3 <div class="fcal_container">
4 <div class="fcal_booking_header">
5 <h2><?php echo esc_html($attributes['title']) ?></h2>
6 <div class="fcal_booking_header_actions">
7 <?php if ($attributes['filter'] == 'show') : ?>
8 <form action="" method="GET">
9 <?php foreach ($period_options as $value => $label): ?>
10 <div class="fcal_radio_btn">
11 <input type="radio" name="booking_period" id="fcal_period_<?php echo esc_attr($value) ?>"
12 value="<?php echo esc_attr($value) ?>" <?php echo $booking_period == $value ? 'checked' : '' ?>
13 onchange="this.form.submit()">
14 <label for="fcal_period_<?php echo esc_attr($value) ?>"><?php echo esc_html($label) ?></label>
15 </div>
16 <?php endforeach; ?>
17 </form>
18 <?php endif; ?>
19 </div>
20 </div>
21 <div class="fcal_all_bookings">
22 <div class="fcal_bookings">
23 <div class="fcal_booking_wrapper">
24 <?php foreach ($bookings as $booking) : ?>
25 <div class="fcal_booking" onclick="location.href='<?php echo esc_url($booking->getConfirmationUrl()); ?>'">
26 <div class="fcal_spot_wrapper <?php echo 'fcal_spot_status_' . esc_attr($booking->status) ?>">
27 <div class="fcal_spot_line">
28 <div class="fcal_spot_timing">
29 <p class="fcal_booking_date"><?php echo esc_html($booking->booking_date); ?></p>
30 <p class="fcal_booking_time"><?php echo esc_html($booking->booking_time); ?></p>
31 <p class="fcal_booking_timezone">(<?php echo esc_html($booking->person_time_zone); ?>)</p>
32 </div>
33 <div class="fcal_spot_desc">
34 <h3 class="fcal_spot_title">
35 <?php echo wp_kses_post($booking->getBookingTitle(true)); ?>
36 </h3>
37 <div class="fcal_spot_desc_sub_info">
38 <?php if ($booking->happening_status) : ?>
39 <?php foreach ($booking->happening_status as $slug => $status) : ?>
40 <div class="fcal_spot_happening">
41 <span class=<?php echo 'fcal_' . esc_attr($slug) ?>>
42 <?php echo esc_html($status) ?>
43 </span>
44 </div>
45 <?php endforeach; ?>
46 <?php else : ?>
47 <span class="fcal_spot_period_status">
48 <?php echo esc_html($booking->booking_status_text) ?>
49 </span>
50 <?php endif; ?>
51
52 <?php if ($booking->payment_status) : ?>
53 <p class="fcal_spot_payment_status <?php echo esc_attr($booking->payment_status) ?>">
54 <?php echo esc_html($booking->payment_status_text) ?>
55 </p>
56 <?php endif; ?>
57
58 <?php if ($booking->status == 'pending' && $booking->payment_status != 'pending') : ?>
59 <p class="fcal_spot_period_status unconfirmed">
60 <?php esc_html_e('Unconfirmed', 'fluent-booking') ?>
61 </p>
62 <?php endif; ?>
63 </div>
64 </div>
65 <div class="fcal_spot_actions">
66 <button class="fcal_plain_btn"
67 onclick="location.href='<?php echo esc_url($booking->getConfirmationUrl()); ?>'">
68 <?php esc_html_e('View', 'fluent-booking')?>
69 </button>
70 </div>
71 </div>
72 </div>
73 </div>
74 <?php endforeach; ?>
75 <?php if ($bookings->isEmpty()): ?>
76 <div class="fcal_no_bookings">
77 <p><?php echo esc_html($attributes['no_bookings']) ?></p>
78 </div>
79 <?php endif; ?>
80 </div>
81 </div>
82 </div>
83
84 <!-- Pagination -->
85 <?php if ($attributes['pagination'] == 'show' && $bookings->lastPage() > 1): ?>
86 <ul class="fcal_pagination">
87 <span><?php echo esc_html(__('Total', 'fluent-booking') . ' ' . $bookings->total())?></span>
88
89 <form action="" method="GET">
90 <select name="booking_per_page" id="fcal_booking_per_page" onchange="this.form.submit()">
91 <?php foreach ($page_options as $option): ?>
92 <option value="<?php echo esc_attr($option); ?>" <?php $per_page == $option ? 'selected' : '' ?>>
93 <?php echo esc_html($option) . '/' . esc_html__('page', 'fluent-booking') ?>
94 </option>
95 <?php endforeach; ?>
96 </select>
97 </form>
98
99 <?php if ($bookings->onFirstPage()): ?>
100 <a class="fcal_btn prev disabled" aria-label="Previous page is disabled" role="button">«</a>
101 <?php else: ?>
102 <a class="fcal_btn prev" aria-label="Go to previous page" role="button"
103 href="<?php echo esc_url($bookings->previousPageUrl()); ?>">«
104 </a>
105 <?php endif; ?>
106
107 <ul class="fcal_pager">
108 <?php for ($page = $start_page; $page <= $end_page; $page++): ?>
109 <?php if ($page == $bookings->currentPage()): ?>
110 <li class="active"><span><?php echo esc_html($page); ?></span></li>
111 <?php else: ?>
112 <li><a aria-label="Go to page <?php echo esc_attr($page); ?>"
113 href="<?php echo esc_url($bookings->url($page)); ?>"><?php echo esc_html($page); ?></a>
114 </li>
115 <?php endif; ?>
116 <?php endfor; ?>
117 </ul>
118
119 <?php if ($bookings->hasMorePages()): ?>
120 <a class="fcal_btn next" aria-label="Go to next page" role="button"
121 href="<?php echo esc_url($bookings->nextPageUrl()); ?>">»
122 </a>
123 <?php else: ?>
124 <a class="fcal_btn next disabled" aria-label="Next page is disabled" role="button">»</a>
125 <?php endif; ?>
126 </ul>
127 <?php endif; ?>
128 </div>
129