Browse Source

rename a variable

stanley-king 4 years atrás
parent
commit
96e505bdad
2 changed files with 6 additions and 8 deletions
  1. 0 1
      helper/refill/api/xyz/gftd/RefillOil.php
  2. 6 7
      helper/refill/policy/xyz/policy.php

+ 0 - 1
helper/refill/api/xyz/gftd/RefillOil.php

@@ -138,7 +138,6 @@ class RefillOil extends refill\IRefillOil
         $params['outOrderNumber'] = $order_sn;
 
         return $params;
-
     }
 
     public function query($refill_info)

+ 6 - 7
helper/refill/policy/xyz/policy.php

@@ -9,12 +9,13 @@ use StatesHelper;
 
 class policy extends ProviderManager implements IPolicy
 {
-    const normal_times = 3;
-    const normle_time_out = 900;
+    const normal_times = 15;
+    const normal_time_out = 900;
+    const normal_req_secs = 60;
 
     const high_times = 3;
     const high_time_out = 60;
-
+    
     protected $mChannelControl;
     protected $mMchctl;
     public function __construct()
@@ -58,8 +59,6 @@ class policy extends ProviderManager implements IPolicy
         }
 
         return [$result,$overload];
-//        $this->sort_price($providers,$spec,$card_type,$quality);
-//        return [$providers,false];
     }
 
     //按价格从低到高排序
@@ -120,7 +119,7 @@ class policy extends ProviderManager implements IPolicy
             return $checker($refill_info, $order_info,$time_out,$quality);
         }
         else {
-            return $checker($refill_info, $order_info,policy::normle_time_out,1);
+            return $checker($refill_info, $order_info,policy::normal_time_out,1);
         }
     }
 
@@ -138,7 +137,7 @@ class policy extends ProviderManager implements IPolicy
             }
         }
         elseif($quality == 1) {
-            return $commit_times < policy::normal_times && time() - $order_time < policy::normle_time_out;
+            return $commit_times < policy::normal_times && time() - $order_time < policy::normal_time_out;
         }
         else {
             return $commit_times < policy::high_times && time() - $order_time < policy::high_time_out;