|
@@ -159,9 +159,10 @@ namespace iiie.WebApiUtils.BusinessManager
|
159
|
159
|
{
|
160
|
160
|
return Execute((db, table) =>
|
161
|
161
|
{
|
162
|
|
- var count = table.Count(predicate);
|
163
|
|
- var results = table.OrderBy(orderBy).Where(GetGlobalSelectPredicateStatic())
|
164
|
|
- .Where(predicate).Skip(page * perPage).Take(perPage).Select(DbToDboGetStatic).ToList();
|
|
162
|
+ var globalPredicate = GetGlobalSelectPredicateStatic();
|
|
163
|
+ var count = table.Where(globalPredicate).Count(predicate);
|
|
164
|
+ var results = table.OrderBy(orderBy).Where(globalPredicate).Where(predicate)
|
|
165
|
+ .Skip(page * perPage).Take(perPage).Select(DbToDboGetStatic).ToList();
|
165
|
166
|
var result = new DboGetMultiple<TDboGet>
|
166
|
167
|
{
|
167
|
168
|
Count = count,
|