Git Product home page Git Product logo

Comments (18)

nworr avatar nworr commented on May 24, 2024 1

with #4414 the data table will no longer be empty when using HTML tag with attributes in field content (virtual or not)

PR still needed for displaying a thumbnail

from lizmap-web-client.

Gustry avatar Gustry commented on May 24, 2024

Can you elaborate ? What is is not working ? What is the error in the console ? Any picture ?

from lizmap-web-client.

josemvm avatar josemvm commented on May 24, 2024

@Gustry the table is not displayd at all on data tool

from lizmap-web-client.

Gustry avatar Gustry commented on May 24, 2024

Any error message displayed in the console ? (F12)

from lizmap-web-client.

josemvm avatar josemvm commented on May 24, 2024

no, no errors displayed in the console, just 11:31:07 WARNING Server[15550]: Error parsing post data as XML: at line 1, column 1: error occurred while parsing element. Assuming urlencoded query string sent in the post body. in qgis server log file...

from lizmap-web-client.

Gustry avatar Gustry commented on May 24, 2024

Please describe your issue @josemvm

this expression here [URL] stop working on 3.7.7-pre.7395

is very vague.

Is the panel empty ? Is the table there but empty (table headers) ?
Does it work if you remove the virtual field ? (maybe try to not expose it with WMS/WFS?)
Is the button to open the "Attribute table" panel OK ? Is the button to choose the layer to display in the panel OK ?
Is-there any error in the console when pressing one of these buttons ? (Check both "console" and "networks" tab) There must be a WFS requests sent to get the data ? Is the content of the request empty or is there an HTTP error code ?

Your first description and title mention that the expression is not working (so I understand only the tip preview is not working, then later you say : "the table is not displayd at all on data tool", so it means nothing is displayed at all ?

from lizmap-web-client.

josemvm avatar josemvm commented on May 24, 2024

@Gustry sorry

Is the panel empty ? Is the table there but empty (table headers) ?

the panel is not empty, the panel has de name of the table but the table doesn´t appears (no headers)

Does it work if you remove the virtual field ? (maybe try to not expose it with WMS/WFS?)

yes, it works if i remove the virtual field (just expose with WFS)

Is the button to open the "Attribute table" panel OK ? Is the button to choose the layer to display in the panel OK ?

yes

Is-there any error in the console when pressing one of these buttons ? (Check both "console" and "networks" tab) There must be a WFS requests sent to get the data ? Is the content of the request empty or is there an HTTP error code ?

no errors in the console nor in the network inspector
this is the request in apache access.log file
127.0.0.1 - - [29/Apr/2024:14:26:00 +0100] "GET /cgi-bin/qgis_mapserv.fcgi?map=%2Fvar%2Fwww%2Fhtml%2Flizmap%5Fweb%5Fclient%2Flizmap%2Finstall%2Fma%2FsigRedesA%2Eqgs&outputformat=XMLSCHEMA&request=describefeaturetype&service=WFS&typename=valvulasCorte&version=1%2E0%2E0&Lizmap%5FUser=xx%5Fxxxxx&Lizmap%5FUser%5FGroups=admins%2C%20giig%2C%20users&Lizmap%5FOverride%5FFilter=1 HTTP/1.1" 200 1742 "-" "3.7.7-pre" 10.27.10.58 - - [29/Apr/2024:14:26:00 +0100] "POST /index.php/lizmap/service HTTP/1.1" 200 1672 "http://xxxxx.xxxxx.xx/index.php/view/map?repository=ma&project=sigRedesA" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:124.0) Gecko/20100101 Firefox/124.0"

from lizmap-web-client.

Gustry avatar Gustry commented on May 24, 2024

no errors in the console nor in the network inspector

Do you have data inside ? (with the virtual field enabled)

from lizmap-web-client.

josemvm avatar josemvm commented on May 24, 2024

i have no the request in the console inspector like this if the virtual field is enabled:
http://xxxxx.xxxxx.xx/index.php/lizmap/service?repository=ma&project=sigRedesA&REQUEST=GetMap&SERVICE=WMS&VERSION=1.3.0&FORMAT=image%2Fpng&STYLES=1%20-%20s%2F%20Etiquetas&TRANSPARENT=true&LAYERS=bocasIncendio&DPI=96&WIDTH=2080&HEIGHT=537&CRS=EPSG%3A3763&BBOX=-49717.39180027518%2C-116553.26722038354%2C87866.21670027517%2C-81032.88367961647&ts=1714398035229

from lizmap-web-client.

Gustry avatar Gustry commented on May 24, 2024

Your comment above is a REQUEST=GetMap related to WMS, so not linked to WFS.

When you open the attribute table, all the data is fetched with WFS.

from lizmap-web-client.

josemvm avatar josemvm commented on May 24, 2024

@Gustry i can provide to you an url for inspector

from lizmap-web-client.

Gustry avatar Gustry commented on May 24, 2024

Yes, you can, with the virtual field enabled.

from lizmap-web-client.

Gustry avatar Gustry commented on May 24, 2024

@josemvm I was expecting you to see the request made to QGIS server to fetch the data :

image

And we can see you got data from the server in the web browser :

image

But due to recent PR about security, this Javascript injection has been disabled.

There is still a bug that the table should have been loaded but only the content of the field should have been disabled.

CC @laurentj and @nboisteault

from lizmap-web-client.

nworr avatar nworr commented on May 24, 2024

the DOMPurify call return a string that can't be handled by JSON.parse function

SyntaxError: JSON.parse: expected ',' or '}' after property value in object at line 1 column 374 of the JSON data
Maybe because the content is json formatted and contain escaped " and ' ?

image

PR #4409 to fix it

Another one will fix the thumbnail creation

from lizmap-web-client.

josemvm avatar josemvm commented on May 24, 2024

@nworr many thanks!

from lizmap-web-client.

josemvm avatar josemvm commented on May 24, 2024

but... it means that the thumbnail will appear in the table (or not)?

from lizmap-web-client.

nworr avatar nworr commented on May 24, 2024

yes that's the goal ( onload= are now prohibited, but the expression may be like concat('<img src="foo" data-src=',"virtual_field" , ' class="attrirbute-thumbnal" ') , doc will be updated )

from lizmap-web-client.

josemvm avatar josemvm commented on May 24, 2024

ok, thanks again, i will try ;-)

from lizmap-web-client.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.