mirror of
https://github.com/OpenAPITools/openapi-generator.git
synced 2025-05-12 20:50:55 +00:00
fix object declaration in model
This commit is contained in:
parent
7ca8edb590
commit
b5f0b24bae
@ -26,6 +26,6 @@ fi
|
|||||||
|
|
||||||
# if you've executed sbt assembly previously it will use that instead.
|
# if you've executed sbt assembly previously it will use that instead.
|
||||||
export JAVA_OPTS="${JAVA_OPTS} -XX:MaxPermSize=256M -Xmx1024M -DloggerPath=conf/log4j.properties"
|
export JAVA_OPTS="${JAVA_OPTS} -XX:MaxPermSize=256M -Xmx1024M -DloggerPath=conf/log4j.properties"
|
||||||
ags="$@ generate -i modules/openapi-generator/src/test/resources/2_0/petstore.yaml -l typescript-angular -o samples/client/petstore/typescript-angular-v2/default --additional-properties ngVersion=2"
|
ags="generate -i modules/openapi-generator/src/test/resources/2_0/petstore.yaml -l typescript-angular -o samples/client/petstore/typescript-angular-v2/default --additional-properties ngVersion=2 $@"
|
||||||
|
|
||||||
java $JAVA_OPTS -jar $executable $ags
|
java $JAVA_OPTS -jar $executable $ags
|
||||||
|
@ -176,8 +176,6 @@ public class TypeScriptAngularClientCodegen extends AbstractTypeScriptClientCode
|
|||||||
public String getTypeDeclaration(Schema p) {
|
public String getTypeDeclaration(Schema p) {
|
||||||
if (p instanceof FileSchema) {
|
if (p instanceof FileSchema) {
|
||||||
return "Blob";
|
return "Blob";
|
||||||
} else if (!StringUtils.isEmpty(p.get$ref())) {
|
|
||||||
return "any";
|
|
||||||
} else {
|
} else {
|
||||||
return super.getTypeDeclaration(p);
|
return super.getTypeDeclaration(p);
|
||||||
}
|
}
|
||||||
|
@ -107,8 +107,6 @@ public class TypeScriptFetchClientCodegen extends AbstractTypeScriptClientCodege
|
|||||||
return "any";
|
return "any";
|
||||||
} else if (p instanceof BinarySchema) {
|
} else if (p instanceof BinarySchema) {
|
||||||
return "any";
|
return "any";
|
||||||
} else if (!StringUtils.isEmpty(p.get$ref())) { // model
|
|
||||||
return "any";
|
|
||||||
} else {
|
} else {
|
||||||
return super.getTypeDeclaration(p);
|
return super.getTypeDeclaration(p);
|
||||||
}
|
}
|
||||||
|
@ -156,8 +156,6 @@ public class TypeScriptInversifyClientCodegen extends AbstractTypeScriptClientCo
|
|||||||
public String getTypeDeclaration(Schema p) {
|
public String getTypeDeclaration(Schema p) {
|
||||||
if (p instanceof FileSchema) {
|
if (p instanceof FileSchema) {
|
||||||
return "Blob";
|
return "Blob";
|
||||||
} else if (!StringUtils.isEmpty(p.get$ref())) {
|
|
||||||
return "any";
|
|
||||||
} else {
|
} else {
|
||||||
return super.getTypeDeclaration(p);
|
return super.getTypeDeclaration(p);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user