Hi Eric,
It by simple customization, but this is not override. So it will disappear at upgrade process.
for Events Module to display only the NEXT event, please follow this steps:
1. edit /modules/mod_community_events/mod_community_events.php line 40, replace it with:
$result = $model->getEvents($categoryIds, null, $sorted, null, true, false, null, array('parent' => $eventparent), $handler->getContentTypes(), $default, null, true);
public function getEvents($categoryId = null, $userId = null, $sorting = null, $search = null, $hideOldEvent = true, $showOnlyOldEvent = false, $pending = null, $advance = null, $type = CEventHelper::ALL_TYPES, $contentid = 0, $limit = null, $nextEventOnly = false) {
if ($nextEventOnly) {
$extraSQL .= ' AND a.' . $db->quoteName('startdate') . ' > ' . $db->Quote($pastDate->format('Y-m-d H:i:s', true, false));
}
Hi,
I tried making the changes suggested, but it broke the site (white screen). I re-loaded the original files and it is working again.
I don't really want a solution where you have to hack the code, then change every time there's an upgrade. Are you aware of an alternative module which has this functionality, or could it be built in as standard?
Thanks,
Eric.
Hi Eric,
I think that because you did typo on code. that blank screen caused by that.
for rightnow your changes need hack the core. Community module still not support upcoming event ONLY. but upcoming and current events.
you can use our feature request for your voice:
uservoice.jomsocial.com/forums/101561-jo...ial-feature-requests
If you want me do it for you (for the module changes). I will do it for you. but you need provide me FTP access detail. by editing your first post at this topic. put it at Site Info Form.
Regards,
Albert
Hi,
Sorry for not getting back in touch. I found a 3rd party extension which I thought would work for me, but it is now causing a 1064 error. I am not keen to hack your extension to give me this functionality as I will lose it each time I upgrade.
Would you consider including this functionality within the Events module as standard i.e. display next event. My client really needs this, and I think your other customers would benefit from this too.
Please let me know.
Thanks,
Eric.
Hi Eric,
our product manager decided to put this at Jomsocial 3.3 version. estimation will be released at next year.
for quick solution I only can offer core changes for you. if you can provide me FTP access detail, I can do it for you.
Regards,
Albert