abp generate-proxy does not create the model properties as set by the [JsonProperty] attribue
- ABP Framework version 4.2.1 (Stable).
- User Interface Angular.
- Database Provider EF Core 5
I'm using vivet/GoogleApi.
When abp generate-proxy generates a TypeScript model of a Dto that has a [JsonProperty] attribute; the output model has the name of the C# property instead of the name in the attribute.
For example, I'm returning: https://github.com/vivet/GoogleApi/blob/bed8a7988feba69bb9037afd597dc08b0a42195e/GoogleApi/Entities/Places/Details/Response/DetailsResult.cs#L23

And what I'm getting in the generated model is:

But the serializer in the ApplicationService is serializing it into the name put in the attribute:

Is there an option to overcome this problem, or am I missing something?
Hi @idreeshaddad,
We will investigate the issue and reply you asap. Thanks.
Resolved by #7819
Angular part has been moved to #7852
Thank you guys for the effort, but unfortunately the problem still exists after updating to 4.3:

As you can see, abp generate-proxy generated a TypeScript model of a Dto that has a [JsonProperty] attribute; the output model has the name of the C# property instead of the name in the attribute!
(JsonProperty)

(Abp generated TypeScript model)

@idreeshaddad Can you try a new project?
Hi @idreeshaddad,
There is a package called @abp/ng.schematics in the package.json file. Please upgrade it to v4.3.0 and try again.
Hi @idreeshaddad,
There is a package called
@abp/ng.schematicsin the package.json file. Please upgrade it to v4.3.0 and try again.
Thank you @armanozak it worked. And for those who might stumble upon this issue: Do not forget to npm install after you change the schematics version, then abp generate-proxy , and enjoy programming.