change order events are displayed in in My Events

  • stikkimorey
  • Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
11 years 7 months ago #19368 by stikkimorey
We have lots of events and they are displayed in order of event ID in the front end. Is it possible to make them display by start date instead because then it would be easier to find the event we want to edit.

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

More
11 years 7 months ago #19437 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Re: change order events are displayed in in My Events
Hi

You can edit the code alitle. Please follow the instruction below :

1. Open the file components/com_eventbooking/models/events.php

2. Find the code below :
Code:
$orderby = ' ORDER BY a.id DESC ';

3. Change it to :
Code:
$orderby = ' ORDER BY a.event_date DESC ';

After that, it will work as expected.

Tuan

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

More
11 years 4 months ago #23598 by OTWD
Incorrect i found to order the category list for latest event first change
components/com_eventbooking/models/category.php
Approx line 189:

$orderby = ' ORDER BY a.event_date ';

to
$orderby = ' ORDER BY a.event_date DESC ';

Success consists of going from failure to failure without loss of enthusiasm.

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

More
11 years 4 months ago #23631 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Re: change order events are displayed in in My Events

On Twd wrote: Incorrect i found to order the category list for latest event first change
components/com_eventbooking/models/category.php
Approx line 189:

$orderby = ' ORDER BY a.event_date ';

to
$orderby = ' ORDER BY a.event_date DESC ';


This is correct code want you want to order the events on events category page. My instructions mentioned above is for My submitted events page (which display events submitted by users in the front-end).

Tuan

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

More
11 years 3 months ago #24318 by jeff
Hi, is it possible for me to edit code so that my events are shown in front end in the same order that they are sorted by in admin (in 'order' column) ?
At present, it doesn't matter what order I place them in Admin, the front end always looks same.

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

More
11 years 3 months ago #24337 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Re: change order events are displayed in in My Events
Hi jeff

Could you send me the link to the page you are talking about so that I can guide you ?

Tuan

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

Moderators: Tuan Pham Ngoc