stanley-king 1 年之前
父節點
當前提交
e5c46af1b0

+ 0 - 1
core/framework/cache/cache.redis.php

@@ -274,7 +274,6 @@ class Cacheredis extends Cache
         }
 
         if (count($data) == 1) {
-            Log::record("hset",Log::DEBUG);
             $this->handler->hset($this->_key($name,$prefix), key($data),current($data));
         } elseif (count($data) > 1) {
             $this->handler->hMset($this->_key($name,$prefix), $data);

+ 0 - 2
helper/refill/RefillBase.php

@@ -266,7 +266,6 @@ class RefillBase
 
             $mod_refill->partition(util::part_refill($order_time))->edit($order_id, ['notify_time' => time(), 'is_retrying' => 0,'notify_state' => 1]);
             util::monitor_callback($mchid, $spec, $card_type, $refill_info['mch_amount'], $refill_info['channel_amount'], $success, $order_time);
-            Log::record("onEvent complete 1", Log::DEBUG);
             util::onEventComplete($refill_info, $order_info, $success);
             util::pop_queue_order($mchid,$mch_order,$order_time);
             QueueClient::push("NotifyMerchantComplete", ['order_id' => $order_id,'manual' => false]);
@@ -355,7 +354,6 @@ class RefillBase
             $refill_info = $mod_refill->partition(util::part_refill($order_time))->getOrderInfo(['order_id' => $order_id]);
             $mod_order = Model('vr_order');
             $order_info = $mod_order->partition(util::part_notify())->getOrderInfo(['order_id' => $order_id]);
-            Log::record("onEvent complete 2", Log::DEBUG);
             util::onEventComplete($refill_info, $order_info, true);
 
             return [true,$order_id,''];

+ 0 - 12
helper/refill/event/card_crash.php

@@ -5,8 +5,6 @@ namespace refill\event;
 use refill\order;
 use refill\util;
 use mtopcard;
-use Log;
-
 
 # 规避相同手机卡号撞单问题解
 class card_crash implements IEventRefill
@@ -34,16 +32,13 @@ class card_crash implements IEventRefill
 
     public function onBeforeSubmit(order $order)
     {
-        Log::record("card_crash onBeforeSubmit 1",Log::DEBUG);
         if(!$order->is_phone()) {
             return true;
         }
 
-        Log::record("card_crash onBeforeSubmit 2",Log::DEBUG);
         $card_no = $order->card_no();
         $ret = $this->can_submit($card_no);
 
-        Log::record("card_crash onBeforeSubmit 3",Log::DEBUG);
         if(!$ret)
         {
             $mchid = $order->mchid();
@@ -60,25 +55,18 @@ class card_crash implements IEventRefill
             }
         }
 
-        Log::record("card_crash onBeforeSubmit 3",Log::DEBUG);
         return true;
     }
     public function onSubmit(order $order)
     {
-        Log::record("card_crash onSubmit 1",Log::DEBUG);
-
         if(!$order->is_phone()) {
             return;
         }
 
-        Log::record("card_crash onSubmit 2",Log::DEBUG);
-
         $card_no = $order->card_no();
         $oid = $order->unique_id();
 
         $this->submit($card_no,$oid);
-
-        Log::record("card_crash onSubmit 3",Log::DEBUG);
     }
 
 

+ 3 - 10
helper/refill/event/crash.php

@@ -2,8 +2,6 @@
 
 namespace refill\event;
 
-use Log;
-
 trait crash
 {
     private function can_submit($card_no)
@@ -167,27 +165,22 @@ trait crash
 
     private function write($card_no, $val)
     {
-        Log::record('card_crash write 1',Log::DEBUG);
         $data = [$card_no => json_encode($val)];
-        wcache('card_crash', $data, 'refill-');
+        wcache(card_crash::cache_name, $data, 'refill-');
     }
 
     private function read($card_no)
     {
-        Log::record('card_crash read 1',Log::DEBUG);
-
-        $ret = rcache('card_crash', 'refill-', $card_no);
+        $ret = rcache(card_crash::cache_name, 'refill-', $card_no);
         if (empty($ret)) {
             return false;
         }
-        Log::record('card_crash read 2',Log::DEBUG);
-
 
         $values = $ret[$card_no];
         return json_decode($values, true);
     }
     private function delete($card_no)
     {
-        dcache('card_crash', 'refill-', $card_no);
+        dcache(card_crash::cache_name, 'refill-', $card_no);
     }
 }