mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-10-15 19:54:57 +08:00
Adding Select all checkbox to all suitable admin lists, fixes #5026
This commit is contained in:
@@ -16,8 +16,10 @@
|
||||
<div class="manage">
|
||||
@Html.ActionLink(createLinkText.Text, "Create", new { Area = "Contents", Id = (string)Model.Options.SelectedFilter }, new { @class = "button primaryAction" })
|
||||
</div>
|
||||
|
||||
@using (Html.BeginFormAntiForgeryPost()) {
|
||||
<fieldset class="bulk-actions">
|
||||
<label><input type="checkbox" class="check-all" />@T("Select all")</label>@T(" | ")
|
||||
<label for="publishActions">@T("Actions:")</label>
|
||||
<select id="publishActions" name="Options.BulkAction">
|
||||
@Html.SelectOption((ContentsBulkAction)Model.Options.BulkAction, ContentsBulkAction.None, T("Choose action...").ToString())
|
||||
|
@@ -8,6 +8,7 @@
|
||||
<div class="actions"><a class="add button primaryAction" href="@Url.BlogCreate()">@T("New Blog")</a></div>
|
||||
using(Html.BeginFormAntiForgeryPost(Url.Action("List", "Admin", new { area = "Contents", id = "" }))) {
|
||||
<fieldset class="bulk-actions">
|
||||
<label><input type="checkbox" class="check-all" />@T("Select all")</label>@T(" | ")
|
||||
<label for="publishActions">@T("Actions:")</label>
|
||||
<select id="publishActions" name="Options.BulkAction">
|
||||
@Html.SelectOption(ContentsBulkAction.None, ContentsBulkAction.None, T("Choose action...").ToString())
|
||||
|
@@ -3,6 +3,7 @@
|
||||
@if (Model.ContentItems.Items.Count > 0) {
|
||||
using (Html.BeginFormAntiForgeryPost(Url.Action("List", "Admin", new { area = "Contents", id = "" }))) {
|
||||
<fieldset class="bulk-actions">
|
||||
<label><input type="checkbox" class="check-all" />@T("Select all")</label>@T(" | ")
|
||||
<label for="publishActions">@T("Actions:")</label>
|
||||
<select id="publishActions" name="Options.BulkAction">
|
||||
@Html.SelectOption(ContentsBulkAction.None, ContentsBulkAction.None, T("Choose action...").ToString())
|
||||
@@ -17,6 +18,7 @@
|
||||
@Display(Model.ContentItems)
|
||||
</fieldset>
|
||||
}
|
||||
} else {
|
||||
}
|
||||
else {
|
||||
<div class="info message">@T("There are no posts for this blog.")</div>
|
||||
}
|
@@ -7,6 +7,7 @@
|
||||
Html.ValidationSummary();
|
||||
<fieldset>
|
||||
<legend>@T("Choose the types to include in the export file:")</legend>
|
||||
<label><input type="checkbox" class="check-all" />@T("Select all")</label>
|
||||
<ol>
|
||||
@{var contentTypeIndex = 0;}
|
||||
@foreach (var contentTypeEntry in Model.ContentTypes) {
|
||||
|
@@ -18,8 +18,8 @@
|
||||
@using (Html.BeginFormAntiForgeryPost()) {
|
||||
@Html.ValidationSummary()
|
||||
<div class="manage">@Html.ActionLink(T("Add a new Query").ToString(), "Create", new { Area = "Contents", id = "Query", returnurl = HttpContext.Current.Request.RawUrl }, new { @class = "button primaryAction" })</div>
|
||||
|
||||
<fieldset class="bulk-actions">
|
||||
<label><input type="checkbox" class="check-all" />@T("Select all")</label>@T(" | ")
|
||||
<label for="publishActions">@T("Actions:")</label>
|
||||
<select id="publishActions" name="@Html.NameOf(m => m.Options.BulkAction)">
|
||||
@Html.SelectOption(Model.Options.BulkAction, QueriesBulkAction.None, T("Choose action...").ToString())
|
||||
|
@@ -30,7 +30,7 @@
|
||||
</colgroup>
|
||||
<thead>
|
||||
<tr>
|
||||
<th scope="col">@T("Name")</th>
|
||||
<th scope="col"><input type="checkbox" class="check-all" /> @T("Name")</th>
|
||||
<th scope="col"></th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
@@ -16,6 +16,7 @@
|
||||
</div>
|
||||
@using (Html.BeginFormAntiForgeryPost()) {
|
||||
<fieldset class="bulk-actions">
|
||||
<label><input type="checkbox" class="check-all" />@T("Select all")</label>@T(" | ")
|
||||
<label for="publishActions">@T("Actions:")</label>
|
||||
<select id="publishActions" name="Options.BulkAction">
|
||||
@Html.SelectOption((ContentsBulkAction)Model.Options.BulkAction, ContentsBulkAction.None, T("Choose action...").ToString())
|
||||
|
@@ -72,7 +72,7 @@
|
||||
});
|
||||
|
||||
$(".check-all").change(function () {
|
||||
$(this).parents("table.items").find(":checkbox:not(:disabled)").prop('checked', $(this).prop("checked"));
|
||||
$("input[type=checkbox]:not(:disabled)").prop('checked', $(this).prop("checked"))
|
||||
});
|
||||
|
||||
// Handle keypress events in bulk action fieldsets that are part of a single form.
|
||||
|
Reference in New Issue
Block a user