Frontend input field creation in "Submit location"

  • Viktoras
  • Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
More
2 weeks 1 day ago #124124 by Viktoras
I am having small problem with "Submit location". In documentation example ( eventbookingdoc.joomservices.com/fronten...ment/submit-location ) there are several fields shown (Name, address, city, state, coordinates and publish).

In Submit location menu item I see less fields (name, address, coordinates and publish). I want to add new field (text box), but I cannot find where and I cannot find where are other hidden fields (for example - state).
Attachments:

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

More
2 weeks 1 day ago #124128 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Frontend input field creation in "Submit location"
Hello

What's the purpose of using city and state fields? In the latest versions, we only require full address of the location enters into address field o the location, no need for city and state fields anymore

If you really want to show city and state fields, go to Extensions -> Modules, publish the two modules:

- Events Booking - Events By City
- Events Booking - Events By State

Regards,

Tuan

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

  • Viktoras
  • Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
More
2 weeks 1 day ago - 2 weeks 1 day ago #124137 by Viktoras
Project is similar to "world cleanup day".
People can report exact location where they spotted trash and now client wants that people could report trash type (plastic, tires etc.). So fields would be (name, address, coordinates and trash type).

I have just published those two modules and nothing happened. I prefer new field creation, but if it's not easy, at least I am willing to use existing fields for the same purpose.
Last edit: 2 weeks 1 day ago by Viktoras.

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

More
2 weeks 1 day ago #124140 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Frontend input field creation in "Submit location"
Hello

You would have to customize code yourself if you want to add extra fields:

1. Alter the table #__eb_locations, add more fields to store new information you need

2. Customize submit location form layout, add the extra fields you want. The files you need to customize is:

- components/com_eventbooking/themes/default/location/form.php
- components/com_eventbooking/themes/default/location/popup.php

Once the modification for the above fields completed, you need to move the modified file to PATH_TO_TEMPLATE/html/com_eventbooking/location 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.

  • Viktoras
  • Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
More
2 weeks 21 hours ago #124151 by Viktoras
Somehow old message lost. I have created database entry, field in "submit location", when i fill field - entry show up in database. So far so good. But after submission I see table with columns
Name Address City State Zip Country Latitude Longitude
I need only
Name Address (Trash type) Latitude Longitude
Where can i change that?

also I have similar problem when opening location in backend - admin cannot see input fields. Only Name Alias Address and Coordinates

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

More
2 weeks 10 hours ago #124166 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Frontend input field creation in "Submit location"
Hello

1. About the table, if you want to add/remove fields, you need to edit code in the file components/com_eventbooking/themes/default/locations/default.php

2. For backend, if you want to add more fields, you will have to edit code in the file administrator/components/com_eventbooking/view/location/tmpl/default.php

Hope it helps

Tuan

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

More
1 week 4 days ago #124192 by Richard Chick
Replied by Richard Chick on topic Frontend input field creation in "Submit location"
I have just started using Events Booking and I was VERY disappointed to see that City and State have been removed as Venue input fields. I see at least two important reasons for having individual fields. First it is important for uninformed users to have an unambiguous place to enter that information (no need to follow the "suggested" formats. Secondly it places the information correctly in the location list forms. I cannot believe this has been done.

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

More
1 week 4 days ago #124193 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Frontend input field creation in "Submit location"
Hello Richard

There was two reasons two fields were removed:

1. You just need to enter full address of the location into single address field and more important, use auto complete feature to select correct address (suggested by Google map API) to select the correct/full address without having to type it all if needed

2. As mentioned, if you still want to enter City and State data for location, just publish the two mentioned modules and the fields will be available:

- Events Booking - Events By City
- Events Booking - Events By State

Regards,

Tuan

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

More
1 week 4 days ago #124194 by Richard Chick
Replied by Richard Chick on topic Frontend input field creation in "Submit location"
I wish to avoid using Google maps as I am creating a non-profit site and I want to minimize costs if volume becomes high.
Regarding autocomplete I was finding it to step on my input but I may have been using it incorrectly.
I will try using the additional modules but I am trying to end up with a super-simple front-end user interface.

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

More
1 week 4 days ago #124195 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Frontend input field creation in "Submit location"
Hi Richard

You will need to have a valid Google Map API Key to have that auto-complete feature to work. Although Google requires you to provide billing information to register for an API Key, they provide free usage which in most case you won't have to pay if your site does not have a very high traffict

Regards,

Tuan

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

Moderators: Tuan Pham Ngoc