44 lines
774 B
C#
44 lines
774 B
C#
namespace LFlow.Base.Utils;
|
|
|
|
/// <summary>
|
|
/// 返回结果包装 (分页)
|
|
/// </summary>
|
|
/// <typeparam name="T"></typeparam>
|
|
[Serializable]
|
|
public class PagedApiResult<T> : ApiResult<T> where T : class, new()
|
|
{
|
|
public new T? Data
|
|
{
|
|
get; set;
|
|
}
|
|
public int TotalCount
|
|
{
|
|
get; set;
|
|
}
|
|
|
|
public int PageIndex
|
|
{
|
|
get; set;
|
|
}
|
|
|
|
public int PageSize
|
|
{
|
|
get; set;
|
|
}
|
|
|
|
public PagedApiResult()
|
|
{
|
|
}
|
|
|
|
public PagedApiResult(bool success, string message, T data, int totalCount, int pageIndex, int pageSize)
|
|
{
|
|
Success = success;
|
|
Message = message;
|
|
Data = data;
|
|
TotalCount = totalCount;
|
|
PageIndex = pageIndex;
|
|
PageSize = pageSize;
|
|
}
|
|
|
|
}
|