Mercurial > gemma
diff client/src/components/toolbar/Toolbar.vue @ 2355:31a1dcdba068
client: fix draw line/polygon and use name constants
* the drawn line/polygon will disapear from the map when the user click on the relative icon. its a defect in the orginal code
* use name constants instead of strings for the call of Layers
author | Fadi Abbud <fadi.abbud@intevation.de> |
---|---|
date | Wed, 20 Feb 2019 13:23:30 +0100 |
parents | a08e0f532304 |
children | bb5286acfee2 |
line wrap: on
line diff
--- a/client/src/components/toolbar/Toolbar.vue Wed Feb 20 12:23:31 2019 +0100 +++ b/client/src/components/toolbar/Toolbar.vue Wed Feb 20 13:23:30 2019 +0100 @@ -110,6 +110,7 @@ * Markus Kottländer <markus.kottlaender@intevation.de> */ import { mapState, mapGetters } from "vuex"; +import { LAYERS } from "@/store/map.js"; export default { name: "toolbar", @@ -135,7 +136,7 @@ this.cutTool.setActive(false); this.$store.commit("map/setCurrentMeasurement", null); this.$store.dispatch("map/enableIdentifyTool"); - this.getVSourceByName("Draw Tool").clear(); + this.getVSourceByName(LAYERS.DRAWTOOL).clear(); } }); }