This commit is contained in:
22
BimAI.Application/DTOModels/AuthDto.cs
Normal file
22
BimAI.Application/DTOModels/AuthDto.cs
Normal file
@@ -0,0 +1,22 @@
|
||||
namespace BimAI.Application.DTOModels;
|
||||
|
||||
public class GoogleAuthRequest
|
||||
{
|
||||
public string? IdToken { get; set; }
|
||||
}
|
||||
|
||||
public class GoogleAuthResponse
|
||||
{
|
||||
public bool Success { get; set; }
|
||||
public string? Token { get; set; }
|
||||
public UserDto? User { get; set; }
|
||||
public string? Error { get; set; }
|
||||
}
|
||||
|
||||
public class UserDto {
|
||||
public Guid Id { get; set; }
|
||||
public string Email { get; set; } = default!;
|
||||
public string FullName { get; set; } = default!;
|
||||
public bool IsActive { get; set; }
|
||||
public DateTime? LastLoginAt { get; set; }
|
||||
}
|
||||
12
BimAI.Application/DTOModels/Common/PagedResult.cs
Normal file
12
BimAI.Application/DTOModels/Common/PagedResult.cs
Normal file
@@ -0,0 +1,12 @@
|
||||
namespace BimAI.Application.DTOModels.Common;
|
||||
|
||||
public class PagedResult<T>
|
||||
{
|
||||
public List<T> Items { get; set; } = new();
|
||||
public int TotalCount { get; set; }
|
||||
public int PageSize { get; set; }
|
||||
public int Page { get; set; }
|
||||
public int TotalPages => (int)Math.Ceiling(TotalCount / (double)PageSize);
|
||||
public bool HasPreviousPage => Page > 1;
|
||||
public bool HasNextPage => Page < TotalPages;
|
||||
}
|
||||
22
BimAI.Application/DTOModels/ProductDto.cs
Normal file
22
BimAI.Application/DTOModels/ProductDto.cs
Normal file
@@ -0,0 +1,22 @@
|
||||
namespace BimAI.Application.DTOModels;
|
||||
|
||||
public class ProductDto
|
||||
{
|
||||
public Guid Id { get; set; }
|
||||
public string Name { get; set; } = string.Empty;
|
||||
public string Code { get; set; } = string.Empty;
|
||||
public string Ean { get; set; } = string.Empty;
|
||||
public string StockAddresses { get; set; } = string.Empty;
|
||||
public DateTime CreatedAt { get; set; }
|
||||
public DateTime UpdatedAt { get; set; }
|
||||
}
|
||||
|
||||
public class ProductFilterRequest
|
||||
{
|
||||
public string? Search { get; set; }
|
||||
public string? Name { get; set; }
|
||||
public string? Code { get; set; }
|
||||
public string? Ean { get; set; }
|
||||
public int Page { get; set; } = 1;
|
||||
public int PageSize { get; set; } = 20;
|
||||
}
|
||||
Reference in New Issue
Block a user