不支持canvas

小程序拨打电话

index.wxml
<view class="hotLine" bindtap="callPhone" data-phone="{{mobile}}">{{mobile}}</view>


index.js
Page({

  /**
   * 页面的初始数据
   */
  data: {
    mobile:'1008611'
  },
  callPhone(e){
     var mobile = e.currentTarget.dataset.phone; 
     var that = this;
     wx.makePhoneCall({
       phoneNumber: mobile,
       success:function(){},
     })
  },
})
posted @ 2020-01-13 11:27  pycmsj  阅读(382)  评论(0编辑  收藏  举报