3liz / lizmap-web-client

Transfer a QGIS project on a server, Lizmap is providing the web interface to browse it
https://www.lizmap.com
Mozilla Public License 2.0
254 stars 143 forks source link

GeoJSON when displaying attribute table is not valid #2704

Open juwizeye opened 2 years ago

juwizeye commented 2 years ago

Hi , I have installed Qgis server et lizmap on a lunix remote machine and Qgis desktop locally on Windows, it works well i can see a map in the canvas. image But there is nothing in the layers's attributes tables . same for localization by layer , I can't see the values of the attribute that I selected. image

I tested the same projet on localhost , and i worked nicely. there nothing in lizmap logs , If you have any suggestion I am all years. I use:

Gustry commented 2 years ago

Do you have any error in the javascript console ? when clicking buttons ?

You should see network requests to fetch data.

juwizeye commented 2 years ago

@Gustry no i don't have any error

juwizeye commented 2 years ago

@Gustry how I can i see network requests?

juwizeye commented 2 years ago

I have this error in nginx logs image

juwizeye commented 2 years ago

@Gustry , when I used chrome browser I found the following error : image I have this error when I use either PostgreSQL or spatial .

Gustry commented 2 years ago

Indeed, thanks to the URL you have published in #1714, we can see the GeoJSON when fetching data for the attribute table is invalid: Screenshot from 2022-01-26 10-10-43

@nboisteault @mdouchin Any idea how this error is in the geojson data ?

Lizmap version: 3.5.0

juwizeye commented 2 years ago

@Gustry is there any special configuration for Https? I think that the problem come from there because when I am on localhost it works fine.

juwizeye commented 2 years ago

I found the solution , I had used fcgiwrap to install qgisserver and now I am using spawn-fcgi and it works fine. Thank you for your help @Gustry

Gustry commented 2 years ago

Indeed, according to the QGIS documentation, fcgiwrap is not recommended, performances are bad. I'm not sure why HTTPS on QGIS Server. QGIS Server must stay hidden from the network otherwise you would have security issue if they bypass Lizmap. But indeed, you might have the use case for it and you can still have HTTPS.

But anyway, the GeoJSON mustn't have some error message in the geojson content. It makes it invalid.