| | |
| | | <template> |
| | | <div class="left-top-toolbox-panel"> |
| | | <div class="specific-tools"> |
| | | <el-button @click="changeSelect" v-show="selectGroup"> |
| | | <el-button class="el-button-choice" @click="changeSelect" v-show="selectGroup"> |
| | | <img src="@assets/images/map-pages/icon/toolbox/tool.png" alt=""> |
| | | <span>工具</span> |
| | | </el-button> |
| | | <el-button @click="changeSelect" v-show="!selectGroup"> |
| | | <el-button class="el-button-choice" @click="changeSelect" v-show="!selectGroup"> |
| | | <img src="@assets/images/map-pages/icon/toolbox/Selecd/tool.png" alt=""> |
| | | <a>工具</a> |
| | | </el-button> |
| | |
| | | </div> |
| | | </el-popover> |
| | | <el-button @click="changeSelect" class="special-button"> |
| | | <i :class="selectGroup === false ? 'el-icon-d-arrow-right':'el-icon-d-arrow-left'"></i> |
| | | <i class="el-icon-d-arrow-left"></i> |
| | | </el-button> |
| | | </el-row> |
| | | </transition> |
| | |
| | | selectGroup: false, |
| | | drawLayer: null, |
| | | map: null, |
| | | L: window.L, |
| | | // L: window.L, |
| | | active: -1, |
| | | Selecd: -1 |
| | | } |
| | |
| | | } |
| | | }, |
| | | choiceItem (itemT, indexT) { |
| | | // console.log(itemT.label) |
| | | this.Selecd = indexT |
| | | switch (itemT.label) { |
| | | case '点标绘': |
| | |
| | | iconAnchor: [13, 16], |
| | | popupAnchor: [26, -32] |
| | | }) |
| | | var drawLayer = this.map.editTools.startMarker() |
| | | drawLayer.setIcon(myIcon) |
| | | this.drawLayer.addLayer(drawLayer) |
| | | this.setLogic(drawLayer) |
| | | var drawLayerMarker = this.map.editTools.startMarker() |
| | | drawLayerMarker.setIcon(myIcon) |
| | | this.drawLayer.addLayer(drawLayerMarker) |
| | | this.setLogic(drawLayerMarker) |
| | | break |
| | | case '线标绘': |
| | | var drawLayerLine = this.map.editTools.startPolyline() |
| | |
| | | setLogic (layer) { |
| | | layer.on('dblclick', this.L.DomEvent.stop).on('dblclick', layer.toggleEdit) |
| | | layer.setStyle({ |
| | | color: 'red', |
| | | fillColor: '#ffffff', |
| | | fillOpacity: 0.1, |
| | | fill: true |
| | | color: 'red' |
| | | }) |
| | | }, |
| | | changeSelect () { |
| | |
| | | |
| | | span { |
| | | display: block; |
| | | font-size: 0.012rem; |
| | | color: @color-tool; |
| | | } |
| | | |
| | |
| | | } |
| | | } |
| | | |
| | | .el-button-choice { |
| | | z-index: 999; |
| | | padding: 0; |
| | | margin: 0 0.015rem; |
| | | width: 45px; |
| | | height: 45px; |
| | | background: @background-color-tools; |
| | | border: 1px solid @color-shadow; |
| | | } |
| | | |
| | | .specific-tools-group { |
| | | z-index: 1; |
| | | //.tools-panel-content { |