作者 lihan
1 个管道 的构建 通过 耗费 0 秒

支付宝

@@ -433,9 +433,12 @@ class OrderController extends HomeBaseController @@ -433,9 +433,12 @@ class OrderController extends HomeBaseController
433 require EXTEND_PATH . '/alipay/config.php'; 433 require EXTEND_PATH . '/alipay/config.php';
434 require_once EXTEND_PATH . '/alipay/wappay/service/AlipayTradeService.php'; 434 require_once EXTEND_PATH . '/alipay/wappay/service/AlipayTradeService.php';
435 $arr = $_POST; 435 $arr = $_POST;
  436 + cache('zfb', $arr);
436 $alipaySevice = new AlipayTradeService($config); 437 $alipaySevice = new AlipayTradeService($config);
437 $alipaySevice->writeLog(var_export($_POST, true)); 438 $alipaySevice->writeLog(var_export($_POST, true));
438 - if ($result = $alipaySevice->check($arr)) { 439 + $result = $alipaySevice->check($arr);
  440 + cache('notify', $result);
  441 + if ($result) {
439 Db::name('user')->where(['id' => 10])->setInc('balance', 1); 442 Db::name('user')->where(['id' => 10])->setInc('balance', 1);
440 } 443 }
441 } 444 }