Commit a301ed28 authored by Facius's avatar Facius

improvement: 领取奖励之后提示

parent a0c7c728
;(function() { ;(function() {
let NODE_ENV = 'test' // dev:开发环境 | test:测试环境 | prod:生产环境 let NODE_ENV = 'prod' // dev:开发环境 | test:测试环境 | prod:生产环境
let ENV_VAR = null let ENV_VAR = null
let VERSION = 'v1.3.1' let VERSION = 'v1.3.1'
if (process.env.NODE_ENV === 'development') { if (process.env.NODE_ENV === 'development') {
......
...@@ -36,6 +36,9 @@ ...@@ -36,6 +36,9 @@
领取10天体验卡 领取10天体验卡
</u-button> </u-button>
</view> </view>
<view>
<u-toast ref="uToast" />
</view>
</view> </view>
</template> </template>
...@@ -119,10 +122,17 @@ export default { ...@@ -119,10 +122,17 @@ export default {
.then((res) => { .then((res) => {
// this.loading = false // this.loading = false
// 切换题库 // 切换题库
this.setPageInfo(this.selectedData) this.$refs.uToast.show({
this.$u.vuex('searchHistory', []) title: '您已领取奖励,获得题库10天体验卡',
this.$u.route({ type: 'success',
type: 'back', duration: 1500,
callback: () => {
this.setPageInfo(this.selectedData)
this.$u.vuex('searchHistory', [])
this.$u.route({
type: 'back',
})
},
}) })
}) })
.catch((err) => { .catch((err) => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment