我使用 asp.net 。我在一个页面上有 3 个嵌套的数据列表。在内部数据列表中,有复选框。我看起来像下面。
我的 dalist 的设计如下:
<asp:DataList ID="grdRubrikKazanimlari" runat="server"
OnItemDataBound="grdRubrikKazanimlari_OnItemDataBound"
CssClass="grdRubrikKazanimlari" >
<ItemTemplate>
<div style="width:100%;display:block;">
<asp:Label ID="lblDegTipIliskiID" runat="server" Visible="false" Text='<%# DataBinder.Eval(Container.DataItem, "DegTipIliskiID")%>'></asp:Label>
<asp:Label ID="lblDegerlendirmeTipiID" runat="server" Visible="false" Text='<%# DataBinder.Eval(Container.DataItem, "DegerlendirmeTipiID")%>'></asp:Label>
<h1>
<asp:Label ID="lblDegerlendirmeTipi" runat="server" Text=""><%# DataBinder.Eval(Container.DataItem, "DegerlendirmeTipi")%></asp:Label>
</h1>
<asp:DataList ID="grdRubrikKazanimGrup" runat="server" OnItemDataBound="grdRubrikKazanimGrup_OnItemDataBound" CssClass="grdRubrikKazanimGrup">
<ItemTemplate>
<div style="width:96%;display:block;margin-left:5px;">
<asp:Label ID="lblAltGrupIliskiID" runat="server" Visible="false" Text='<%# DataBinder.Eval(Container.DataItem, "AltGrupIliskiID")%>'></asp:Label>
<h2>
<asp:Label ID="lblDegerlendirmeTipi" runat="server" Text=""><%# DataBinder.Eval(Container.DataItem, "AltGrup")%></asp:Label>
</h2>
<asp:DataList ID="grdRubrikKazanimlar" runat="server" OnItemDataBound="grdRubrikKazanimlar_OnItemDataBound" CssClass="grdRubrikKazanimlar" >
<HeaderTemplate>
<table style="width:100%;">
<tr style="line-height:25px;">
<td style="width:70%;text-align:left;padding-left:12px;font-weight:bold;">Kazanım Açıklaması</td>
<td style="width:15%;background-color:#91c98f;text-align:center">T.Edinilmiş</td>
<td style="width:15%;background-color:#bf6f86;text-align:center">T.Edinilmemiş</td>
</tr>
</table>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblRubrikKazanimID" runat="server" Text='<%# DataBinder.Eval(Container.DataItem, "RubrikKazanimID")%>' Visible="false"></asp:Label>
<table style="width:100%;" id="tblkazanim">
<tr style="height:50px;vertical-align:middle;">
<td style="width:70%;text-align:left;padding-left:12px;">
<li>
<asp:Label ID="lblDegerlendirmeTipi" runat="server" Text='<%# DataBinder.Eval(Container.DataItem, "KazanimAciklama")%>'></asp:Label>
</li>
</td>
<td style="width:15%;background-color:#91c98f;text-align:center;vertical-align:middle;">
<asp:CheckBox ID="chkSeciliMi" runat="server" align="center" CssClass="chsecili" OnCheckedChanged="chkSeciliMi_CheckChanged" AutoPostBack="true" />
</td>
<td style="width:15%;background-color:#bf6f86;text-align:center;vertical-align:middle;">
<asp:CheckBox ID="chkYarimSeciliMi" runat="server" AutoPostBack="true" OnCheckedChanged="chkYarimSeciliMi_CheckChanged" CssClass="chkYarimSeciliMi"/>
</td>
</tr>
</table>
<div style="width:96%;display:block;">
<asp:Label ID="lblDegTipIliskiID" runat="server" Text="" Visible="false"></asp:Label>
<asp:Label ID="lblDegerlendirmeTipiID" runat="server" Text="" Visible="false"></asp:Label>
<asp:Label ID="lblKazanimDegerlendirmeTipiID" runat="server" Text='<%# DataBinder.Eval(Container.DataItem, "DegTipIliskiID")%>' Visible="false"></asp:Label>
<asp:Label ID="lblKazanimSirasi" runat="server" Text='<%# DataBinder.Eval(Container.DataItem, "Sirasi")%>' Visible="false"></asp:Label>
</div>
</ItemTemplate>
</asp:DataList>
</div>
</ItemTemplate>
</asp:DataList>
</div>
</ItemTemplate>
</asp:DataList>
我希望用户只检查水平线上的复选框。我怎样才能使用 jquery 做到这一点。谢谢。