|
@@ -78,9 +78,10 @@ class BaseClient
|
|
$secretKey = $this->app->getKey($endpoint);
|
|
$secretKey = $this->app->getKey($endpoint);
|
|
@file_put_contents("quanju.txt", $secretKey . "-参数解析3\r\n", 8);
|
|
@file_put_contents("quanju.txt", $secretKey . "-参数解析3\r\n", 8);
|
|
$encryptMethod = Support\get_encrypt_method(Support\Arr::get($params, 'sign_type', 'MD5'), $secretKey);
|
|
$encryptMethod = Support\get_encrypt_method(Support\Arr::get($params, 'sign_type', 'MD5'), $secretKey);
|
|
- @file_put_contents("quanju.txt", json_encode($encryptMethod) . "-参数解析4\r\n", 8);
|
|
+ @file_put_contents("quanju.txt", $encryptMethod . "-参数解析4\r\n", 8);
|
|
$params['sign'] = Support\generate_sign($params, $secretKey, $encryptMethod);
|
|
$params['sign'] = Support\generate_sign($params, $secretKey, $encryptMethod);
|
|
@file_put_contents("quanju.txt", $params['sign'] . "-参数解析5\r\n", 8);
|
|
@file_put_contents("quanju.txt", $params['sign'] . "-参数解析5\r\n", 8);
|
|
|
|
+ @file_put_contents("quanju.txt", json_encode($params) . "-参数解析6\r\n", 8);
|
|
$options = array_merge([
|
|
$options = array_merge([
|
|
'body' => Support\XML::build($params),
|
|
'body' => Support\XML::build($params),
|
|
], $options);
|
|
], $options);
|
|
@@ -88,7 +89,8 @@ class BaseClient
|
|
$this->pushMiddleware($this->logMiddleware(), 'log');
|
|
$this->pushMiddleware($this->logMiddleware(), 'log');
|
|
|
|
|
|
$response = $this->performRequest($endpoint, $method, $options);
|
|
$response = $this->performRequest($endpoint, $method, $options);
|
|
-
|
|
+ $a=$returnResponse ? $response : $this->castResponseToType($response, $this->app->config->get('response_type'));
|
|
|
|
+ @file_put_contents("quanju.txt", json_encode($a) . "-参数解析7\r\n", 8);
|
|
return $returnResponse ? $response : $this->castResponseToType($response, $this->app->config->get('response_type'));
|
|
return $returnResponse ? $response : $this->castResponseToType($response, $this->app->config->get('response_type'));
|
|
}
|
|
}
|
|
|
|
|