Add JsonPropertyName attributes to DTO properties for serialization

This commit is contained in:
2025-11-13 16:19:14 +00:00
parent 10017850f8
commit 0bbf821489
59 changed files with 915 additions and 397 deletions

View File

@@ -23,12 +23,18 @@
// Copyright © 2003-2021 Natalia Portillo
*******************************************************************************/
using System.Text.Json.Serialization;
namespace Marechai.Data.Dtos;
public class GpuByMachineDto : BaseDto<long>
{
public int GpuId { get; set; }
public int MachineId { get; set; }
[JsonPropertyName("gpu_id")]
public int GpuId { get; set; }
[JsonPropertyName("machine_id")]
public int MachineId { get; set; }
[JsonPropertyName("company")]
public string CompanyName { get; set; }
public string Name { get; set; }
[JsonPropertyName("name")]
public string Name { get; set; }
}