- Posts: 8
- Thank you received: 0
New registration status
- Andrea Prando
- Topic Author
- Offline
- New Member
-
Less
More
8 years 4 months ago #106204
by Andrea Prando
New registration status was created by Andrea Prando
Hi,
on my site I created a new status for the event registration.
This new option is a Paid option. It means that the user has paid but must be activated manually from admin.
Everything works correctly but the user who has this new status (option= 4 ) could sign up again for the same event.
How do I do it to redirect it as if I had it as a status "Paid" (option = 0)?
Like $app->redirect('index.php', JText::_('EB_YOU_REGISTERED_ALREADY')); when status is "Paid"?
Sorry for my english.
Thanks
on my site I created a new status for the event registration.
This new option is a Paid option. It means that the user has paid but must be activated manually from admin.
Everything works correctly but the user who has this new status (option= 4 ) could sign up again for the same event.
How do I do it to redirect it as if I had it as a status "Paid" (option = 0)?
Like $app->redirect('index.php', JText::_('EB_YOU_REGISTERED_ALREADY')); when status is "Paid"?
Sorry for my english.
Thanks
Please Log in or Create an account to join the conversation.
- Tuan Pham Ngoc
- Offline
- Administrator
-
8 years 4 months ago #106212
by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic New registration status
Hi Andrea
Try to look at the file components/com_eventbooking/helper/registration.php, method acceptRegistration
There is block of code like this:
Change it to:
Then check it again, it might work
Regards,
Tuan
Try to look at the file components/com_eventbooking/helper/registration.php, method acceptRegistration
There is block of code like this:
Code:
if ($preventDuplicateRegistration && $user->id)
{
$query->clear()
->select('COUNT(id)')
->from('#__eb_registrants')
->where('event_id = ' . $event->id)
->where('user_id = ' . $user->id)
->where('(published=1 OR (payment_method LIKE "os_offline%" AND published NOT IN (2,3)))');
$db->setQuery($query);
$total = $db->loadResult();
if ($total)
{
return false;
}
}
Change it to:
Code:
if ($preventDuplicateRegistration && $user->id)
{
$query->clear()
->select('COUNT(id)')
->from('#__eb_registrants')
->where('event_id = ' . $event->id)
->where('user_id = ' . $user->id)
->where('(published IN (1, 4) OR (payment_method LIKE "os_offline%" AND published NOT IN (2,3)))');
$db->setQuery($query);
$total = $db->loadResult();
if ($total)
{
return false;
}
}
Then check it again, it might work
Regards,
Tuan
Please Log in or Create an account to join the conversation.
- Andrea Prando
- Topic Author
- Offline
- New Member
-
Less
More
- Posts: 8
- Thank you received: 0
8 years 4 months ago #106224
by Andrea Prando
Replied by Andrea Prando on topic New registration status
Hi Tuan,
it works.
Thanks!
it works.
Thanks!
Please Log in or Create an account to join the conversation.
- Tuan Pham Ngoc
- Offline
- Administrator
-
8 years 4 months ago #106239
by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic New registration status
Oh, great
. Happy to hear that
Please Log in or Create an account to join the conversation.
Moderators: Tuan Pham Ngoc
Support
Documentation
Information
Copyright © 2026 Joomla Extensions by Joomdonation. All Rights Reserved.
joomdonation.com is not affiliated with or endorsed by the Joomla! Project or Open Source Matters.
The Joomla! name and logo is used under a limited license granted by Open Source Matters the trademark holder in the United States and other countries.
The Joomla! name and logo is used under a limited license granted by Open Source Matters the trademark holder in the United States and other countries.