Permalink
Browse files

Update samples to include subfolder examples for both normal and area…

… feature folders
  • Loading branch information...
KenBonny committed Jul 18, 2018
1 parent d4359d6 commit 682c5b1eaf9b7ed1da8a96ea97734e2c972e4472
@@ -0,0 +1,9 @@
@model Type
@{
Layout = "_Layout";
}
<div>
Main content rendered by <b>@Model.FullName</b>
</div>
@@ -0,0 +1,7 @@
@{
Layout = "_Layout";
}
<div>
Main component rendered by Area Administration::SubFolder::SubFolderController::Index
</div>
@@ -0,0 +1,14 @@
using Microsoft.AspNetCore.Mvc;
namespace WebApplication.Areas.Administration.Features.Test.SubFolder
{
[Area("Administration")]
public class SubFolderController : Controller
{
[HttpGet]
public IActionResult Index()
{
return View();
}
}
}
@@ -0,0 +1,14 @@
using Microsoft.AspNetCore.Mvc;
namespace WebApplication.Areas.Administration.Features.Test
{
[Area("Administration")]
public class TestController : Controller
{
[HttpGet]
public IActionResult Index()
{
return View("Index", typeof(TestController));
}
}
}
@@ -0,0 +1,7 @@
@{
Layout = "_Layout";
}
<div>
Main content rendered by FEATURE:Foo:SubFoo:SubFooController::SubFoo
</div>
@@ -0,0 +1,13 @@
using Microsoft.AspNetCore.Mvc;
namespace WebApplication.Features.Foo.SubFoo
{
public class SubFooController : Controller
{
[HttpGet]
public IActionResult SubFoo()
{
return View();
}
}
}
@@ -2,18 +2,37 @@
<html>
<head>
<meta name="viewport" content="width=device-width" />
<title>@ViewBag.Title</title>
<meta name="viewport" content="width=device-width"/>
<title>@ViewBag.Title</title>
</head>
<body>
@await Component.InvokeAsync("MainMenu")
@RenderBody()
<footer>
Footer rendered by _Layout<br />
<a href="/">Home</a><br/>
<a href="/Foo/Home">Feature: Foo</a><br/>
<a href="/Bar/Home">Feature: Bar</a><br />
<a href="/Administration/Overview">Area Administration: Overview</a>
</footer>
@await Component.InvokeAsync("MainMenu")
@RenderBody()
<footer>
Footer rendered by _Layout
<ul>
<li>
<a href="/">Home</a><br/>
</li>
<li>
<a href="/Foo/Home">Feature: Foo</a><br/>
</li>
<li>
<a href="/SubFoo/SubFoo">Feature: Sub Foo</a><br/>
</li>
<li>
<a href="/Bar/Home">Feature: Bar</a><br/>
</li>
<li>
<a href="/Administration/Overview">Area Administration: Overview</a><br/>
</li>
<li>
<a href="/Administration/Test">Area Administration: Test</a>
</li>
<li>
<a href="/Administration/SubFolder">Area Administration: SubFolder</a>
</li>
</ul>
</footer>
</body>
</html>
</html>

0 comments on commit 682c5b1

Please sign in to comment.