Browse Source

update

master
DengBiao 1 year ago
parent
commit
3ca9cc72c5
1 changed files with 5 additions and 1 deletions
  1. +5
    -1
      src/applet/app/controllers/AliCallBackController.php

+ 5
- 1
src/applet/app/controllers/AliCallBackController.php View File

@@ -83,18 +83,22 @@ class AliCallBackController extends \Phalcon\Mvc\Controller
break; break;
case "alipay.planet.ecocampus.spi.trade.pay.detail": case "alipay.planet.ecocampus.spi.trade.pay.detail":
//SPI::交易通知 //SPI::交易通知
$this->logger($params, 'alipay.planet.ecocampus.spi.trade.pay.detail', true);
$this->logger(["params" => $params], 'alipay.planet.ecocampus.spi.trade.pay.detail', true);
$biz_content = json_decode($params["biz_content"], true); $biz_content = json_decode($params["biz_content"], true);
$this->logger(["biz_content" => $biz_content], 'alipay.planet.ecocampus.spi.trade.pay.detail', true);
//获取用户身份信息 //获取用户身份信息
$userIdentityId = 0; $userIdentityId = 0;
if (isset($biz_content["buyer_info"])) { if (isset($biz_content["buyer_info"])) {
$userIdentityId = $biz_content["buyer_info"]["roster_code"] ?? 0; //身份id $userIdentityId = $biz_content["buyer_info"]["roster_code"] ?? 0; //身份id
} }
$userIdentity = UserIdentity::findFirst("id = '{$userIdentityId}'"); $userIdentity = UserIdentity::findFirst("id = '{$userIdentityId}'");
$this->logger(["userIdentity1" => $userIdentity], 'alipay.planet.ecocampus.spi.trade.pay.detail', true);
if (empty($userIdentity)) { if (empty($userIdentity)) {
$selfSupportForSchoolInfo = SelfSupportForUserFaceInfo::findFirst("user_id = '{$biz_content["buyer_id"]}'"); $selfSupportForSchoolInfo = SelfSupportForUserFaceInfo::findFirst("user_id = '{$biz_content["buyer_id"]}'");
$this->logger(["selfSupportForSchoolInfo" => $selfSupportForSchoolInfo], 'alipay.planet.ecocampus.spi.trade.pay.detail', true);
if (!$selfSupportForSchoolInfo) { if (!$selfSupportForSchoolInfo) {
$userIdentity = UserIdentity::findFirst("id = '{$selfSupportForSchoolInfo->user_identity_id}'"); $userIdentity = UserIdentity::findFirst("id = '{$selfSupportForSchoolInfo->user_identity_id}'");
$this->logger(["userIdentity2" => $userIdentity], 'alipay.planet.ecocampus.spi.trade.pay.detail', true);
if (empty($userIdentity)) { if (empty($userIdentity)) {
$response = [ $response = [
"code" => "40000", "code" => "40000",


Loading…
Cancel
Save