Added static filters

This commit is contained in:
Michael Buchoff
2024-05-27 16:11:10 -04:00
parent b73f748dba
commit 709e3d6fae
6 changed files with 37 additions and 6 deletions

View File

@@ -54,6 +54,13 @@ namespace SieveUnitTests.Services
return result;
}
public static IQueryable<IPost> HasInTitleStatic(IQueryable<Post> source, string op, string[] values)
{
var result = source.Where(p => p.Title.Contains(values[0]));
return result;
}
public IQueryable<IComment> IsNew(IQueryable<IComment> source, string op, string[] values)
{
var result = source.Where(c => c.DateCreated > DateTimeOffset.UtcNow.AddDays(-2));