diff --git a/src/pages/gzyd/index.vue b/src/pages/gzyd/index.vue index 910e981..91f148b 100644 --- a/src/pages/gzyd/index.vue +++ b/src/pages/gzyd/index.vue @@ -53,6 +53,12 @@ 立即领取 + + + {{ showmsg }} + + + @@ -86,6 +92,8 @@ const contentMsg = ref('') const statusCode = ref(0) const couponId = ref(uni.getStorageSync('couponId') || null) const url = ref('') +const show = ref(false) +const showmsg = ref('商品库存不足!') onLoad(() => { const { activity_code: code, token } = getUrlParams() @@ -167,6 +175,9 @@ const receiveFun = async () => { uni.setStorageSync('myPage', 'result') uni.setStorageSync('couponId', res.data.coupon_id) couponId.value = res.data.coupon_id + } else if (res.code === 2003) { + show.value = true + showmsg.value = res.message } else { uni.showToast({ title: res.message, @@ -245,6 +256,27 @@ page { margin: 0 50rpx 50rpx; overflow-y: auto; } + .notLogin { + position: relative; + width: 599rpx; + height: 543rpx; + background-image: url('@/assets/images/gzyd/notLogin.webp'); + background-size: 100% 100%; + } + .notLogin-txt { + position: absolute; + top: 278rpx; + left: 0; + width: 100%; + text-align: center; + } + .notLogin-btn { + position: absolute; + top: 421rpx; + left: 177rpx; + width: 246rpx; + height: 79rpx; + } .rules { position: fixed;