mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-09-22 20:13:50 +08:00
Fixing that container pager shape was not displayed
--HG-- branch : 1.x extra : rebase_source : 80295bb54f53c656d8da9113f4dfcb43d2040fe9
This commit is contained in:
@@ -68,17 +68,20 @@ namespace Orchard.Core.Containers.Drivers {
|
||||
? pager.PageSize
|
||||
: part.PageSize;
|
||||
|
||||
// var pagerShape = _shapeFactory.Pager(pager).TotalItemCount(query.Count());
|
||||
var pagerShape = shapeHelper.Pager(pager).TotalItemCount(query.Count());
|
||||
|
||||
var startIndex = part.Paginated ? pager.GetStartIndex() : 0;
|
||||
var pageOfItems = query.Slice(startIndex, pager.PageSize).ToList();
|
||||
|
||||
var list = _shapeFactory.List();
|
||||
list.AddRange(pageOfItems.Select(item => _contentManager.BuildDisplay(item, "Summary")));
|
||||
list.Classes.Add("content-items");
|
||||
list.Classes.Add("list-items");
|
||||
var listShape = shapeHelper.List();
|
||||
listShape.AddRange(pageOfItems.Select(item => _contentManager.BuildDisplay(item, "Summary")));
|
||||
listShape.Classes.Add("content-items");
|
||||
listShape.Classes.Add("list-items");
|
||||
|
||||
return list;
|
||||
return shapeHelper.Parts_Container_Contained(
|
||||
List: listShape,
|
||||
Pager: pagerShape
|
||||
);
|
||||
}),
|
||||
ContentShape("Parts_Container_Contained_Summary",
|
||||
() => shapeHelper.Parts_Container_Contained_Summary(ContentPart: part)),
|
||||
|
@@ -0,0 +1,3 @@
|
||||
@Display(Model.List)
|
||||
|
||||
@Display(Model.Pager)
|
@@ -490,6 +490,9 @@
|
||||
<ItemGroup>
|
||||
<Content Include="Shapes\Views\ErrorPage.cshtml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Containers\Views\Parts.Container.Contained.cshtml" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
|
||||
<Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v10.0\WebApplications\Microsoft.WebApplication.targets" />
|
||||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||
|
@@ -18,6 +18,7 @@
|
||||
<OldToolsVersion>3.5</OldToolsVersion>
|
||||
<UpgradeBackupLocation />
|
||||
<TargetFrameworkProfile />
|
||||
<UseIISExpress>false</UseIISExpress>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
@@ -83,7 +84,9 @@
|
||||
</Content>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Content Include="Placement.info" />
|
||||
<Content Include="Placement.info">
|
||||
<SubType>Designer</SubType>
|
||||
</Content>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Content Include="Views\Admin\List.cshtml" />
|
||||
|
Reference in New Issue
Block a user