@@ -530,31 +530,27 @@ function getEditGeometryUrl(settings, wfsData, extent) {
530530 return url + 'isinitopen=wfst&layerids=' + layerIds . join ( ',' ) ;
531531}
532532
533- function getMasterportalLayerIds ( fieldConfiguration , wfsData , includeAll = false ) {
533+ function getMasterportalLayerIds ( fieldConfiguration , wfsData ) {
534534 const rasterLayerId = fieldConfiguration . masterportal_raster_layer_id ;
535- const vectorLayerIds = getMasterportalVectorLayerIds ( fieldConfiguration , wfsData , includeAll ) ;
535+ const vectorLayerIds = getMasterportalVectorLayerIds ( fieldConfiguration , wfsData ) ;
536536
537537 return rasterLayerId
538538 ? [ rasterLayerId ] . concat ( vectorLayerIds )
539539 : vectorLayerIds ;
540540}
541541
542- function getMasterportalVectorLayerIds ( fieldConfiguration , wfsData , includeAll ) {
542+ function getMasterportalVectorLayerIds ( fieldConfiguration , wfsData ) {
543543 const fieldName = fieldConfiguration . masterportal_vector_layer_field_name ;
544544 const mapping = fieldConfiguration . masterportal_vector_layer_ids ;
545545
546546 let result ;
547547 if ( fieldName && mapping && wfsData ) {
548- if ( includeAll ) {
549- result = fieldConfiguration . masterportal_vector_layer_ids . map ( entry => entry . layer_id ) ;
550- } else {
551- result = wfsData . features . map ( feature => feature . properties [ fieldName ] )
552- . reduce ( ( result , value ) => {
553- const layerId = mapping . find ( entry => entry . field_value === value ) ?. layer_id ;
554- if ( layerId && ! result . includes ( layerId ) ) result . push ( layerId ) ;
555- return result ;
556- } , [ ] ) ;
557- }
548+ result = wfsData . features . map ( feature => feature . properties [ fieldName ] )
549+ . reduce ( ( result , value ) => {
550+ const layerId = mapping . find ( entry => entry . field_value === value ) ?. layer_id ;
551+ if ( layerId && ! result . includes ( layerId ) ) result . push ( layerId ) ;
552+ return result ;
553+ } , [ ] ) ;
558554 }
559555
560556 if ( result ?. length ) {
0 commit comments