<template>
    <div :class="noroll?'noroll':''">
        <!-- 加载组件 -->
        <div class = "lod">
          <Loading></Loading>
        </div>
        <!-- 头部组件 -->
        <SportsHead></SportsHead>
        <!-- 亚洲冠军杯组件 -->
        <championsCup v-if="isShow ==1" />
        <!-- 首页球类赛事组件 -->
        <Serch v-else-if="isShow == 2"></Serch>
        <!-- <LinkFooter></LinkFooter> -->
    </div>
</template>
<script>
import  SportsHead from '@/components/StSportsHead';
import  Serch from '@/components/StSerch';
import  LinkFooter from '@/components/StLinkFooter';
import  Schedule from '@/components/StSchedule';
import  Loading from '@/components/StLoading';
import  championsCup from '@/components/StChampionsCup';
export default {
    name:"AllMatch",
    components:{
        SportsHead,
        Serch,
        LinkFooter,
        Schedule,
        Loading,
        championsCup
    },
    data(){
        return{
            isShow:100, // 断定是否为冠军跳入
            // ballId:this.$route.query.id
            noroll:false,
        }

    },
    computed:{
        noRoll(){
            return this.$store.getters.getNoRoll
        }
    },
    watch:{
        noRoll(val){
            this.noroll=val
        }
    },
    mounted(){
        if(this.$route.query.id == 'gj'){
            this.isShow = 1;
        }else{
            this.isShow = 2;
        }
    }
    // created(){
    //     this.getId();
    // },
    // methods:{
    //     getId:function(){
    //         console.log(this.$store.getters.getGameRatio);
    //     }
    // }
    //    this.$store.dispatch('GETSHOW',true);
}
</script>
<style  scoped>
/* .noroll{
    position: fixed;
     width: 100%;
    top: 0;
    left: 0;
} */
    .lod{
        z-index: 999;
        position: fixed;
        width: 100%;
    }
</style>
