-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
9 changed files
with
123 additions
and
85 deletions.
There are no files selected for viewing
16 changes: 13 additions & 3 deletions
16
...etCore.Mvc.UI.Theme.Pure/Themes/Pure/Components/BottomNavbar/BottomNavbarViewComponent.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,22 @@ | ||
using Microsoft.AspNetCore.Mvc; | ||
using System.Threading.Tasks; | ||
using Microsoft.AspNetCore.Mvc; | ||
using Volo.Abp.AspNetCore.Mvc; | ||
using Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Toolbars; | ||
|
||
namespace Dignite.Abp.AspNetCore.Mvc.UI.Theme.Pure.Components.BottomNavbar; | ||
|
||
public class BottomNavbarViewComponent : AbpViewComponent | ||
{ | ||
public virtual IViewComponentResult Invoke() | ||
protected IToolbarManager ToolbarManager { get; } | ||
|
||
public BottomNavbarViewComponent(IToolbarManager toolbarManager) | ||
{ | ||
ToolbarManager = toolbarManager; | ||
} | ||
|
||
public virtual async Task<IViewComponentResult> InvokeAsync() | ||
{ | ||
return View(); | ||
var toolbar = await ToolbarManager.GetAsync(PureToolbars.BottomNavigationBar); | ||
return View(toolbar); | ||
} | ||
} |
16 changes: 12 additions & 4 deletions
16
...gnite.Abp.AspNetCore.Mvc.UI.Theme.Pure/Themes/Pure/Components/BottomNavbar/Default.cshtml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,12 @@ | ||
@using Dignite.Abp.AspNetCore.Mvc.UI.Theme.Pure.Components.BottomToolbar | ||
<nav class="bottom-navbar"> | ||
@(await Component.InvokeAsync<BottomToolbarViewComponent>()) | ||
</nav> | ||
@using Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Toolbars | ||
@model Toolbar | ||
|
||
@if (Model.Items.Any()) | ||
{ | ||
<nav class="bottom-navbar"> | ||
@foreach (var toolbarItem in Model.Items.OrderBy(i => i.Order)) | ||
{ | ||
@(await Component.InvokeAsync(toolbarItem.ComponentType)) | ||
} | ||
</nav> | ||
} |
22 changes: 0 additions & 22 deletions
22
...Core.Mvc.UI.Theme.Pure/Themes/Pure/Components/BottomToolbar/BottomToolbarViewComponent.cs
This file was deleted.
Oops, something went wrong.
6 changes: 0 additions & 6 deletions
6
...nite.Abp.AspNetCore.Mvc.UI.Theme.Pure/Themes/Pure/Components/BottomToolbar/Default.cshtml
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
18 changes: 15 additions & 3 deletions
18
...AspNetCore.Mvc.UI.Theme.Pure/Themes/Pure/Components/PageFooter/PageFooterViewComponent.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,24 @@ | ||
using Microsoft.AspNetCore.Mvc; | ||
using System.Threading.Tasks; | ||
using Microsoft.AspNetCore.Mvc; | ||
using Volo.Abp.AspNetCore.Mvc; | ||
using Volo.Abp.UI.Navigation; | ||
|
||
namespace Dignite.Abp.AspNetCore.Mvc.UI.Theme.Pure.Components.PageFooter; | ||
|
||
public class PageFooterViewComponent : AbpViewComponent | ||
{ | ||
public virtual IViewComponentResult Invoke() | ||
private readonly IMenuManager _menuManager; | ||
|
||
public PageFooterViewComponent(IMenuManager menuManager) | ||
{ | ||
_menuManager = menuManager; | ||
} | ||
|
||
|
||
|
||
public virtual async Task<IViewComponentResult> InvokeAsync() | ||
{ | ||
return View(); | ||
var menu = await _menuManager.GetAsync(PureMenus.SiteMap); | ||
return View(menu); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters