mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2026-02-09 09:16:41 +08:00
Fixed issues caught when pre-compiling views. Note that I temporarily added an implicit conversion from LocalizedString to String. This may go away with Louis's pending changes.
--HG-- branch : dev
This commit is contained in:
@@ -8,7 +8,7 @@
|
|||||||
<div class="secondary">
|
<div class="secondary">
|
||||||
<% Html.Zone("secondary");%>
|
<% Html.Zone("secondary");%>
|
||||||
<fieldset>
|
<fieldset>
|
||||||
<input class="button primaryAction" type="submit" name="submit.Save" value="<%=_Encoded("Save") %>"/>
|
<input class="button primaryAction" type="submit" name="submit.Save" value="<%: T("Save") %>"/>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -23,13 +23,13 @@
|
|||||||
<li class="previous">
|
<li class="previous">
|
||||||
<h4><%=year %> <span>(<%=yearMonths.Sum(ym => ym.Value) %>)</span></h4><%
|
<h4><%=year %> <span>(<%=yearMonths.Sum(ym => ym.Value) %>)</span></h4><%
|
||||||
} %>
|
} %>
|
||||||
<%: Html.UnorderedList(yearMonths, (t, i) => Html.Link(string.Format("{0:MMMM} ({1})", t.Key.ToDateTime(), t.Value), Url.BlogArchiveMonth(Model.Blog.Slug, t.Key.Year, t.Key.Month)), "archiveMonthList") %>
|
<%: Html.UnorderedList(yearMonths, (t, i) => Html.Link(string.Format("{0:MMMM} ({1})", t.Key.ToDateTime(), t.Value), Url.BlogArchiveMonth(Model.Blog.Slug, t.Key.Year, t.Key.Month)).ToString(), "archiveMonthList") %>
|
||||||
</li><%
|
</li><%
|
||||||
} %>
|
} %>
|
||||||
</ul><%
|
</ul><%
|
||||||
}
|
}
|
||||||
else { %>
|
else { %>
|
||||||
<%: Html.UnorderedList(Model.Archives, (t, i) => Html.Link(string.Format("{0:MMMM yyyy} ({1})", t.Key.ToDateTime(), t.Value), Url.BlogArchiveMonth(Model.Blog.Slug, t.Key.Year, t.Key.Month)), "archiveMonthList") %><%
|
<%: Html.UnorderedList(Model.Archives, (t, i) => Html.Link(string.Format("{0:MMMM yyyy} ({1})", t.Key.ToDateTime(), t.Value), Url.BlogArchiveMonth(Model.Blog.Slug, t.Key.Year, t.Key.Month)).ToString(), "archiveMonthList") %><%
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else { %>
|
else { %>
|
||||||
|
|||||||
@@ -7,7 +7,7 @@
|
|||||||
<%@ Import Namespace="Orchard.Blogs.Models"%>
|
<%@ Import Namespace="Orchard.Blogs.Models"%>
|
||||||
<div class="summary">
|
<div class="summary">
|
||||||
<div class="properties">
|
<div class="properties">
|
||||||
<h3><%: Html.Link(s, Url.BlogPostEdit(Model.Item))%></h3>
|
<h3><%: Html.Link(Model.Item.Title, Url.BlogPostEdit(Model.Item))%></h3>
|
||||||
<ul>
|
<ul>
|
||||||
<li><%
|
<li><%
|
||||||
if (Model.Item.HasPublished) { %>
|
if (Model.Item.HasPublished) { %>
|
||||||
|
|||||||
@@ -7,7 +7,7 @@
|
|||||||
<fieldset class="actions bulk">
|
<fieldset class="actions bulk">
|
||||||
<label for="publishActions"><%: T("Actions:") %></label>
|
<label for="publishActions"><%: T("Actions:") %></label>
|
||||||
<select id="publishActions" name="<%=Html.NameOf(m => m.Options.BulkAction)%>">
|
<select id="publishActions" name="<%=Html.NameOf(m => m.Options.BulkAction)%>">
|
||||||
<%: Html.SelectOption(Model.Options.BulkAction, CommentIndexBulkAction.None, T("Choose action...")) %>
|
<%: Html.SelectOption(Model.Options.BulkAction, CommentIndexBulkAction.None, T("Choose action...").ToString()) %>
|
||||||
<%: Html.SelectOption(Model.Options.BulkAction, CommentIndexBulkAction.Approve, T("Approve")) %>
|
<%: Html.SelectOption(Model.Options.BulkAction, CommentIndexBulkAction.Approve, T("Approve")) %>
|
||||||
<%: Html.SelectOption(Model.Options.BulkAction, CommentIndexBulkAction.Pend, T("Pend")) %>
|
<%: Html.SelectOption(Model.Options.BulkAction, CommentIndexBulkAction.Pend, T("Pend")) %>
|
||||||
<%: Html.SelectOption(Model.Options.BulkAction, CommentIndexBulkAction.MarkAsSpam, T("Mark as Spam")) %>
|
<%: Html.SelectOption(Model.Options.BulkAction, CommentIndexBulkAction.MarkAsSpam, T("Mark as Spam")) %>
|
||||||
|
|||||||
@@ -40,5 +40,5 @@ Exported as xml</h2>
|
|||||||
<% using (Html.BeginFormAntiForgeryPost()) { %>
|
<% using (Html.BeginFormAntiForgeryPost()) { %>
|
||||||
<%:Html.TextAreaFor(m=>m.ExportText, new{style="width:100%;height:640px;"}) %>
|
<%:Html.TextAreaFor(m=>m.ExportText, new{style="width:100%;height:640px;"}) %>
|
||||||
<br />
|
<br />
|
||||||
<input class="button primaryAction" type="submit" value="<%=_Encoded("Merge Changes") %>" />
|
<input class="button primaryAction" type="submit" value="<%: T("Merge Changes") %>" />
|
||||||
<%} %>
|
<%} %>
|
||||||
|
|||||||
@@ -68,7 +68,7 @@ using (Html.BeginFormAntiForgeryPost(Url.Action("Save",new {id=Model.SelectedCon
|
|||||||
|
|
||||||
</table>
|
</table>
|
||||||
<p>
|
<p>
|
||||||
<input type="submit" value="<%=_Encoded("Save") %>" />
|
<input type="submit" value="<%: T("Save") %>" />
|
||||||
</p>
|
</p>
|
||||||
<% } %>
|
<% } %>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -43,7 +43,7 @@
|
|||||||
<h4><%: T("Depends on:")%></h4>
|
<h4><%: T("Depends on:")%></h4>
|
||||||
<%: Html.UnorderedList(
|
<%: Html.UnorderedList(
|
||||||
feature.Descriptor.Dependencies.OrderBy(s => s),
|
feature.Descriptor.Dependencies.OrderBy(s => s),
|
||||||
(s, i) => Html.Link(s, string.Format("#{0}", s.AsFeatureId(n => T(n)))),
|
(s, i) => Html.Link(s, string.Format("#{0}", s.AsFeatureId(n => T(n)))).ToString(),
|
||||||
"",
|
"",
|
||||||
"dependency",
|
"dependency",
|
||||||
"") %>
|
"") %>
|
||||||
|
|||||||
@@ -15,7 +15,7 @@
|
|||||||
<p><%: module.Description %></p><%
|
<p><%: module.Description %></p><%
|
||||||
} %>
|
} %>
|
||||||
<ul class="pageStatus" style="color:#666; margin:.6em 0 0 0;">
|
<ul class="pageStatus" style="color:#666; margin:.6em 0 0 0;">
|
||||||
<li><%=T("Features: {0}", string.Join(", ", module.Features.Select(f => Html.Link(f.Name, string.Format("{0}#{1}", Url.Action("features", new { area = "Orchard.Modules" }), f.Name.AsFeatureId(n => T(n))) )).OrderBy(s => s).ToArray())) %></li>
|
<li><%=T("Features: {0}", string.Join(", ", module.Features.Select(f => Html.Link(f.Name, string.Format("{0}#{1}", Url.Action("features", new { area = "Orchard.Modules" }), f.Name.AsFeatureId(n => T(n)))).ToString()).OrderBy(s => s).ToArray())) %></li>
|
||||||
<li> | <%: T("Author: {0}", !string.IsNullOrEmpty(module.Author) ? module.Author : (new []{"Bradley", "Bertrand", "Renaud", "Suha", "Sebastien", "Jon", "Nathan", "Erik"})[(module.DisplayName.Length + (new Random()).Next()) % 7]) %></li><%-- very efficient, I know --%>
|
<li> | <%: T("Author: {0}", !string.IsNullOrEmpty(module.Author) ? module.Author : (new []{"Bradley", "Bertrand", "Renaud", "Suha", "Sebastien", "Jon", "Nathan", "Erik"})[(module.DisplayName.Length + (new Random()).Next()) % 7]) %></li><%-- very efficient, I know --%>
|
||||||
<li> | <%: T("Website: {0}", !string.IsNullOrEmpty(module.HomePage) ? module.HomePage : T("<a href=\"http://orchardproject.net\">http://orchardproject.net</a>").ToString())%></li>
|
<li> | <%: T("Website: {0}", !string.IsNullOrEmpty(module.HomePage) ? module.HomePage : T("<a href=\"http://orchardproject.net\">http://orchardproject.net</a>").ToString())%></li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|||||||
@@ -12,6 +12,10 @@ namespace Orchard.Localization {
|
|||||||
return new LocalizedString(x);
|
return new LocalizedString(x);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static implicit operator string(LocalizedString x) {
|
||||||
|
return x.ToString();
|
||||||
|
}
|
||||||
|
|
||||||
public string Text {
|
public string Text {
|
||||||
get { return _localized; }
|
get { return _localized; }
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -11,7 +11,7 @@
|
|||||||
<RootNamespace>Orchard.Web</RootNamespace>
|
<RootNamespace>Orchard.Web</RootNamespace>
|
||||||
<AssemblyName>Orchard.Web</AssemblyName>
|
<AssemblyName>Orchard.Web</AssemblyName>
|
||||||
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
|
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
|
||||||
<MvcBuildViews>false</MvcBuildViews>
|
<MvcBuildViews>true</MvcBuildViews>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||||
<DebugSymbols>true</DebugSymbols>
|
<DebugSymbols>true</DebugSymbols>
|
||||||
|
|||||||
Reference in New Issue
Block a user