/** * 帐号解冻。 * @param int $user_id 二手房用户ID。 * @param int $amount 消费金额 * @param int $proid 房源ID * @param string $app 引用的业务。可能值:JP,ZF,AJK * @param int $sn 流水号 * @param string $note 备注信息 * @param bool $newFrozen 是否使用新的扣费程序 * @param bool|string $requestId 是否使用外部requestId * @return string $sn */ public static function cancel_frozen($user_id, $amount, $proid, $app, $sn, $note = '', $newFrozen = false, $requestId = false) { $ret = FALSE; // 新扣费程序 if ($newFrozen) { $info = Bll_Service_Payment::bidUnfreeze($app, array('userId' => $user_id, 'reqId' => $requestId ? $requestId : self::get_reqid($proid, $app), 'amount' => (int) ($amount * 100), 'frozenSN' => $sn, 'note' => $note)); return strcasecmp(trim($info['status']), 'ok') == 0 || $info['code'] == 398507; } else { $url_path = 'use'; $params = array('userId' => $user_id, 'reqId' => $requestId ? $requestId : self::get_reqid($proid, $app), 'amount' => (int) ($amount * 100), 'frozenSN' => $sn, 'note' => $note); $info = Util_CallAPI::call_internal_exes_api($url_path, 'hz_bid', $params); if ($info['data']['status'] === 'ok') { $ret = $info['data']['data']['sn']; } } return $ret; }