返乡登记
This commit is contained in:
@@ -54,15 +54,15 @@
|
|||||||
<u-popup v-model="show" mode="bottom" border-radius="14">
|
<u-popup v-model="show" mode="bottom" border-radius="14">
|
||||||
<div class="line-bg"></div>
|
<div class="line-bg"></div>
|
||||||
<div class="flex">
|
<div class="flex">
|
||||||
<div class="item">
|
<div class="item" @click="share">
|
||||||
<img src="./components/img/zf.png" alt="">
|
<img src="./components/img/zf.png" alt="">
|
||||||
<p>转发</p>
|
<p>转发</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="item">
|
<div class="item" @click="shareWechat">
|
||||||
<img src="./components/img/wx.png" alt="">
|
<img src="./components/img/wx.png" alt="">
|
||||||
<p>分享到微信</p>
|
<p>分享到微信</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="item">
|
<div class="item" @click="copy">
|
||||||
<img src="./components/img/lj.png" alt="">
|
<img src="./components/img/lj.png" alt="">
|
||||||
<p>获取链接</p>
|
<p>获取链接</p>
|
||||||
</div>
|
</div>
|
||||||
@@ -79,7 +79,7 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { mapState } from 'vuex'
|
import { mapState } from 'vuex'
|
||||||
|
import qs from "query-string"
|
||||||
export default {
|
export default {
|
||||||
appName: '返乡登记',
|
appName: '返乡登记',
|
||||||
data() {
|
data() {
|
||||||
@@ -97,7 +97,12 @@ export default {
|
|||||||
showSelect: false
|
showSelect: false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
computed: { ...mapState(['user']) },
|
computed: {
|
||||||
|
...mapState(['user']),
|
||||||
|
params() {
|
||||||
|
return qs.parse(decodeURIComponent(location.search))
|
||||||
|
}
|
||||||
|
},
|
||||||
onShow() {
|
onShow() {
|
||||||
document.title = '返乡登记'
|
document.title = '返乡登记'
|
||||||
this.isGirdUser()
|
this.isGirdUser()
|
||||||
@@ -178,9 +183,37 @@ export default {
|
|||||||
this.show = false
|
this.show = false
|
||||||
},
|
},
|
||||||
open() {
|
open() {
|
||||||
console.log(123)
|
|
||||||
this.show = true
|
this.show = true
|
||||||
}
|
},
|
||||||
|
copy() {
|
||||||
|
let oInput = document.createElement('input')
|
||||||
|
oInput.value = this.params.linkUrl
|
||||||
|
document.body.appendChild(oInput)
|
||||||
|
oInput.select()
|
||||||
|
document.execCommand('Copy')
|
||||||
|
this.$u.toast('已复制')
|
||||||
|
oInput.remove()
|
||||||
|
},
|
||||||
|
share() {
|
||||||
|
this.injectJWeixin(['shareAppMessage', 'shareWechatMessage']).then(() => {
|
||||||
|
this.wxInvoke(['shareAppMessage', {
|
||||||
|
title: this.params.title,
|
||||||
|
desc: this.params.tableExplain,
|
||||||
|
link: this.params.linkUrl,
|
||||||
|
imgUrl: this.params.headPicture
|
||||||
|
}])
|
||||||
|
})
|
||||||
|
},
|
||||||
|
shareWechat() {
|
||||||
|
this.injectJWeixin(['shareAppMessage', 'shareWechatMessage']).then(() => {
|
||||||
|
this.wxInvoke(['shareWechatMessage', {
|
||||||
|
title: this.params.title,
|
||||||
|
desc: this.params.tableExplain,
|
||||||
|
link: this.params.linkUrl,
|
||||||
|
imgUrl: this.params.headPicture
|
||||||
|
}])
|
||||||
|
})
|
||||||
|
},
|
||||||
},
|
},
|
||||||
onReachBottom() {
|
onReachBottom() {
|
||||||
this.current ++
|
this.current ++
|
||||||
|
|||||||
Reference in New Issue
Block a user