$ ("#checkAll"). Bind ("click", Function () {
Debugger
if (this.checked) {
$ ("[name = Checkitem]:checkbox"). attr ("Checked", true);
}
else {
$ ("[name = Checkitem]:checkbox"). attr ("checked", false);
}
});
<table class= "Table table-striped table-hover table-condensed" >
<thead>
<tr>
<th><input id= "Checkall" type= "checkbox"/></th>
<th> Order Number </th>
<th> Customer Code </th>
<th> Customer Name </th>
<th> Order Date </th>
<th> waybill number </th>
<th> e-commerce platform name </th>
<th> Lot Number </th>
<th> Edit </th>
</tr>
</thead>
<tbody>
@foreach (var item in Model)
{
<tr>
<td><input id= "@item. Id "Name=" Checkitem "type=" checkbox "/></td>
<td> @Ajax. ActionLink (item. OrderNo, "Details", new {item. Id}, new Ajaxoptions {Updatetargetid = "Main"}) </td>
<td> @Html. displayfor (A = Item. Customcode) </td>
<td> @Html. displayfor (A = Item. Customname) </td>
<td> @Html. displayfor (A = Item. CreateDate) </td>
<td> @Html. displayfor (A = Item. Waybillno) </td>
<td> @Html. displayfor (A = Item. Platname) </td>
<td> @Html. displayfor (A = Item. Batchno) </td>
<td>
@Ajax. ActionLink ("editor", "edit", NULL, new {id = Item.) Id}, new Ajaxoptions {Updatetargetid = "Main"}, new {@class = ""})
<span> </span>
@Ajax. ActionLink ("Remove", "delete", NULL, new {id = Item. Id}, new Ajaxoptions {Updatetargetid = "Main", HttpMethod = "Delete", Confirm = "Are you sure you want to delete this record?" This operation is not recoverable! "}, new {@class =" "})
</td>
</tr>
}
</tbody>
</table>
Jquery Table List Multi-select implementation