|
|
@@ -161,6 +161,7 @@
|
|
|
<view class="fixed-copy">
|
|
|
<view class="btn-copy u-font-22"
|
|
|
:style="{marginBottom: `${footerHeight}rpx`}"
|
|
|
+ v-show="detail.search_key"
|
|
|
@click.stop="copyShopName">复制店名</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
@@ -196,7 +197,8 @@ export default {
|
|
|
shop_address: '',
|
|
|
join_status: '',
|
|
|
start_time: '',
|
|
|
- end_time: ''
|
|
|
+ end_time: '',
|
|
|
+ search_key: ''
|
|
|
}
|
|
|
}
|
|
|
},
|
|
|
@@ -311,6 +313,7 @@ export default {
|
|
|
uni.getLocation({
|
|
|
type: 'gcj02',
|
|
|
success: (res) => {
|
|
|
+ this.$store.commit('changeLocation', { lat: res.latitude, lng: res.longitude })
|
|
|
resolve(res)
|
|
|
},
|
|
|
fail: () => {
|
|
|
@@ -344,6 +347,12 @@ export default {
|
|
|
}
|
|
|
if (type === 1) {
|
|
|
params.id = this.detail.id
|
|
|
+ if (this.$store.state.lat) {
|
|
|
+ params.lat = this.$store.state.lat
|
|
|
+ }
|
|
|
+ if (this.$store.state.lng) {
|
|
|
+ params.lng = this.$store.state.lng
|
|
|
+ }
|
|
|
} else {
|
|
|
params.record_id = this.detail.user_activity_id
|
|
|
}
|
|
|
@@ -383,7 +392,19 @@ export default {
|
|
|
// this.joinActivity(1)
|
|
|
// }
|
|
|
// })
|
|
|
- this.joinActivity(1)
|
|
|
+ if (this.detail.tips) {
|
|
|
+ uni.showModal({
|
|
|
+ title: '提示',
|
|
|
+ content: this.detail.tips,
|
|
|
+ success: (res) => {
|
|
|
+ if (res.confirm) {
|
|
|
+ this.joinActivity(1)
|
|
|
+ }
|
|
|
+ }
|
|
|
+ })
|
|
|
+ } else {
|
|
|
+ this.joinActivity(1)
|
|
|
+ }
|
|
|
},
|
|
|
// 取消报名
|
|
|
cancelJoin () {
|
|
|
@@ -419,11 +440,11 @@ export default {
|
|
|
},
|
|
|
copyShopName () {
|
|
|
uni.setClipboardData({
|
|
|
- data: this.detail.shop_name,
|
|
|
+ data: this.detail.search_key,
|
|
|
success: () => {
|
|
|
uni.showToast({
|
|
|
icon: 'none',
|
|
|
- title: '平台门店复制成功'
|
|
|
+ title: '搜索关键字复制成功'
|
|
|
})
|
|
|
}
|
|
|
})
|