Browse Source

调试支付

Robin 6 năm trước cách đây
mục cha
commit
74826637f8

+ 1 - 1
normandcrm/crm/backend/controllers/PayController.php

@@ -22,7 +22,7 @@ class PayController extends Controller
         if ($payType <= 0) {
             return 'invalid request';
         }
-        file_put_contents('huiqi1.txt',$payType);
+
         if (Yii::$app->getRequest()->getIsPost()) {
             $data = Yii::$app->getRequest()->post();
             if (empty($data)) {

+ 1 - 1
normandcrm/crm/backend/models/PayApi.php

@@ -29,7 +29,7 @@ class PayApi extends BaseApi
     public function callNotify($data, $payType)
     {
         !isset($data['payType']) && $data['payType'] = $payType;
-        file_put_contents('huiqi2.txt',$payType);
+
         $result = $this->post($this->apiUrl . '/notify', $data);
         if ($result['code'] == 1) {
             return $this->returnArray(1, $result['data'], $result['message']);

+ 0 - 4
normandcrm/service/backend/controllers/PayController.php

@@ -32,11 +32,7 @@ class PayController extends BaseController
     public function actionNotify()
     {
         $model = new PayForm();
-
-
         $data = Yii::$app->getRequest()->post();
-        $tt = print_r($data,true);
-        file_put_contents('huiqi3.txt',$tt);
         if ($model->handleNotify($data)) {
             return $this->outJson(1, $model->getOutNotifyResult());
         } else {

+ 1 - 1
normandcrm/service/common/pay/BasePayHandler.php

@@ -65,7 +65,7 @@ eot;
      */
     public static function getPayHandlerByPayType($payType)
     {
-        file_put_contents('huiqi5.txt',$payType);
+
         switch ($payType) {
             case 1:
                 $handler = new \common\pay\renren\PayHandler();

+ 1 - 3
normandcrm/service/common/pay/PayForm.php

@@ -175,7 +175,7 @@ class PayForm extends Model
     public function handleNotify($data)
     {
         $payType = isset($data['payType']) ? trim($data['payType']) : '';
-        file_put_contents('huiqi4.txt',$payType);
+
         if($data['payType']=="wy_bb" || $data['payType']=="alipay_bb"){
             $handler = BasePayHandler::getPayHandlerByPayType(19);
         }else{
@@ -185,9 +185,7 @@ class PayForm extends Model
         unset($data['token']);
         $success = false;
         if ($handler != null) {
-            file_put_contents('huiqidata.txt',\GuzzleHttp\json_encode($data));
             $success = $handler->handleNotify($data);
-            file_put_contents('huiqi7.txt',$success);
             $this->_outNotifyResult = $handler->outNotify($success);
         }
         return $success;

+ 0 - 1
normandcrm/service/common/pay/payplat/PayHandler.php

@@ -106,7 +106,6 @@ class PayHandler extends BasePayHandler
     public function outNotify($success)
     {
         if ($success == true) {
-            file_put_contents('huiqi6.txt',$success);
             return 'success';
         } else {
 			// 返回的数据格式