forked from loafle/openapi-generator-original
adds default headers
This commit is contained in:
parent
4ed819c4a0
commit
2b24aa8f91
@ -13,6 +13,7 @@ namespace {{package}} {
|
|||||||
{{/description}}
|
{{/description}}
|
||||||
export class {{classname}} {
|
export class {{classname}} {
|
||||||
private basePath = '{{basePath}}';
|
private basePath = '{{basePath}}';
|
||||||
|
public defaultHeaders : any = {};
|
||||||
|
|
||||||
static $inject: string[] = ['$http', '$httpParamSerializer'];
|
static $inject: string[] = ['$http', '$httpParamSerializer'];
|
||||||
|
|
||||||
@ -31,7 +32,7 @@ namespace {{package}} {
|
|||||||
|
|
||||||
{{/pathParams}}
|
{{/pathParams}}
|
||||||
let queryParameters: any = {};
|
let queryParameters: any = {};
|
||||||
let headerParams: any = {};
|
let headerParams: any = this.defaultHeaders;
|
||||||
{{#hasFormParams}}
|
{{#hasFormParams}}
|
||||||
let formParams: any = {};
|
let formParams: any = {};
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user