mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-09-18 17:47:54 +08:00
When a Core feature (e.g. Routable) had a new data migration upgrade, there was no way to run the upgrade
--HG-- branch : dev
This commit is contained in:
@@ -30,49 +30,50 @@
|
|||||||
if (feature == features.First())
|
if (feature == features.First())
|
||||||
featureClassName += " first";
|
featureClassName += " first";
|
||||||
if (feature == features.Last())
|
if (feature == features.Last())
|
||||||
featureClassName += " last"; %>
|
featureClassName += " last";%>
|
||||||
<li class="<%: featureClassName %>" id="<%: featureId %>" title="<%: T("{0} is {1}", Html.AttributeEncode(feature.Descriptor.Name), featureState) %>">
|
<li class="<%:featureClassName%>" id="<%:featureId%>" title="<%:T("{0} is {1}", Html.AttributeEncode(feature.Descriptor.Name), featureState)%>">
|
||||||
<div class="summary">
|
<div class="summary">
|
||||||
<div class="properties">
|
<div class="properties">
|
||||||
<h3><%:feature.Descriptor.Name %></h3>
|
<h3><%:feature.Descriptor.Name%></h3>
|
||||||
<p class="description"><%:feature.Descriptor.Description %></p><%
|
<p class="description"><%:feature.Descriptor.Description%></p><%
|
||||||
if (feature.Descriptor.Dependencies != null && feature.Descriptor.Dependencies.Any()) { %>
|
if (feature.Descriptor.Dependencies != null && feature.Descriptor.Dependencies.Any()) {%>
|
||||||
<div class="dependencies">
|
<div class="dependencies">
|
||||||
<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)))),
|
||||||
"",
|
"",
|
||||||
"dependency",
|
"dependency",
|
||||||
"") %>
|
"")%>
|
||||||
</div><%
|
</div><%
|
||||||
} %>
|
}%>
|
||||||
</div><%
|
</div>
|
||||||
if (showActions) { %>
|
<div class="actions">
|
||||||
<div class="actions"><%
|
<%
|
||||||
|
if (showActions) {
|
||||||
if (feature.IsEnabled) {
|
if (feature.IsEnabled) {
|
||||||
using (Html.BeginFormAntiForgeryPost(string.Format("{0}", Url.Action("Disable", new { area = "Orchard.Modules" })), FormMethod.Post, new {@class = "inline link"})) { %>
|
using (Html.BeginFormAntiForgeryPost(string.Format("{0}", Url.Action("Disable", new { area = "Orchard.Modules" })), FormMethod.Post, new {@class = "inline link"})) { %>
|
||||||
<%: Html.Hidden("id", feature.Descriptor.Name, new { id = "" })%>
|
<%:Html.Hidden("id", feature.Descriptor.Name, new {id = ""})%>
|
||||||
<%: Html.Hidden("force", true)%>
|
<%:Html.Hidden("force", true)%>
|
||||||
<button type="submit"><%: T("Disable") %></button><%
|
<button type="submit"><%:T("Disable")%></button><%
|
||||||
}
|
|
||||||
} else {
|
|
||||||
using (Html.BeginFormAntiForgeryPost(string.Format("{0}", Url.Action("Enable", new { area = "Orchard.Modules" })), FormMethod.Post, new {@class = "inline link"})) { %>
|
|
||||||
<%: Html.Hidden("id", feature.Descriptor.Name, new { id = "" })%>
|
|
||||||
<%: Html.Hidden("force", true)%>
|
|
||||||
<button type="submit"><%: T("Enable") %></button><%
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if(Model.FeaturesThatNeedUpdate.Contains(feature.Descriptor.Name)){
|
|
||||||
using (Html.BeginFormAntiForgeryPost(string.Format("{0}", Url.Action("Update", new { area = "Orchard.Modules" })), FormMethod.Post, new {@class = "inline link"})) { %>
|
|
||||||
<%: Html.Hidden("id", feature.Descriptor.Name, new { id = "" })%>
|
|
||||||
<%: Html.Hidden("force", true)%>
|
|
||||||
<button type="submit" class="update"><%: T("Update") %></button><%
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
%>
|
else {
|
||||||
</div><%
|
using (Html.BeginFormAntiForgeryPost(string.Format("{0}", Url.Action("Enable", new { area = "Orchard.Modules" })), FormMethod.Post, new {@class = "inline link"})) { %>
|
||||||
} %>
|
<%: Html.Hidden("id", feature.Descriptor.Name, new { id = "" })%>
|
||||||
|
<%: Html.Hidden("force", true)%>
|
||||||
|
<button type="submit"><%: T("Enable") %></button><%
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if(Model.FeaturesThatNeedUpdate.Contains(feature.Descriptor.Name)){
|
||||||
|
using (Html.BeginFormAntiForgeryPost(string.Format("{0}", Url.Action("Update", new { area = "Orchard.Modules" })), FormMethod.Post, new {@class = "inline link"})) { %>
|
||||||
|
<%: Html.Hidden("id", feature.Descriptor.Name, new { id = "" })%>
|
||||||
|
<%: Html.Hidden("force", true)%>
|
||||||
|
<button type="submit" class="update"><%: T("Update") %></button><%
|
||||||
|
}
|
||||||
|
}%>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</li><%
|
</li><%
|
||||||
} %>
|
} %>
|
||||||
|
Reference in New Issue
Block a user