From 8701dcdb7a3fa91ad88351e5242548d8a53b8d92 Mon Sep 17 00:00:00 2001 From: Tino Fuhrmann Date: Wed, 12 Apr 2017 19:00:56 +0200 Subject: [PATCH 1/2] Fixed classFilename in typescript-angular and recreated samples --- .../src/main/resources/typescript-angular/apis.mustache | 6 +++--- .../src/main/resources/typescript-angular/models.mustache | 2 +- .../petstore-security-test/typescript-angular/api/api.ts | 4 ++-- samples/client/petstore/typescript-angular/api/api.ts | 8 ++++---- 4 files changed, 10 insertions(+), 10 deletions(-) diff --git a/modules/swagger-codegen/src/main/resources/typescript-angular/apis.mustache b/modules/swagger-codegen/src/main/resources/typescript-angular/apis.mustache index 85522cf6c58..fc1bce9ae8d 100644 --- a/modules/swagger-codegen/src/main/resources/typescript-angular/apis.mustache +++ b/modules/swagger-codegen/src/main/resources/typescript-angular/apis.mustache @@ -1,9 +1,9 @@ {{#apiInfo}} {{#apis}} {{#operations}} -export * from './{{ classname }}'; -import { {{ classname }} } from './{{ classname }}'; +export * from './{{ classFilename }}'; +import { {{ classname }} } from './{{ classFilename }}'; {{/operations}} {{/apis}} -export const APIS = [ {{#apis}}{{#operations}}{{ classname }}, {{/operations}}{{/apis}}]; +export const APIS = [{{#apis}}{{#operations}}{{ classname }}, {{/operations}}{{/apis}}]; {{/apiInfo}} \ No newline at end of file diff --git a/modules/swagger-codegen/src/main/resources/typescript-angular/models.mustache b/modules/swagger-codegen/src/main/resources/typescript-angular/models.mustache index ace053bd55b..02a39c248c4 100644 --- a/modules/swagger-codegen/src/main/resources/typescript-angular/models.mustache +++ b/modules/swagger-codegen/src/main/resources/typescript-angular/models.mustache @@ -1,5 +1,5 @@ {{#models}} {{#model}} -export * from './{{{ classname }}}'; +export * from './{{{ classFilename }}}'; {{/model}} {{/models}} diff --git a/samples/client/petstore-security-test/typescript-angular/api/api.ts b/samples/client/petstore-security-test/typescript-angular/api/api.ts index 940c85b890d..c8fc0cc936d 100644 --- a/samples/client/petstore-security-test/typescript-angular/api/api.ts +++ b/samples/client/petstore-security-test/typescript-angular/api/api.ts @@ -1,3 +1,3 @@ export * from './FakeApi'; -import { FakeApi } from './FakeApi'; -export const APIS = [ FakeApi, ]; +import { FakeApi } from './FakeApi'; +export const APIS = [FakeApi, ]; diff --git a/samples/client/petstore/typescript-angular/api/api.ts b/samples/client/petstore/typescript-angular/api/api.ts index 0d1e9f047fd..02423026327 100644 --- a/samples/client/petstore/typescript-angular/api/api.ts +++ b/samples/client/petstore/typescript-angular/api/api.ts @@ -1,7 +1,7 @@ export * from './PetApi'; -import { PetApi } from './PetApi'; +import { PetApi } from './PetApi'; export * from './StoreApi'; -import { StoreApi } from './StoreApi'; +import { StoreApi } from './StoreApi'; export * from './UserApi'; -import { UserApi } from './UserApi'; -export const APIS = [ PetApi, StoreApi, UserApi, ]; +import { UserApi } from './UserApi'; +export const APIS = [PetApi, StoreApi, UserApi, ]; From 91910b47840af60e0f475964a4fac7f628b17eb7 Mon Sep 17 00:00:00 2001 From: Tino Fuhrmann Date: Thu, 13 Apr 2017 20:12:27 +0200 Subject: [PATCH 2/2] Changed classname to classFilename in ts-angular2/models.mustache Also recreated ts-angular2 sample --- .../src/main/resources/typescript-angular2/models.mustache | 2 +- samples/client/petstore/typescript-angular2/npm/README.md | 4 ++-- samples/client/petstore/typescript-angular2/npm/package.json | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/modules/swagger-codegen/src/main/resources/typescript-angular2/models.mustache b/modules/swagger-codegen/src/main/resources/typescript-angular2/models.mustache index ace053bd55b..02a39c248c4 100644 --- a/modules/swagger-codegen/src/main/resources/typescript-angular2/models.mustache +++ b/modules/swagger-codegen/src/main/resources/typescript-angular2/models.mustache @@ -1,5 +1,5 @@ {{#models}} {{#model}} -export * from './{{{ classname }}}'; +export * from './{{{ classFilename }}}'; {{/model}} {{/models}} diff --git a/samples/client/petstore/typescript-angular2/npm/README.md b/samples/client/petstore/typescript-angular2/npm/README.md index 9bfa85dc2ec..dc87504299b 100644 --- a/samples/client/petstore/typescript-angular2/npm/README.md +++ b/samples/client/petstore/typescript-angular2/npm/README.md @@ -1,4 +1,4 @@ -## @swagger/angular2-typescript-petstore@0.0.1-SNAPSHOT.201703211709 +## @swagger/angular2-typescript-petstore@0.0.1-SNAPSHOT.201704132011 ### Building @@ -19,7 +19,7 @@ navigate to the folder of your consuming project and run one of next commando's. _published:_ ``` -npm install @swagger/angular2-typescript-petstore@0.0.1-SNAPSHOT.201703211709 --save +npm install @swagger/angular2-typescript-petstore@0.0.1-SNAPSHOT.201704132011 --save ``` _unPublished (not recommended):_ diff --git a/samples/client/petstore/typescript-angular2/npm/package.json b/samples/client/petstore/typescript-angular2/npm/package.json index ae0d67dbafa..b4ea8a079bc 100644 --- a/samples/client/petstore/typescript-angular2/npm/package.json +++ b/samples/client/petstore/typescript-angular2/npm/package.json @@ -1,6 +1,6 @@ { "name": "@swagger/angular2-typescript-petstore", - "version": "0.0.1-SNAPSHOT.201703211709", + "version": "0.0.1-SNAPSHOT.201704132011", "description": "swagger client for @swagger/angular2-typescript-petstore", "author": "Swagger Codegen Contributors", "keywords": [