Only first WFS/json label passed to mapfish on print report request
Hi all,
if a WFS layer with labels is printed with mapfish3 all features have the very same label (instead of their own) in the print. E.g. if I do print some WFS layer like e.g.:
I do get a result with all Points having the same label (compare to the pdf attached).
I first updated mapfish, but no difference.
The issue is not really surprising looking at the report request:
{"uniqueIdList":[],"visibleLayerIds":["topplus_wmts","fa_rettungsp"],"layout":"A4 quer (box)","attributes":{"title":"FreiGIS","map":{"dpi":300,"projection":"EPSG:25832","center":[416958.25101621123,5310834.124718633],"scale":15000,"layers":[{"type":"geojson","style":{"version":"2","*":{"symbolizers":[{"type":"point","graphicWidth":25,"graphicHeight":25.8,"externalGraphic":"https://geoportal.freiburg.de/img/Rettungspunkt.png","graphicOpacity":1},{"type":"text","label":"FR-012","fontColor":"#000000","fontOpacity":0.9,"labelOutlineColor":"#008f35","labelOutlineWidth":3,"labelXOffset":0,"labelYOffset":-25,"fontSize":16,"fontFamily":"Comic Sans MS","labelAlign":"cm"}]}},"geojson":[{"type":"Feature","geometry":{"type":"Point","coordinates":[415132.5211,5312248.0816,0]},"properties":{"boundedBy":[415132.5211,5312248.0816,415132.5211,5312248.0816],"":"undefined_0"},"id":"3225"},{"type":"Feature","geometry":{"type":"Point","coordinates":[414574.1658,5311155.8933,0]},"properties":{"boundedBy":[414574.1658,5311155.8933,414574.1658,5311155.8933],"":"undefined_0"},"id":"3229"},{"type":"Feature","geometry":{"type":"Point","coordinates":[417545.041,5309552.6093,0]},"properties":{"boundedBy":[417545.041,5309552.6093,417545.041,5309552.6093],"":"undefined_0"},"id":"3233"},{"type":"Feature","geometry":{"type":"Point","coordinates":[416597.2665,5311831.0177,0]},"properties":{"boundedBy":[416597.2665,5311831.0177,416597.2665,5311831.0177],"":"undefined_0"},"id":"3237"},{"type":"Feature","geometry":{"type":"Point","coordinates":[418822.0768,5311640.6877,0]},"properties":{"boundedBy":[418822.0768,5311640.6877,418822.0768,5311640.6877],"":"undefined_0"},"id":"3241"},{"type":"Feature","geometry":{"type":"Point","coordinates":[417158.6031,5311506.1163,0]},"properties":{"boundedBy":[417158.6031,5311506.1163,417158.6031,5311506.1163],"":"undefined_0"},"id":"3245"},{"type":"Feature","geometry":{"type":"Point","coordinates":[418013.6312,5310693.9231,0]},"properties":{"boundedBy":[418013.6312,5310693.9231,418013.6312,5310693.9231],"":"undefined_0"},"id":"3249"},{"type":"Feature","geometry":{"type":"Point","coordinates":[415725.5595,5310150.0306,0]},"properties":{"boundedBy":[415725.5595,5310150.0306,415725.5595,5310150.0306],"":"undefined_0"},"id":"3253"}]},{"baseURL":"https://sgx.geodatenzentrum.de/wmts_topplus_open/tile/1.0.0/web/{style}/{TileMatrixSet}/{TileMatrix}/{TileRow}/{TileCol}.png","opacity":1,"type":"WMTS","layer":"web","style":"default","imageFormat":"image/png","matrixSet":"EU_EPSG_25832_TOPPLUS","matrices":[{"identifier":"00","matrixSize":[6,5],"topLeftCorner":[-3803165.98427299,8805908.08284866],"scaleDenominator":17471320.750897426,"tileSize":[256,256]},{"identifier":"01","matrixSize":[12,10],"topLeftCorner":[-3803165.98427299,8805908.08284866],"scaleDenominator":8735660.375448713,"tileSize":[256,256]},{"identifier":"02","matrixSize":[24,20],"topLeftCorner":[-3803165.98427299,8805908.08284866],"scaleDenominator":4367830.187724357,"tileSize":[256,256]},{"identifier":"03","matrixSize":[48,40],"topLeftCorner":[-3803165.98427299,8805908.08284866],"scaleDenominator":2183915.0938621783,"tileSize":[256,256]},{"identifier":"04","matrixSize":[96,80],"topLeftCorner":[-3803165.98427299,8805908.08284866],"scaleDenominator":1091957.5469310891,"tileSize":[256,256]},{"identifier":"05","matrixSize":[192,160],"topLeftCorner":[-3803165.98427299,8805908.08284866],"scaleDenominator":545978.7734655463,"tileSize":[256,256]},{"identifier":"06","matrixSize":[384,320],"topLeftCorner":[-3803165.98427299,8805908.08284866],"scaleDenominator":272989.38673277246,"tileSize":[256,256]},{"identifier":"07","matrixSize":[768,640],"topLeftCorner":[-3803165.98427299,8805908.08284866],"scaleDenominator":136494.69336638605,"tileSize":[256,256]},{"identifier":"08","matrixSize":[1536,1280],"topLeftCorner":[-3803165.98427299,8805908.08284866],"scaleDenominator":68247.3466831932,"tileSize":[256,256]},{"identifier":"09","matrixSize":[3072,2560],"topLeftCorner":[-3803165.98427299,8805908.08284866],"scaleDenominator":34123.673341596535,"tileSize":[256,256]},{"identifier":"10","matrixSize":[6144,5120],"topLeftCorner":[-3803165.98427299,8805908.08284866],"scaleDenominator":17061.836670798286,"tileSize":[256,256]},{"identifier":"11","matrixSize":[12288,10240],"topLeftCorner":[-3803165.98427299,8805908.08284866],"scaleDenominator":8530.918335399143,"tileSize":[256,256]},{"identifier":"12","matrixSize":[24576,20480],"topLeftCorner":[-3803165.98427299,8805908.08284866],"scaleDenominator":4265.4591676995715,"tileSize":[256,256]},{"identifier":"13","matrixSize":[49152,40960],"topLeftCorner":[-3803165.98427299,8805908.08284866],"scaleDenominator":2132.729583849782,"tileSize":[256,256]}],"requestEncoding":"REST"}]},"showGfi":false,"gfi":{},"showLegend":false,"legend":{}},"outputFilename":"Ausdruck","outputFormat":"pdf"}
You don’t need to search it, don’t worry: There is only one label passed (which is "label":"FR-012") in this example.
Best,
Dominik
Comments (6)
-
reporter -
- changed status to open
-
-
assigned issue to
-
assigned issue to
-
Info zur Bearbeitung des Issues:
in der stylev3. json muss amm style die Property “
labelField”
mit einer Property des Features gefüllt sein.Das benutzen wir in den Hamburger Portalen nicht.
-
reporter Genau. Im obigen Beispiel mit den Rettungspunkten ist
"labelField": "nummer_neu",
Die ganze Style.json findet sich hier: https://geoportal.freiburg.de/freigis_dev/ressources/style_v3.json
Der betreffende Style heißt naheliegenderweise “rettungspunkte”.
Klappt in der Ansicht im Portal super. Nur im Ausdruck übergibt er nur ein Label.
-
- changed status to resolved
Hallo Herr Fröhlich,
der Fehler wird mit dem nächsten Veröffentlichung des Masterportals behoben sein.
Jedes Feature wird dann korrekt mit seinem eigenen Label dargestellt.
Beste Grüße Melanie Klamp
- Log in to comment
The behaviour is dependent on the styling rules: If there is an individual rule for all the features, they also have their individual labels in the print. E.g. print this:
https://geoportal.freiburg.de/freigis_dev/?Map/layerIds=topplus_wmts,alkis_sw_bg,gemarkung&visibility=true,true,true&transparency=0,0,0&Map/center=[412334.1766267634,5315745.0532521345]&Map/zoomLevel=1
Best,
Dominik