mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-07-31 19:06:34 +08:00
#19641: Fixing exception when displaying all workflows
Work Item: 19641 --HG-- branch : 1.x
This commit is contained in:
parent
dd71ed679b
commit
3c195471d6
@ -85,10 +85,15 @@ namespace Orchard.Workflows.Controllers {
|
||||
break;
|
||||
}
|
||||
|
||||
var results = queries
|
||||
.Skip(pager.GetStartIndex())
|
||||
.Take(pager.PageSize)
|
||||
.ToList();
|
||||
if (pager.GetStartIndex() > 0) {
|
||||
queries = queries.Skip(pager.GetStartIndex());
|
||||
}
|
||||
|
||||
if (pager.PageSize > 0) {
|
||||
queries = queries.Take(pager.PageSize);
|
||||
}
|
||||
|
||||
var results = queries.ToList();
|
||||
|
||||
var model = new AdminIndexViewModel {
|
||||
WorkflowDefinitions = results.Select(x => new WorkflowDefinitionEntry {
|
||||
|
Loading…
Reference in New Issue
Block a user