|
|
|
@ -1,16 +1,24 @@ |
|
|
|
|
<template> |
|
|
|
|
<!-- 赛事管理 --> |
|
|
|
|
<div> |
|
|
|
|
<el-card shadow="hover" class="m-b-20"> |
|
|
|
|
<el-card shadow="hover" |
|
|
|
|
class="m-b-20"> |
|
|
|
|
<div class="flex-between"> |
|
|
|
|
<el-page-header @back="back" :content="name + '/管理'"></el-page-header> |
|
|
|
|
<el-page-header @back="back" |
|
|
|
|
:content="name + '/管理'"></el-page-header> |
|
|
|
|
</div> |
|
|
|
|
</el-card> |
|
|
|
|
<div class="page" style="margin-bottom: 24px"> |
|
|
|
|
<div class="page" |
|
|
|
|
style="margin-bottom: 24px"> |
|
|
|
|
<div class="tabs"> |
|
|
|
|
<a class="item" v-for="(item,index) in tabs" :key="index" :class="{active: index == active}" @click="tabChange(index)">{{ item }}</a> |
|
|
|
|
<a class="item" |
|
|
|
|
v-for="(item,index) in tabs" |
|
|
|
|
:key="index" |
|
|
|
|
:class="{active: index == active}" |
|
|
|
|
@click="tabChange(index)">{{ item }}</a> |
|
|
|
|
</div> |
|
|
|
|
<MatchDetail v-if="active == 'tab1'" ref="detail" /> |
|
|
|
|
<MatchDetail v-if="active == 'tab1'" |
|
|
|
|
ref="detail" /> |
|
|
|
|
<MatchArch v-if="active == 'tab2'" /> |
|
|
|
|
<MatchProgress v-else-if="active == 'tab3'" /> |
|
|
|
|
<notice v-else-if="active == 'tab4'" /> |
|
|
|
@ -32,7 +40,7 @@ export default { |
|
|
|
|
data () { |
|
|
|
|
return { |
|
|
|
|
name: this.$route.query.name, |
|
|
|
|
active: this.$route.query.tab || "tab1", |
|
|
|
|
active: this.$route.query.tab || '', |
|
|
|
|
tabs: { |
|
|
|
|
tab1: "大赛详情", |
|
|
|
|
tab2: "大赛成绩管理", |
|
|
|
@ -69,7 +77,7 @@ export default { |
|
|
|
|
|
|
|
|
|
const type = this.$route.query.tab |
|
|
|
|
const keys = Object.keys(this.tabs) |
|
|
|
|
this.active = keys.includes(type) ? type : keys[0] |
|
|
|
|
if (keys.length) this.active = keys.includes(type) ? type : keys[0] |
|
|
|
|
}, |
|
|
|
|
back () { |
|
|
|
|
this.handleSave(0) && this.backPage() |
|
|
|
@ -123,5 +131,4 @@ export default { |
|
|
|
|
</script> |
|
|
|
|
|
|
|
|
|
<style scoped> |
|
|
|
|
|
|
|
|
|
</style> |