|
@@ -15,7 +15,7 @@
|
|
|
<span style="color: #666666;font-size: 28rpx">联系电话:</span>
|
|
|
<span style="color: #18172A;font-size: 36rpx;font-weight: 600">{{ form.activityPhone }}</span>
|
|
|
</span>
|
|
|
- <img src="https://www.idea-co-sf.com/gardenProduct/image/phoneIcon.png" class="phoneIcon">
|
|
|
+ <img src="https://www.idea-co-sf.com/gardenProduct/image/phoneIcon.png" class="phoneIcon" @tap="call">
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="appSecondBox">
|
|
@@ -35,7 +35,7 @@
|
|
|
<span class="secondBoxTitle">活动地址</span>
|
|
|
<span class="secondBoxInfo dhInfo">
|
|
|
<span>{{ form.activityAddress }} - {{ form.activityAddressDetail }}</span>
|
|
|
- <img src="./image/dhIcon.png" class="dhIcon">
|
|
|
+ <img src="./image/dhIcon.png" class="dhIcon" @tap="getLocal">
|
|
|
</span>
|
|
|
</div>
|
|
|
<div class="secondBoxItem">
|
|
@@ -87,10 +87,39 @@ export default {
|
|
|
},
|
|
|
onLoad(options) {
|
|
|
this.activityId = options.activityId
|
|
|
- this.url = url
|
|
|
+ this.url = options.url
|
|
|
this.getById()
|
|
|
},
|
|
|
methods: {
|
|
|
+ call(){
|
|
|
+ uni.makePhoneCall({
|
|
|
+ phoneNumber: this.form.activityPhone, // 电话号码
|
|
|
+ success: function () {
|
|
|
+ console.log('拨打电话成功');
|
|
|
+ },
|
|
|
+ fail: function () {
|
|
|
+ console.log('拨打电话失败');
|
|
|
+ }
|
|
|
+ });
|
|
|
+ },
|
|
|
+ getLocal(){
|
|
|
+ const _this = this
|
|
|
+ uni.openLocation({
|
|
|
+ latitude: Number(_this.form.latitude),
|
|
|
+ longitude: Number(_this.form.longitude),
|
|
|
+ success: function () {
|
|
|
+ console.log('success');
|
|
|
+ }
|
|
|
+ });
|
|
|
+ // uni.getLocation({
|
|
|
+ // type: 'gcj02', //返回可以用于uni.openLocation的经纬度
|
|
|
+ // success: function (res) {
|
|
|
+ // const latitude = res.latitude;
|
|
|
+ // const longitude = res.longitude;
|
|
|
+ //
|
|
|
+ // }
|
|
|
+ // });
|
|
|
+ },
|
|
|
getById(){
|
|
|
const data = {
|
|
|
id : this.activityId,
|