优化购买

This commit is contained in:
唐明明
2023-07-17 11:50:55 +08:00
parent ad19d17644
commit 6277a1c29f

View File

@@ -31,7 +31,7 @@
<rich-text :nodes="content"></rich-text>
<!-- 报名信息 -->
<view class="footer">
<view class="footer-btn" @click="onBuy">立即购买</view>
<view :class="['footer-btn', count.ing <= 0 ? 'in' : '']" @click="onBuy">立即购买</view>
</view>
</view>
</template>
@@ -72,6 +72,13 @@
},
methods: {
onBuy(){
if(this.count.ing <= 0){
uni.showToast({
title: '暂无可报名学期',
icon : 'none'
})
return
}
this.$Router.push({
name : 'EmpowerBuy',
params : { id: this.id }
@@ -131,5 +138,6 @@
background-color: white;
box-shadow: 0 0 10rpx 10rpx rgba(0, 0, 0, .04);
.footer-btn{ background: $mian-color; color: white; line-height: 100rpx; border-radius: 50rpx; flex: 1; text-align: center; font-weight: bold; font-size: 36rpx; }
.footer-btn.in{ opacity: .6; }
}
</style>