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

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %>
<%@ Register Src="../../../UserControls/GridViewPager/GridViewPager.ascx" TagName="GridViewPager" TagPrefix="uc1" %>
<%@ Register Src="~/UserControls/Common/ScreenGroup/ScreenGroup.ascx" TagName="ScreenGroupControl" TagPrefix="ScreenGroup" %>
<%@ Register Src="~/UserControls/HTMLEditor/HTMLEditorControl.ascx" TagName="HTMLEditor" TagPrefix="uc1" %>

<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
    <asp:UpdatePanel ID="AlertConfigurationUpdatePanel" runat="server">
        <ContentTemplate>
            <div id="divContentPage">
                <div style="width: 100%">
                    <table width="100%" cellpadding="0" cellspacing="0">
                    </table>
                    <div class="spacer5">
                        <asp:Image ID="Image3" runat="server" ImageUrl="~/Images/spacer.gif"></asp:Image>
                    </div>
                    <table width="100%" border="0" style="vertical-align: top; margin-top: -1px" cellpadding="0" cellspacing="0">
                        <tr>
                            <td class="dashBoardLeftCont" style="width: 160px" valign="top">
                                <div id="leftContainer">
                                    <dl class="expandMenu">
                                        <table width="100%" border="0">
                                            <tr>
                                                <td>
                                                    <div class="himssuHeader3WireBox">
                                                        <dt id="dtSETTINGS" onclick="showHideSwitch('ddSETTINGS')">
                                                            <table width="100%" cellpadding="0" cellspacing="0">
                                                                <tr>
                                                                    <td>
                                                                        <div class="himsBoxHeader">
                                                                            <div class="leftdiv">
                                                                            </div>
                                                                            <div class="himsBoxTitle">
                                                                                <table width="100%">
                                                                                    <tr>
                                                                                        <td style="width: 100%">
                                                                                            <div class="headerText">
                                                                                                Master
                                                                                            </div>
                                                                                        </td>
                                                                                        <td>
                                                                                            <img name="ddSETTINGSButton" id="ddSETTINGSButton" src="../../../Images/buttonCollapse.gif"></img>
                                                                                        </td>
                                                                                    </tr>
                                                                                </table>
                                                                            </div>
                                                                        </div>
                                                                    </td>
                                                                </tr>
                                                            </table>
                                                        </dt>
                                                        <dd style="text-align: left; margin: 0px" id="ddSETTINGS">
                                                            <table width="100%" cellpadding="0" cellspacing="0">
                                                                <tr>
                                                                    <td>
                                                                        <div class="himsBoxContent leftTableContainer">
                                                                            <div class="leftUlMenu">
                                                                                <ul id="sidebarmenu1">
                                                                                    <ScreenGroup:ScreenGroupControl EnableViewState="true" ID="ScreenGroupControl" ScreenGroupId="124"
                                                                                        Visible="true" runat="server" />
                                                                                </ul>
                                                                            </div>
                                                                        </div>
                                                                    </td>
                                                                </tr>
                                                            </table>
                                                            <div class="himsBoxFooter">
                                                                <div>
                                                                </div>
                                                            </div>
                                                        </dd>
                                                    </div>
                                                </td>
                                            </tr>
                                        </table>
                                    </dl>
                                </div>
                            </td>
                            <td class="minMaxButton" style="width: 1%; margin: 0; vertical-align: top">
                                <asp:Image ID="Image7" runat="server" ImageUrl="~/Images/spacer.gif"></asp:Image>
                            </td>
                            <td style="vertical-align: top">
                                <div class="himssuHeader2WireBox">
                                    <div class="himsBoxHeader">
                                        <asp:Panel ID="Panel1" runat="server" meta:resourcekey="Panel1Resource1">
                                            <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" Text="Existing Alert Configurations"
                                                        meta:resourcekey="Label3Resource1"></asp:Label>
                                                    <cc1:CollapsiblePanelExtender ID="cpe" runat="server" TargetControlID="DetailPanel"
                                                        ExpandControlID="Image1" CollapseControlID="Image1" TextLabelID="Label3" Collapsed="True"
                                                        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="outerBox pTop5">
                                                    <div class="controlLabelWidth">
                                                        <asp:Label ID="ModuleNameSearchLabel" runat="server" Text="Module Name"
                                                            meta:resourcekey="ModuleNameSearchLabelResource1"></asp:Label>
                                                    </div>
                                                    <div class="fLeft pRight5">
                                                        <asp:DropDownList ID="ModuleNameSearchDropDownList" runat="server"
                                                            Width="150px" AutoPostBack="True" SkinID="CustomWidthDropDownList"
                                                            OnSelectedIndexChanged="ModuleNameSearchDropDownList_SelectedIndexChanged"
                                                            onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()"
                                                            meta:resourcekey="ModuleNameSearchDropDownListResource1">
                                                        </asp:DropDownList>
                                                    </div>
                                                </div>
                                                <div class="outerBoxPreBtn pTop5">
                                                    <div class="controlLabelWidth">
                                                        <asp:Label ID="EventNameSearchLabel" runat="server" Text="Event Name"
                                                            meta:resourcekey="EventNameSearchLabelResource1"></asp:Label>
                                                    </div>
                                                    <div class="fLeft pRight5">
                                                        <asp:DropDownList ID="EventNameSearchDropDownList" runat="server" Width="150px"
                                                            SkinID="CustomWidthDropDownList" onmouseleave="showHideTooltip()"
                                                            onmouseenter="showHideTooltip()"
                                                            meta:resourcekey="EventNameSearchDropDownListResource1">
                                                        </asp:DropDownList>
                                                    </div>
                                                </div>
                                                <div class="outerBox pTop5">
                                                    <div class="searchBoxBtn">
                                                        <asp:Button ID="SearchButton" runat="server" Text="Search"
                                                            OnClick="SearchButton_Click" SkinID="0" CssClass="PrimaryButton" />
                                                        <asp:Button ID="ClearButton" runat="server" Text="Clear"
                                                            OnClick="ClearSearchButton_Click" meta:resourcekey="ClearButtonResource1" />
                                                    </div>
                                                </div>
                                                <div class="cBoth">
                                                </div>
                                                <div id="ExistingAlertConfigurationsDiv" runat="server">
                                                    <div class="spacer">
                                                        <asp:Image ID="Image2" runat="server" ImageUrl="~/Images/spacer.gif"
                                                            meta:resourcekey="Image2Resource1" />
                                                    </div>
                                                    <div class="himssuHeader1WireBox">
                                                        <div class="himsBoxHeader" id="GridViewPagerDiv" runat="server" visible="False">
                                                            <div class="leftdiv">
                                                            </div>
                                                            <div class="himsBoxTitle">
                                                                <div class="gridHeaderText fLeft">
                                                                    <asp:Label ID="GridViewLabel" Text="Alert Configuration List" runat="server"
                                                                        Font-Bold="True" meta:resourcekey="GridViewLabelResource1" ForeColor="White" />
                                                                </div>
                                                                <div class="fRight">
                                                                    <uc1:GridViewPager ID="ExistingAlertConfigurationsGridViewPager" runat="server"
                                                                        OnFirstRecordClick="ExistingAlertConfigurationsGridViewPager_FirstRecordClick" OnLastRecordClick="ExistingAlertConfigurationsGridViewPager_LastRecordClick"
                                                                        OnNextRecordClick="ExistingAlertConfigurationsGridViewPager_NextRecordClick" OnPrevRecordClick="ExistingAlertConfigurationsGridViewPager_PrevRecordClick"
                                                                        OnTextBoxValueChange="ExistingAlertConfigurationsGridViewPager_TextBoxValueChange" />
                                                                </div>
                                                            </div>
                                                        </div>
                                                        <div class="himsBoxContent">

                                                            <div id="DivHeader" style="vertical-align: top; width: 100%;">
                                                                <asp:Table ID="GridViewTable" runat="server" CellPadding="0" CellSpacing="0"
                                                                    BackColor="#E8E8E8" ForeColor="Black" Width="100%" GridLines="Both"
                                                                    CssClass="GridViewTableRow" meta:resourcekey="GridViewTableResource1">
                                                                </asp:Table>
                                                            </div>
                                                            <div id="GridViewMessageDiv" class="himsBoxContentMsg" runat="server"
                                                                visible="False">
                                                            </div>
                                                            <div id="DivData" class="Container" style="vertical-align: top; height: 109px; width: 99.6%;">
                                                                <asp:GridView ID="ExistingAlertConfigurationsGridView" runat="server"
                                                                    Width="100%" AllowPaging="True" PageSize="5"
                                                                    OnSelectedIndexChanged="ExistingAlertConfigurationsGridView_SelectedIndexChanged" ShowHeader="False"
                                                                    AutoGenerateColumns="False" OnPageIndexChanging="ExistingAlertConfigurationsGridView_PageIndexChanging"
                                                                    EmptyDataText="No Alert Configurations Found For The Search Criteria!"
                                                                    meta:resourcekey="ExistingAlertConfigurationsGridViewResource1">

                                                                    <Columns>
                                                                        <asp:CommandField ShowSelectButton="True" HeaderText="Select"
                                                                            meta:resourcekey="CommandFieldResource1">
                                                                            <ItemStyle Width="5%" />
                                                                        </asp:CommandField>
                                                                        <asp:BoundField DataField="ModuleName" HeaderText="Module Name"
                                                                            meta:resourcekey="BoundFieldResource1">
                                                                            <ItemStyle Width="8%" />
                                                                        </asp:BoundField>
                                                                        <asp:TemplateField HeaderText="Event Name"
                                                                            meta:resourcekey="TemplateFieldResource1">
                                                                            <ItemTemplate>
                                                                                <asp:Label runat="server" Text='<%# Bind("EventName") %>' ID="EventNameLabel"
                                                                                    meta:resourcekey="EventNameLabelResource1"></asp:Label>
                                                                                <asp:HiddenField ID="AlertId" runat="server" Value='<%# Eval("AlertId") %>' />
                                                                            </ItemTemplate>
                                                                            <ItemStyle Width="18%" />
                                                                        </asp:TemplateField>
                                                                        <asp:BoundField DataField="RecipientType" HeaderText="Recipient Type"
                                                                            meta:resourcekey="BoundFieldResource2">
                                                                            <ItemStyle Width="15%" />
                                                                        </asp:BoundField>
                                                                        <asp:BoundField DataField="AttachmentName" HeaderText="Attachment Type"
                                                                            meta:resourcekey="BoundFieldResource6">
                                                                            <ItemStyle Width="15%" />
                                                                        </asp:BoundField>
                                                                        <asp:BoundField DataField="Recipient" HeaderText="Recipient"
                                                                            meta:resourcekey="BoundFieldResource3">
                                                                            <ItemStyle Width="12%" />
                                                                        </asp:BoundField>
                                                                        <asp:BoundField DataField="ModeName" HeaderText="Alert Mode"
                                                                            meta:resourcekey="BoundFieldResource4">
                                                                            <ItemStyle Width="7%" />
                                                                        </asp:BoundField>
                                                                        <asp:BoundField DataField="Trigger" HeaderText="Trigger"
                                                                            meta:resourcekey="BoundFieldResource5">
                                                                            <ItemStyle Width="5%" />
                                                                        </asp:BoundField>
                                                                        <asp:TemplateField HeaderText="Duration"
                                                                            meta:resourcekey="TemplateFieldResource2">
                                                                            <ItemTemplate>
                                                                                <asp:Label runat="server" Text='<%# Bind("DurationValue") %>'
                                                                                    ID="DurationValueLabel" meta:resourcekey="DurationValueLabelResource1"></asp:Label>
                                                                                <asp:Label runat="server" Text='<%# Bind("DurationFormat") %>'
                                                                                    ID="DurationFormatLabel" meta:resourcekey="DurationFormatLabelResource1"></asp:Label>
                                                                            </ItemTemplate>
                                                                            <ItemStyle Width="7%" />
                                                                        </asp:TemplateField>
                                                                        <asp:TemplateField HeaderText="InActive"
                                                                            meta:resourcekey="TemplateFieldResource3">
                                                                            <ItemTemplate>
                                                                                <asp:Label ID="InActiveLabel" runat="server"
                                                                                    Text='<%# DataBinder.Eval(Container.DataItem,"IsObsolete").ToString().ToUpper()=="TRUE"?"Y":"N" %>'
                                                                                    meta:resourcekey="InActiveLabelResource1"></asp:Label>
                                                                            </ItemTemplate>
                                                                            <ItemStyle HorizontalAlign="Center" Width="7%" />
                                                                        </asp:TemplateField>
                                                                    </Columns>
                                                                    <PagerSettings Visible="False" />
                                                                </asp:GridView>
                                                            </div>
                                                        </div>
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                    </asp:Panel>
                                </div>
                                <div class="spacer">
                                    <asp:Image ID="spacerImage" runat="server" ImageUrl="~/Images/spacer.gif"
                                        meta:resourcekey="spacerImageResource1" />
                                </div>
                                <div class="himssuHeader1WireBox">
                                    <div class="himsBoxHeader">
                                        <div class="leftdiv">
                                        </div>
                                        <div class="himsBoxTitle">
                                            <div class="headerText">
                                                <asp:Label ID="HeaderLabel" runat="server" Text="Alert Configuration"
                                                    meta:resourcekey="HeaderLabelResource1"></asp:Label>
                                            </div>
                                        </div>
                                    </div>
                                    <div class="himsBoxContent">
                                        <div class="contentHolder">
                                            <div class="outerBox pTop5">
                                                <div class="controlLabelWidth">
                                                    <asp:Label ID="ModuleNameLabel" runat="server" Text="Module Name"
                                                        SkinID="MandatoryLabel" meta:resourcekey="ModuleNameLabelResource1"></asp:Label>
                                                </div>
                                                <div class="fLeft pRight5">
                                                    <asp:DropDownList ID="ModuleDropDownList" runat="server" Width="150px"
                                                        AutoPostBack="True" SkinID="CustomWidthDropDownList"
                                                        OnSelectedIndexChanged="ModuleNameDropDownList_SelectedIndexChanged"
                                                        onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()"
                                                        meta:resourcekey="ModuleDropDownListResource1">
                                                    </asp:DropDownList>
                                                </div>
                                            </div>
                                            <div class="outerBox pTop5">
                                                <div class="controlLabelWidth">
                                                    <asp:Label ID="EventNameLabel" runat="server" Text="Event Name"
                                                        SkinID="MandatoryLabel" meta:resourcekey="EventNameLabelResource2"></asp:Label>
                                                </div>
                                                <div class="fLeft pRight5">
                                                    <asp:DropDownList ID="EventDropDownList" runat="server" Width="150px"
                                                        AutoPostBack="True" SkinID="CustomWidthDropDownList"
                                                        OnSelectedIndexChanged="EventDropDownList_SelectedIndexChanged"
                                                        onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()"
                                                        meta:resourcekey="EventDropDownListResource1">
                                                    </asp:DropDownList>
                                                </div>
                                            </div>
                                            <div class="cBoth"></div>
                                            <div class="outerBox pTop5">
                                                <div class="controlLabelWidth">
                                                    <asp:Label ID="RecipientTypeLabel" runat="server" Text="Recipient Type"
                                                        SkinID="MandatoryLabel" meta:resourcekey="RecipientTypeLabelResource1"></asp:Label>
                                                </div>
                                                <div class="fLeft pRight5">
                                                    <asp:DropDownList ID="RecipientTypeDropDownList" runat="server" Width="150px"
                                                        SkinID="CustomWidthDropDownList" AutoPostBack="True"
                                                        OnSelectedIndexChanged="RecipientTypeDropDownList_SelectedIndexChanged"
                                                        onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()"
                                                        meta:resourcekey="RecipientTypeDropDownListResource1">
                                                    </asp:DropDownList>
                                                </div>
                                            </div>
                                            <div class="outerBox pTop5">
                                                <div class="controlLabelWidth">
                                                    <asp:Label ID="RecipientLabel" runat="server" Text="Recipient"
                                                        SkinID="MandatoryLabel" meta:resourcekey="RecipientLabelResource1"></asp:Label>
                                                </div>
                                                <div class="fLeft pRight5">
                                                    <asp:DropDownList ID="RecipientDropDownList" runat="server" Width="150px"
                                                        SkinID="CustomWidthDropDownList" onmouseleave="showHideTooltip()"
                                                        onmouseenter="showHideTooltip()"
                                                        meta:resourcekey="RecipientDropDownListResource1">
                                                    </asp:DropDownList>
                                                </div>
                                            </div>
                                            <div class="cBoth"></div>
                                            <div class="outerBox pTop5">
                                                <div class="controlLabelWidth">
                                                    <asp:Label ID="AlertModeLabel" runat="server" Text="Alert Mode"
                                                        SkinID="MandatoryLabel" meta:resourcekey="AlertModeLabelResource1"></asp:Label>
                                                </div>
                                                <div class="fLeft pRight5">
                                                    <asp:DropDownList ID="AlertModeDropDownList" runat="server" Width="150px"
                                                        AutoPostBack="True" SkinID="CustomWidthDropDownList"
                                                        OnSelectedIndexChanged="AlertModeDropDownList_SelectedIndexChanged"
                                                        onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()"
                                                        meta:resourcekey="AlertModeDropDownListResource1">
                                                    </asp:DropDownList>
                                                </div>
                                            </div>
                                            <div class="cBoth"></div>
                                            <div class="outerBox pTop5">
                                                <div class="controlLabelWidth">
                                                    <asp:Label ID="TriggerLabel" runat="server" Text="Trigger"
                                                        SkinID="MandatoryLabel" meta:resourcekey="TriggerLabelResource1"></asp:Label>
                                                </div>
                                                <div class="fLeft pRight5">
                                                    <asp:DropDownList ID="TriggerDropDownList" runat="server" Width="150px"
                                                        AutoPostBack="True" SkinID="CustomWidthDropDownList"
                                                        onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()"
                                                        meta:resourcekey="TriggerDropDownListResource1">
                                                    </asp:DropDownList>
                                                </div>
                                            </div>
                                            <div class="outerBox pTop5">
                                                <div class="controlLabelWidth">
                                                    <asp:Label ID="DurationLabel" runat="server" Text="Duration"
                                                        SkinID="MandatoryLabel" meta:resourcekey="DurationLabelResource1"></asp:Label>
                                                </div>
                                                <div class="fLeft pRight5">
                                                    <asp:TextBox ID="DurationTextBox" runat="server" Width="38px"
                                                        SkinID="CustomWidthTextBox" MaxLength="3"
                                                        meta:resourcekey="DurationTextBoxResource1"></asp:TextBox>
                                                    <asp:DropDownList ID="DurationDropDownList" runat="server" Width="100px"
                                                        SkinID="CustomWidthDropDownList" onmouseleave="showHideTooltip()"
                                                        onmouseenter="showHideTooltip()"
                                                        meta:resourcekey="DurationDropDownListResource1">
                                                    </asp:DropDownList>
                                                </div>
                                            </div>
                                            <div class="cBoth"></div>
                                            <div class="outerBox pTop5">
                                                <div class="controlLabelWidth">
                                                    <asp:Label ID="AttachmentTypeLabel" runat="server" Text="Attachment Type"
                                                        meta:resourcekey="AttachmentTypeLabellResource1"></asp:Label>
                                                </div>
                                                <div class="fLeft pRight5">
                                                    <asp:DropDownList ID="AttachmentTypeDropDownList" runat="server" Width="150px"
                                                        AutoPostBack="false" SkinID="CustomWidthDropDownList"
                                                        onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()"
                                                        meta:resourcekey="AttachmentTypeDropDownListResource1">
                                                    </asp:DropDownList>
                                                </div>
                                            </div>
                                            <div class="cBoth"></div>
                                            <div class="outerBox pTop5" id="InActiveControlRow" runat="server">
                                                <div class="fLeft">
                                                    <asp:CheckBox ID="InActiveCheckBox" runat="server"
                                                        meta:resourcekey="InActiveCheckBoxResource1" />
                                                </div>
                                                <div class="fLeft pLeft5 pTop5">
                                                    <asp:Label ID="InActiveLabel" runat="server" Text="In Active"
                                                        meta:resourcekey="InActiveLabelResource2"></asp:Label>
                                                </div>
                                            </div>

                                            <div class="cBoth">
                                            </div>
                                            <table id="MailTable" runat="server" visible="false">
                                                <tr>
                                                    <td>
                                                        <div class="spacer5">
                                                            <asp:Image ID="Image4" runat="server" ImageUrl="~/Images/spacer.gif"
                                                                meta:resourcekey="Image2Resource1" />
                                                        </div>
                                                    </td>
                                                </tr>
                                                <tr>
                                                    <td style="width: 20%">
                                                        <asp:ListBox Height="200px" Width="200px" ID="lstParameter" runat="server" DataTextField="ColumnNames"
                                                            DataValueField="ColumnNames" onmousedown="d = new drag(this)" onmouseup="d.drop(this.form.SMSTextBox)"
                                                            onmouseout="if (typeof d != 'undefined') d.setIndex()"
                                                            meta:resourcekey="lstParameterResource1"></asp:ListBox>
                                                    </td>
                                                    <td colspan="2">
                                                        <asp:Panel ID="MailPanel" runat="server" Height="198px" Width="100%"
                                                            meta:resourcekey="MailPanelResource1">
                                                            <uc1:HTMLEditor ID="MailTextBox" runat="server" />
                                                        </asp:Panel>
                                                        <asp:TextBox SkinID="MultiLineTextbox" ID="SMSTextBox" runat="server" Height="198px"
                                                            Width="200px" multiline="true" TextMode="MultiLine" Visible="False" onmouseleave="showHideTooltip()"
                                                            onmouseenter="showHideTooltip()" meta:resourcekey="SMSTextBoxResource1"></asp:TextBox>
                                                    </td>
                                                </tr>
                                            </table>

                                            <div class="cBoth"></div>
                                        </div>
                                    </div>
                                </div>
                            </td>
                        </tr>
                    </table>
                </div>
            </div>
            <div class="spacer">
                <img src="../../../Images/spacer.gif" />
            </div>
        </ContentTemplate>
    </asp:UpdatePanel>
  <%--  <script data-main="../../../JavaScript/rjs/encrypt/alert-encrypt" src="../../../JavaScript/rjs/require.js"></script>   --%>
      <script data-main='<%=ResolveUrl("~/JavaScript/rjs/alert")%>' src='<%=ResolveUrl("~/JavaScript/rjs/require.js")%>'></script>
</asp:Content>