mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-09-19 18:27:55 +08:00
Changed the manage blogs layout the same as the list of posts.
--HG-- branch : dev
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
<h1><%=Html.TitleForPage(T("Manage Blogs").ToString()) %></h1>
|
||||
<%-- todo: Add helper text here when ready. <p><%=_Encoded("Possible text about setting up and managing a blog goes here.") %></p> --%><%
|
||||
if (Model.Entries.Count() > 0) { %>
|
||||
<div class="actions"><a class="add button" href="<%=Url.BlogCreate() %>"><%=_Encoded("New Blog") %></a></div>
|
||||
<div class="actions"><a class="add button primaryAction" href="<%=Url.BlogCreate() %>"><%=_Encoded("New Blog") %></a></div>
|
||||
<%=Html.UnorderedList(Model.Entries, (entry, i) => {
|
||||
// Add blog post count rendering into "meta" zone
|
||||
entry.ContentItemViewModel.Zones.AddAction("meta", html => {
|
||||
@@ -20,7 +20,7 @@ if (Model.Entries.Count() > 0) { %>
|
||||
// Display the summary for the blog post
|
||||
return Html.DisplayForItem(entry.ContentItemViewModel).ToHtmlString();
|
||||
}, "blogs contentItems")%>
|
||||
<div class="actions"><a class="add button" href="<%=Url.BlogCreate() %>"><%=_Encoded("New Blog") %></a></div><%
|
||||
<div class="actions"><a class="add button primaryAction" href="<%=Url.BlogCreate() %>"><%=_Encoded("New Blog") %></a></div><%
|
||||
} else { %>
|
||||
<div class="info message"><%=T("There are no blogs for you to see. Want to <a href=\"{0}\">add one</a>?", Url.BlogCreate()).ToString()%></div><%
|
||||
} %>
|
@@ -2,23 +2,30 @@
|
||||
<%@ Import Namespace="Orchard.Mvc.ViewModels"%>
|
||||
<%@ Import Namespace="Orchard.Blogs.Extensions"%>
|
||||
<%@ Import Namespace="Orchard.Blogs.Models"%>
|
||||
<h2><%=Html.Link(Html.Encode(Model.Item.Name), Url.BlogForAdmin(Model.Item.Slug)) %></h2>
|
||||
<div class="meta"><%Html.Zone("meta");%></div>
|
||||
|
||||
<div class="summary">
|
||||
<div class="properties">
|
||||
<h3><%=Html.Link(Html.Encode(Model.Item.Name), Url.BlogForAdmin(Model.Item.Slug)) %></h3>
|
||||
<p><%Html.Zone("meta");%></p>
|
||||
<%--<p>[list of authors] [modify blog access]</p>--%>
|
||||
<p><%=Html.Encode(Model.Item.Description) %></p>
|
||||
<ul class="actions">
|
||||
<li class="construct">
|
||||
<a href="<%=Url.BlogForAdmin(Model.Item.Slug) %>" class="ibutton blog" title="<%=_Encoded("Manage Blog") %>"><%=_Encoded("Manage Blog") %></a>
|
||||
<a href="<%=Url.BlogEdit(Model.Item.Slug) %>" class="ibutton edit" title="<%=_Encoded("Edit Blog") %>"><%=_Encoded("Edit Blog") %></a>
|
||||
<a href="<%=Url.Blog(Model.Item.Slug) %>" class="ibutton view" title="<%=_Encoded("View Blog") %>"><%=_Encoded("View Blog") %></a>
|
||||
<a href="<%=Url.BlogPostCreate(Model.Item.Slug) %>" class="ibutton add page" title="<%=_Encoded("New Post") %>"><%=_Encoded("New Post") %></a>
|
||||
</li>
|
||||
<li class="destruct">
|
||||
</div>
|
||||
|
||||
<div class="related">
|
||||
|
||||
<%--<a href="<%=Url.BlogForAdmin(Model.Item.Slug) %>" title="<%=_Encoded("Manage Blog") %>"><%=_Encoded("Manage Blog") %></a><%=_Encoded(" | ")%>--%>
|
||||
<a href="<%=Url.Blog(Model.Item.Slug) %>" title="<%=_Encoded("View") %>"><%=_Encoded("View") %></a><%=_Encoded(" | ")%>
|
||||
<a href="<%=Url.BlogEdit(Model.Item.Slug) %>" title="<%=_Encoded("Edit") %>"><%=_Encoded("Edit") %></a><%=_Encoded(" | ")%>
|
||||
<a href="<%=Url.BlogPostCreate(Model.Item.Slug) %>" title="<%=_Encoded("New Post") %>"><%=_Encoded("New Post") %></a><%=_Encoded(" | ")%>
|
||||
|
||||
<%-- todo: (heskew) this is waaaaa too verbose. need template helpers for all ibuttons --%>
|
||||
<% using (Html.BeginFormAntiForgeryPost(Url.BlogDelete(Model.Item.Slug), FormMethod.Post, new { @class = "inline" })) { %>
|
||||
<fieldset>
|
||||
<button type="submit" class="ibutton remove" title="<%=_Encoded("Remove Blog") %>"><%=_Encoded("Remove Blog") %></button>
|
||||
</fieldset><%
|
||||
<button type="submit" class="linkButton" title="<%=_Encoded("Delete") %>"><%=_Encoded("Delete") %></button>
|
||||
<%
|
||||
} %>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
<div style="clear:both;"></div>
|
||||
</div>
|
@@ -7,7 +7,7 @@
|
||||
<%@ Import Namespace="Orchard.Blogs.Extensions"%>
|
||||
<%@ Import Namespace="Orchard.Blogs.Models"%>
|
||||
|
||||
<div class="blogPost summary">
|
||||
<div class="summary">
|
||||
<div class="properties">
|
||||
<h3><%=Html.Link(Html.Encode(Model.Item.Title), Url.BlogPostEdit(Model.Item.Blog.Slug, Model.Item.Id))%></h3>
|
||||
|
||||
|
@@ -733,7 +733,7 @@ table.items, textarea, input.text, input.text-box,
|
||||
/* Added classes for new blog list layout
|
||||
---------------------------------------------------------- */
|
||||
|
||||
.blogPost.summary {
|
||||
.summary {
|
||||
padding:.6em .4em;
|
||||
}
|
||||
.actions {
|
||||
@@ -750,7 +750,6 @@ table.items, textarea, input.text, input.text-box,
|
||||
}
|
||||
#main .contentItems .properties h3 {
|
||||
border-bottom:none;
|
||||
margin:0;
|
||||
margin:0 0 0 .2em;
|
||||
padding:0;
|
||||
}
|
||||
@@ -759,8 +758,9 @@ table.items, textarea, input.text, input.text-box,
|
||||
float:right;
|
||||
text-align:right;
|
||||
}
|
||||
.related .commentcount{
|
||||
line-height:2em;
|
||||
.commentcount {
|
||||
margin:0 0 0 .2em;
|
||||
line-height:2em;
|
||||
}
|
||||
.contentItems .properties ul li{
|
||||
border:0;
|
||||
|
Reference in New Issue
Block a user