<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="DashboardControlli.aspx.cs" Inherits="OlympiaIntranet.DashboardControlli" %>

<%@ Register Assembly="DevExpress.Web.v23.2, Version=23.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web" TagPrefix="dx" %>

<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>Dashboard Controlli</title>
</head>
<body>
    <form id="form1" runat="server">
        <dx:ASPxPanel ID="ASPxPanel1" runat="server" EnableTheming="True" Theme="Aqua">
            <PanelCollection>
                <dx:PanelContent>
                    <table style="width: 100%; padding: 10px;">
                        <tr>
                            <td>
                                <h2 style="font-family: Tahoma,Arial,sans-serif; color: #1F4E79; margin: 0 0 10px 0;">Dashboard Controlli 
                                </h2>
                            </td>
                            <td style="text-align: right; vertical-align: middle;">
                                <dx:ASPxButton ID="btnExportExcel" runat="server"
                                    Theme="Aqua"
                                    EnableTheming="True"
                                    Text="Esporta Excel"
                                    AutoPostBack="True"
                                    OnClick="btnExportExcel_Click">
                                    <Image IconID="export_exporttoxlsx_16x16">
                                    </Image>
                                </dx:ASPxButton>
                            </td>
                        </tr>
                    </table>

                    <dx:ASPxGridView ID="gvDashboardAlert" runat="server"
                        Theme="Aqua"
                        EnableTheming="True"
                        AutoGenerateColumns="False"
                        KeyFieldName="ID"
                        Width="100%"
                        OnDataBinding="gvDashboardAlert_DataBinding">

                        <SettingsBehavior AllowEllipsisInText="True" />

                        <SettingsPager Mode="ShowAllRecords" />

                        <Settings ShowGroupPanel="False" ShowFilterRow="True" />

                        <SettingsExport ExcelExportMode="WYSIWYG" />

                        <Columns>
                            <dx:GridViewDataTextColumn FieldName="ID" Caption="ID"
                                Width="50px" ReadOnly="True">
                                <Settings AllowSort="True" AllowHeaderFilter="True" />
                            </dx:GridViewDataTextColumn>

                            <dx:GridViewDataTextColumn FieldName="Descrizione" Caption="Descrizione"
                                Width="300px" ReadOnly="True">
                                <Settings AllowSort="True" AllowHeaderFilter="True" />
                            </dx:GridViewDataTextColumn>

                            <dx:GridViewDataTextColumn FieldName="Frequenza" Caption="Frequenza"
                                Width="100px" ReadOnly="True">
                                <Settings AllowSort="True" AllowHeaderFilter="True" />
                            </dx:GridViewDataTextColumn>

                            <dx:GridViewDataTextColumn FieldName="Giorno" Caption="Giorno"
                                Width="80px" ReadOnly="True">
                                <Settings AllowSort="True" AllowHeaderFilter="True" />
                            </dx:GridViewDataTextColumn>

                            <dx:GridViewDataTextColumn FieldName="Orario" Caption="Orario"
                                Width="80px" ReadOnly="True">
                                <Settings AllowSort="True" AllowHeaderFilter="True" />
                            </dx:GridViewDataTextColumn>

                            <dx:GridViewDataTextColumn FieldName="Destinatari" Caption="Destinatari"
                                Width="250px" ReadOnly="True">
                                <Settings AllowSort="True" AllowHeaderFilter="True" />
                            </dx:GridViewDataTextColumn>
                        </Columns>


                    </dx:ASPxGridView>

                    <%-- Exporter collegato alla griglia --%>
                    <dx:ASPxGridViewExporter ID="gridExporter" runat="server"
                        GridViewID="gvDashboardAlert"
                        FileName="DashboardAlert" />

                </dx:PanelContent>
            </PanelCollection>
        </dx:ASPxPanel>
    </form>
</body>
</html>
