Hello,
I have this code
<% foreach (var item in Model.List) { %>
<tr>
<td><%: item.LastName %></td>
<td><%: item.FirstName %></td>
<td><%: item.IsEnable %></td>
<td><a href="#" class="CustomerEdit">Edit</a></td>
<td><a href="#" class="CustomerDetail">Detail</a></td>
<td><a href="#" class="CustomerDelete">Delete</a></td>
</tr>
<% } %>
<script language="javascript" type="text/javascript">
$(document).ready(function () {
$(".CustomerEdit").click(function () {
alert("blabla");
//need id here
});
});
</script>
It's not in the code but I have an "Item.Id", it's not place anywhere because I don't know where place it ;-). I'd like when I click on the "Edit" hyperlink get the id (item.Id) of the current line.
Any idea ?
Thanks,