收藏
回答

map中嵌套cover-view,点击事件无效,请问如何解决?

地图上展示marker,marker上展示气泡callout,因展示的内容太多,使用的自定义callout,参照文档里提供的demo,实现了,我想要的效果,但是点击事件没反应,请问如何处理?

 <view>
    <map class="home-map" scale="{{currentScale}}" longitude="{{currentLongitude}}" latitude="{{currentLatitude}}" markers="{{markers}}" bindtap="bindtapmap" bindmarkertap="bindmarkertap" show-location="true">
      <cover-view slot="callout">
        <block wx:for="{{customCalloutMarkerIds}}" wx:key="*this">
          <cover-view class="customCallout" marker-id="{{item}}" >
            <cover-view class="content" > 
              <cover-view bindtap="trackPlayBack">车牌号{{currentMarker.id}}</cover-view>
              <cover-view>车牌号{{currentMarker.name}}</cover-view>
              <cover-view>车牌号{{currentMarker.latitude}}</cover-view>
              <cover-view>车牌号{{currentMarker.longitude}}</cover-view>
              <cover-view>车牌号{{currentVehicle}}</cover-view>
            </cover-view>
          </cover-view>
        </block>
      </cover-view>
    </map>
  </view>

trackPlayBack(){
  console.log(111111)
  wx.navigateTo({
    url'/pages/trackPlayBack/trackPlayBack',
  })
}
回答关注问题邀请回答
收藏

3 个回答

登录 后发表内容