<%@ Page Language="VB" Inherits="System.Web.Mvc.ViewPage" %>

<%@ Register TagPrefix="uc" TagName="Menu" Src="~/Views/Shared/Menu.ascx" %>
<%@ Register TagPrefix="uc" TagName="ClientMenu" Src="~/Views/Client/ClientMenu.ascx" %>
<%@ Register TagPrefix="uc" TagName="ClientSearch" Src="~/Views/Client/Search.ascx" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"></script>
<html xmlns="http://www.w3.org/1999/xhtml" >
<head id="Head1" runat="server">
    <title>Index</title>   
<style type="text/css">
.table_client tr th {
	text-align: left;
}
</style>
</head>
<body>
    <uc:Menu id="MenuTop" 
        runat="server" />

    <uc:ClientMenu id="SubMenu" 
        runat="server"/>

<h2>Liste des clients<br />
  <br />
</h2>
        <form name="SearchForm" id="SearchForm" method="post" action="client/SetClientFilter" runat="server" >
    <uc:ClientSearch id="SearchPanel" runat="server" />
    </form><br />


<div>
   <%  
       Dim dt As CoursE.coursedata.clientDataTable = Me.ViewData.Item("tableclient")
     
       %><table class="table_client"><tr>
       <th width="113">Prénom</th>
       <th width="479">Nom</th>
       <th width="49">Type</th>
       <th width="49"></th></tr><%
       For intCpt As Integer = 0 To dt.DefaultView.ToTable.Rows.Count - 1
       %><tr><td><%
                     Response.Write(dt.DefaultView.Item(intCpt).Item("CLIENT_FIRST_NAME"))
       %></td><td><%
                      Response.Write(dt.DefaultView.Item(intCpt).Item("CLIENT_LAST_NAME"))
       %></td><td><%
                      Response.Write(dt.DefaultView.Item(intCpt).Item("CLIENT_TYPE"))
       %></td><td><a href="Client/Details/<% Response.Write(dt.DefaultView.Item(intCpt).Item("CLIENT_ID")) %>">Voir</a></td></tr><%
             Next
                    %></table><%
                                  
       Response.Write("<br />Total : " & dt.Rows.Count)
   %> 
    </div>
</body>
</html>
