Prechádzať zdrojové kódy

修改滚球赛事时间进程

彭俊 6 rokov pred
rodič
commit
3dfef2e780

+ 8 - 8
Application/Sports/Controller/MatchListWeb.php

@@ -260,20 +260,20 @@ where a.match_id = b.match_id and a.id = b.id ";
                     if($v['match_id'] == $vv->match_id){
                         //如果是网球结果
                         if($game_code == 'wq'){
-                            $matchNum[$k]['home_player_score'] = $vv->home_player_score;
-                            $matchNum[$k]['guest_player_score'] = $vv->guest_player_score;
+                            $matchNum[$k]['home_player_score'] = $vv->home_player_score?:0;
+                            $matchNum[$k]['guest_player_score'] = $vv->guest_player_score?:0;
                             $matchNum[$k]['result_mark'] = $vv->result_mark;
                         }else if($game_code == 'bq'){
-                            $matchNum[$k]['home_score'] = $vv->home_score;
-                            $matchNum[$k]['guest_score'] = $vv->guest_score;
+                            $matchNum[$k]['home_score'] = $vv->home_score?:0;
+                            $matchNum[$k]['guest_score'] = $vv->guest_score?:0;
                             $matchNum[$k]['result_mark'] = $vv->result_mark;
                         }
                         else{
-                            $matchNum[$k]['home_score'] = $vv->home_score;
-                            $matchNum[$k]['guest_score'] = $vv->guest_score;
+                            $matchNum[$k]['home_score'] = $vv->home_score?:0;
+                            $matchNum[$k]['guest_score'] = $vv->guest_score?:0;
                         }
-                        $matchNum[$k]['a_time'] = $vv->a_time;
-                        $matchNum[$k]['match_process'] = $vv->match_process;
+                        $matchNum[$k]['a_time'] = $vv->a_time?:0;
+                        $matchNum[$k]['match_process'] = $vv->match_process?:'';
                     }
                 }
             }