mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2026-02-09 09:16:41 +08:00
Formatting Orchard.Modules templates
This commit is contained in:
@@ -17,8 +17,8 @@
|
||||
</fieldset>
|
||||
|
||||
if (Model.InstallModules) {
|
||||
<span>@Html.ActionLink(T("Install a module from your computer").ToString(), "AddModule", "PackagingServices", new { area = "Orchard.Packaging", returnUrl = HttpContext.Current.Request.RawUrl }, null)</span>
|
||||
}
|
||||
<span>@Html.ActionLink(T("Install a module from your computer").ToString(), "AddModule", "PackagingServices", new { area = "Orchard.Packaging", returnUrl = HttpContext.Current.Request.RawUrl }, null)</span>
|
||||
}
|
||||
|
||||
if (Model.Modules.Any()) {
|
||||
<ul class="contentItems">
|
||||
@@ -26,7 +26,8 @@
|
||||
<li>@Display.ModuleEntry(Module: module)</li>
|
||||
}
|
||||
</ul>
|
||||
} else {
|
||||
}
|
||||
else {
|
||||
<p>@T("No modules available").ToString()</p>
|
||||
}
|
||||
|
||||
|
||||
@@ -6,34 +6,34 @@
|
||||
}
|
||||
@using (Html.BeginFormAntiForgeryPost()) {
|
||||
if (Model.Modules.Any()) {
|
||||
<ul class="contentItems">
|
||||
@foreach (var moduleEntry in Model.Modules.OrderBy(m => m.Module.Descriptor.Name)) {
|
||||
var module = moduleEntry.Module;
|
||||
var descriptor = module.Descriptor;
|
||||
<ul class="contentItems">
|
||||
@foreach (var moduleEntry in Model.Modules.OrderBy(m => m.Module.Descriptor.Name)) {
|
||||
var module = moduleEntry.Module;
|
||||
var descriptor = module.Descriptor;
|
||||
|
||||
<li>
|
||||
<div class="summary">
|
||||
<div class="properties">
|
||||
<h2>@descriptor.Name<span> - @T("Version: {0}", !string.IsNullOrEmpty(descriptor.Version) ? descriptor.Version : T("1.0").ToString())</span></h2>
|
||||
<li>
|
||||
<div class="summary">
|
||||
<div class="properties">
|
||||
<h2>@descriptor.Name<span> - @T("Version: {0}", !string.IsNullOrEmpty(descriptor.Version) ? descriptor.Version : T("1.0").ToString())</span></h2>
|
||||
|
||||
@*@if (!string.IsNullOrEmpty(descriptor.Description)) {
|
||||
<p>@descriptor.Description</p>
|
||||
}*@
|
||||
|
||||
@foreach (var recipe in moduleEntry.Recipes) {
|
||||
<br/>
|
||||
<div>
|
||||
<h4>@recipe.Name.CamelFriendly() - @Html.ActionLink(T("Execute").Text, "Recipes", "Admin", new {area = "Orchard.Modules", moduleId = descriptor.Id, name = recipe.Name}, new {itemprop = "UnsafeUrl"})</h4>
|
||||
<p>@(!string.IsNullOrEmpty(recipe.Description) ? recipe.Description : T("No description").ToString())</p>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
}
|
||||
</ul>
|
||||
}
|
||||
else {
|
||||
<p>@T("No modules available").ToString()</p>
|
||||
}
|
||||
@*@if (!string.IsNullOrEmpty(descriptor.Description)) {
|
||||
<p>@descriptor.Description</p>
|
||||
}*@
|
||||
|
||||
@foreach (var recipe in moduleEntry.Recipes) {
|
||||
<br />
|
||||
<div>
|
||||
<h4>@recipe.Name.CamelFriendly() - @Html.ActionLink(T("Execute").Text, "Recipes", "Admin", new { area = "Orchard.Modules", moduleId = descriptor.Id, name = recipe.Name }, new { itemprop = "UnsafeUrl" })</h4>
|
||||
<p>@(!string.IsNullOrEmpty(recipe.Description) ? recipe.Description : T("No description").ToString())</p>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
}
|
||||
</ul>
|
||||
}
|
||||
else {
|
||||
<p>@T("No modules available").ToString()</p>
|
||||
}
|
||||
}
|
||||
@@ -9,28 +9,30 @@
|
||||
}
|
||||
|
||||
<div class="summary">
|
||||
@if (module.Notifications != null && module.Notifications.Count > 0) {
|
||||
<div class="notifications">
|
||||
@if (module.Notifications != null && module.Notifications.Count > 0) {
|
||||
<div class="notifications">
|
||||
@foreach (string notification in module.Notifications) {
|
||||
<h5>@Html.Raw(notification)</h5>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
<div class="properties">
|
||||
<h2@{ if(!string.IsNullOrEmpty(moduleClasses)) {<text> class="@moduleClasses"</text>}}>@module.Descriptor.Name<span> - @T("Version: {0}", !string.IsNullOrEmpty(module.Descriptor.Version) ? module.Descriptor.Version : T("1.0").ToString())</span></h2>
|
||||
<h2@{ if(!string.isnullorempty(moduleclasses)) {<text> class="@moduleClasses" </text> }}>
|
||||
@module.Descriptor.Name<span> - @T("Version: {0}", !string.IsNullOrEmpty(module.Descriptor.Version) ? module.Descriptor.Version : T("1.0").ToString())</span></h2>
|
||||
|
||||
@if (!string.IsNullOrEmpty(module.Descriptor.Description)) {
|
||||
<p>@module.Descriptor.Description</p>
|
||||
}
|
||||
@if (!string.IsNullOrEmpty(module.Descriptor.Description)) {
|
||||
<p>@module.Descriptor.Description</p>
|
||||
}
|
||||
|
||||
<ul class="pageStatus" style="color:#666; margin:.6em 0 0 0;">
|
||||
@{ IEnumerable<FeatureDescriptor> features = module.Descriptor.Features; }
|
||||
<li>@T("Features: {0}", MvcHtmlString.Create(string.Join(", ", features.Select(f => Html.Link(string.IsNullOrEmpty(f.Name) ? f.Id : f.Name, string.Format("{0}#{1}", Url.Action("features", new { area = "Orchard.Modules" }), f.Id.AsFeatureId(n => T(n)))).ToString()).OrderBy(s => s).ToArray())))</li>
|
||||
<li> | @T("Author: {0}", !string.IsNullOrEmpty(module.Descriptor.Author) ? module.Descriptor.Author : T("Unknown").ToString())</li>
|
||||
<li> | @T("Website: ")
|
||||
@if (!string.IsNullOrEmpty(module.Descriptor.WebSite)) { <a href="@module.Descriptor.WebSite">@module.Descriptor.WebSite</a> }
|
||||
else { @T("Unknown").ToString() }
|
||||
</li>
|
||||
</ul>
|
||||
<ul class="pageStatus" style="color:#666; margin:.6em 0 0 0;">
|
||||
@{ IEnumerable<FeatureDescriptor> features = module.Descriptor.Features; }
|
||||
<li>@T("Features: {0}", MvcHtmlString.Create(string.Join(", ", features.Select(f => Html.Link(string.IsNullOrEmpty(f.Name) ? f.Id : f.Name, string.Format("{0}#{1}", Url.Action("features", new { area = "Orchard.Modules" }), f.Id.AsFeatureId(n => T(n)))).ToString()).OrderBy(s => s).ToArray())))</li>
|
||||
<li> | @T("Author: {0}", !string.IsNullOrEmpty(module.Descriptor.Author) ? module.Descriptor.Author : T("Unknown").ToString())</li>
|
||||
<li>
|
||||
| @T("Website: ")
|
||||
@if (!string.IsNullOrEmpty(module.Descriptor.WebSite)) { <a href="@module.Descriptor.WebSite">@modu>@module.Descriptor.WebSite</a> }
|
||||
else { @T("Unknown").ToString() }
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
Reference in New Issue
Block a user