File tree Expand file tree Collapse file tree 2 files changed +13
-2
lines changed
packages/clients/dish/src Expand file tree Collapse file tree 2 files changed +13
-2
lines changed Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ import {
1919} from '../servicesConstants'
2020import { scaleFromZoomLevel } from '../utils/calculateScaleFromResolution'
2121
22- const alkisMinZoom = 10
22+ export const alkisMinZoom = 10
2323export const beschriftungMinZoom = 9
2424
2525const layersIntern : LayerConfiguration [ ] = [
Original file line number Diff line number Diff line change 11import { MapInstance } from '@polar/core'
22import { categoryIdAlkisSearch } from '../mapConfigurations/searchConfigParams'
3+ import { alkisWms } from '../servicesConstants'
4+ import { alkisMinZoom } from '../mapConfigurations/layerConfigIntern'
35
46export function watchSearchResultForAlkisSearch ( instance : MapInstance ) {
57 instance . subscribe ( 'plugin/addressSearch/chosenAddress' , ( chosenAddress ) => {
@@ -21,7 +23,16 @@ export function watchSearchResultForAlkisSearch(instance: MapInstance) {
2123 patternKeysSearchResult . includes ( item )
2224 )
2325 ) {
24- console . log ( '### ES KLAPPT' )
26+ instance . $store . getters . map . getView ( ) . setZoom ( alkisMinZoom )
27+ const activeMaskIds =
28+ instance . $store . getters [ 'plugin/layerChooser/activeMaskIds' ]
29+ if ( ! activeMaskIds . includes ( alkisWms ) ) {
30+ activeMaskIds . push ( alkisWms )
31+ instance . $store . dispatch (
32+ 'plugin/layerChooser/setActiveMaskIds' ,
33+ activeMaskIds
34+ )
35+ }
2536 }
2637 } )
2738}
You can’t perform that action at this time.
0 commit comments