mirror of
https://github.com/foss42/apidash.git
synced 2025-06-01 23:45:19 +08:00
[ISSUE 375] - php curl options setup
This commit is contained in:
@ -154,17 +154,15 @@ echo $response;
|
|||||||
result += templateHeader.render({'headers': headers});
|
result += templateHeader.render({'headers': headers});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// renders the initial request init function call
|
||||||
result += kStringRequestInit;
|
result += kStringRequestInit;
|
||||||
|
|
||||||
//renders the request temlate
|
//renders the request temlate
|
||||||
var templateRequest = jj.Template(kTemplateRequest);
|
var templateRequestOptsInit = jj.Template(kTemplateRequestOptsInit);
|
||||||
result += templateRequest.render({
|
result += templateRequestOptsInit.render({'method': requestModel.method.name});
|
||||||
"authority": uri.authority,
|
if (headers.isNotEmpty) {
|
||||||
"method": httpMethod(method.name.toUpperCase()),
|
result += kStringHeaderOpt;
|
||||||
"path": uri.path,
|
}
|
||||||
"queryParamsStr": hasQuery ? "queryParamsStr" : "",
|
|
||||||
});
|
|
||||||
|
|
||||||
if (hasBody || requestModel.hasFormData) {
|
if (hasBody || requestModel.hasFormData) {
|
||||||
result += kStringRequestBodyOpt;
|
result += kStringRequestBodyOpt;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user