Add customer communication system
This commit is contained in:
12
LittleShop/DTOs/PagedResultDto.cs
Normal file
12
LittleShop/DTOs/PagedResultDto.cs
Normal file
@@ -0,0 +1,12 @@
|
||||
namespace LittleShop.DTOs;
|
||||
|
||||
public class PagedResult<T>
|
||||
{
|
||||
public List<T> Items { get; set; } = new();
|
||||
public int TotalCount { get; set; }
|
||||
public int PageNumber { get; set; }
|
||||
public int PageSize { get; set; }
|
||||
public int TotalPages => (int)Math.Ceiling((double)TotalCount / PageSize);
|
||||
public bool HasPrevious => PageNumber > 1;
|
||||
public bool HasNext => PageNumber < TotalPages;
|
||||
}
|
||||
Reference in New Issue
Block a user