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

Not able to get the preview of KML files. #58

Closed
shubham-mahajan opened this issue May 16, 2018 · 9 comments
Closed

Not able to get the preview of KML files. #58

shubham-mahajan opened this issue May 16, 2018 · 9 comments

Comments

@shubham-mahajan
Copy link
Member

Hi Team

I have installed the extension as per readme, but I am not able to get the preview. No error is coming either in JS or in CKAN. Are there any dependencies that I need to install for ckanext-geoview to work properly.

The preview is completely blank page. Attaching the screenshot for the same.

Loading... The text is coming and after that, it went blank.

screen shot 2018-05-15 at 6 02 15 pm

Thanks

@pduchesne
Copy link

Hello Shubham,

I tried that resource on a local instance of mine and it worked fine.
can you share a link to an online CKAN instance that reproduces the problem?

@shubham-mahajan
Copy link
Member Author

Hi @pduchesne ,

I am also working on local instance only, but if you require I will set up the same in public instance and share the same. The basic difference I am able to see with a working site and my instance are mainly mapconfig options in the inspection of the elements. Is there any dependency on other extension or Framework?

@pduchesne
Copy link

Can you share your ckanext.spatial.* and ckanext.geoview.* values from your config? And your basemaps.json config, if you have one.

@shubham-mahajan
Copy link
Member Author

@pduchesne

I have not installed the spatial extension, is it required for geoview to work, it's not there in documentation.

ckan.plugins = stats geo_view text_view image_view resource_proxy
ckan.views.default = image_view geo_view
ckan.spatial.srid = 4326
ckanext.geoview.ol_viewer.formats = wms kml geojson

@pduchesne
Copy link

OK, I got it.

There's been a regression causing the default basemap to fail. I'll fix that.

In the mean time, to be able to work with your current install, you'll have to explicitly specify a basemap in your config, f.i. :

ckanext.spatial.common_map.type = XYZ
ckanext.spatial.common_map.custom.url = http://tile.openstreetmap.org/{z}/{x}/{y}.png
ckanext.spatial.common_map.attribution = Map tiles & Data by OpenStreetMap, under CC BY SA.

@pduchesne
Copy link

my bad, you should use this (custom type) :

ckanext.spatial.common_map.type = custom
ckanext.spatial.common_map.custom.url = http://tile.openstreetmap.org/{z}/{x}/{y}.png
ckanext.spatial.common_map.attribution = Map tiles & Data by OpenStreetMap, under CC BY SA.

@shubham-mahajan
Copy link
Member Author

Hi @pduchesne

Thanks for providing the configuration, it's displaying the display. But default, MAP Viewer(Open Layers) is not getting created for KML files/URLs. Is there any option or configuration entry for default view as MAP Viewer for all the KML files.

P.S.
Configuration entries used are:-

ckan.plugins = stats geo_view text_view image_view resource_proxy
ckan.views.default = image_view geo_view
ckan.spatial.srid = 4326
ckanext.geoview.ol_viewer.formats = wms kml geojson
ckanext.spatial.common_map.type = custom
ckanext.spatial.common_map.custom.url = http://tile.openstreetmap.org/{z}/{x}/{y}.png
ckanext.spatial.common_map.attribution = Map tiles & Data by OpenStreetMap, under CC BY SA.

@pduchesne
Copy link

the correct config key for default views is ckan.views.default_views, not ckan.views.default

@shubham-mahajan
Copy link
Member Author

@pduchesne

Thanks a lot, everything is working fine now. For default view, it was a typo.

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