Hi Yves,
My users pointed me to a problem. Some users booked twice on a popular event. Both times for the maximum bookable places.
I tested it on my test account and found out that even when you booked an event, the Booking button is still showing on the eventform (modern template) and clicking on it allows them to book again. In the My Bookings tab both bookings are showing.
I solved the problem by removing one condition for showing this button:
// Book
if (($this->user->id OR MatukioHelperSettings::getSettings('booking_unregistered', 1) == 1)
AND $this->event->cancelled == 0
AND $this->event->nrbooked > 0
AND (count($buchopt[2]) == 0)) [b]// OR (count($buchopt[2]) > 0 && MatukioHelperSettings::getSettings('frontend_usermehrereplaetze', 1) != 0)))[/b]
{
$bookinglink = JRoute::_("index.php?option=com_matukio&view=bookevent&cid=" . $this->event->id . ":"
. JFilterOutput::stringURLSafe($this->event->title)
);
echo " <a title=\"" . JTEXT::_('COM_MATUKIO_BOOK') . "\" href=\"" . $bookinglink
. "\"><span class=\"mat_book\" type=\"button\"><img src=\""
. MatukioHelperUtilsBasic::getComponentImagePath()
. "1116.png\" border=\"0\" align=\"absmiddle\"> "
. JTEXT::_('COM_MATUKIO_BOOK') . "</span></a>";
}
This code is found in event/tmpl/modern.php around row 543.
The problem is that I don't know if my sollution is correct. It helped, but I cannot explain why the condition on the "Book more than one place" configuration option is there. If I set this option to "No", no one can book more than one place on any event. Than the question of how many places one wants to book, doesn't show on the booking form.
My configuration setup is:
Joomla version: 3.3.6
Matukio version:
4.5.0
No payment plugins are used
Can users book more than one place = Yes
Can you please take a look?