sp4rky35
Forum Replies Created
-
Oh, so nice, thank you !
Hi again !
Looks like latest updates introduced some bug displaying locked /full timeslots . When only one seat (my slot has 2 available seats) is booked, the name of the people who booked appears correctly. But when both seats are booked and slot is grayed / disabled, the names go under slot. This was not the case a few weeks ago (screenshot in my first posts on this topic show correct behaviour)
(moved to forminator pro support, closing here)
Hi again, noticed another small bug.
On mobile, the code to define the next step name does not work on 3rd step.
# in wbk5-frontend.js
this.container.find('.current-step-w').html(acive_step_title)
var next_li = this.container
.find('.appointment-status-list-w > li.active-w')
.nextAll('li')
if (next_li.length > 0) {
var next_text = this.container.find('.button-next-w').html()
this.container
.find('.next-step-w')
.html(next_text + ': ' + next_li.find('.text-title-w').html())
}As there is no
else
, thep.next-step-w
content is not deleted / updated for last step (confirmation / submission), so when you’re on 3rd step, you still see a “Next : 3rd-step-name”Yw ! Btw, my point 7 is solved with a customer template like :
if ( !defined( 'ABSPATH' ) ) exit;
$services_ids = $data[0];
$times = $data[1];
$category_id = $data[2];
// Build a service -> [list,of,times] dict
$times_by_service = array();
foreach ($services_ids as $slot_id => $service_id) {
// Get existing slots for this service, if any
$slots = $times_by_service[$service_id] ?? [];
// Append this slot time
$slots[] = $times[$slot_id];
// and store it in array again
$times_by_service[$service_id] = $slots;
}
$time_format = WBK_Format_Utils::get_time_format();
$date_format = WBK_Format_Utils::get_date_format();
foreach ($times_by_service as $service_id => $slots){
$service = new WBK_Service( $service_id );
if( !$service->is_loaded() ){
continue;
}
?>
<h4><?php echo esc_html( $service->get_name() ) ?></h4>
<ul>
<?php
foreach ($slots as $slot) {
?><li>
<?php echo wp_date( $date_format, $slot, new DateTimeZone( date_default_timezone_get() ) ); ?>
à
<?php echo wp_date( $time_format, $slot, new DateTimeZone( date_default_timezone_get() ) ); ?>
</li>
<?php
}
?>
</ul>
<?php
}
$html = WBK_Placeholder_Processor::process_not_booked_item_placeholders( $services_ids, $times, $category_id );
if( get_option ('wbk_mode', 'webba5' ) != 'webba5' ){
$html .= '<hr class="wbk-form-separator">';
} else {
$html = '<p class="first-text-w">' . $html . '<p>';
}
echo $html;
?>Still many improvements (no need 2 different date/time formatting for ex, and css is terrible), but it does work ??
Nop it isn’t, this is your code, unmodified. You can see than first image is “calendar icon” but format is
$time_format
, and the icon is clock but format isdate format
. I ‘d have expected calendar for date and clock for time ??I’m still playing with filter, works for my needs, thanks ??
In meantime I noticed a small bug with summary in thank you message :
<li>
<span class="list-icon-w">
<img src="<?php echo WP_WEBBA_BOOKING__PLUGIN_URL . '/public/images/calendar-icon.png' ?>" alt="star">
</span>
<?php echo wp_date( $time_format, $booking->get_start(), new DateTimeZone( date_default_timezone_get() ) ); ?>
</li>
<li>
<span class="list-icon-w">
<img src="<?php echo WP_WEBBA_BOOKING__PLUGIN_URL . '/public/images/clock-black-icon.png' ?>" alt="star">
</span>
<?php echo wp_date( $date_format, $booking->get_start(), new DateTimeZone( date_default_timezone_get() ) ); ?>
</li>I’d expect calendar icon for date, and clock icon for time ??
- This reply was modified 2 months, 2 weeks ago by sp4rky35.
I think so. It would looks nicer if it is “integrated” in the form layout, but having it just above seems much less work. My guess is to provide some filter with current submission data (ie, list of chosen timeslots), and display the result above the form. This way it does not change anything by default but allow people to customize the summary as they wish, without messing with the form itself (which seems much more complex)
Given the quality of your product (compared to the others I tried), that’s the least I can do ??
I perfectly understand that, thanks for your (fast) answer anyway ! Maybe there could have a way to include it as part of the 3rd step, just at the beginning of the form ? As you support both default from and custom from contact form 7, I have no idea about how this could be easily done (shortcode ? filter ?)
I would imagine an extra step before the final form. So basically workflow would change from :
- choose services -> choose slots -> add personal information in form -> confirmation
to :
- choose services -> choose slots -> get a summary of all booked slots (either validate or go back to modify) -> add personal information in form -> confirmation
Thanks for 6, will give it a try !
For 7, I just noticed it appears only at the 3rd step, not during 2nd. It’s better but not visible on mobile, so a dedicated summary step seems better. I did not understand in our previous messages that the summary on left side would be on 3rd step, I thought it would replace the list on top of the right side during 2nd step.
Oh, didn’t notice it / see it in changelog. It works well, thank you !
I think the main remaining issues are the 6 & 7 :
6. could be fixed with some filter to customize time slot (need to have the service as well in filter parameters)
7. having summary in left bar instead of top of the right section sounds good on large screen, but does not help much in mobile (and most of our/the traffic is mobile). Having a summary *before* asking for extra info (with a previous/next button) would be perfect.
Thanks !
Sorry, had no time to check (holiday time) ?? Just checked, I only see the “read more” customization (which works fine, thanks !)
9. Another small layout request (that’s why I put it here), active and disabled slots do not have the same layout, active have :
<input class="timeslot_radio-w" type="radio" name="day-1731625200_1731699900_1">
<span class="radio-time-block-w radio-time-block-w timeslot-animation-w">
<span class="radio-time-inner-w">
<span class="radio-checkmark"></span>
<span class="time-w time-long-w">
20:45 </span>
</span><!-- /.radio-time-inner-w -->
<span class="available-w">
[...]
while disabled have
<input class="timeslot_radio-w" type="radio" name="time-1" disabled="">
<span class="radio-time-block-w timeslot-animation-w">
<span class="radio-checkmark"></span>
<span class="time-w time-long-w">
19:30
</span>
<span class="available-w1">
[...]
I’ve removed extra data attributes for clarity, but basically, active slots have an extra
radio-time-inner-w
span which includesradio-checkmark
andtime-w
, while disabled put everything on same depth, it makes things complicated when you want to customize slots without, apparently, any reason.so … off course, it’s now working … Might be a cache issue (only did a browser cache refresh).