forked from loafle/openapi-generator-original
merged
This commit is contained in:
commit
2f6bf95fa2
@ -30,7 +30,6 @@ class {{classname}} {
|
||||
/**
|
||||
* {{nickname}}
|
||||
* {{summary}}
|
||||
*
|
||||
{{#allParams}}
|
||||
* @param {{dataType}} ${{paramName}} {{description}} ({{^optional}}required{{/optional}}{{#optional}}optional{{/optional}})
|
||||
{{/allParams}}
|
||||
@ -67,10 +66,20 @@ class {{classname}} {
|
||||
}
|
||||
{{/pathParams}}
|
||||
|
||||
//make the API Call
|
||||
// Generate form params
|
||||
if (! isset($body)) {
|
||||
$body = array();
|
||||
}
|
||||
{{#formParams}}
|
||||
if(${{paramName}} != null) {
|
||||
$body['{{paramName}}'] = ${{paramName}};
|
||||
}
|
||||
{{/formParams}}
|
||||
if (empty($body)) {
|
||||
$body = null;
|
||||
}
|
||||
|
||||
// Make the API Call
|
||||
$response = $this->apiClient->callAPI($resourcePath, $method,
|
||||
$queryParams, $body,
|
||||
$headerParams);
|
||||
|
Loading…
x
Reference in New Issue
Block a user