44 lines
1.3 KiB
Plaintext
44 lines
1.3 KiB
Plaintext
@using System.Web.Http.Description
|
|
@using System.Collections.ObjectModel
|
|
@using System.Linq
|
|
@model Collection<ApiDescription>
|
|
|
|
@{
|
|
ViewBag.Title = "ASP.NET Web API Help Page";
|
|
|
|
// Group APIs by controller
|
|
ILookup<string, ApiDescription> apiGroups = Model.ToLookup(api => api.ActionDescriptor.ControllerDescriptor.ControllerName);
|
|
}
|
|
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<title>@ViewBag.Title</title>
|
|
<link type="text/css" href="@ViewBag.HelpRoute/HelpPage_css" rel="stylesheet" />
|
|
</head>
|
|
<body>
|
|
<header class="help-page">
|
|
<div class="content-wrapper">
|
|
<div class="float-left">
|
|
<h1>@ViewBag.Title</h1>
|
|
</div>
|
|
</div>
|
|
</header>
|
|
<div id="body" class="help-page">
|
|
<section class="featured">
|
|
<div class="content-wrapper">
|
|
<h2>Introduction</h2>
|
|
<p>
|
|
Provide a general description of your APIs here.
|
|
</p>
|
|
</div>
|
|
</section>
|
|
<section class="content-wrapper main-content clear-fix">
|
|
@foreach (IGrouping<string, ApiDescription> controllerGroup in apiGroups)
|
|
{
|
|
@Include("ApiGroup.cshtml", controllerGroup, typeof (IGrouping<string, ApiDescription>))
|
|
}
|
|
</section>
|
|
</div>
|
|
</body>
|
|
</html>
|