mirror of
https://github.com/DrizzleTime/Foxel.git
synced 2026-05-12 02:20:28 +08:00
13 lines
382 B
C#
13 lines
382 B
C#
namespace Foxel.Models;
|
|
|
|
public record PaginatedResult<T> : BaseResult<List<T>>
|
|
{
|
|
|
|
|
|
public int Page { get; set; } = 1;
|
|
public int PageSize { get; set; } = 10;
|
|
public int TotalCount { get; set; }
|
|
public int TotalPages => (int)Math.Ceiling(TotalCount / (double)PageSize);
|
|
public bool HasPreviousPage => Page > 1;
|
|
public bool HasNextPage => Page < TotalPages;
|
|
} |