소스 검색

异常处理

彭俊 6 년 전
부모
커밋
946a131291
2개의 변경된 파일6개의 추가작업 그리고 4개의 파일을 삭제
  1. 3 2
      Application/Api/Model/MoneyBuy.php
  2. 3 2
      Application/Commons/Model/Money_buy_match.php

+ 3 - 2
Application/Api/Model/MoneyBuy.php

@@ -360,10 +360,11 @@ class MoneyBuy extends Model {
             $moneyBuyMthOr[0][$key][0] = 'batch_id';
             $moneyBuyMthOr[0][$key][1] = $value['batch_id'];
         }
-        $moneyBuyMthWhere['bet_type'] = 2;
+      
         // 获取注单
+        $moneyBuyMthWhere['bet_type'] = 2;
         $moneyBuyMthMdl = lm('Money_buy_match', "commons");
-        $moneyBuyMthSlt = ['status', 'matchResult', 'bet_money', 'home_team', 'guest_team', 'condition', 'odds', 'odds_name', 'match_id', 'batch_id', 'money_buy_match.game_code', 'money_buy_match.odds_code'];
+        $moneyBuyMthSlt = ['status', 'matchresult', 'bet_money', 'home_team', 'guest_team', 'condition', 'odds', 'odds_name', 'match_id', 'batch_id', 'money_buy_match.game_code', 'money_buy_match.odds_code'];
         $getMoneyBuyMth = $moneyBuyMthMdl -> moneyBuyMatch($moneyBuyMthSlt, $moneyBuyMthWhere, $moneyBuyMthOr, $begin, $pageSize);
         // 获取所有的比赛类型
         $stGameTypeMdl = lm('StGameType', "commons");

+ 3 - 2
Application/Commons/Model/Money_buy_match.php

@@ -25,13 +25,13 @@ class Money_buy_match extends Model {
      * @param mixed $orderBy 排序字段
      * @return array JsonString
      */
+   
     public function moneyBuyMatch($select, $where = '', $orWhere = '', $begin = '', $pageSize = '', $orderBy = ['batch_id' => 'desc']) {
         // 查询字段
         $result = $this -> select($select)
         ->join('st_odds_code', function ($join) {
             $join->on('money_buy_match.odds_code', '=','st_odds_code.odds_code')->on('money_buy_match.game_code', '=','st_odds_code.game_code');
         });
-
         // 查询条件
         if (!empty($where)) {
             $result = $result -> where($where);
@@ -51,6 +51,7 @@ class Money_buy_match extends Model {
                 });
             }
         }
+
         // 查询起始
         if (strlen($begin)) {
             $result = $result -> offset($begin);
@@ -64,9 +65,9 @@ class Money_buy_match extends Model {
         foreach ($orderBy as $key => $value) {
             $result = $result -> orderBy($key, $value);
         }
+
         // 获取数据
         $result = $result -> get();
-
         return $result;
     }