| 12345678910111213141516171819202122232425262728293031323334353637 |
- <template>
- <view class="draw-map">
- <draw @onSubmit="onSubmit"></draw>
- </view>
- </template>
- <script>
- import Draw from '@/components/OpenLayerMap/Draw.vue';
- export default {
- components:{
- Draw
- },
- data(){
- return {
- eventChannel:null
- }
- },
- onLoad(e) {
- this.eventChannel = this.getOpenerEventChannel();
- },
- methods:{
- onSubmit(e) {
- this.eventChannel.emit('savePolygonCoords', {
- coords: e
- })
- uni.navigateBack();
- }
- }
- }
- </script>
- <style lang="scss">
- .draw-map{
- height: calc(100vh - var(--window-top) - 40rpx);
- background-color: $uni-user-page-bgc;
- }
- </style>
|