-
Notifications
You must be signed in to change notification settings - Fork 70
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Geocomplete, lan, lon? #71
Comments
This is doing both reverse Geocode and setting lat and lng inputs on my form.
|
are you using php filament v2 or v3? I am using v3 and I have the same problem, doesn't update my "lat" and "lng" fields. Strangely enough mine it works only if I click on the address multiple times. For example if I drag the pin on the map for the first time or I search for an address it will update the "lng" and "lat" from the Map::make('location) using:
After this the ->afterStateUpdated() will not be called again, even if I drag and drop in another location. But if I drag and drop in another location, the address will change in the Geocomplete::make('site_address') dropdown, I select the address and the "lng" and "lat" are not being changed, I click again on the input box, dropdown appears, I select again on the address showing up from "powered by Google", nothing happens again, when I do it 3th time somehow it triggers this ->updateLatLng() and it updates the "lat" and "lng". And after it updates the "lat" and "lng" if I click again on the input box for the full_address the dropdown from the "powered by Google" doesn't appear anymore. Another way to update the "lat" and "lng" on the first click is if I click on the ->geolocate() button. I don't need to click on this button multiple times to update the "lat" and "lng". I only click once and it works properly, I think something was implemented correctly for this function but not for ->updateLatLng(). |
Is it possible to get lan, lon out of submitting the geocomplete field, instead the searched address?
I use the field as a standalone search inside a livewire component.
The text was updated successfully, but these errors were encountered: