using Sieve.Services; namespace SieveUnitTests.Entities { public class SieveConfigurationForPost : ISieveConfiguration { public static void ConfigureStatic(SievePropertyMapper mapper) { mapper .Property(p => p.Id) .CanSort(); mapper.Property(p => p.ThisHasNoAttributeButIsAccessible) .CanSort() .CanFilter() .HasName("shortname"); mapper.Property(p => p.TopComment.Text) .CanFilter(); mapper.Property(p => p.TopComment.Id) .CanSort(); mapper.Property(p => p.OnlySortableViaFluentApi) .CanSort(); mapper.Property(p => p.TopComment.Text) .CanFilter() .HasName("topc"); mapper.Property(p => p.FeaturedComment.Text) .CanFilter() .HasName("featc"); mapper .Property(p => p.DateCreated) .CanSort() .HasName("CreateDate"); mapper .Property(post => post.DeletedBy) .CanSort() .HasName("DeletedBy"); mapper .Property(post => post.UpdatedBy) .CanFilter() .HasName("UpdatedBy"); } public void Configure(SievePropertyMapper mapper) { ConfigureStatic(mapper); } } }