Git Product home page Git Product logo

shire's Introduction

profile for umbe1987 on Stack Exchange, a network of free, community-driven Q&A sites

shire's People

Stargazers

 avatar  avatar

Watchers

 avatar

shire's Issues

return info text problem with forEach

I tried to separate the logic of getting the layers (WMS) info 'map.onclick' in e19c94a.
Right now, getText() uses forEach.

return in forEach loop does not stops function as explained here.

using forEach, you are entering a new function (.foreach(function (e) {โ€ฆ})) and calling return there stops that new function and not the parent (checkIfFollowed) one

I would need to take advantage from it: if it returns "everything", I might check how many undefined or text I get and do something with them. Need to test a bit...

zooming with two fingers in Chrome mobile causes the panel to render badly

Apparently this happens only in Chrome when zooming in or out the map with two fingers on mobile.

Problem
the toc looses the opacity slider and legens under each layer.

Cause
Acoording to openlayers/openlayers#9105, too many change:resolution events are triggered when zooming with two fingers.

Solution proposed
Using debouncing in JavaScript.

Handle Exceptions other than GetMap

  • LEGEND

Like in this case:
immagine
Layers don't have a legend, and so requesting it leads to:

  • WMS Exceptions (example)

  • Nasty image within layer list

  • GetFeatureInfo

If exception is raised after a GetFeatureInfo request, it goes inside a "info" fancyAlert, rather than an "error" one (e.g. this one).

immagine

Attribute Table pagination

As requesting all the records from a WFS which has many rows slows down the rendering of the table, now there's an impse limit to a maximum of feature requests which is 200 (maybe too few).
I can implement a pagination like I do for the Info panel, by paginating the rows with the parameters STARTINDEX combined with MAXFEATURES, as described in https://docs.qgis.org/testing/en/docs/user_manual/working_with_ogc/server/services.html#getfeature.

e.g. 200 records starting from the 200th

https://www.wondermap.it/cgi-bin/qgis_mapserv.fcgi?map=/home/ubuntu/qgis/projects/glaciers_WMS/demo_glaciers.qgs&SERVICE=WFS&VERSION=1.1.0&REQUEST=GetFeature&MAXFEATURES=200&STARTINDEX=200&TYPENAME=glaciers_area&

(without geometry, see also #19)
https://www.wondermap.it/cgi-bin/qgis_mapserv.fcgi?map=/home/ubuntu/qgis/projects/glaciers_WMS/demo_glaciers.qgs&SERVICE=WFS&VERSION=1.1.0&REQUEST=GetFeature&MAXFEATURES=200&STARTINDEX=200&TYPENAME=glaciers_area&GEOMETRYNAME=none&

Add legend to layers with GetLegendGraphic if possible

Limiting number of rows in WFS request to build table results in truncated download

The limit to requests a maximum of 200 records from WFS to build the Attribute Table causes the download of the same only 200 records.

export function GetFeatureURL(url, typename) {
// generate a GetFeature request
// WARNING: MAXFEATURES set to 200 not to stress the server!!!
url += "SERVICE=WFS&VERSION=1.1.0&REQUEST=GetFeature&MAXFEATURES=200&";
url = url + "TYPENAME=" + typename + "&";
return url;
}

Either I create a sort of pagination to split the requests in 200 records per page, or I should remove the final part of the WFS URL request passed in the downolad button like url.replace('&MAXFEATURES=200&','');.

// finally creates the download button (to be placed in the footer)
var button = downloadBtn(url);
return [table, button];

Info tab is missing header

This is happenign because I am using info_panel.innerHTML = (data); ti inserto the info inside the panel, replacing everything there was before clicking the layer, and thus the <h1> header.
Need to handle this!

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.