diff --git a/Sieve/Models/SieveModel.cs b/Sieve/Models/SieveModel.cs index 9e013d1..9483d45 100644 --- a/Sieve/Models/SieveModel.cs +++ b/Sieve/Models/SieveModel.cs @@ -1,18 +1,22 @@ using System.Collections.Generic; using System.ComponentModel.DataAnnotations; +using System.Runtime.Serialization; namespace Sieve.Models { + [DataContract] public class SieveModel : ISieveModel { + [DataMember] public string Filters { get; set; } + [DataMember] public string Sorts { get; set; } - [Range(1, int.MaxValue)] + [DataMember, Range(1, int.MaxValue)] public int? Page { get; set; } - [Range(1, int.MaxValue)] + [DataMember, Range(1, int.MaxValue)] public int? PageSize { get; set; } public List FiltersParsed diff --git a/Sieve/Sieve.csproj b/Sieve/Sieve.csproj index fc4601e..a2b336c 100644 --- a/Sieve/Sieve.csproj +++ b/Sieve/Sieve.csproj @@ -2,7 +2,7 @@ netstandard2.0 - 2.1.2 + 2.1.3 Sieve is a simple, clean, and extensible framework for .NET Core that adds sorting, filtering, and pagination functionality out of the box. Most common use case would be for serving ASP.NET Core GET queries. Documentation available on GitHub: https://github.com/Biarity/Sieve/ Copyright 2018 @@ -10,7 +10,7 @@ https://github.com/Biarity/Sieve https://emojipedia-us.s3.amazonaws.com/thumbs/240/twitter/120/alembic_2697.png - Fix issue #28 + Fix issue #30 true true Biarity