forked from loafle/openapi-generator-original
comment out array of enum test case, fix JS enum partial template
This commit is contained in:
parent
aec2f4e27c
commit
73e6626e15
@ -96,8 +96,20 @@ exports.prototype['{{baseName}}'] = {{#defaultValue}}{{{defaultValue}}}{{/defaul
|
||||
}
|
||||
|
||||
{{/vars}}{{/emitModelMethods}}
|
||||
{{#vars}}{{#isEnum}}{{>partial_model_inner_enum}}{{/isEnum}}{{#items.isEnum}}{{#items}}
|
||||
{{>partial_model_inner_enum}}{{/items}}*/{{/items.isEnum}}{{/vars}}
|
||||
{{#vars}}
|
||||
{{#isEnum}}
|
||||
{{^isContainer}}
|
||||
{{>partial_model_inner_enum}}
|
||||
{{/isContainer}}
|
||||
{{/isEnum}}
|
||||
{{#items.isEnum}}
|
||||
{{#items}}
|
||||
{{^isContainer}}
|
||||
{{>partial_model_inner_enum}}
|
||||
{{/isContainer}}
|
||||
{{/items}}
|
||||
{{/items.isEnum}}
|
||||
{{/vars}}
|
||||
|
||||
return exports;
|
||||
{{/model}}{{/models}}}));
|
||||
|
@ -1101,13 +1101,15 @@ definitions:
|
||||
type: array
|
||||
items:
|
||||
$ref: '#/definitions/ReadOnlyFirst'
|
||||
array_of_enum:
|
||||
type: array
|
||||
items:
|
||||
type: string
|
||||
enum:
|
||||
- UPPER
|
||||
- lower
|
||||
# commented out the below test case for array of enum for the time being
|
||||
# as not all language can handle it
|
||||
#array_of_enum:
|
||||
# type: array
|
||||
# items:
|
||||
# type: string
|
||||
# enum:
|
||||
# - UPPER
|
||||
# - lower
|
||||
NumberOnly:
|
||||
type: object
|
||||
properties:
|
||||
|
@ -6,7 +6,7 @@ This SDK is automatically generated by the [Swagger Codegen](https://github.com/
|
||||
|
||||
- API version: 1.0.0 ' \" =end
|
||||
- Package version: 1.0.0 =end
|
||||
- Build date: 2016-06-28T23:09:17.545+08:00
|
||||
- Build date: 2016-06-29T21:40:05.384+08:00
|
||||
- Build package: class io.swagger.codegen.languages.JavascriptClientCodegen
|
||||
|
||||
## Installation
|
||||
@ -72,7 +72,7 @@ api.testCodeInjectEnd(opts, callback);
|
||||
|
||||
## Documentation for API Endpoints
|
||||
|
||||
All URIs are relative to *https://petstore.swagger.io */ ' " =end/v2 */ ' " =end*
|
||||
All URIs are relative to *https://petstore.swagger.io ' \" =end/v2 ' \" =end*
|
||||
|
||||
Class | Method | HTTP request | Description
|
||||
------------ | ------------- | ------------- | -------------
|
||||
|
@ -1,6 +1,6 @@
|
||||
# SwaggerPetstoreEnd.FakeApi
|
||||
|
||||
All URIs are relative to *https://petstore.swagger.io */ ' " =end/v2 */ ' " =end*
|
||||
All URIs are relative to *https://petstore.swagger.io ' \" =end/v2 ' \" =end*
|
||||
|
||||
Method | HTTP request | Description
|
||||
------------- | ------------- | -------------
|
||||
|
@ -55,9 +55,9 @@
|
||||
/**
|
||||
* The base URL against which to resolve every API call's (relative) path.
|
||||
* @type {String}
|
||||
* @default https://petstore.swagger.io */ ' " =end/v2 */ ' " =end
|
||||
* @default https://petstore.swagger.io ' \" =end/v2 ' \" =end
|
||||
*/
|
||||
this.basePath = 'https://petstore.swagger.io */ ' " =end/v2 */ ' " =end'.replace(/\/+$/, '');
|
||||
this.basePath = 'https://petstore.swagger.io ' \" =end/v2 ' \" =end'.replace(/\/+$/, '');
|
||||
|
||||
/**
|
||||
* The authentication methods to be included for all API calls.
|
||||
|
@ -86,7 +86,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
return exports;
|
||||
}));
|
||||
|
||||
|
@ -6,7 +6,7 @@ This SDK is automatically generated by the [Swagger Codegen](https://github.com/
|
||||
|
||||
- API version: 1.0.0
|
||||
- Package version: 1.0.0
|
||||
- Build date: 2016-06-28T23:09:39.810+08:00
|
||||
- Build date: 2016-06-29T21:39:55.793+08:00
|
||||
- Build package: class io.swagger.codegen.languages.JavascriptClientCodegen
|
||||
|
||||
## Installation
|
||||
|
@ -6,13 +6,5 @@ Name | Type | Description | Notes
|
||||
**arrayOfString** | **[String]** | | [optional]
|
||||
**arrayArrayOfInteger** | **[[Integer]]** | | [optional]
|
||||
**arrayArrayOfModel** | **[[ReadOnlyFirst]]** | | [optional]
|
||||
**arrayOfEnum** | **[String]** | | [optional]
|
||||
|
||||
|
||||
<a name="[ArrayOfEnumEnum]"></a>
|
||||
## Enum: [ArrayOfEnumEnum]
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
@ -92,7 +92,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
return exports;
|
||||
}));
|
||||
|
||||
|
@ -94,7 +94,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
return exports;
|
||||
}));
|
||||
|
||||
|
@ -81,7 +81,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
return exports;
|
||||
}));
|
||||
|
||||
|
@ -100,7 +100,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
return exports;
|
||||
}));
|
||||
|
||||
|
@ -59,7 +59,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
};
|
||||
|
||||
/**
|
||||
@ -82,9 +81,6 @@
|
||||
if (data.hasOwnProperty('array_array_of_model')) {
|
||||
obj['array_array_of_model'] = ApiClient.convertToType(data['array_array_of_model'], [[ReadOnlyFirst]]);
|
||||
}
|
||||
if (data.hasOwnProperty('array_of_enum')) {
|
||||
obj['array_of_enum'] = ApiClient.convertToType(data['array_of_enum'], ['String']);
|
||||
}
|
||||
}
|
||||
return obj;
|
||||
}
|
||||
@ -101,37 +97,8 @@
|
||||
* @member {Array.<Array.<module:model/ReadOnlyFirst>>} array_array_of_model
|
||||
*/
|
||||
exports.prototype['array_array_of_model'] = undefined;
|
||||
/**
|
||||
* @member {Array.<module:model/ArrayTest.ArrayOfEnumEnum>} array_of_enum
|
||||
*/
|
||||
exports.prototype['array_of_enum'] = undefined;
|
||||
|
||||
|
||||
/**
|
||||
* Allowed values for the <code>array_of_enum</code> property.
|
||||
* @enum {[String]}
|
||||
* @readonly
|
||||
*/
|
||||
exports.[ArrayOfEnumEnum] = {
|
||||
};
|
||||
|
||||
/**
|
||||
* Allowed values for the <code>arrayOfEnum</code> property.
|
||||
* @enum {String}
|
||||
* @readonly
|
||||
*/
|
||||
exports.ArrayOfEnumEnum = {
|
||||
/**
|
||||
* value: "UPPER"
|
||||
* @const
|
||||
*/
|
||||
"UPPER": "UPPER",
|
||||
/**
|
||||
* value: "lower"
|
||||
* @const
|
||||
*/
|
||||
"lower": "lower" };
|
||||
*/
|
||||
|
||||
return exports;
|
||||
}));
|
||||
|
@ -89,7 +89,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
return exports;
|
||||
}));
|
||||
|
||||
|
@ -92,7 +92,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
return exports;
|
||||
}));
|
||||
|
||||
|
@ -89,7 +89,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
return exports;
|
||||
}));
|
||||
|
||||
|
@ -115,6 +115,7 @@
|
||||
* @const
|
||||
*/
|
||||
"lower": "lower" };
|
||||
|
||||
/**
|
||||
* Allowed values for the <code>enum_integer</code> property.
|
||||
* @enum {Integer}
|
||||
@ -131,6 +132,7 @@
|
||||
* @const
|
||||
*/
|
||||
"-1": -1 };
|
||||
|
||||
/**
|
||||
* Allowed values for the <code>enum_number</code> property.
|
||||
* @enum {Number}
|
||||
|
@ -184,7 +184,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
return exports;
|
||||
}));
|
||||
|
||||
|
@ -100,7 +100,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
return exports;
|
||||
}));
|
||||
|
||||
|
@ -93,7 +93,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
return exports;
|
||||
}));
|
||||
|
||||
|
@ -85,7 +85,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
return exports;
|
||||
}));
|
||||
|
||||
|
@ -110,7 +110,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
return exports;
|
||||
}));
|
||||
|
||||
|
@ -92,7 +92,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
return exports;
|
||||
}));
|
||||
|
||||
|
@ -84,7 +84,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
return exports;
|
||||
}));
|
||||
|
||||
|
@ -92,7 +92,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
return exports;
|
||||
}));
|
||||
|
||||
|
@ -141,7 +141,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
return exports;
|
||||
}));
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user