Você não pode selecionar mais de 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.

ErrorResponse.cs 606B

1234567891011121314151617181920212223
  1. using Microsoft.AspNetCore.Mvc.ModelBinding;
  2. namespace BlackRock.Reporting.API.Controllers.Model
  3. {
  4. public class ErrorResponse
  5. {
  6. public IEnumerable<string> Errors { get; set; }
  7. public Enum StatusCode { get; set; }
  8. public ModelStateDictionary Validations { get; set; }
  9. public static ErrorResponse Validation(ModelStateDictionary validations)
  10. {
  11. return new ErrorResponse
  12. {
  13. Validations = validations
  14. };
  15. }
  16. }
  17. // I/O
  18. // Output: DTO : Entity wraper, Agregations
  19. // Input: Query / Form
  20. }