Skip to content
This repository has been archived by the owner on Oct 17, 2022. It is now read-only.

Marker is not moving after i've search on the textbox #31

Open
recepgums opened this issue Jan 10, 2020 · 8 comments
Open

Marker is not moving after i've search on the textbox #31

recepgums opened this issue Jan 10, 2020 · 8 comments
Assignees
Labels
question Further information is requested

Comments

@recepgums
Copy link

recepgums commented Jan 10, 2020

MapMarker::make("Location")
                ->latitude('latitude')
                ->longitude('longitude')->searchProvider('openstreetmap'),

**
image
**
It was working yesterday as well but now doesn't work

@mikebronner mikebronner self-assigned this Jan 10, 2020
@mikebronner mikebronner added the question Further information is requested label Jan 10, 2020
@mikebronner
Copy link
Owner

Hi @recepgums, could you be more specific as to what "is not working"? We haven't made any updates, as you can so, so it is likely either an issue with OpenStreetMaps, or a configuration change in your app.

If you can provide any stack trace or other error logs, that would help identify what is going on.

@recepgums
Copy link
Author

recepgums commented Jan 13, 2020

Hi @recepgums, could you be more specific as to what "is not working"? We haven't made any updates, as you can so, so it is likely either an issue with OpenStreetMaps, or a configuration change in your app.

If you can provide any stack trace or other error logs, that would help identify what is going on.

nova-map-marker-field:1 Uncaught (in promise) Error: Bounds are not valid.
    at e.fitBounds (nova-map-marker-field:1)
    at NewClass.centerMap (nova-map-marker-field:1)
    at NewClass.showResult (nova-map-marker-field:1)
    at NewClass.<anonymous> (nova-map-marker-field:1)
    at eval (eval at <anonymous> (nova-map-marker-field:1), <anonymous>:1:2976)

I got this error on console.

I mean after i filled textbox and pressed enter, i couldn't see any moving on map. Marker is stayin same possition. There may be an error with OpenStreetMaps as you say

@parelius
Copy link

parelius commented May 4, 2020

I have the same issue. I did not declare the search provider explicitly.
I get search results but when I select an entry from the suggestions, nothing happens.

I can confirm that it was working some time ago but now it isn't.

@mikebronner
Copy link
Owner

@parelius Thanks for adding to the conversation. :) Could you provide your Nova field declaration as well? That will help with troubleshooting.

@parelius
Copy link

parelius commented May 4, 2020

Hi Mike, sure I can:

use GeneaLabs\NovaMapMarkerField\MapMarker;
use Eminiarts\Tabs\Tabs;

public function fields(Request $request)
{
	return [
	
		// some more fields...
	
		(new Tabs('Info', [
		
			__('photos.tab-content') => [
			
				// some more fields...
			
				MapMarker::make(__('photos.coordinates'))
				                    ->latitude('exif_latitude')
				                    ->longitude('exif_longitude')
				                    ->defaultLatitude(46.951082)
				                    ->defaultLongitude(7.438632)
				                    ->required()
				                    ->hideFromIndex(),
			
			],
			
			// some more tabs...
		
		])),
	
	];
}

As you see, I'm using Eminiarts\Tabs\Tabs. I don't see a difference if using MapMarker inside Tabs or not. The issue remains the same.
MapMarker used to work, even within Tabs, some time ago.

I'm currently on Laravel framework 7.9.2 and Nova 3.5.0, but I noticed this issue earlier with Laravel 7.6.2 and Nova 3.3.2.

Console Log is the same as reported by @recepgums

nova-map-marker-field:1 Uncaught (in promise) Error: Bounds are not valid.
    at e.fitBounds (nova-map-marker-field:1)
    at e.centerMap (nova-map-marker-field:1)
    at e.showResult (nova-map-marker-field:1)
    at e.<anonymous> (nova-map-marker-field:1)
    at eval (eval at <anonymous> (nova-map-marker-field:1), <anonymous>:3:2975)

@mikebronner
Copy link
Owner

@parelius Awesome, thanks for the update .... I will take a look soon, hopefully over the next few days.

@parelius
Copy link

Any news here?

@gregoriohc
Copy link

Same problem here... I guess it is related with this issue on the "leaflet-geosearch" library:
smeijer/leaflet-geosearch#167

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

4 participants