Skip to content

Commit

Permalink
[Javascript] v1.0.6
Browse files Browse the repository at this point in the history
  • Loading branch information
gideruette committed Sep 6, 2024
1 parent 0a87527 commit 287858f
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
4 changes: 2 additions & 2 deletions TopModel.Generator.Javascript/AngularApiClientGenerator.cs
Original file line number Diff line number Diff line change
Expand Up @@ -207,10 +207,10 @@ private void WriteEndpoint(Endpoint endpoint, FileWriter fw)
}

var needResponseType = returnType == "string" || returnType == "Blob" || returnType == "ArrayBuffer";
var getter = $"this.http.{endpoint.Method.ToLower()}<{returnType}>";
var getter = $"{endpoint.Method.ToLower()}<{returnType}>";
if (needResponseType)
{
getter = $"{endpoint.Method.ToLower()}(`/{fullRoute}`";
getter = $"{endpoint.Method.ToLower()}";
}

fw.Write(2, $@"return {(Config.ApiMode == TargetFramework.ANGULAR_PROMISE ? "lastValueFrom(" : string.Empty)}this.http.{getter}(`/{fullRoute}`");
Expand Down
4 changes: 4 additions & 0 deletions TopModel.Generator.Javascript/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@

## 1.0.6

- [#389](https://github.com/klee-contrib/topmodel/pull/389) - Prise en compte des returnType Blob et ArrayBuffer Hot fix x2

## 1.0.5

- [#389](https://github.com/klee-contrib/topmodel/pull/389) - Prise en compte des returnType Blob et ArrayBuffer Hot fix
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

<PropertyGroup>
<PackageOutputPath>../.nupkg</PackageOutputPath>
<Version>1.0.5</Version>
<Version>1.0.6</Version>
<IncludeSourceRevisionInInformationalVersion>false</IncludeSourceRevisionInInformationalVersion>
<Authors>JabX;gideruette</Authors>
<Description>Générateurs JS/TS pour TopModel</Description>
Expand Down

0 comments on commit 287858f

Please sign in to comment.