Front End Locations

  • Andrew Davis
  • Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
9 years 6 months ago #52107 by Andrew Davis
Front End Locations was created by Andrew Davis
I have added a menu item that points to "My Locations"
however when the screen loads, or i try to create a new location there is no map (like you get in the backend).

Have i missed something?

Also is it possible to have the users view ALL Locations not just the ones that they created?

Regards
Andrew
Attachments:

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

More
9 years 6 months ago #52109 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Front End Locations
Hi Andrew

1. At the moment, the front-end submit location form is just a simple form, we don't have support for advanced location setup like in the back-end. Something which we will integrate it in the future but not for now.

2. To allow users to view all locations, you will need to edit the code alitle. Open the file components/com_eventbooking/views/event/view.html.php, find the code below:
Code:
if ($user->authorise('core.admin', 'com_eventbooking')) { $sql = 'SELECT id, name FROM #__eb_locations WHERE published=1 ORDER BY name'; } else { $sql = 'SELECT id, name FROM #__eb_locations WHERE published=1 AND user_id=' . $user->id . ' ORDER BY name '; }

Change it to:

$sql = 'SELECT id, name FROM #__eb_locations WHERE published=1 ORDER BY name';

After that, users will see all locations.

Regards,

Tuan
The following user(s) said Thank You: DPaW, Andrew Davis

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

More
9 years 2 months ago #59330 by DPaW
Replied by DPaW on topic Front End Locations
I'm going to give this a go, it's exactly what we need, to show all events on a location map

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

More
9 years 2 months ago #59337 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Front End Locations

DPaW wrote: I'm going to give this a go, it's exactly what we need, to show all events on a location map


Then congratulations for seeing the solution :D.

Tuan

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

Moderators: Tuan Pham Ngoc