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

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="EM" %>
<%@ Register Src="~/Template/GVPager.ascx" TagName="Pager" TagPrefix="EM" %>
<%@ Register Assembly="System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
    Namespace="System.Web.UI" TagPrefix="cc1" %>

<asp:Content ID="Content5" ContentPlaceHolderID="CPH_Content" runat="Server">

    <div class="col-xs-12">
        <div class="card">
            <div class="header">
                <h2>
                    <asp:Literal ID="Ltl_SubsInfo" runat="server" /></h2>
            </div>
            <div class="body">
                <EM:TabContainer ID="TC_Queue" runat="server" OnClientActiveTabChanged="loadTabPanel">
                    <EM:TabPanel ID="Tab_Queue" runat="server" HeaderText="<%$ Resources:Content,strADSyncTemplate%>">
                        <ContentTemplate>
                            <asp:Button ID="Btn_Tab0" runat="server" Style="display: none;" />
                            <asp:Panel ID="Pnl_TabContent0" runat="server">
                                <%--Start Search Box--%>
                                <asp:Panel ID="Pnl_Search_Outer" runat="server" DefaultButton="Btn_Search">
                                    <div class="row">
                                        <div class="panel-group search-panel" id="AS_ADSyncList" role="tablist" aria-multiselectable="true">
                                            <div class="col-xs-12" role="tab" id="SH_ADSyncList">
                                                <div class="card">
                                                    <div class="header" role="button" data-toggle="collapse" data-parent="#AS_ADSyncList" href="#<%= CSB_ADSyncList.ClientID%>" aria-expanded="true" aria-controls="SH_ADSyncList">
                                                        <h3>
                                                            <%= Resources.Content.GN0000395%>
                                                        </h3>
                                                    </div>
                                                    <div id="CSB_ADSyncList" runat="server" class="body panel-collapse collapse" role="tabpanel" aria-labelledby="SH_ADSyncList" aria-expanded="false">
                                                        <div class="row">
                                                            <div class="col-md-3 col-sm-6 col-xs-12" runat="server" id="td_Owner">
                                                                <div class="form-group form-float">
                                                                    <asp:DropDownList ID="DDl_Owner" runat="server" onchange="setOwnerCookie(this)"></asp:DropDownList>
                                                                </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="txtTemplateName" runat="server" MaxLength="200"></asp:TextBox>
                                                                        <asp:Label ID="Lbl_TemplateName" runat="server" EnableViewState="false" Text="<%$ Resources:Content,String273%>" 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">
                                                                    <asp:DropDownList ID="DDl_OU" runat="server">
                                                                    </asp:DropDownList>
                                                                </div>
                                                            </div>
                                                            <div class="col-xs-12">
                                                                <div class="form-group form-float">
                                                                    <asp:Button ID="Btn_Search" 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>

                                    <div class="row">
                                        <div class="col-xs-12 Div_OpsRow" runat="server" id="Tbl_operations">
                                            <div class="card">
                                                <div class="header">
                                                    <h3>
                                                        <%= Resources.Content.GN00001320%>      <%--Operations--%>
                                                    </h3>
                                                </div>
                                                <div class="body">
                                                    <asp:Button ID="Btn_AddAdSyncTemplate" runat="server" class="btn btn-primary waves-effect btnAction" Text="<%$ Resources:Content,strAddAdSyncTemplate%>" />
                                                </div>
                                            </div>
                                        </div>
                                        <div class="col-xs-12">
                                            <%--Start GV_List--%>
                                            <asp:GridView CssClass="table table-bordered table-striped table-hover" EmptyDataText="<%$ Resources:Content, GN00001375 %>"
                                                ID="GV_List" AllowPaging="true" AllowSorting="true" runat="server" AutoGenerateColumns="False">

                                                <Columns>

                                                    <asp:TemplateField SortExpression="TemplateName" HeaderText="<%$ Resources:Content, String273 %>" HeaderStyle-CssClass="col-xs-4" ItemStyle-CssClass="col-xs-4">
                                                        <ItemTemplate>
                                                            <%#DataBinder.Eval(Container, "DataItem.TemplateName")%>
                                                            <asp:HiddenField ID="Hf_TemplateName" runat="server" Value='<%# DataBinder.Eval(Container, "DataItem.TemplateName")%>' />
                                                        </ItemTemplate>
                                                    </asp:TemplateField>
                                                    <asp:TemplateField SortExpression="Description" HeaderText="<%$ Resources:Content, GN0000597 %>" HeaderStyle-CssClass="col-xs-5" ItemStyle-CssClass="col-xs-5">
                                                        <ItemTemplate>
                                                            <%#DataBinder.Eval(Container, "DataItem.Description")%>
                                                        </ItemTemplate>
                                                    </asp:TemplateField>
                                                    <asp:TemplateField HeaderText="<%$ Resources:Content, strDefaultTemplate %>" HeaderStyle-CssClass="col-xs-2" ItemStyle-CssClass="col-xs-2">
                                                        <ItemTemplate>
                                                            <asp:Image ID="Img_OutlookLicenseEnabled" runat="server"
                                                                ImageUrl='<%# IIf(DataBinder.Eval(Container, "DataItem.IsDefault") = True, ResolveClientUrl("~/Images/icons/yes.png"), ResolveClientUrl("~/Images/icons/error.png"))%>' />
                                                            <asp:Label ID="lblIsDefault" Text='<%#IsDefault(DataBinder.Eval(Container, "DataItem.IsDefault").ToString())%>' runat="server">
                                                            </asp:Label>
                                                        </ItemTemplate>
                                                    </asp:TemplateField>
                                                    <asp:TemplateField HeaderText='<%$ Resources:Content, GN0000360 %>' HeaderStyle-CssClass="col-xs-1" ItemStyle-CssClass="col-xs-1">
                                                        <ItemTemplate>
                                                            <ul class="option-menu" id="div_options" runat="server">
                                                                <li class="dropdown">
                                                                    <a href="javascript:void(0);" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">
                                                                        <i class="material-icons">menu</i>
                                                                    </a>
                                                                    <ul class="dropdown-menu pull-right">
                                                                        <li>
                                                                            <asp:LinkButton ID="LB_Edit" runat="server" Text="<%$Resources:Content,GN0000276%>"
                                                                                CommandName="EditTemp" CommandArgument='<%#DataBinder.Eval(Container, "DataItem.AdSyncTemplateID")%>'></asp:LinkButton></li>
                                                                        <li>
                                                                            <asp:LinkButton ID="LB_SetAsDefault" CssClass="btnAction" Visible="<%# IsLoggedInAsProvider%>" runat="server" Text="<%$Resources:Content,strSetAsDefault%>"
                                                                                CommandName="SetAsDefault" CommandArgument='<%#DataBinder.Eval(Container, "DataItem.AdSyncTemplateID")%>'></asp:LinkButton></li>
                                                                        <li>
                                                                            <asp:LinkButton ID="LB_RemoveTemp" CssClass="btnAction" Text="<%$ Resources:Content,GN0000278%>" CommandArgument='<%#DataBinder.Eval(Container, "DataItem.AdSyncTemplateID")%>' runat="server"
                                                                                CommandName="DeleteTemp" Visible='<%# Not DataBinder.Eval(Container, "DataItem.IsDefault") AndAlso IsLoggedInAsProvider %>'>
                                                                            </asp:LinkButton></li>

                                                                        <EM:ConfirmButtonExtender ID="CBE_Remove" ConfirmText="<%$ Resources:Content,strDeleteTemplateConfirmation%>"
                                                                            runat="server" TargetControlID="LB_RemoveTemp" />
                                                                    </ul>
                                                                </li>
                                                            </ul>
                                                        </ItemTemplate>
                                                    </asp:TemplateField>
                                                </Columns>
                                                <%--PagerTemplate Start--%>
                                                <PagerTemplate>
                                                    <EM:Pager ID="Pager1" runat="server" />
                                                </PagerTemplate>
                                                <%--PagerTemplate End--%>
                                            </asp:GridView>
                                        </div>
                                    </div>
                                </asp:Panel>

                            </asp:Panel>
                        </ContentTemplate>
                    </EM:TabPanel>

                </EM:TabContainer>
            </div>
        </div>
    </div>
</asp:Content>

