Browse Source

sunguidong

zhangguidong 2 years ago
parent
commit
113143eb25
1 changed files with 13 additions and 12 deletions
  1. 13 12
      app/pay/controller/Pay.php

+ 13 - 12
app/pay/controller/Pay.php

@@ -89,19 +89,20 @@ class Pay extends Controller
     }
     public function BalancePayNotify()
     {
-        $data = file_get_contents('php://input');
-        $is_xml =  xml_parser($data);
-        if($is_xml) {
-            $jsonXml = json_encode(simplexml_load_string($data, 'SimpleXMLElement', LIBXML_NOCDATA));
-            $data = json_decode($jsonXml, true);
-            Log::write('pay_notifiy:'.$jsonXml, 'notice');
-        }
-        else{
-            $data = input();
-            Log::write('pay_notifiy_pay:'.var_export($data,true), 'notice');
-        }
-        file_put_contents('pay3_log.log', $data["out_trade_no"]);
+//        $data = file_get_contents('php://input');
+//        $is_xml =  xml_parser($data);
+//        if($is_xml) {
+//            $jsonXml = json_encode(simplexml_load_string($data, 'SimpleXMLElement', LIBXML_NOCDATA));
+//            $data = json_decode($jsonXml, true);
+//            Log::write('pay_notifiy:'.$jsonXml, 'notice');
+//        }
+//        else{
+//            $data = input();
+//            Log::write('pay_notifiy_pay:'.var_export($data,true), 'notice');
+//        }
+//        file_put_contents('pay3_log.log', $data["out_trade_no"]);
 
+        $data = ['out_trade_no'=>'16654543898562'];
         event('BalancePayNotify', $data);
     }