Browse Source

generate-proxy multiple angular model fix

pull/4701/head
Erol Arkat 6 years ago
parent
commit
75aa35f959
  1. 13
      framework/src/Volo.Abp.Cli.Core/Volo/Abp/Cli/Commands/GenerateProxyCommand.cs

13
framework/src/Volo.Abp.Cli.Core/Volo/Abp/Cli/Commands/GenerateProxyCommand.cs

@ -294,7 +294,7 @@ namespace Volo.Abp.Cli.Commands
if (firstType == "List" && !File.Exists(secondTypeModelPath))
{
secondType = "any";
}
}
serviceFileText.AppendLine(
firstType == "List"
@ -322,13 +322,15 @@ namespace Volo.Abp.Cli.Commands
"String" => "string",
"IActionResult" => "void",
"ActionResult" => "void",
"Int64" => "number",
"Int32" => "number",
_ => type
};
};
serviceFileText.AppendLine(
$" {actionName}({parametersText}): Observable<{type}> {{");
if (type != "void" && type != "string")
if (type != "void" && type != "string" && type != "number")
{
secondTypeList.Add(type);
}
@ -503,6 +505,11 @@ namespace Volo.Abp.Cli.Commands
var path = output + $"{outputPrefix}/{rootPath}/{controllerPathName}/models/{typeModelName}";
if (File.Exists(path))
{
return null;
}
var modelFileText = new StringBuilder();
var baseType = (string)type["baseType"];

Loading…
Cancel
Save