加入挑战

This commit is contained in:
marvzhang
2020-03-19 18:56:59 +08:00
parent e3a059eb7c
commit e33dfd7992
30 changed files with 504 additions and 21 deletions

View File

@@ -49,6 +49,7 @@
size="mini"
type="primary"
icon="el-icon-s-flag"
@click="onStartChallenge(c)"
>
{{$t('Start Challenge')}}
</el-button>
@@ -80,6 +81,13 @@ export default {
await this.$request.post('/challenges-check')
const res = await this.$request.get('/challenges')
this.challenges = res.data.data || []
},
onStartChallenge (c) {
if (c.path) {
this.$router.push(c.path)
} else {
this.$message.success(this.$t('You have started the challenge.'))
}
}
},
async created () {
@@ -96,8 +104,8 @@ export default {
}
.challenge-list .challenge-item {
flex-basis: 240px;
width: 240px;
flex-basis: 280px;
width: 280px;
margin: 10px;
}

View File

@@ -60,6 +60,11 @@ This Disclaimer and privacy protection statement (hereinafter referred to as "di
8. 传播:任何公司或个人在网络上发布,传播我们软件的行为都是允许的,但因公司或个人传播软件可能造成的任何法律和刑事事件 Crawlab 开发组不负任何责任。
`
}
},
mounted () {
this.$request.put('/actions', {
type: 'view_disclaimer'
})
}
}
</script>