<%@ Page Title="" Language="C#" MasterPageFile="~/MasterDesign.Master" AutoEventWireup="true"
    CodeBehind="ArtistsPage.aspx.cs" Inherits="AUDIOTEKA.ArtistsPage" %>

<%@ Assembly Src="~/Artists.cs" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainPlaceHolder" runat="server">
    <h2>
        Zoznam autorov
    </h2>
    <% if (HttpContext.Current.User.IsInRole("user"))
       {  %>
    Pridať <a href="NewArtist.aspx" title="Pridanie nového autora.">nového autora</a>.
    <br />
    <br />
    <% } %>
    <asp:GridView ID="ArtistsGridView" DataSourceID="ArtistsDataSource" AllowPaging="true"
        PageSize="15" DataKeyNames="ArtistId" runat="server" AutoGenerateColumns="false">
        <RowStyle CssClass="rowA" />
        <AlternatingRowStyle CssClass="rowB" />
        <HeaderStyle CssClass="rowH" BorderColor="Black" ForeColor="White" Font-Underline="false" />
        <Columns>
            <asp:HyperLinkField ItemStyle-BorderColor="black" HeaderText="Autor" DataNavigateUrlFormatString="~/AlbumPage.aspx?artist={0}"
                DataNavigateUrlFields="LastName" DataTextField="LastName" />
            <%-- <asp:BoundField ItemStyle-BorderColor="black" DataField="LastName" HeaderText="Autor" />--%>
            <asp:BoundField ItemStyle-BorderColor="black" DataField="FirstName" HeaderText="Meno" />
            <asp:HyperLinkField ItemStyle-BorderColor="black" HeaderText="HomePage" DataNavigateUrlFormatString="http://{0}"
                DataNavigateUrlFields="HomePage" DataTextField="HomePage" />
        </Columns>
        <PagerStyle BorderStyle="Solid" BorderWidth="1px" BorderColor="white" />
    </asp:GridView>
    <asp:ObjectDataSource TypeName="AUDIOTEKA.Artists" SelectMethod="SelectPage" SelectCountMethod="SelectCount"
        ID="ArtistsDataSource" runat="server" EnablePaging="true" />
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="LeftPlaceHolder" runat="server">
</asp:Content>
