<%@ page language="VB" masterpagefile="~/Template/Master.master" autoeventwireup="false" inherits="RCC_O365_LicenseUsageReport, MachSol.MachPanel.Web" %>


<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="EM" %>
<%@ Register Assembly="AjaxControls" Namespace="AjaxControls" TagPrefix="EM" %>
<%@ Register Src="~/Template/GVPager.ascx" TagName="Pager" TagPrefix="UC" %>

<asp:Content ID="Content5" ContentPlaceHolderID="CPH_Content" runat="Server">
    <div class="col-xs-12">
        <div class="card">
            <div class="body">
                <asp:Panel ID="Pnl_Filter" runat="server" DefaultButton="Btn_Filter">
                    <div class="row">
                        <div class="panel-group search-panel" id="AS_LicenseReport" role="tablist" aria-multiselectable="true">
                            <div class="col-xs-12" role="tab" id="SH_LicenseReport">
                                <div class="card">
                                    <div class="header" role="button" data-toggle="collapse" data-parent="#AS_LicenseReport" href="#<%= CSB_LicenseReport.ClientID%>" aria-expanded="true" aria-controls="SH_LicenseReport">
                                        <h3>
                                            <%= Resources.Content.GN0000395%>
                                        </h3>
                                    </div>
                                    <div id="CSB_LicenseReport" runat="server" class="body panel-collapse collapse" role="tabpanel" aria-labelledby="SH_LicenseReport" aria-expanded="false">
                                        <div class="row">
                                            <div class="col-md-3 col-sm-6 col-xs-12" id="Div_SrchOwner" runat="server">
                                                <div class="form-group form-float">
                                                    <asp:DropDownList ID="DDL_SrchOwner" runat="server" onchange="setOwnerCookie(this)">
                                                    </asp:DropDownList>
                                                </div>
                                            </div>

                                            <div class="col-md-3 col-sm-6 col-xs-12" id="Div_SrchCustomerName" runat="server">
                                                <div class="form-group form-float">
                                                    <div class="form-line">
                                                        <asp:TextBox ID="TxBx_SrchCustomerName" runat="server" />
                                                        <asp:Label ID="Label2" runat="server" class="form-label" EnableViewState="false" Text="<%$ Resources:Content,Customer%>"></asp:Label>
                                                    </div>
                                                </div>
                                            </div>

                                            <div class="col-md-3 col-sm-6 col-xs-12" id="Div_SrchCompanyName" runat="server">
                                                <div class="form-group form-float">
                                                    <div class="form-line">
                                                        <asp:TextBox ID="TxBx_SrchCompanyName" runat="server" MaxLength="200"></asp:TextBox>
                                                        <asp:Label ID="Label4" class="form-label" runat="server" Text="<%$ Resources:Content,CompanyName %>"></asp:Label>
                                                    </div>

                                                </div>
                                            </div>
                                            <div class="col-md-3 col-sm-6 col-xs-12" id="Div_SrchTenantName">
                                                <div class="form-group form-float">
                                                    <div class="form-line">
                                                        <asp:TextBox ID="TxBx_SrchTenantName" runat="server" MaxLength="200"></asp:TextBox>
                                                        <asp:Label ID="Ltrl_TenantName" class="form-label" runat="server" Text="<%$ Resources:Content,strTenant %>"></asp:Label>
                                                    </div>

                                                </div>
                                            </div>
                                            <div class="col-md-3 col-sm-6 col-xs-12">
                                                <div class="form-group form-float">
                                                    <div class="form-line">
                                                        <asp:TextBox ID="TxBx_SrchDomain" runat="server"></asp:TextBox>
                                                        <asp:Label ID="Label1" runat="server" EnableViewState="false" Text="<%$ Resources:Content,GN0000653%>" class="form-label"></asp:Label>
                                                    </div>
                                                </div>
                                            </div>
                                            <div class="col-md-3 col-sm-6 col-xs-12">
                                                <div class="form-group form-float">
                                                    <div class="form-line">
                                                        <asp:TextBox ID="TxBx_SrchLicense" runat="server"></asp:TextBox>
                                                        <asp:Label ID="Label3" runat="server" EnableViewState="false" Text="<%$ Resources:Content,License%>" class="form-label"></asp:Label>
                                                    </div>
                                                </div>
                                            </div>
                                            <div class="col-xs-12">
                                                <div class="form-group form-float">
                                                    <asp:Button ID="Btn_Filter" runat="server" class="btn btn-primary waves-effect" Text="<%$ Resources:Content,GN0000391%>" />
                                                    <asp:Button ID="Btn_Clear" Visible="false" class="btn btn-primary waves-effect" runat="server"
                                                        Text="<%$ Resources:Content,String289 %>" />
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </asp:Panel>

                <asp:Panel ID="Pnl_List" runat="server">
                    <div class="double-scroll-wrapper1">
                        <div>
                        </div>
                    </div>
                    <div class="double-scroll-wrapper2">
                        <asp:GridView ID="GV_LicenseReports" CurrentSortExpression="TenantName" CurrentSortDirection="Asc"
                            CssClass="table table-bordered table-striped table-hover" runat="server" AllowPaging="true" AllowSorting="true" EmptyDataText='<%$ Resources:Content, GN00001375 %>'
                            AutoGenerateColumns="false" Style="width: 1520px">

                            <Columns>
                                <asp:TemplateField HeaderText="<%$ Resources:Content, Customer %>" SortExpression="Customer"
                                    HeaderStyle-Width="200px">
                                    <ItemTemplate>
                                                            <asp:HyperLink ID="HL_Customer" runat="server" />
                                    </ItemTemplate>
                                </asp:TemplateField>
                                <asp:TemplateField HeaderText="<%$ Resources:Content, CompanyName %>" SortExpression="CompanyName"
                                    HeaderStyle-Width="200px">
                                    <ItemTemplate>
                                        <asp:Label ID="Lbl_CompanyName" runat="server" Text='<%# DataBinder.Eval(Container, "DataItem.CustomerCompanyName")%>'></asp:Label>
                                    </ItemTemplate>
                                </asp:TemplateField>
                                <asp:TemplateField HeaderText="<%$ Resources:Content, Owner %>" SortExpression="Owner"
                                    HeaderStyle-Width="200px">
                                    <ItemTemplate>
                                        <asp:HyperLink ID="HL_Owner" runat="server" Text='<%#DataBinder.Eval(Container, "DataItem.Owner")%>' />
                                    </ItemTemplate>
                                </asp:TemplateField>
                                <asp:TemplateField HeaderText="<%$ Resources:Content, strTenant %>" SortExpression="TenantName"
                                    HeaderStyle-Width="200px">
                                    <ItemTemplate>
                                         <asp:HyperLink ID="HL_TenantName" runat="server"></asp:HyperLink>
                                    </ItemTemplate>
                                </asp:TemplateField>
                                <asp:TemplateField HeaderText="<%$ Resources:Content, License %>" SortExpression="LicenseName"
                                    HeaderStyle-Width="200px">
                                    <ItemTemplate>
                                        <asp:Label ID="Lbl_LicenseName" runat="server" Text='<%# DataBinder.Eval(Container, "DataItem.AccountSkuFriendlyName")%>'></asp:Label>
                                    </ItemTemplate>
                                </asp:TemplateField>
                                <asp:TemplateField HeaderText="<%$ Resources:Content, ActiveUnits %>" SortExpression="ActiveUnits"
                                    HeaderStyle-Width="100px">
                                    <ItemTemplate>
                                        <asp:Label ID="Lbl_ActiveUnits" runat="server" Text='<%# DataBinder.Eval(Container, "DataItem.ActiveUnits")%>'></asp:Label>
                                    </ItemTemplate>
                                </asp:TemplateField>
                                <asp:TemplateField HeaderText="<%$ Resources:Content, ConsumedUnits %>" SortExpression="ConsumedUnits"
                                    HeaderStyle-Width="100px">
                                    <ItemTemplate>
                                        <asp:Label ID="Lbl_ConsumedUnits" runat="server" Text='<%# DataBinder.Eval(Container, "DataItem.ConsumedUnits")%>'></asp:Label>
                                    </ItemTemplate>
                                </asp:TemplateField>
                                <asp:TemplateField HeaderText="<%$ Resources:Content, LockedoutUnits %>" SortExpression="LockedOutUnits"
                                    HeaderStyle-Width="120px">
                                    <ItemTemplate>
                                        <asp:Label ID="Lbl_LockedoutUnits" runat="server" Text='<%# DataBinder.Eval(Container, "DataItem.LockedOutUnits")%>'></asp:Label>
                                    </ItemTemplate>
                                </asp:TemplateField>
                                <asp:TemplateField HeaderText="<%$ Resources:Content, SuspendedUnits %>" SortExpression="SuspendedUnits"
                                    HeaderStyle-Width="100px">
                                    <ItemTemplate>
                                        <asp:Label ID="Lbl_SuspendedUnits" runat="server" Text='<%# DataBinder.Eval(Container, "DataItem.SuspendedUnits")%>'></asp:Label>
                                    </ItemTemplate>
                                </asp:TemplateField>
                                <asp:TemplateField HeaderText="<%$ Resources:Content, WarningUnits %>" SortExpression="WarningUnits"
                                    HeaderStyle-Width="100px">
                                    <ItemTemplate>
                                        <asp:Label ID="Lbl_WaringUnits" runat="server" Text='<%# DataBinder.Eval(Container, "DataItem.WarningUnits")%>'></asp:Label>
                                    </ItemTemplate>
                                </asp:TemplateField>
                            </Columns>
                            <PagerTemplate>
                                <UC:Pager ID="Pager1" runat="server" />
                            </PagerTemplate>
                        </asp:GridView>
                    </div>
                </asp:Panel>
            </div>
        </div>
    </div>
</asp:Content>
