Feat(抽奖):增加分享
This commit is contained in:
@@ -28,4 +28,11 @@ export function takePrize(lotteryRecordId){
|
||||
* */
|
||||
export function getLogs(page = 1, limit = 10) {
|
||||
return request.get('/lottery/dice/records',{page,limit})
|
||||
}
|
||||
|
||||
/**
|
||||
* 抽奖活动分享
|
||||
* */
|
||||
export function getLotteryShareInfo() {
|
||||
return request.get('/lottery/shareImage')
|
||||
}
|
||||
@@ -80,7 +80,7 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { getDetail, getPrize, takePrize } from '@/api/lottery'
|
||||
import { getDetail, getPrize, takePrize, getLotteryShareInfo } from '@/api/lottery'
|
||||
import gbroMarquee from '../components/gbro-marquee/marquee.vue'
|
||||
|
||||
export default {
|
||||
@@ -113,7 +113,8 @@ export default {
|
||||
text_color: "#333", //字体颜色
|
||||
back_color: "red", //背景色
|
||||
},
|
||||
imgData: []
|
||||
imgData: [],
|
||||
shareAppImg: ''
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
@@ -126,6 +127,13 @@ export default {
|
||||
onLoad() {
|
||||
this.init()
|
||||
},
|
||||
onShareAppMessage() {
|
||||
return {
|
||||
title: '探寻有趣有味的生活方式',
|
||||
path: '/pkg-video/views/lottery',
|
||||
imageUrl: this.shareAppImg
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
init() {
|
||||
getDetail().then(res => {
|
||||
@@ -138,6 +146,9 @@ export default {
|
||||
},1000)
|
||||
}
|
||||
})
|
||||
getLotteryShareInfo().then(res => {
|
||||
this.shareAppImg = res.data || ''
|
||||
})
|
||||
},
|
||||
|
||||
onSubmit() {
|
||||
|
||||
Reference in New Issue
Block a user