|
@@ -4,7 +4,9 @@
|
|
|
<view class="buy">
|
|
|
<button type="buy" circle @click="getSubmit">立即购买</button>
|
|
|
<span>
|
|
|
- <radio :checked="checked" />
|
|
|
+ <radio-group @change="getChange">
|
|
|
+ <radio :value="value" />
|
|
|
+ </radio-group>
|
|
|
<text>购买即视为同意</text>
|
|
|
<navigator url="/pages/imusic/agreement">《场景歌单付费协议》</navigator>
|
|
|
<navigator url="/pages/imusic/service">《音乐服务许可协议》</navigator>
|
|
@@ -20,12 +22,14 @@ export default {
|
|
|
return {
|
|
|
form: {},
|
|
|
// 是否同意
|
|
|
- checked: false
|
|
|
+ value: '0',
|
|
|
+ id: ''
|
|
|
}
|
|
|
},
|
|
|
onLoad(e) {
|
|
|
if (e.id) {
|
|
|
this.getDetail(e.id)
|
|
|
+ this.id = e.id
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
@@ -37,13 +41,18 @@ export default {
|
|
|
})
|
|
|
},
|
|
|
|
|
|
+ getChange() {
|
|
|
+ this.value = '1'
|
|
|
+ },
|
|
|
+
|
|
|
// 立即购买
|
|
|
getSubmit() {
|
|
|
- if (this.checked) {
|
|
|
-
|
|
|
+ if (this.value === '1') {
|
|
|
+ clickPay.postMessage('调取原生支付')
|
|
|
} else {
|
|
|
uni.showToast({
|
|
|
- title: ''
|
|
|
+ title: '文案待定',
|
|
|
+ icon: 'none'
|
|
|
})
|
|
|
}
|
|
|
}
|
|
@@ -102,7 +111,7 @@ span {
|
|
|
width: 100%;
|
|
|
text-align: center;
|
|
|
font-size: 24rpx;
|
|
|
- color: #bdbcbb;
|
|
|
+ color: #d5d5d5;
|
|
|
}
|
|
|
|
|
|
::v-deep uni-radio .uni-radio-input {
|