我正在尝试使用data-table jquery在我们的asp.net页面上实现搜索功能。
标题模板中有一行,项目模板中有2行。第一行表示公司名称,第二行表示转发器,它创建多个项目行。
我想在这里实现的是搜索文本框应该搜索公司名称或项目名称。 但它在第1行的数据源中给出了“请求未知参数'1'的错误。”
如果我在项目模板中只使用一行作为公司名称,则该插件可以使用。
我非常感谢你的建议。
以下是我的代码:
<div class="panel panel-default">
<div class="panel-body sorting-img">
<asp:Literal runat="server" Text="No Data Found"> </asp:Literal>
<div class="table-responsive" id="tabResponsive">
<asp:Repeater runat="server" OnItemDataBound ="rptCompanyList_ItemDataBound" >
<HeaderTemplate>
<table class="table table-striped table-bordered table-hover table-full-width" id="sample_1">
<thead>
<tr>
<th class="center">
<div class="clientTable">
<label>
<%--<input type="checkbox" class="flat-grey">--%>
<asp:CheckBox ID="chkDataAll" CssClass="flat-grey"
AutoPostBack="false" OnCheckedChanged="chkDataAll_CheckedChanged"
runat="server" />
</label>
</div></th>
<th>
Name
</th>
<th>
Created Date
</th>
<th>
Account Rep
</th>
<th>
% Storage (Used|Available)
</th>
<th>
Status
</th>
</tr>
</thead><tbody>
</HeaderTemplate>
<ItemTemplate>
<tr class="clientTr">
<td class="center">
<div class="clientTable">
<label>
<%--<input type="checkbox" class="flat-grey">
<asp:CheckBox ID="chkData" CssClass="flat-grey" AutoPostBack="true"
OnCheckedChanged="chkData_CheckedChanged"
runat="server" />--%>
<asp:CheckBox ID="chkData" CssClass="flat-grey" OnCheckedChanged="chkData_CheckedChanged"
AutoPostBack="false" runat="server" />
<asp:HiddenField ID="hdfAccountID" runat="server" />
</label>
</div></td>
<td>
<!-- //220814_02 -->
<asp:Literal ID="ltName" runat="server"></asp:Literal>
<a class="fc_red pull-left" runat="server" >
Edit
</a>
</td>
<td>
<asp:Literal ID="ltCreateDate" runat="server"></asp:Literal>
</td>
<td>
<asp:Literal ID="ltAccRepName" runat="server"></asp:Literal>
</td>
<td class="proClientBackground">
</td>
<td>
<asp:Literal ID="ltAccountStatus" runat="server"></asp:Literal>
</td>
</tr>
<tr>
<asp:Repeater ID="rptProjectListCompanyWise" runat="server" OnItemDataBound="rptProjectListCompanyWise_ItemDataBound">
<ItemTemplate>
<tr>
<!-- //080814_01 -->
<td align="center">
<%--<img id="imgProject" src="../Images/note_ico.jpg" />--%>
<asp:CheckBox ID="chkData" CssClass="flat-grey" OnCheckedChanged="chkData_CheckedChanged"
AutoPostBack="false" onclick='getProjectID(this);' runat="server" />
</td>
<!-- //080814_01 -->
<td class="projectTD" valign="middle">
<a id="ancManageDocument" class="fc_red" runat="server" href="#">
<asp:Literal ID="ltProjectName" runat="server"></asp:Literal>
</a>
</td>
<td align="left" valign="middle">
<asp:Literal ID="ltCreateDate" runat="server"></asp:Literal>
</td>
<td align="left" valign="middle">
<asp:Literal ID="ltAccRepName" runat="server"></asp:Literal>
</td>
<td class="tdProgress" align="center" valign="middle">
<div class="proClientStorage">
<div class="progress progressAdminClient">
<div id="divProgressBar" runat="server" class="progress-bar" role="progressbar" aria-valuemin="0" aria-valuemax="100" >
</div>
</div>
</div>
</td>
<td align="left" valign="middle">
<asp:Literal ID="ltAccountStatus" runat="server"></asp:Literal>
</td>
</tr>
</ItemTemplate>
</asp:Repeater>
</tr>
</ItemTemplate>
<FooterTemplate>
</tbody>
</table>
</FooterTemplate>
</asp:Repeater>
<asp:HiddenField ID="AllSelectedProjectIDs" runat="server" />
</div>
</div>
</div>