<%@ page language="C#" masterpagefile="~/Pages/Common/MasterPages/MainMasterPage_new.master" autoeventwireup="true" inherits="Pages_Components_Alert_ExternalReceipient_, App_Web_zqbu4vcs" uiculture="auto" meta:resourcekey="PageResource1" enableEventValidation="false" viewStateEncryptionMode="Never" %>

<%@ Register Src="../../../UserControls/GridViewPager/GridViewPager.ascx" TagName="GridViewPager" TagPrefix="uc1" %>
<%@ Register Assembly="Sapphire.Ohu.Web.ControlToolKit.Controls" Namespace="Sapphire.Ohu.Web.ControlToolKit.Controls" TagPrefix="Ctk" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %>
<%@ Register Src="~/UserControls/HTMLEditor/HTMLEditorControl.ascx" TagName="HTMLEditor" TagPrefix="uc1" %>

<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
    <asp:UpdatePanel ID="UP1" runat="server">
        <ContentTemplate>
            <div class="himssuHeader2WireBox">
                <div class="himsBoxHeader">
                    <asp:Panel ID="TopPanel" runat="server" meta:resourcekey="TopPanelResource1">
                        <div class="leftdiv">
                        </div>
                        <div class="himsBoxTitle">
                            <asp:Image ID="Image1" runat="server" class="fLeft"
                                meta:resourcekey="Image1Resource1" />
                            <div class="headerText">
                                <asp:Label ID="Label3" runat="server" meta:resourcekey="Label3Resource1"></asp:Label>
                                <cc1:CollapsiblePanelExtender ID="cpe" runat="server" TargetControlID="DetailPanel"
                                    ExpandControlID="Image1" CollapseControlID="Image1" TextLabelID="Label3" Collapsed="True"
                                    CollapsedText="  Search" ExpandedText="  Search" ImageControlID="Image1" ExpandedImage="~/images/buttonCollapse.gif"
                                    CollapsedImage="~/images/buttonExpand.gif" Enabled="True" />
                            </div>
                        </div>
                    </asp:Panel>
                </div>
                <asp:Panel ID="DetailPanel" runat="server"
                    meta:resourcekey="DetailPanelResource1">
                    <div class="himsBoxContent">
                        <div class="contentHolder">
                            <div class="outerBoxPreBtn pTop5">
                                <div class="controlLabelWidth">
                                    <asp:Label ID="TemplateNameSearchlabel" Text="Name" runat="server"
                                        meta:resourcekey="TemplateNameSearchlabelResource1"></asp:Label>
                                </div>
                                <div class="fLeft pRight5">
                                    <asp:TextBox ID="RecipientNameSearchTextBox" runat="server"
                                        meta:resourcekey="TemplateNameSearchTextBoxResource1"></asp:TextBox>
                                </div>
                            </div>
                            <div class="fLeft pRight5 pTop10">
                                <asp:Button runat="server" ID="SearchButton" Text="Search"
                                    OnClick="SearchButton_Click" SkinID="0" CssClass="PrimaryButton" />
                                <asp:Button ID="ResetButton" runat="server" Text="Clear"
                                    OnClick="ResetButton_Click" />
                            </div>
                            <div class="cBoth">
                            </div>
                            <div id="RecipientGridDiv" runat="server" visible="False">
                                <div class="spacer">
                                    <asp:Image ID="Image4" runat="server" ImageUrl="~/Images/spacer.gif"
                                        meta:resourcekey="Image4Resource1" />
                                </div>
                                <div class="himssuHeader1WireBox" id="PatientRelationDiv" runat="server" style="width: 100%">
                                    <div class="himsBoxHeader" id="ListDiv" runat="server" visible="False">
                                        <div class="leftdiv">
                                        </div>
                                        <div class="himsBoxTitle" style="width: 99%">
                                            <div class="headerText">
                                                <div class="fLeft">
                                                    List
                                                </div>
                                            </div>
                                            <div align="right" class="fRight" style="margin-top: -3px;">
                                                <uc1:GridViewPager ParentGridView="TemplateGridView" ID="ExternalRecipientGridView_GridViewPager"
                                                    runat="server" OnFirstRecordClick="ExternalRecipientGridView_GridViewPager_FirstRecordClick"
                                                    OnLastRecordClick="ExternalRecipientGridView_GridViewPager_LastRecordClick" OnNextRecordClick="ExternalRecipientGridView_GridViewPager_NextRecordClick"
                                                    OnPrevRecordClick="ExternalRecipientGridView_GridViewPager_PrevRecordClick" OnTextBoxValueChange="ExternalRecipientGridView_GridViewPager_TextBoxValueChange" />
                                            </div>
                                        </div>
                                    </div>
                                    <div class="himsBoxContent">
                                        <div id="DivHeader" style="vertical-align: top; width: 100%;">
                                            <asp:Table ID="ExternalRecipientGridViewTable" runat="server" CellPadding="0" CellSpacing="0"
                                                BackColor="#E8E8E8" ForeColor="Black" Width="100%" GridLines="Both"
                                                CssClass="GridViewTableRow"
                                                meta:resourcekey="TemplateMasterGridViewTableResource1">
                                            </asp:Table>
                                        </div>
                                        <div class="himsBoxContentMsg" id="GridMessageDiv" runat="server"
                                            visible="False">
                                        </div>
                                        <div id="DivData" class="Container" style="vertical-align: top; height: 109px; width: 99.6%;">
                                            <asp:GridView Width="100%" ID="ExternalRecipientGridView" runat="server" AutoGenerateColumns="False"
                                                DataKeyNames="Id,CreatedUserId,Name,Mobile,Email,IsObsolete"
                                                OnPageIndexChanging="TemplateGridView_PageIndexChanging"
                                                AllowPaging="True" EmptyDataText="No records found"
                                                PageSize="5" ShowHeader="False"
                                                OnRowDataBound="RecipientGridView_RowDataBound"
                                                meta:resourcekey="TemplateGridViewResource1">
                                                <Columns>
                                                    <asp:TemplateField ItemStyle-Width="5%" ItemStyle-HorizontalAlign="Center">
                                                        <ItemTemplate>
                                                            <asp:LinkButton ID="EditLinkButton" runat="server" CommandName="Select" OnClick="LinkButton_Click"
                                                                Text="Select" CausesValidation="false"></asp:LinkButton>
                                                        </ItemTemplate>
                                                        <ItemStyle HorizontalAlign="Center" Width="10%" />
                                                    </asp:TemplateField>
                                                    <asp:TemplateField Visible="False" meta:resourcekey="TemplateFieldResource1">
                                                        <ItemTemplate>
                                                            <asp:Label ID="TemplateIdLabel" runat="server" Text='<%# Bind("Id") %>' ToolTip='<%# Bind("Id") %>'
                                                                Visible="False"></asp:Label>
                                                        </ItemTemplate>
                                                        <ItemStyle Width="0%" />
                                                    </asp:TemplateField>
                                                    <asp:TemplateField Visible="False" meta:resourcekey="TemplateFieldResource3">
                                                        <ItemTemplate>
                                                            <asp:Label ID="CreatedUserIdLabel" runat="server" Text='<%# Bind("CreatedUserId") %>'
                                                                ToolTip='<%# Bind("CreatedUserId") %>' Visible="False"></asp:Label>
                                                        </ItemTemplate>
                                                        <ItemStyle Width="0%" />
                                                    </asp:TemplateField>
                                                    <asp:TemplateField HeaderText="Name" meta:resourcekey="TemplateFieldResource5">
                                                        <ItemTemplate>
                                                            <asp:Label ID="TitleLabel" runat="server" Width="100px" Text='<%# Bind("Name") %>'
                                                                ToolTip='<%# Bind("Name") %>' CssClass="boxEllips"></asp:Label>
                                                        </ItemTemplate>
                                                        <ItemStyle Width="25%" />
                                                    </asp:TemplateField>
                                                    <asp:TemplateField HeaderText="Mobile"
                                                        meta:resourcekey="TemplateFieldResource6">
                                                        <ItemTemplate>
                                                            <asp:Label ID="MobileLabel" runat="server" Width="100px" Text='<%# Bind("Mobile") %>'
                                                                CssClass="boxEllips" ToolTip='<%# Bind("Mobile") %>'></asp:Label>
                                                        </ItemTemplate>
                                                        <ItemStyle Width="20%" />
                                                    </asp:TemplateField>
                                                    <asp:TemplateField HeaderText="Email"
                                                        meta:resourcekey="TemplateFieldResource6">
                                                        <ItemTemplate>
                                                            <asp:Label ID="EmailLabel" runat="server" Width="100px" Text='<%# Bind("Email") %>'
                                                                CssClass="boxEllips" ToolTip='<%# Bind("Email") %>'></asp:Label>
                                                        </ItemTemplate>
                                                        <ItemStyle Width="20%" />
                                                    </asp:TemplateField>
                                                    <asp:TemplateField HeaderText="InActive"
                                                        meta:resourcekey="TemplateFieldResource6" ItemStyle-HorizontalAlign="Center">
                                                        <ItemTemplate>
                                                            <asp:Label ID="ObsoleteLabel" runat="server" Text='<%# DataBinder.Eval(Container.DataItem,"IsAbsolete").ToString().ToUpper()=="TRUE"?"Y":"N" %>'></asp:Label>
                                                        </ItemTemplate>
                                                        <ItemStyle Width="10%" />
                                                    </asp:TemplateField>
                                                </Columns>
                                                <PagerSettings Visible="False" />
                                            </asp:GridView>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </asp:Panel>
            </div>
            <div class="spacer">
                <asp:Image ID="Image3" runat="server" ImageUrl="~/Images/spacer.gif" meta:resourcekey="Image3Resource1" />
            </div>
            <div class="himssuHeader1WireBox">
                <div class="himsBoxHeader">
                    <div class="leftdiv">
                    </div>
                    <div class="himsBoxTitle">
                        <div class="headerText">
                            Maintainance
                        </div>
                    </div>
                </div>
                <div class="himsBoxContent">
                    <div class="contentHolder">
                        <div class="outerBox pTop5">
                            <div class="controlLabelWidth">
                                <asp:Label ID="RecipientNameLabel" runat="server" Text="Name" SkinID="MandatoryLabel"
                                    meta:resourcekey="TemplateNameLabelResource1"></asp:Label>
                            </div>
                            <div class="fLeft pRight5">
                                <asp:TextBox ID="RecipientNameTextBox1" runat="server" AutoPostBack="False" MaxLength="100"
                                    onmouseleave="showHideTooltip()"
                                    onmouseenter="showHideTooltip()" SkinID="CustomWidthTextbox" Width="150px"
                                    meta:resourcekey="TemplateNameTextBoxResource1"></asp:TextBox>
                                <asp:HiddenField ID="RecipientIdHiddenField" Value='<%#Eval("Id") %>' runat="server" />
                            </div>
                        </div>
                        <div class="cBoth">
                        </div>
                        <div class="outerBox pTop5">
                            <div class="controlLabelWidth">
                                <asp:Label ID="MobileLabel2" runat="server" Text="Mobile No."
                                    meta:resourcekey="Label2Resource1"></asp:Label>
                            </div>
                            <div class="fLeft pRight5">
                                <asp:TextBox SkinID="CustomWidthTextbox" ID="MobileTextBox2" MaxLength="300"
                                    runat="server" Width="150px" onmouseleave="showHideTooltip()"
                                    onmouseenter="showHideTooltip()"
                                    meta:resourcekey="TemplateDescriptionTextBoxResource1"></asp:TextBox>&nbsp;
                            </div>
                        </div>
                        <div class="cBoth">
                        </div>
                        <div class="outerBox pTop5">
                            <div class="controlLabelWidth">
                                <asp:Label ID="EmailLabel3" runat="server" Text="Email Id"
                                    meta:resourcekey="Label12Resource1"></asp:Label>
                            </div>
                            <div class="fLeft pRight5">
                                <asp:TextBox SkinID="EmailTextbox3" ID="EmailTextBox4" MaxLength="300"
                                    runat="server" Width="150px" onmouseleave="showHideTooltip()"
                                    onmouseenter="showHideTooltip()"
                                    meta:resourcekey="TemplateDescriptionTextBoxResource1"></asp:TextBox>&nbsp;
                            </div>
                        </div>
                        <div class="cBoth">
                        </div>
                        <div class="outerBox pTop5" id="IdObsolete" runat="server">
                            <div class="fLeft">
                                <asp:CheckBox ID="ObsoleteCheckBox" runat="server"
                                    meta:resourcekey="ObsoleteCheckBoxResource1" />
                            </div>
                            <div class="fLeft pLeft5 pTop5">
                                <asp:Label ID="ObsoleteLabel" runat="server" Text="InActive"
                                    meta:resourcekey="ObsoleteLabelResource2"></asp:Label>
                            </div>
                        </div>
                        <div class="cBoth">
                        </div>
                    </div>
                </div>
            </div>
        </ContentTemplate>
    </asp:UpdatePanel>
   <%-- <script data-main="../../../JavaScript/rjs/encrypt/external-receipient-encrypt" src="../../../JavaScript/rjs/require.js"></script>--%>
      <script data-main='<%=ResolveUrl("~/JavaScript/rjs/external-receipient")%>' src='<%=ResolveUrl("~/JavaScript/rjs/require.js")%>'></script>
</asp:Content>