Small layout change on list of upcoming events? :)

  • Finn Christensen
  • Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
3 years 2 weeks ago #142761 by Finn Christensen
Small layout change on list of upcoming events? :) was created by Finn Christensen
I have been looking for where to change it, but can't find the right file to change :)

When our event owners show a list of upcoming events they are assigned to we would like to show the event location name for each event on this list

Can you tell me which file to edit? I guess I need to put something like
echo $row->location_name ;
in the file that generates this list of upcoming events?

But which file? :)
I guess this file also has to be copied to my templates folder to make an override? :)

I have attached 2 screenshots so you can see what the menu is and where I would like to have the location name :)


Thanks
Finn
Attachments:

Please Log in or Create an account to join the conversation.

More
3 years 2 weeks ago #142768 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Small layout change on list of upcoming events? :)
It is not that easy because the location data is not available for each event. So you will have to query database to get the information

1. The file you need to modify is components/com_eventbooking/themes/default/events/default.php

2. For each event, you will need to query location data like this


$location = EventbookingHelperDatabase::getLocation($row->location_id);

if ($location)
{
echo $location->name;
}

Something like that should work. Also, please make sure you move the modified file to PATH_TO_TEMPLATE/html/com_eventbooking/events folder so that the change won't be lost when you update to future releases of the extension

Tuan

Please Log in or Create an account to join the conversation.

  • Finn Christensen
  • Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
3 years 2 weeks ago #142770 by Finn Christensen
Replied by Finn Christensen on topic Small layout change on list of upcoming events? :)
Thank you so much Tuan :)

I think that worked :) :)


Finn

Please Log in or Create an account to join the conversation.

More
3 years 2 weeks ago #142771 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Small layout change on list of upcoming events? :)
Great. Happy to hear that :)

Please Log in or Create an account to join the conversation.

  • Finn Christensen
  • Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
3 years 2 weeks ago #142782 by Finn Christensen
Replied by Finn Christensen on topic Small layout change on list of upcoming events? :)
Oh our users have a request :)
When opening this page the events seem to be ordered by event-date with first-upcoming events LAST ont the list - is it possible to reverse the ordering so that events a sorted with "first-coming events" placed FIRST on the list? :)

I hope you understand what I mean?

I know they can click on the header to reverse the ordering, but they would prefer to have the orderring "reversed" ..... so that the cloest date are first and then later dates after that .....

I tried using the settings in eventsbooking configuration for it, but it seems to not affect it?

Please Log in or Create an account to join the conversation.

More
3 years 2 weeks ago #142785 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Small layout change on list of upcoming events? :)
I believe you can try and use this override joomdonation.com/forum/events-booking-cu...order-of-events.html

Tuan

Please Log in or Create an account to join the conversation.