Skip to content
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

popup error with ArcGIS map services v10+ #59

Open
spiveygb opened this issue Sep 19, 2012 · 10 comments
Open

popup error with ArcGIS map services v10+ #59

spiveygb opened this issue Sep 19, 2012 · 10 comments

Comments

@spiveygb
Copy link

I've taken the demo page and replaced the San Francisco 311 feature service with a map servicce for Homeland Security --http://sampleserver3.arcgisonline.com/ArcGIS/rest/services/HomelandSecurity/operations/MapServer/0. The features draw correctly but upon clicking on one of the features I receive the error, "Uncaught TypeError: Cannot read property 'y' of undefined." Logging the geometry.y value on line 19 of EsriJSONLayer.js reveals that the "y" coordinate is repeated multiple times.

@JasonSanford
Copy link
Owner

Do you have a link to the demo you created? Can you create a jsfiddle showing the error?

@spiveygb
Copy link
Author

Jason,

Here is the fiddle:  http://jsfiddle.net/spiveygb/BjXFV/3/

Brett


From: Jason Sanford notifications@github.com
To: JasonSanford/google-vector-layers google-vector-layers@noreply.github.com
Cc: spiveygb spiveygb@yahoo.com
Sent: Wednesday, September 19, 2012 11:44 AM
Subject: Re: [google-vector-layers] popup error with ArcGIS map services v10+ (#59)

Do you have a link to the demo you created? Can you create a jsfiddle showing the error?

Reply to this email directly or view it on GitHub.

@JasonSanford
Copy link
Owner

Ahhh, you're using Leaflet 0.4.x. Have you tried with 0.3.x? The next thing on my list is to update Leaflet Vector Layers to support Leaflet 0.4.x.

@spiveygb
Copy link
Author

I will certainly try that on the fiddle. I thought that your latest update on GitHub (v1.3) referenced 0.4.x? Did I jump the gun on that?


From: Jason Sanford notifications@github.com
To: JasonSanford/google-vector-layers google-vector-layers@noreply.github.com
Cc: spiveygb spiveygb@yahoo.com
Sent: Wednesday, September 19, 2012 2:05 PM
Subject: Re: [google-vector-layers] popup error with ArcGIS map services v10+ (#59)

Ahhh, you're using Leaflet 0.4.x. Have you tried with 0.3.x? The next thing on my list is to update Leaflet Vector Layers to support Leaflet 0.4.x.

Reply to this email directly or view it on GitHub.

@JasonSanford
Copy link
Owner

Yeah, that was just a branch I created to do all of my work to updated to 0.4.x

@spiveygb
Copy link
Author

Ok, I will implement 0.3 into the code and test. I'll let you know how it goes and thanks for the response.


From: Jason Sanford notifications@github.com
To: JasonSanford/google-vector-layers google-vector-layers@noreply.github.com
Cc: spiveygb spiveygb@yahoo.com
Sent: Wednesday, September 19, 2012 2:11 PM
Subject: Re: [google-vector-layers] popup error with ArcGIS map services v10+ (#59)

Yeah, that was just a branch I created to do all of my work to updated to 0.4.x

Reply to this email directly or view it on GitHub.

@JasonSanford
Copy link
Owner

Seems to work: http://jsfiddle.net/FWhNu/

@spiveygb
Copy link
Author

I'm not sure if this is much help to you but I've tracked down where the error is occurring using v0.4. 

It's in Layer.js at line 378: this.options.map.addLayer(ownsPopup.popup);

I'll keep digging on it but I'll have to admit that this is pushing my js skills so I don't know how far I'll get.

Brett


From: Jason Sanford notifications@github.com
To: JasonSanford/google-vector-layers google-vector-layers@noreply.github.com
Cc: spiveygb spiveygb@yahoo.com
Sent: Wednesday, September 19, 2012 2:22 PM
Subject: Re: [google-vector-layers] popup error with ArcGIS map services v10+ (#59)

Seems to work: http://jsfiddle.net/FWhNu/

Reply to this email directly or view it on GitHub.

@spiveygb
Copy link
Author

Perhaps this will save you a couple of minutes when you are working on the upgrade...I tracked down a bit further. It seems as though Leaflet made some changes in the _updatePosition function in the source. In v0.4 it now implements "offset" and this is what doesn't get passed in with Leaflet Vector Layers.  

Thanks for your help yesterday,

Brett


From: Jason Sanford notifications@github.com
To: JasonSanford/google-vector-layers google-vector-layers@noreply.github.com
Cc: spiveygb spiveygb@yahoo.com
Sent: Wednesday, September 19, 2012 2:22 PM
Subject: Re: [google-vector-layers] popup error with ArcGIS map services v10+ (#59)

Seems to work: http://jsfiddle.net/FWhNu/

Reply to this email directly or view it on GitHub.

@JasonSanford
Copy link
Owner

This is fixed in my branch for v1.3.0. I still need to work on the docs pages a bit, but I'm getting close. You could use the code now if you needed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants