Browse Source

追加推送 5/28

彭俊 6 years ago
parent
commit
8dac20b914

+ 1 - 1
app/Http/Controllers/Admin/SoccerNoteListController.php

@@ -44,7 +44,7 @@ class SoccerNoteListController extends Controller
         $dt->addColsFields('prize_money', array('templet' => '#userdetail', 'sort' => false, 'width' => 80));
         $dt->addColsFields('result', array('templet' => '#userdetail', 'sort' => false, 'width' => 80));
         $dt->addColsFields('money_match_time', array('templet' => '#userdetail', 'sort' => false, 'width' => 200));
-        $dt->addColsFields('account', array('templet' => '#userdetail', 'sort' => false, 'width' => 120));
+        $dt->addColsFields('account_money', array('templet' => '#userdetail', 'sort' => false, 'width' => 120));
         $dt->addColsFields('game_status', array('sort' => false, 'width' => 90));
         //$arr[] = 'view';
 //        if (checkRriv('/admin/SoccerNoteList/edit')) {

+ 2 - 2
app/Http/Controllers/Admin/SoccerStringNoteListController.php

@@ -34,14 +34,14 @@ class SoccerStringNoteListController extends Controller
         $dt->setLang('sportsnotelist');
         //$dt->addColsFields('id', array('templet' => '#userdetail', 'sort' => true, 'width' => 80));
         $dt->addColsFields('order_id', array('templet' => '#userdetail', 'sort' => true, 'width' => 200));
-        $dt->addColsFields('str_type', array('templet' => '#userdetail', 'sort' => false, 'width' => 70));
+        $dt->addColsFields('str_type', array('templet' => '#userdetail', 'sort' => false, 'width' => 120));
         $dt->addColsFields('detail_content', array('sort' => false, 'width' => 150));
         $dt->addColsFields('money', array('templet' => '#userdetail', 'sort' => false, 'width' => 90));
         $dt->addColsFields('water_return', array('templet' => '#userdetail', 'sort' => false, 'width' => 90));
         $dt->addColsFields('prize_money', array('templet' => '#userdetail', 'sort' => false, 'width' => 90));
         $dt->addColsFields('result', array('templet' => '#userdetail', 'sort' => false, 'width' => 90));
         $dt->addColsFields('money_time', array('templet' => '#userdetail', 'sort' => false, 'width' => 200));
-        $dt->addColsFields('account', array('templet' => '#userdetail', 'sort' => false, 'width' => 240));
+        $dt->addColsFields('account_money', array('templet' => '#userdetail', 'sort' => false, 'width' => 240));
         $dt->addColsFields('settle_status', array('sort' => false, 'width' => 100));
 //        if (checkRriv('/admin/SoccerStringNoteList/edit')) {
 //            $arr[] ='edit';

+ 3 - 3
app/Http/Controllers/Admin/SportsBaseController.php

@@ -36,13 +36,13 @@ class SportsBaseController extends Controller {
         $dt->setLang('sportsbase');
         $dt->addColsFields('match_id', array('templet' => '#userdetail', 'sort' => true, 'width' => 100));
         $dt->addColsFields('lg_id', array('templet' => '#userdetail', 'sort' => true, 'width' => 80));
-        $dt->addColsFields('name_chinese', array('templet' => '#userdetail', 'sort' => false, 'width' => 200));
-        $dt->addColsFields('home_guest', array('templet' => '#userdetail', 'sort' => false, 'width' => 260));
+        $dt->addColsFields('name_chinese', array('templet' => '#userdetail', 'sort' => false, 'width' => 180));
+        $dt->addColsFields('home_guest', array('templet' => '#userdetail', 'sort' => false, 'width' => 220));
         $dt->addColsFields('match_date', array('templet' => '#userdetail', 'sort' => true, 'width' => 130));
         $dt->addColsFields('match_time', array('templet' => '#userdetail', 'sort' => true, 'width' => 130));
         $dt->addColsFields('recommend', array('templet' => '#recommend', 'sort' => false, 'width' => 120,'align' => 'center'));
         $dt->addColsFields('status', array('templet' => '#userdetail', 'sort' => false, 'width' => 100));
-        $dt->addColsFields('result', array( 'sort' => false, 'width' => 100));
+        //$dt->addColsFields('result', array( 'sort' => false, 'width' => 100));
         if (checkRriv('/admin/SportsBase/edit')) {
             $arr[] = 'edit';
         }

+ 3 - 3
app/Http/Controllers/Admin/SportsBasketController.php

@@ -36,13 +36,13 @@ class SportsBasketController extends Controller {
 		$dt->setLang('sportsbase');
 		$dt->addColsFields('match_id', array('templet' => '#userdetail', 'sort' => true, 'width' => 100));
 		$dt->addColsFields('lg_id', array('templet' => '#userdetail', 'sort' => true, 'width' => 80));
-		$dt->addColsFields('name_chinese', array('templet' => '#userdetail', 'sort' => false, 'width' => 200));
-		$dt->addColsFields('home_guest', array('templet' => '#userdetail', 'sort' => false, 'width' => 260));
+		$dt->addColsFields('name_chinese', array('templet' => '#userdetail', 'sort' => false, 'width' => 180));
+		$dt->addColsFields('home_guest', array('templet' => '#userdetail', 'sort' => false, 'width' => 220));
 		$dt->addColsFields('match_date', array('templet' => '#userdetail', 'sort' => true, 'width' => 130));
 		$dt->addColsFields('match_time', array('templet' => '#userdetail', 'sort' => true, 'width' => 130));
 		$dt->addColsFields('recommend', array('templet' => '#recommend', 'sort' => false, 'width' => 120,'align' => 'center'));
 		$dt->addColsFields('status', array('templet' => '#userdetail', 'sort' => false, 'width' => 100));
-		$dt->addColsFields('result', array( 'sort' => false, 'width' => 100));
+		//$dt->addColsFields('result', array( 'sort' => false, 'width' => 100));
 		//$arr[] = 'view';
 		if (checkRriv('/admin/SportsBasket/edit')) {
 			$arr[] = 'edit';

+ 3 - 3
app/Http/Controllers/Admin/SportsSoccerController.php

@@ -37,13 +37,13 @@ class SportsSoccerController extends Controller {
         $dt->setLang('sportsbase');
         $dt->addColsFields('match_id', array('templet' => '#userdetail', 'sort' => true, 'width' => 100));
         $dt->addColsFields('lg_id', array('templet' => '#userdetail', 'sort' => true, 'width' => 80));
-        $dt->addColsFields('name_chinese', array('templet' => '#userdetail', 'sort' => false, 'width' => 200));
-        $dt->addColsFields('home_guest', array('templet' => '#userdetail', 'sort' => false, 'width' => 260));
+        $dt->addColsFields('name_chinese', array('templet' => '#userdetail', 'sort' => false, 'width' => 180));
+        $dt->addColsFields('home_guest', array('templet' => '#userdetail', 'sort' => false, 'width' => 220));
         $dt->addColsFields('match_date', array('templet' => '#userdetail', 'sort' => true, 'width' => 130));
         $dt->addColsFields('match_time', array('templet' => '#userdetail', 'sort' => true, 'width' => 130));
         $dt->addColsFields('recommend', array('templet' => '#recommend', 'sort' => false, 'width' => 120,'align' => 'center'));
         $dt->addColsFields('status', array('templet' => '#userdetail', 'sort' => false, 'width' => 100));
-        $dt->addColsFields('result', array( 'sort' => false, 'width' => 100));
+        //$dt->addColsFields('result', array( 'sort' => false, 'width' => 100));
         if (checkRriv('/admin/SportsSoccer/edit')) {
             $arr[] = 'edit';
         }

+ 3 - 3
app/Http/Controllers/Admin/SportsTennisController.php

@@ -36,13 +36,13 @@ class SportsTennisController extends Controller {
         $dt->setLang('sportstennis');
         $dt->addColsFields('match_id', array('templet' => '#userdetail', 'sort' => true, 'width' => 100));
         $dt->addColsFields('lg_id', array('templet' => '#userdetail', 'sort' => true, 'width' => 80));
-        $dt->addColsFields('name_chinese', array('templet' => '#userdetail', 'sort' => false, 'width' => 200));
-        $dt->addColsFields('home_guest', array('templet' => '#userdetail', 'sort' => false, 'width' => 260));
+        $dt->addColsFields('name_chinese', array('templet' => '#userdetail', 'sort' => false, 'width' => 180));
+        $dt->addColsFields('home_guest', array('templet' => '#userdetail', 'sort' => false, 'width' => 220));
         $dt->addColsFields('match_date', array('templet' => '#userdetail', 'sort' => true, 'width' => 130));
         $dt->addColsFields('match_time', array('templet' => '#userdetail', 'sort' => true, 'width' => 130));
         $dt->addColsFields('recommend', array('templet' => '#recommend', 'sort' => false, 'width' => 120,'align' => 'center'));
         $dt->addColsFields('status', array('templet' => '#userdetail', 'sort' => false, 'width' => 100));
-        $dt->addColsFields('result', array( 'sort' => false, 'width' => 100));
+        //$dt->addColsFields('result', array( 'sort' => false, 'width' => 100));
         //$arr[] = 'view';
         if (checkRriv('/admin/SportsTennis/edit')) {
             $arr[] = 'edit';

+ 6 - 6
app/Http/Controllers/Admin/SportsbkController.php

@@ -21,12 +21,12 @@ class SportsbkController extends Controller {
 		$dt = \App\Lib\DataTable\DataTable::init();
 		$dt->setDataSource('/admin/Sportsbk/info');
 		$dt->setLang('sportsbk');
-		$dt->addColsFields('id', array('templet' => '#userdetail', 'sort' => true, 'width' => 80));
-		$dt->addColsFields('name_chinese', array('templet' => '#userdetail', 'sort' => true, 'width' => 80));
-		$dt->addColsFields('home_guest_team', array('templet' => '#userdetail', 'sort' => false, 'width' => 120));
-		$dt->addColsFields('u_home_guest_score', array('templet' => '#userdetail', 'sort' => false, 'width' => 130));
-		$dt->addColsFields('match_score', array('templet' => '#userdetail', 'sort' => true, 'width' => 80));
-		$dt->addColsFields('match_winer', array('templet' => '#userdetail', 'sort' => true, 'width' => 80));
+		$dt->addColsFields('lg_id', array('templet' => '#liansai', 'sort' => true, 'width' => 80));
+		$dt->addColsFields('match_time', array('templet' => '#totime', 'sort' => true, 'width' => 80));
+		$dt->addColsFields('home_team', array('templet' => '#userdetail', 'sort' => false, 'width' => 120));
+		$dt->addColsFields('guest_team', array('templet' => '#userdetail', 'sort' => false, 'width' => 130));
+		$dt->addColsFields('dsnum', array('templet' => '#userdetail', 'sort' => true, 'width' => 80));
+		$dt->addColsFields('csnum', array('templet' => '#userdetail', 'sort' => true, 'width' => 80));
 		$dt->addColsFields('match_time', array('templet' => '#userdetail', 'sort' => true, 'width' => 100));
 		$dt->addColsFields('match_process', array('templet' => '#userdetail', 'sort' => false, 'width' => 150));
 		$dt->addColsFields('status', array('templet' => '#userdetail', 'sort' => false, 'width' => 150));

+ 41 - 33
app/Lib/Settlement/Adapter/BqRule.php

@@ -190,26 +190,28 @@ class BqRule
         if ($size == -1) {
             if ($count == 1) {
                 if ($resultUniqueArr[0] == 1) {
-                    return -1;
+                    $data['result'] = -1;
                 } elseif ($resultUniqueArr[0] == 2) {
-                    return 2;
+                    $data['result'] = 2;
                 } else {
-                    return 1;
+                    $data['result'] = 1;
                 }
             } elseif (in_array(1, $resultUniqueArr)) {
-                return 4;
+                $data['result'] = 4;
             } else {
-                return 3;
+                $data['result'] = 3;
             }
         } else {
             if ($count == 1) {
-                return $resultUniqueArr[0];
+                $data['result'] = $resultUniqueArr[0];
             } elseif (in_array(1, $resultUniqueArr)) {
-                return 3;
+                $data['result'] = 3;
             } else {
-                return 4;
+                $data['result'] = 4;
             }
         }
+        $data['matchResult'] = "$homeScore-$guestScore(全场)";
+        return $data;
     }
 
     /**
@@ -267,26 +269,28 @@ class BqRule
         if ($size == -1) {
             if ($count == 1) {
                 if ($resultUniqueArr[0] == 1) {
-                    return -1;
+                    $data['result'] = -1;
                 } elseif ($resultUniqueArr[0] == 2) {
-                    return 2;
+                    $data['result'] = 2;
                 } else {
-                    return 1;
+                    $data['result'] = 1;
                 }
             } elseif (in_array(1, $resultUniqueArr)) {
-                return 4;
+                $data['result'] = 4;
             } else {
-                return 3;
+                $data['result'] = 3;
             }
         } else {
             if ($count == 1) {
-                return $resultUniqueArr[0];
+                $data['result'] = $resultUniqueArr[0];
             } elseif (in_array(1, $resultUniqueArr)) {
-                return 3;
+                $data['result'] = 3;
             } else {
-                return 4;
+                $data['result'] = 4;
             }
         }
+        $data['matchResult'] = "$homeScore-$guestScore(前五局)";
+        return $data;
     }
 
     /**
@@ -306,12 +310,14 @@ class BqRule
         $guestScore = intval($resultModel -> guest_score);
         $difference = $homeScore - $guestScore;
         if ($difference > 0 && $type == 1) {
-            return 1;
+            $data['result'] = 1;
         } elseif ($difference < 0 && $type == 2) {
-            return 1;
+            $data['result'] = 1;
         } else {
-            return -1;
+            $data['result'] = -1;
         }
+        $data['matchResult'] = "$homeScore-$guestScore(全场)";
+        return $data;
     }
 
     /**
@@ -338,14 +344,14 @@ class BqRule
             $resultScore = $condition - $allGoal;
         }
         if ($resultScore > 0) {
-            $result = 1;
+            $data['result'] = 1;
         } elseif ($resultScore < 0) {
-            $result = -1;
+            $data['result'] = 1;
         } else {
-            $result = 2;
+            $data['result'] = 2;
         }
-
-        return $result;
+        $data['matchResult'] = "$homeScore+$guestScore(全场)";
+        return $data;
     }
 
     /**
@@ -377,14 +383,14 @@ class BqRule
             $resultScore = $condition - $allGoal;
         }
         if ($resultScore > 0) {
-            $result = 1;
+            $data['result'] = 1;
         } elseif ($resultScore < 0) {
-            $result = -1;
+            $data['result'] = -1;
         } else {
-            $result = 2;
+            $data['result'] = 2;
         }
-
-        return $result;
+        $data['matchResult'] = "$homeScore+$guestScore(前五局)";
+        return $data;
     }
 
     /**
@@ -408,18 +414,20 @@ class BqRule
         $condition = intval($model -> condition);
         if($type == 1 && $condition == '单'){
             if($allGoal%2 != 0){
-                return 1;
+                $data['result'] = 1;
             }else{
-                return -1;
+                $data['result'] = -1;
             }
         }
         if($type = 2 && $condition = '双'){
             if($allGoal%2 == 0){
-                return 1;
+                $data['result'] = 1;
             }else{
-                return -1;
+                $data['result'] = -1;
             }
         }
+        $data['matchResult'] = "$allGoal(全场)";
+        return $data;
     }
 
 }

+ 36 - 36
app/Lib/Settlement/Adapter/LqRule.php

@@ -67,7 +67,7 @@ class LqRule
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_concede_home($model, $resultModel, $resultRecords){
+    public function concede_home($model, $resultModel, $resultRecords){
         // 主队得分
         $homeScore = intval($resultModel -> home_score);
         // 客队得分
@@ -87,7 +87,7 @@ class LqRule
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_concede_guest($model, $resultModel, $resultRecords){
+    public function concede_guest($model, $resultModel, $resultRecords){
         // 主队得分
         $homeScore = intval($resultModel -> home_score);
         // 客队得分
@@ -107,7 +107,7 @@ class LqRule
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_half_concede_home($model, $resultModel, $resultRecords){
+    public function half_concede_home($model, $resultModel, $resultRecords){
         $newResultRecords = array_reverse($resultRecords);
         $upResultKey = array_search('第二节', array_column($newResultRecords, 'match_process'));
         // 主队得分
@@ -129,7 +129,7 @@ class LqRule
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_half_concede_guest($model, $resultModel, $resultRecords){
+    public function half_concede_guest($model, $resultModel, $resultRecords){
         $newResultRecords = array_reverse($resultRecords);
         $upResultKey = array_search('第二节', array_column($newResultRecords, 'match_process'));
         // 主队得分
@@ -151,7 +151,7 @@ class LqRule
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_one_concede_home($model, $resultModel, $resultRecords){
+    public function one_concede_home($model, $resultModel, $resultRecords){
         $newResultRecords = array_reverse($resultRecords);
         $oneResultKey = array_search('第一节', array_column($newResultRecords, 'match_process'));
         // 主队得分
@@ -173,7 +173,7 @@ class LqRule
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_one_concede_guest($model, $resultModel, $resultRecords){
+    public function one_concede_guest($model, $resultModel, $resultRecords){
         $newResultRecords = array_reverse($resultRecords);
         $oneResultKey = array_search('第一节', array_column($newResultRecords, 'match_process'));
         // 主队得分
@@ -195,7 +195,7 @@ class LqRule
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_two_concede_home($model, $resultModel, $resultRecords){
+    public function two_concede_home($model, $resultModel, $resultRecords){
         $newResultRecords = array_reverse($resultRecords);
         $oneResultKey = array_search('第一节', array_column($newResultRecords, 'match_process'));
         $twoResultKey = array_search('第二节', array_column($newResultRecords, 'match_process'));
@@ -218,7 +218,7 @@ class LqRule
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_two_concede_guest($model, $resultModel, $resultRecords){
+    public function two_concede_guest($model, $resultModel, $resultRecords){
         $newResultRecords = array_reverse($resultRecords);
         $oneResultKey = array_search('第一节', array_column($newResultRecords, 'match_process'));
         $twoResultKey = array_search('第二节', array_column($newResultRecords, 'match_process'));
@@ -241,7 +241,7 @@ class LqRule
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_three_concede_home($model, $resultModel, $resultRecords){
+    public function three_concede_home($model, $resultModel, $resultRecords){
         $newResultRecords = array_reverse($resultRecords);
         $twoResultKey = array_search('第二节', array_column($newResultRecords, 'match_process'));
         $threeResultKey = array_search('第三节', array_column($newResultRecords, 'match_process'));
@@ -264,7 +264,7 @@ class LqRule
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_three_concede_guest($model, $resultModel, $resultRecords){
+    public function three_concede_guest($model, $resultModel, $resultRecords){
         $newResultRecords = array_reverse($resultRecords);
         $twoResultKey = array_search('第二节', array_column($newResultRecords, 'match_process'));
         $threeResultKey = array_search('第三节', array_column($newResultRecords, 'match_process'));
@@ -287,7 +287,7 @@ class LqRule
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_four_concede_home($model, $resultModel, $resultRecords){
+    public function four_concede_home($model, $resultModel, $resultRecords){
         $newResultRecords = array_reverse($resultRecords);
         $threeResultKey = array_search('第三节', array_column($newResultRecords, 'match_process'));
         $fourResultKey = array_search('第四节', array_column($newResultRecords, 'match_process'));
@@ -310,7 +310,7 @@ class LqRule
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_four_concede_guest($model, $resultModel, $resultRecords){
+    public function four_concede_guest($model, $resultModel, $resultRecords){
         $newResultRecords = array_reverse($resultRecords);
         $threeResultKey = array_search('第三节', array_column($newResultRecords, 'match_process'));
         $fourResultKey = array_search('第四节', array_column($newResultRecords, 'match_process'));
@@ -327,13 +327,13 @@ class LqRule
     }
 
     /**
-     * 总进球|全场|
+     * 全场总分
      * @param mixed $model 注单表数据
      * @param mixed $resultModel 结果表数据
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_total_sizes_big($model, $resultModel, $resultRecords){
+    public function total_number_big($model, $resultModel, $resultRecords){
         // 主队得分
         $homeScore = intval($resultModel -> home_score);
         // 客队得分
@@ -346,13 +346,13 @@ class LqRule
     }
 
     /**
-     * 总进球|全场|
+     * 全场总分
      * @param mixed $model 注单表数据
      * @param mixed $resultModel 结果表数据
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_total_sizes_small($model, $resultModel, $resultRecords){
+    public function total_number_small($model, $resultModel, $resultRecords){
         // 主队得分
         $homeScore = intval($resultModel -> home_score);
         // 客队得分
@@ -365,13 +365,13 @@ class LqRule
     }
 
     /**
-     * 总进球|上半场|
+     * 上半场总分
      * @param mixed $model 注单表数据
      * @param mixed $resultModel 结果表数据
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_half_total_sizes_big($model, $resultModel, $resultRecords){
+    public function half_total_sizes_big($model, $resultModel, $resultRecords){
         $newResultRecords = array_reverse($resultRecords);
         $upResultKey = array_search('第二节', array_column($newResultRecords, 'match_process'));
         // 主队得分
@@ -386,13 +386,13 @@ class LqRule
     }
 
     /**
-     * 总进球|上半场|
+     * 上半场总分
      * @param mixed $model 注单表数据
      * @param mixed $resultModel 结果表数据
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_half_total_sizes_small($model, $resultModel, $resultRecords){
+    public function half_total_sizes_small($model, $resultModel, $resultRecords){
         $newResultRecords = array_reverse($resultRecords);
         $upResultKey = array_search('第二节', array_column($newResultRecords, 'match_process'));
         // 主队得分
@@ -407,13 +407,13 @@ class LqRule
     }
 
     /**
-     * 总进球|第一节|
+     * 第一节总分
      * @param mixed $model 注单表数据
      * @param mixed $resultModel 结果表数据
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_one_total_sizes_big($model, $resultModel, $resultRecords){
+    public function one_total_sizes_big($model, $resultModel, $resultRecords){
         $newResultRecords = array_reverse($resultRecords);
         $oneResultKey = array_search('第一节', array_column($newResultRecords, 'match_process'));
         // 主队得分
@@ -428,13 +428,13 @@ class LqRule
     }
 
     /**
-     * 总进球|第一节|
+     * 第一节总分
      * @param mixed $model 注单表数据
      * @param mixed $resultModel 结果表数据
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_one_total_sizes_small($model, $resultModel, $resultRecords){
+    public function one_total_sizes_small($model, $resultModel, $resultRecords){
         $newResultRecords = array_reverse($resultRecords);
         $oneResultKey = array_search('第一节', array_column($newResultRecords, 'match_process'));
         // 主队得分
@@ -449,13 +449,13 @@ class LqRule
     }
 
     /**
-     * 总进球|第二节|
+     * 第二节总分
      * @param mixed $model 注单表数据
      * @param mixed $resultModel 结果表数据
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_two_total_sizes_big($model, $resultModel, $resultRecords){
+    public function two_total_sizes_big($model, $resultModel, $resultRecords){
         $newResultRecords = array_reverse($resultRecords);
         $oneResultKey = array_search('第一节', array_column($newResultRecords, 'match_process'));
         $twoResultKey = array_search('第二节', array_column($newResultRecords, 'match_process'));
@@ -471,13 +471,13 @@ class LqRule
     }
 
     /**
-     * 总进球|第二节|
+     * 第二节总分
      * @param mixed $model 注单表数据
      * @param mixed $resultModel 结果表数据
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_two_total_sizes_small($model, $resultModel, $resultRecords){
+    public function two_total_sizes_small($model, $resultModel, $resultRecords){
         $newResultRecords = array_reverse($resultRecords);
         $oneResultKey = array_search('第一节', array_column($newResultRecords, 'match_process'));
         $twoResultKey = array_search('第二节', array_column($newResultRecords, 'match_process'));
@@ -493,13 +493,13 @@ class LqRule
     }
 
     /**
-     * 总进球|第三节|
+     * 第三节总分
      * @param mixed $model 注单表数据
      * @param mixed $resultModel 结果表数据
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_three_total_sizes_big($model, $resultModel, $resultRecords){
+    public function three_total_sizes_big($model, $resultModel, $resultRecords){
         $newResultRecords = array_reverse($resultRecords);
         $twoResultKey = array_search('第二节', array_column($newResultRecords, 'match_process'));
         $threeResultKey = array_search('第三节', array_column($newResultRecords, 'match_process'));
@@ -515,13 +515,13 @@ class LqRule
     }
 
     /**
-     * 总进球|第三节|
+     * 第三节总分
      * @param mixed $model 注单表数据
      * @param mixed $resultModel 结果表数据
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_three_total_sizes_small($model, $resultModel, $resultRecords){
+    public function three_total_sizes_small($model, $resultModel, $resultRecords){
         $newResultRecords = array_reverse($resultRecords);
         $twoResultKey = array_search('第二节', array_column($newResultRecords, 'match_process'));
         $threeResultKey = array_search('第三节', array_column($newResultRecords, 'match_process'));
@@ -537,13 +537,13 @@ class LqRule
     }
 
     /**
-     * 总进球|第四节|
+     * 第四节总分
      * @param mixed $model 注单表数据
      * @param mixed $resultModel 结果表数据
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_four_total_sizes_big($model, $resultModel, $resultRecords){
+    public function four_total_sizes_big($model, $resultModel, $resultRecords){
         $newResultRecords = array_reverse($resultRecords);
         $threeResultKey = array_search('第三节', array_column($newResultRecords, 'match_process'));
         $fourResultKey = array_search('第四节', array_column($newResultRecords, 'match_process'));
@@ -559,13 +559,13 @@ class LqRule
     }
 
     /**
-     * 总进球|第四节|
+     * 第四节总分
      * @param mixed $model 注单表数据
      * @param mixed $resultModel 结果表数据
      * @param mixed $resultRecords 结果记录表数据
      * @return string 1:赢  -1:输  2:平  3:赢半平半  4:输半平半
      */
-    public function lq_four_total_sizes_small($model, $resultModel, $resultRecords){
+    public function four_total_sizes_small($model, $resultModel, $resultRecords){
         $newResultRecords = array_reverse($resultRecords);
         $threeResultKey = array_search('第三节', array_column($newResultRecords, 'match_process'));
         $fourResultKey = array_search('第四节', array_column($newResultRecords, 'match_process'));

+ 31 - 25
app/Models/MoneyBuyStr.php

@@ -61,6 +61,7 @@ class MoneyBuyStr extends BaseModel {
             //$str_type = str_replace('*', '串', $data[$i]->str_type);
             $mun = explode('串',$data[$i]->str_type);
             $data[$i]->detail_content = $data[$i]->settle_status.':'.$mun[0].' [<a class="detail" lay-event="detail" pid="id" uri="/admin/SoccerStringNoteList/detail/?id=" href="/admin/SoccerStringNoteList/detail/?id='.$data[$i]->id.'"> 详情 </a>]';
+            $data[$i]->str_type = $data[$i]->str_type.'<br>(<span>'.$data[$i]->account_name.'</span>)';
 
             //反水
             $data[$i]->water_return = -1;
@@ -83,24 +84,26 @@ class MoneyBuyStr extends BaseModel {
             //用户投注前账户金额
             $data[$i]->available_cash = $data[$i]->money_cash+$data[$i]->money;
 
-            $data[$i]->account = $data[$i]->available_cash.' <span>'.$data[$i]->account_name.' </span> '.$data[$i]->frozen_cash;
-
-            if($data[$i]->settle_status == '未结算'){
-                $result = array();
-                for($j=0;$j<count($content);$j++){
-                    if($data[$i]->batch_id == $content[$j]->batch_id){
-                        $result[] = $content[$j]->result;
-                    }
-                }
-                if(in_array(0,$result)){
-                    $data[$i]->settle_status = $data[$i]->settle_status.'<br><a class="layui-btn layui-btn-sm resettlement settlement" lay-event="detail" pid="id" lay-filter = "resettlement" uri="" href="javascript:void(0)" style="background-color: grey;"> 结算 </a>';
-                }else{
-                    $data[$i]->settle_status = $data[$i]->settle_status.'<br><a class="layui-btn layui-btn-sm settlement" lay-event="detail" pid="id" lay-filter = "resettlement" uri="/admin/SoccerStringNoteList/settlement/?id=" href="javascript:settlement(\'/admin/SoccerStringNoteList/settlement/?id='.$data[$i]->id.'\');"> 结算 </a>';
-                }
-
-            }else if($data[$i]->settle_status == '已结算'){
-                $data[$i]->settle_status = $data[$i]->settle_status.'<br><a class="layui-btn layui-btn-sm resettlement settlement" lay-event="detail" pid="id" lay-filter = "resettlement" uri="" href="javascript:void(0)" style="background-color: #FFAF60;"> 已结算 </a>';
-            }
+            $data[$i]->account_money = $data[$i]->available_cash.' <span>'.$data[$i]->money.' </span> '.$data[$i]->frozen_cash;
+
+            $data[$i]->settle_status = $data[$i]->settle_status;
+
+//            if($data[$i]->settle_status == '未结算'){
+//                $result = array();
+//                for($j=0;$j<count($content);$j++){
+//                    if($data[$i]->batch_id == $content[$j]->batch_id){
+//                        $result[] = $content[$j]->result;
+//                    }
+//                }
+//                if(in_array(0,$result)){
+//                    $data[$i]->settle_status = $data[$i]->settle_status.'<br><a class="layui-btn layui-btn-sm resettlement settlement" lay-event="detail" pid="id" lay-filter = "resettlement" uri="" href="javascript:void(0)" style="background-color: grey;"> 结算 </a>';
+//                }else{
+//                    $data[$i]->settle_status = $data[$i]->settle_status.'<br><a class="layui-btn layui-btn-sm settlement" lay-event="detail" pid="id" lay-filter = "resettlement" uri="/admin/SoccerStringNoteList/settlement/?id=" href="javascript:settlement(\'/admin/SoccerStringNoteList/settlement/?id='.$data[$i]->id.'\');"> 结算 </a>';
+//                }
+//
+//            }else if($data[$i]->settle_status == '已结算'){
+//                $data[$i]->settle_status = $data[$i]->settle_status.'<br><a class="layui-btn layui-btn-sm resettlement settlement" lay-event="detail" pid="id" lay-filter = "resettlement" uri="" href="javascript:void(0)" style="background-color: #FFAF60;"> 已结算 </a>';
+//            }
 
         }
         return $data->toArray();
@@ -127,7 +130,9 @@ class MoneyBuyStr extends BaseModel {
         $res = $this->where('id',$id)->first();
         $data = \App\Models\MoneyBuyMatch::where('batch_id',$res->batch_id)->where('bet_type','2')->get();
         $game_type = \App\Models\StGameType::get();
+        $odds_code = \App\Models\Matchcode::get();
         for($i=0;$i<count($data);$i++){
+            $league = DB::table('st_'.$data[$i]->game_code.'_league')->join('st_'.$data[$i]->game_code.'_competition','st_'.$data[$i]->game_code.'_competition.lg_id','=','st_'.$data[$i]->game_code.'_league.lg_id')->where('st_'.$data[$i]->game_code.'_league.lg_id',$data[$i]->lg_id)->first();
             $league = DB::table('st_'.$data[$i]->game_code.'_league')->join('st_'.$data[$i]->game_code.'_competition','st_'.$data[$i]->game_code.'_competition.lg_id','=','st_'.$data[$i]->game_code.'_league.lg_id')->where('st_'.$data[$i]->game_code.'_league.lg_id',$data[$i]->lg_id)->first();
             if(!empty($league)){
                 $data[$i]->league = $league->name_chinese;
@@ -143,13 +148,14 @@ class MoneyBuyStr extends BaseModel {
             if(!empty(strstr($data[$i]->odds_code,'guest',true))){
                 $data[$i]->team = $data[$i]->guest_team;
             }
-            $p_code = \App\Models\Matchcode::where('odds_code',$data[$i]->p_code)->where('game_code',$data[$i]->game_code)->first();
-            $odds_code = \App\Models\Matchcode::where('odds_code',$data[$i]->odds_code)->where('game_code',$data[$i]->game_code)->first();
-            if(!empty($odds_code)){
-                $data[$i]->odds_code = $odds_code->odds_name;
-            }
-            if(!empty($p_code)){
-                $data[$i]->p_code = $p_code->odds_name;
+
+            for($j=0;$j<count($odds_code);$j++){
+                if($data[$i]->game_code == $odds_code[$j]->game_code && $data[$i]->odds_code == $odds_code[$j]->odds_code){
+                    $data[$i]->odds_code = $odds_code[$j]->odds_name;
+                }
+                if($data[$i]->game_code == $odds_code[$j]->game_code && $data[$i]->p_code == $odds_code[$j]->odds_code){
+                    $data[$i]->p_code = $odds_code[$j]->odds_name;
+                }
             }
 
             $data[$i]->home_guest = $data[$i]->home_team.' VS '.$data[$i]->guest_team;

+ 20 - 20
app/Models/SportsBase.php

@@ -19,30 +19,30 @@ class SportsBase extends BaseModel {
                 if($bqmatch[$b]->match_date < date("Y-m-d",time()) && strtotime($bqmatch[$b]->match_time.' '.$bqmatch[$b]->match_time)+10800 < time()){
                     \App\Models\SportsBase::where('match_id',$bqmatch[$b]->match_id)->update(['status'=>'2']);
                     \App\Models\Stbqresultrecord::where('match_id',$bqmatch[$b]->match_id)->update(['status'=>'2']);
-                    $comendnotice = \App\Models\Comendnotice::where('match_id',$bqmatch[$b]->match_id)->first();
-                    if(empty($comendnotice)){
-                        $db = new \App\Models\Comendnotice();
-                        $db->status = 0;
-                        $db->game_code = 'bq';
-                        $db->match_id = $bqmatch[$b]->match_id;
-                        $db->done_time = date("Y-m-d h:i:s", time());
-                        $db->ctime = date("Y-m-d h:i:s", time());
-                        $db->save();
-                    }
+//                    $comendnotice = \App\Models\Comendnotice::where('match_id',$bqmatch[$b]->match_id)->first();
+//                    if(empty($comendnotice)){
+//                        $db = new \App\Models\Comendnotice();
+//                        $db->status = 0;
+//                        $db->game_code = 'bq';
+//                        $db->match_id = $bqmatch[$b]->match_id;
+//                        $db->done_time = date("Y-m-d h:i:s", time());
+//                        $db->ctime = date("Y-m-d h:i:s", time());
+//                        $db->save();
+//                    }
                 }
                 if($bqmatch[$b]->match_date == date("Y-m-d",time()) && strtotime($bqmatch[$b]->match_date.' '.$bqmatch[$b]->match_time)+10800 < time()){
                     \App\Models\SportsBase::where('match_id',$bqmatch[$b]->match_id)->update(['status'=>'2']);
                     \App\Models\Stbqresultrecord::where('match_id',$bqmatch[$b]->match_id)->update(['status'=>'2']);
-                    $comendnotice = \App\Models\Comendnotice::where('match_id',$bqmatch[$b]->match_id)->first();
-                    if(empty($comendnotice)){
-                        $db = new \App\Models\Comendnotice();
-                        $db->status = 0;
-                        $db->game_code = 'bq';
-                        $db->match_id = $bqmatch[$b]->match_id;
-                        $db->done_time = date("Y-m-d h:i:s", time());
-                        $db->ctime = date("Y-m-d h:i:s", time());
-                        $db->save();
-                    }
+//                    $comendnotice = \App\Models\Comendnotice::where('match_id',$bqmatch[$b]->match_id)->first();
+//                    if(empty($comendnotice)){
+//                        $db = new \App\Models\Comendnotice();
+//                        $db->status = 0;
+//                        $db->game_code = 'bq';
+//                        $db->match_id = $bqmatch[$b]->match_id;
+//                        $db->done_time = date("Y-m-d h:i:s", time());
+//                        $db->ctime = date("Y-m-d h:i:s", time());
+//                        $db->save();
+//                    }
                 }
             }
         }

+ 20 - 20
app/Models/SportsBasket.php

@@ -19,30 +19,30 @@ class SportsBasket extends BaseModel {
                 if($lqmatch[$b]->match_date < date("Y-m-d",time()) && strtotime($lqmatch[$b]->match_time.' '.$lqmatch[$b]->match_time)+4200 < time()){
                     \App\Models\SportsBasket::where('id',$lqmatch[$b]->id)->update(['status'=>'2']);
                     \App\Models\Stlqresultrecord::where('match_id',$lqmatch[$b]->match_id)->update(['status'=>'2']);
-                    $comendnotice = \App\Models\Comendnotice::where('match_id',$lqmatch[$b]->match_id)->first();
-                    if(empty($comendnotice)){
-                        $db = new \App\Models\Comendnotice();
-                        $db->status = 0;
-                        $db->game_code = 'lq';
-                        $db->match_id = $lqmatch[$b]->match_id;
-                        $db->done_time = date("Y-m-d h:i:s", time());
-                        $db->ctime = date("Y-m-d h:i:s", time());
-                        $db->save();
-                    }
+//                    $comendnotice = \App\Models\Comendnotice::where('match_id',$lqmatch[$b]->match_id)->first();
+//                    if(empty($comendnotice)){
+//                        $db = new \App\Models\Comendnotice();
+//                        $db->status = 0;
+//                        $db->game_code = 'lq';
+//                        $db->match_id = $lqmatch[$b]->match_id;
+//                        $db->done_time = date("Y-m-d h:i:s", time());
+//                        $db->ctime = date("Y-m-d h:i:s", time());
+//                        $db->save();
+//                    }
                 }
                 if($lqmatch[$b]->match_date == date("Y-m-d",time()) && strtotime($lqmatch[$b]->match_date.' '.$lqmatch[$b]->match_time)+4200 < time()){
                     \App\Models\SportsBasket::where('id',$lqmatch[$b]->id)->update(['status'=>'2']);
                     \App\Models\Stlqresultrecord::where('match_id',$lqmatch[$b]->match_id)->update(['status'=>'2']);
-                    $comendnotice = \App\Models\Comendnotice::where('match_id',$lqmatch[$b]->match_id)->first();
-                    if(empty($comendnotice)){
-                        $db = new \App\Models\Comendnotice();
-                        $db->status = 0;
-                        $db->game_code = 'lq';
-                        $db->match_id = $lqmatch[$b]->match_id;
-                        $db->done_time = date("Y-m-d h:i:s", time());
-                        $db->ctime = date("Y-m-d h:i:s", time());
-                        $db->save();
-                    }
+//                    $comendnotice = \App\Models\Comendnotice::where('match_id',$lqmatch[$b]->match_id)->first();
+//                    if(empty($comendnotice)){
+//                        $db = new \App\Models\Comendnotice();
+//                        $db->status = 0;
+//                        $db->game_code = 'lq';
+//                        $db->match_id = $lqmatch[$b]->match_id;
+//                        $db->done_time = date("Y-m-d h:i:s", time());
+//                        $db->ctime = date("Y-m-d h:i:s", time());
+//                        $db->save();
+//                    }
                 }
             }
         }

+ 24 - 49
app/Models/SportsNoteList.php

@@ -51,7 +51,7 @@ class SportsNoteList extends BaseModel {
             }else if($data[$i]->game_status==3){
                 $data[$i]->game_status = '平';
             }
-            $data[$i]->match_id_order = '<span>'.$data[$i]->match_id.'</span><br>'.$data[$i]->order_id;
+            $data[$i]->match_id_order = '<span>'.$data[$i]->match_id.'</span> (<span>'.$data[$i]->account_name.'</span>)<br>'.$data[$i]->order_id;
             $data[$i]->league = $data[$i]->name_chinese;
 
             $data[$i]->home_guest = $data[$i]->home_team.' VS '.$data[$i]->guest_team;
@@ -75,33 +75,33 @@ class SportsNoteList extends BaseModel {
             //此时结果金额
             $data[$i]->result = $data[$i]->water_return+$data[$i]->gain_money;
             //用户投注前账户金额
-            $data[$i]->available_cash = $data[$i]->money_cash;
+            $data[$i]->available_cash = $data[$i]->money_cash+$data[$i]->money;
 
-            $data[$i]->account = $data[$i]->available_cash.'<br><span>'.$data[$i]->account_name.'</span><br>'.$data[$i]->frozen_cash;
+            $data[$i]->account_money = $data[$i]->available_cash.'<br><span>'.$data[$i]->money.'</span><br>'.$data[$i]->frozen_cash;
 
-
-            $data[$i]->str = 0;
-            $data[$i]->str1 = 0;
             for($b=0;$b<count($content);$b++){
+                $data[$i]->str = 0;
+                $data[$i]->str1 = 0;
                 if(!empty($content[$b]->odds_code)){
-                    if(!empty(strstr($content[$b]->odds_code,'home',true))){
+                    if(!empty(stristr($content[$b]->odds_code,'home'))){
                         $data[$i]->team = $data[$i]->home_team;
                     }
-                    if(!empty(strstr($content[$b]->odds_code,'guest',true))){
+                    if(!empty(stristr($content[$b]->odds_code,'guest'))){
                         $data[$i]->team = $data[$i]->guest_team;
                     }
                 }
 
                 if($data[$i]->match_id == $content[$b]->match_id && $data[$i]->batch_id == $content[$b]->batch_id){
-                    if($content[$b]->result == '0'){
-                        $data[$i]->str = 1;
-                    }else{
-                        if($data[$i]->game_status == '未处理'){
-                            $data[$i]->str = 2;
-                        }else{
-                            $data[$i]->str = 3;
-                        }
-                    }
+//                    if($content[$b]->result == '0'){
+//                        $data[$i]->str = 1;
+//                    }else{
+//                        if($data[$i]->game_status == '未处理'){
+//                            $data[$i]->str = 2;
+//                        }else{
+//                            $data[$i]->str = 3;
+//                        }
+//                    }
+                    $data[$i]->game_status = $data[$i]->game_status;
 
                     //投注详情
                     if(!empty($data[$i]->match_time)){
@@ -125,41 +125,16 @@ class SportsNoteList extends BaseModel {
                     }
                 }
             }
-            if($data[$i]->str == 1){
-                $data[$i]->game_status = $data[$i]->game_status.'<br><a class="layui-btn layui-btn-sm audit" lay-event="detail" pid="id" uri="" href="javascript:void(0)" style="background-color: grey;"> 结算 </a>';
-            }
-            if($data[$i]->str == 2){
-                $data[$i]->game_status = $data[$i]->game_status.'<br><a class="layui-btn layui-btn-sm settlement" lay-event="detail" pid="id" uri="/admin/SoccerNoteList/settlement/?id=" href="javascript:settlement(\'/admin/SoccerNoteList/settlement/?id='.$data[$i]->id.'\');"> 结算 </a>';
-            }
-            if($data[$i]->str == 3){
-                $data[$i]->game_status = $data[$i]->game_status.'<br><a class="layui-btn layui-btn-sm resettlement" lay-event="detail" pid="id" uri="" href="javascript:void(0)" style="background-color: #FFAF60;"> 已结算 </a>';
-            }
-            $data[$i]->content = $data[$i]->content1.$data[$i]->content;
-
-
-//            $content = \App\Models\MoneyBuyMatch::where('batch_id',$data[$i]->batch_id)->where('match_id',$data[$i]->match_id)->where('bet_type','1')->get();
-//            if($content[0]->result == '0'){
+//            if($data[$i]->str == 1){
 //                $data[$i]->game_status = $data[$i]->game_status.'<br><a class="layui-btn layui-btn-sm audit" lay-event="detail" pid="id" uri="" href="javascript:void(0)" style="background-color: grey;"> 结算 </a>';
-//            }else{
-//                if($data[$i]->game_status == '未处理'){
-//                    $data[$i]->game_status = $data[$i]->game_status.'<br><a class="layui-btn layui-btn-sm settlement" lay-event="detail" pid="id" uri="/admin/SoccerNoteList/settlement/?id=" href="javascript:settlement(\'/admin/SoccerNoteList/settlement/?id='.$data[$i]->id.'\');"> 结算 </a>';
-//                }else{
-//                    //$data[$i]->game_status = $data[$i]->game_status.'<br><a class="layui-btn layui-btn-sm resettlement" lay-event="detail" pid="id" uri="/admin/SoccerNoteList/resettlement/?id=" href="javascript:resettlement(\'/admin/SoccerNoteList/resettlement/?id='.$data[$i]->id.'\');"> 重新结算 </a>';
-//                    $data[$i]->game_status = $data[$i]->game_status.'<br><a class="layui-btn layui-btn-sm resettlement" lay-event="detail" pid="id" uri="" href="javascript:void(0)" style="background-color: #FFAF60;"> 已结算 </a>';
-//                }
 //            }
-//
-//            for($j=0;$j<count($content);$j++){
-//                $odds_code = $content[$j]->odds_code;
-//                $result = \App\Models\Matchcode::where('odds_code',$odds_code)->first();
-//                if(!empty($result)){
-//                    $odds_name = $result->odds_name;
-//                }else{
-//                    $odds_name = $odds_code;
-//                }
-//                $data[$i]->content = $data[$i]->content.$odds_name.' #'.$content[$j]->condition.' ¥'.$content[$j]->bet_money.'@'.$content[$j]->odds.'<br>';
-//
+//            if($data[$i]->str == 2){
+//                $data[$i]->game_status = $data[$i]->game_status.'<br><a class="layui-btn layui-btn-sm settlement" lay-event="detail" pid="id" uri="/admin/SoccerNoteList/settlement/?id=" href="javascript:settlement(\'/admin/SoccerNoteList/settlement/?id='.$data[$i]->id.'\');"> 结算 </a>';
+//            }
+//            if($data[$i]->str == 3){
+//                $data[$i]->game_status = $data[$i]->game_status.'<br><a class="layui-btn layui-btn-sm resettlement" lay-event="detail" pid="id" uri="" href="javascript:void(0)" style="background-color: #FFAF60;"> 已结算 </a>';
 //            }
+            $data[$i]->content = $data[$i]->content1.$data[$i]->content;
 
         }
         return $data->toArray();

+ 20 - 20
app/Models/SportsSoccer.php

@@ -19,30 +19,30 @@ class SportsSoccer extends BaseModel {
                 if($zqmatch[$b]->match_date < date("Y-m-d",time()) && strtotime($zqmatch[$b]->match_time.' '.$zqmatch[$b]->match_time)+7200 < time()){
                     \App\Models\SportsSoccer::where('id',$zqmatch[$b]->id)->update(['status'=>'2']);
                     \App\Models\Stzqresultrecord::where('match_id',$zqmatch[$b]->match_id)->update(['status'=>'2']);
-                    $comendnotice = \App\Models\Comendnotice::where('match_id',$zqmatch[$b]->match_id)->first();
-                    if(empty($comendnotice)){
-                        $db = new \App\Models\Comendnotice();
-                        $db->status = 0;
-                        $db->game_code = 'zq';
-                        $db->match_id = $zqmatch[$b]->match_id;
-                        $db->done_time = date("Y-m-d h:i:s", time());
-                        $db->ctime = date("Y-m-d h:i:s", time());
-                        $db->save();
-                    }
+//                    $comendnotice = \App\Models\Comendnotice::where('match_id',$zqmatch[$b]->match_id)->first();
+//                    if(empty($comendnotice)){
+//                        $db = new \App\Models\Comendnotice();
+//                        $db->status = 0;
+//                        $db->game_code = 'zq';
+//                        $db->match_id = $zqmatch[$b]->match_id;
+//                        $db->done_time = date("Y-m-d h:i:s", time());
+//                        $db->ctime = date("Y-m-d h:i:s", time());
+//                        $db->save();
+//                    }
                 }
                 if($zqmatch[$b]->match_date == date("Y-m-d",time()) && strtotime($zqmatch[$b]->match_date.' '.$zqmatch[$b]->match_time)+7200 < time()){
                     \App\Models\SportsSoccer::where('id',$zqmatch[$b]->id)->update(['status'=>'2']);
                     \App\Models\Stzqresultrecord::where('match_id',$zqmatch[$b]->match_id)->update(['status'=>'2']);
-                    $comendnotice = \App\Models\Comendnotice::where('match_id',$zqmatch[$b]->match_id)->first();
-                    if(empty($comendnotice)){
-                        $db = new \App\Models\Comendnotice();
-                        $db->status = 0;
-                        $db->game_code = 'zq';
-                        $db->match_id = $zqmatch[$b]->match_id;
-                        $db->done_time = date("Y-m-d h:i:s", time());
-                        $db->ctime = date("Y-m-d h:i:s", time());
-                        $db->save();
-                    }
+//                    $comendnotice = \App\Models\Comendnotice::where('match_id',$zqmatch[$b]->match_id)->first();
+//                    if(empty($comendnotice)){
+//                        $db = new \App\Models\Comendnotice();
+//                        $db->status = 0;
+//                        $db->game_code = 'zq';
+//                        $db->match_id = $zqmatch[$b]->match_id;
+//                        $db->done_time = date("Y-m-d h:i:s", time());
+//                        $db->ctime = date("Y-m-d h:i:s", time());
+//                        $db->save();
+//                    }
                 }
             }
         }

+ 20 - 20
app/Models/SportsTennis.php

@@ -19,30 +19,30 @@ class SportsTennis extends BaseModel {
                 if($wqmatch[$b]->match_date < date("Y-m-d",time()) && strtotime($wqmatch[$b]->match_time.' '.$wqmatch[$b]->match_time)+10800 < time()){
                     \App\Models\SportsTennis::where('match_id',$wqmatch[$b]->match_id)->update(['status'=>'2']);
                     \App\Models\Stwqresultrecord::where('match_id',$wqmatch[$b]->match_id)->update(['status'=>'2']);
-                    $comendnotice = \App\Models\Comendnotice::where('match_id',$wqmatch[$b]->match_id)->first();
-                    if(empty($comendnotice)){
-                        $db = new \App\Models\Comendnotice();
-                        $db->status = 0;
-                        $db->game_code = 'wq';
-                        $db->match_id = $wqmatch[$b]->match_id;
-                        $db->done_time = date("Y-m-d h:i:s", time());
-                        $db->ctime = date("Y-m-d h:i:s", time());
-                        $db->save();
-                    }
+//                    $comendnotice = \App\Models\Comendnotice::where('match_id',$wqmatch[$b]->match_id)->first();
+//                    if(empty($comendnotice)){
+//                        $db = new \App\Models\Comendnotice();
+//                        $db->status = 0;
+//                        $db->game_code = 'wq';
+//                        $db->match_id = $wqmatch[$b]->match_id;
+//                        $db->done_time = date("Y-m-d h:i:s", time());
+//                        $db->ctime = date("Y-m-d h:i:s", time());
+//                        $db->save();
+//                    }
                 }
                 if($wqmatch[$b]->match_date == date("Y-m-d",time()) && strtotime($wqmatch[$b]->match_date.' '.$wqmatch[$b]->match_time)+10800 < time()){
                     \App\Models\SportsTennis::where('match_id',$wqmatch[$b]->match_id)->update(['status'=>'2']);
                     \App\Models\Stwqresultrecord::where('match_id',$wqmatch[$b]->match_id)->update(['status'=>'2']);
-                    $comendnotice = \App\Models\Comendnotice::where('match_id',$wqmatch[$b]->match_id)->first();
-                    if(empty($comendnotice)){
-                        $db = new \App\Models\Comendnotice();
-                        $db->status = 0;
-                        $db->game_code = 'wq';
-                        $db->match_id = $wqmatch[$b]->match_id;
-                        $db->done_time = date("Y-m-d h:i:s", time());
-                        $db->ctime = date("Y-m-d h:i:s", time());
-                        $db->save();
-                    }
+//                    $comendnotice = \App\Models\Comendnotice::where('match_id',$wqmatch[$b]->match_id)->first();
+//                    if(empty($comendnotice)){
+//                        $db = new \App\Models\Comendnotice();
+//                        $db->status = 0;
+//                        $db->game_code = 'wq';
+//                        $db->match_id = $wqmatch[$b]->match_id;
+//                        $db->done_time = date("Y-m-d h:i:s", time());
+//                        $db->ctime = date("Y-m-d h:i:s", time());
+//                        $db->save();
+//                    }
                 }
             }
         }

+ 1 - 0
resources/lang/zh-cn/sportsnotelist.php

@@ -37,6 +37,7 @@ return array(
 
     'notelist_type' => '投注球类',
     'account' => '投注账号',
+    'account_money' => '账户金额',
     'date' => '日期',
     'star_time' => '开始时间',
     'end_time' => '结束时间',

+ 14 - 0
resources/views/admin/sportsbk/outcome.blade.php

@@ -21,6 +21,20 @@
             width: auto;
         }
     </style>
+    <script type="text/html" id="liansai">
+      @{{#if(d.match_id!=null){ }}
+        <span>@{{ d.match_id}}</span>
+      @{{#} }}<br>
+      @{{#if(d.name_chinese!=null){ }}
+        <span>@{{ d.name_chinese}}</span>
+      @{{#} }}
+    </script>
+
+    <script type="text/html" id="totime">
+      @{{#if(d.match_time!=null){ }}
+        <span>@{{ d.match_time}}</span>
+      @{{#} }}
+    </script>
 
     <script type="text/html" id="status">
         @if(checkRriv('/admin/sportsbk/index'))<input type="checkbox" name="status" value="@{{d.id}}" lay-skin="switch" lay-text="进行中|已结束" lay-filter="openStatus" @{{ d.status == '1' ? 'checked' : '' }}>@endif

+ 1 - 1
resources/views/sports/sports_notelist.blade.php

@@ -146,7 +146,7 @@
                     <div class="layui-inline">
                         <a class="layui-btn layui-btn-sm lay-btn-diy"   data-type="reload" eventType="event-query-submit" style="opacity: 1; pointer-events: auto;">提交</a>
                         <a  class="layui-btn   layui-btn-sm layui-btn-normal reset" data-type="reload" style="opacity: 1; pointer-events: auto;">重置</a>
-                        @if(checkRriv('/admin/SoccerNoteList/batchsettlement'))<a href="javascript:batchsettlement('/admin/SoccerNoteList/batchsettlement');" class="layui-btn layui-btn-sm  layui-btn-danger">批量结算</a>@endif
+                        {{--@if(checkRriv('/admin/SoccerNoteList/batchsettlement'))<a href="javascript:batchsettlement('/admin/SoccerNoteList/batchsettlement');" class="layui-btn layui-btn-sm  layui-btn-danger">批量结算</a>@endif--}}
                         <a class="layui-btn layui-btn-sm layui-btn-green set" data-type="reload" style="opacity: 1; pointer-events: auto;"><i class="layui-icon">ဂ</i></a>
                         {{--@if(checkRriv('/admin/SportsSoccer/add'))<a href="/admin/SportsSoccer/add" class="layui-btn layui-btn-sm ">添加</a>@endif--}}
                         {{--@if(checkRriv('/admin/SoccerNoteList/orderstatus'))<a href="/admin/SoccerNoteList/orderstatus" class="layui-btn layui-btn-sm ">订单状态审核</a>@endif--}}

+ 1 - 1
resources/views/sports/sports_stringnotelist.blade.php

@@ -124,7 +124,7 @@
                     <div class="layui-inline">
                         <a class="layui-btn layui-btn-sm lay-btn-diy"   data-type="reload" eventType="event-query-submit" style="opacity: 1; pointer-events: auto;">提交</a>
                         <a  class="layui-btn   layui-btn-sm layui-btn-normal reset" data-type="reload" style="opacity: 1; pointer-events: auto;">重置</a>
-                        @if(checkRriv('/admin/SoccerstringNoteList/batchsettlement'))<a href="javascript:batchsettlement('/admin/SoccerstringNoteList/batchsettlement');" class="layui-btn layui-btn-sm  layui-btn-danger">批量结算</a>@endif
+                        {{--@if(checkRriv('/admin/SoccerstringNoteList/batchsettlement'))<a href="javascript:batchsettlement('/admin/SoccerstringNoteList/batchsettlement');" class="layui-btn layui-btn-sm  layui-btn-danger">批量结算</a>@endif--}}
                         <a class="layui-btn layui-btn-sm layui-btn-green set" data-type="reload" style="opacity: 1; pointer-events: auto;"><i class="layui-icon">ဂ</i></a>
                         {{--@if(checkRriv('/admin/SoccerstringNoteList/add'))<a href="/admin/SoccerstringNoteList/add" class="layui-btn layui-btn-sm ">添加</a>@endif--}}
                         @if(checkRriv('/admin/SoccerstringNoteList/delete'))<a href="javascript:delWin('/admin/SoccerstringNoteList/delete?id=');" class="layui-btn layui-btn-sm  layui-btn-danger">删除</a>@endif