| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134 |
- <template>
- <div class="BallDisc column">
- <div class="row allAlignment center box" style="background:#a0a0a0;" @click="jumpBallDisc">
- <span class="row center" style="font-size:.3rem;color:#fff; font-weight: bold;">{{titel}}</span>
- <div>
- <span class="mark row center">{{idx}}</span>
- <img src="../assets/st-imges/minRightArrow.png" alt>
- </div>
- </div>
- <div style=" padding: 0 0.3rem;">
- <BasketballBlock :type="st.type1"></BasketballBlock>
- <BasketballBlock :type="st.type2"></BasketballBlock>
- <BasketballBlock :type="st.type3"></BasketballBlock>
- <Tennis></Tennis>
- </div>
- <div v-if="noData">
- <NotOpend :title="this.info"/>
- </div>
- <!-- <Loading/> -->
- </div>
- </template>
- <script>
- import "@/css/index.css";
- import BasketballBlock from "@/components/StBasketballBlock";
- import Loading from "@/components/StLoading";
- import Tennis from "@/components/StTennis";
- import NotOpend from "@/components/StNotOpend";
- import Bus from '@/assets/bus.js';
- export default {
- name: "BallDisc",
- data() {
- return {
- data: "",
- titel: "滚球盘",
- // index: 0,
- // 区分接口
- st: {
- type1: 1,
- type2: 2,
- type3: 3
- },
- noData: false,
- info: "暂无相关滚球赛事",
- zqCondition: false,
- bqCondition: false,
- wqCondition: false,
- lqCondition: false,
- idx : '',
- timers : true // 定时器开关
- };
- },
- methods: {
- jumpBallDisc: function() {
- this.$store.dispatch("GETACTIVITY", 'StRollBall')
- this.$router.push({
- path: "/StRollBallpage",
- query: { number: 0, home: true, hmsts: 1 }
- });
- },
- getAjax(){
- if(this.idx == 0){
- this.noData = true;
- }else{
- this.noData = false;
- }
- }
- },
- components: {
- BasketballBlock,
- Tennis,
- Loading,
- NotOpend
- },
- mounted() {
- if (this.$store.getters.getHeadTitle) {
- let title = this.$store.getters.getHeadTitle;
- this.idx = title[0][0].matchNum
- }
-
- //获取条数。。
- this.getAjax();
- let _this = this;
- this.$public.ajaxTimerFun(function(timing){
- if (_this.timers){
- _this.getAjax();
- }else{
- clearInterval(timing);
- }
- })
- },
- computed: {
- getHeadTit(){
- return this.$store.getters.getHeadTitle
- }
- },
- watch: {
- getHeadTit(val){
- this.idx = val[0][0].matchNum
- }
- },
- beforeDestroy(){
- this.timers = false;
- }
- };
- </script>
- <style scoped>
- .box {
- width: 100%;
- padding: 0.28rem 0;
- background: #f8f8f8;
- padding: 0 0.3rem;
- height: 0.88rem;
- }
- .BallDisc {
- font-size: 0.32rem;
- background: #f8f8f8;
- color: #000000;
- margin-bottom: 0.12rem;
- }
- div /deep/ .tennis .ballBtn {
- border-bottom: none;
- }
- .mark {
- position: absolute;
- right: 0.8rem;
- width: 0.4rem;
- height: 0.4rem;
- border-radius: 50%;
- background: #f76649;
- color: floralwhite;
- font-size: 0.2rem;
- }
- </style>
|