<%@ Page Language="vb" AutoEventWireup="false" CodeBehind="Counter_Party_EmailConfig.aspx.vb" Inherits="FinIQWebApp.Counter_Party_EmailConfig" MasterPageFile="~/FiniqAppMasterPage.Master" %>

<%@ Register Assembly="System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" Namespace="System.Web.UI" TagPrefix="asp" %>



<asp:Content ID="Content1" runat="server" ContentPlaceHolderID="MainContent">
    <asp:UpdateProgress ID="UpdateProgress2" runat="server" AssociatedUpdatePanelID="UpdatePanel1"
        DisplayAfter="0">
        <ProgressTemplate>
            <div class="divLoading">
                <img alt="Loading" src="../App_Resources/loading.gif" /><span class="lbl">Loading...&nbsp;&nbsp;</span>
            </div>
        </ProgressTemplate>
    </asp:UpdateProgress>

    <asp:UpdatePanel ID="UpdatePanel1" runat="server" UpdateMode="Conditional" >
        <ContentTemplate>

            <style>
                #btnLoad:hover, #btnSave:hover {
                    cursor: pointer;
                }

                .lblSuccess {
                    color: green;
                }

                .divLoading {
                    position: absolute;
                    top: 48px;
                    left: 260px;
                }

                fieldset {
                    border-color: white;
                    border: solid 1px #dddddd;
                    box-sizing: border-box;
                    
                    border-collapse: collapse;
                }
                /*.Grid .GridItem:first-child {
                    background-color:  #f9f9f9 !important;
                }*/
            </style>
            <script>
                function AllowAlphaNumericOnly(e) {

                    var keycode;
                    if (window.event)
                        keycode = window.event.keyCode;
                    else if (event)
                        keycode = event.keyCode;
                    else if (e)
                        keycode = e.which;
                    else return true;

                    if ((keycode > 47 && keycode <= 57) || (keycode > 64 && keycode < 91) || (keycode > 96 && keycode < 123)) {

                        return true;
                    }

                    else { return false; }

                }

            </script>
            <table>
                <tr>
                    <td>
                        <asp:Label ID="lblError" CssClass="lblError" runat="server" Style="margin-bottom: 20px !important" />
                        <asp:Label ID="lblSuccess" CssClass="lblError" runat="server" Style="margin-bottom: 20px !important" />
                    </td>
                </tr>
            </table>
            <table style="width: 100%; margin-top: 5px;">
                <tr>
                    <td>
                        <asp:Panel ID="pnlOne" runat="server" >
                            <table>
                                <tr>
                                    <td>
                                        <asp:Label ID="lblProduct" runat="server" Text="Product Name  " CssClass="lbl" />
                                    </td>
                                    <td>
                                        <asp:DropDownList ID="ddlProduct" runat="server" AutoPostBack="True" Style="padding: 5px;" Width="200px">
                                            <%--<asp:ListItem Text="test" Value="test"/>--%>
                                        </asp:DropDownList>
                                    </td>

                                    <td>
                                        <asp:Label ID="lblMsgType" runat="server" Text="Message Type  " CssClass="lbl" Style="padding-left: 17px;" />
                                    </td>
                                    <td>
                                        <asp:DropDownList ID="ddlMsgType" runat="server" AutoPostBack="True" Style="padding: 5px;" Width="200px">
                                            <asp:ListItem Text="RFQ" Value="RFQ" />
                                            <asp:ListItem Text="Order" Value="Order" />

                                        </asp:DropDownList>
                                    </td>

                                </tr>

                                <tr>
                                    <td>
                                        <asp:Label ID="lblProductVariation" runat="server" Text="Product Variation  " CssClass="lbl" />
                                    </td>
                                    <td>
                                        <asp:DropDownList ID="ddlProductVariation" runat="server" AutoPostBack="True" Style="padding: 5px;" Width="200px">
                                            <%--<asp:ListItem Text="test" Value="test"/>--%>
                                        </asp:DropDownList>
                                    </td>
                                    <td>
                                        <asp:Label ID="lblMsgDirection" runat="server" Text="Message Direction  " CssClass="lbl" Style="padding-left: 17px;" />
                                    </td>
                                    <td>
                                        <asp:DropDownList ID="ddlMsgDirection" runat="server" AutoPostBack="True" Style="padding: 5px;" Width="200px">
                                            <asp:ListItem Text="Request" Value="Request" />
                                            <asp:ListItem Text="Response" Value="Response" />
                                        </asp:DropDownList>
                                    </td>
                                </tr>

                                <tr>
                                    <td>
                                        <asp:Label ID="lblPriceProvider" runat="server" Text="Counterparty  " CssClass="lbl" />
                                    </td>
                                    <td>
                                        <asp:DropDownList ID="ddlPriceProvider" runat="server" AutoPostBack="True" Style="padding: 5px;" Width="200px">
                                            <%--<asp:ListItem Text="test" Value="test"/>--%>
                                        </asp:DropDownList>
                                    </td>
<%--                                    <Rishabh C, Joel D|05-Feb-2020|Changes done|As per discussions with Tushar A, Lehanshu k, Swanand L|JIRA Ref UBSSINT-202 User group related changes in Counter party email configuration>  --%>
                                    <td>
                                         <asp:Label ID="lblUserGrp" runat="server" Text="User Group  " CssClass="lbl" Style="padding-left: 17px;" />
                                    </td>
                                    <td>
                                        <asp:DropDownList ID="ddlUserGroup" runat="server" AutoPostBack="True" Style="padding: 5px;" Width="200px" >
                                            <%--<asp:ListItem Text="test" Value="test"/>--%>
                                        </asp:DropDownList>
                                    </td>
                                     <%--<Rishabh C, Joel D|05-Feb-2020|Changes done|As per discussions with Tushar A, Lehanshu k, Swanand L>--%>
                                </tr>
                                <tr style="margin-bottom:5px !important;"></tr>
                            </table>

                            <table>
                                <tr>
                                    <td>
                                        <asp:Button ID="btnLoad" Text="Load" runat="server" CssClass="btn" Width="100px" />
                                    </td>
                                    <td>
                                        <asp:Button ID="btnSave" Enabled="false" Text="Save" runat="server" CssClass="btn" Width="100px" />
                                    </td>
                                </tr>
                            </table>
                        </asp:Panel>
                    </td>
                </tr>
            </table>
            <table id="tblEmailSetup" runat="server" visible="false">
                <tr>
                    <td>
                         <table id="CopyToCounterPartyTable" runat="server" style="padding-top: 25px; padding-bottom: 25px;">
                        <tr>
                            <td>
                                <asp:Label ID="lblCopyTo" Text="Copy Emails To" runat="server"> </asp:Label>
                                <asp:CheckBox runat="server" ID="chkCopyTo" CssClass="chk" AutoPostBack="true" Style="margin-left: 8px;" />
                                <%--For the CounterParty Selection AutoSuggestion Box--%>
                            </td>
                            <td>

                                <asp:TextBox runat="server" ID="txtCopyTo" CssClass="txt txttemp" ReadOnly="true"  Width="177px" ></asp:TextBox>
                            </td>
                            <td>
                                <asp:Panel ID="PopUPDiv" runat="server" CssClass="ConfirmationPopup" Style="top: 350px; left: 720px; position: absolute; z-index: 10; width: auto; height: auto; background-color: #FFFFFF; border: solid 1px #DDDDDD; border-bottom: solid 2px #DDDDDD; border-right: solid 2px #DDDDDD;" Visible="false" Placement="Center">

                                    <table>
                                        <tr>
                                            <td>
                                                <asp:Label runat="server" Text="" CssClass="lbl PopUpUpperLeft  hideControl" ID="lblPopUP"></asp:Label></td>
                                            <td style="white-space: nowrap; text-align: right; width: 120px;">
                                                <asp:Button runat="server" CssClass="btn btnApply" Text="Copy Email IDs" ID="btnApply"></asp:Button>
                                                &nbsp;
                                                <asp:Button runat="server" CssClass="btn btnClose" Text="X" ID="btnClose"></asp:Button></td>

                                        </tr>


                                        <tr>
                                            <td class="LowerTDPopUp" colspan="2" style="padding-top: 10px;>
                                                <asp:GridView runat="server" ID="dgPopUp" AutoGenerateColumns="false" AllowPaging="true" PageSize="28">
                                                    <HeaderStyle CssClass="GridHeader" Font-Size="X-Small" BackColor="#ededed" Font-Bold="False"
                                                        ForeColor="White" HorizontalAlign="Center" Wrap="false" />
                                                    <RowStyle CssClass="GridItem" Wrap="false" />
                                                    <emptydatatemplate > No Record Found</emptydatatemplate>
                                                    <Columns>
                                                        <asp:TemplateField HeaderText="">
                                                            <HeaderStyle HorizontalAlign="Center" Width="20px" VerticalAlign="Middle"></HeaderStyle>
                                                            <ItemStyle HorizontalAlign="Center" Width="20px" VerticalAlign="Middle" />
                                                            <ItemTemplate>
                                                                <asp:CheckBox ID="chk" runat="server" Checked="false" />
                                                            </ItemTemplate>
                                                        </asp:TemplateField>
                                                        <asp:TemplateField HeaderText="Product Variant ID" Visible="false">
                                                            <HeaderStyle HorizontalAlign="Center" VerticalAlign="Middle"></HeaderStyle>
                                                            <ItemTemplate>
                                                                <asp:Label ID="lblProductVariantID" runat="server" Text='<%# Eval("SubTemplateId")%>' Width="250px"></asp:Label>
                                                            </ItemTemplate>
                                                        </asp:TemplateField>
                                                        <asp:TemplateField HeaderText="Product Variation">
                                                            <HeaderStyle HorizontalAlign="Center" VerticalAlign="Middle"></HeaderStyle>
                                                            <ItemTemplate>
                                                                <asp:Label ID="lblProductvariation" runat="server" Text='<%# Eval("SubTemplateName")%>' Width="250px"></asp:Label>
                                                            </ItemTemplate>
                                                        </asp:TemplateField>

                                                    </Columns>
                                                </asp:GridView>
                                            </td>
                                        </tr>
                                    </table>
                                </asp:Panel>


                            </td>
                        </tr>
                    </table>
                    </td>
                </tr>

                <tr>
                    <td class="SMTPTD">
                        <fieldset class="EmailSetupFieldSet">
                            <legend>
                                <table class="tblEmailSetupLegendTD">
                                    <tr>
                                        <td>
                                            <asp:Label runat="server" Text="Email Setup" ID="lblEmailSetup" CssClass="lbl"></asp:Label>
                                        </td>
                                    </tr>
                                </table>
                            </legend>


                            <asp:Panel ID="pnlEmailSetup" runat="server" Width="100%" Style="height: 100%;">
                                <table style="padding: 5px;width: 100%;padding-bottom: 15px;">
                                    <tr>
                                        <td colspan="2"></td>
<%--                                        <td>
                                            <asp:label ID="lblDefault" runat="server" Text="DEFAULT"></asp:label>
                                        </td>--%>
                                    </tr>
                                    <%--<tr>
                                        <td colspan="2" style="margin-left:10px !important;">
                                            <asp:Label ID="lblFrom" Text="From" runat="server" Width="50px"> </asp:Label>
                                        </td>
                                        <td>                                        
                                            <asp:CheckBox runat="server" ID="chkFrom" CssClass="chk" AutoPostBack="true" />
                                            <%--TextAlign="left" style="display:inline-block"--%>
                                        <%--</td>
                                        <td >
                                            <asp:TextBox TextMode="MultiLine" placeholder="abc@gmail.com,xyz@gmail.com" Rows="1" runat="server" ID="txtFrom" CssClass="txt txttemp" Width="580px"></asp:TextBox>
                                        </td>
                                    </tr>--%>
                                    <tr style = "height : 10px"></tr>
                                    <tr>
                                        <td colspan="2">
                                            <asp:Label ID="lblTo" Text="To" runat="server"> </asp:Label>
                              
                                            <%--TextAlign="left" style="display:inline-block"--%>
                                        </td>
                                         <td>                                        
                                            <asp:CheckBox runat="server" ID="chkTo" CssClass="chk" AutoPostBack="true" />
                                            <%--TextAlign="left" style="display:inline-block"--%>
                                        </td>
                                        <td >
                                            <asp:TextBox TextMode="MultiLine" placeholder="abc@gmail.com,xyz@gmail.com" Rows="1" runat="server" ID="txtTo" CssClass="txt txttemp" Width="580px"></asp:TextBox>
                                        </td>

                                    </tr>
                                    <tr style = "height : 10px"></tr>
                                    <tr>
                                        <td colspan="2">
                                            <asp:Label ID="lblCc" Text="Cc" runat="server"> </asp:Label>
                                    
                                        </td>
                                         <td>                                        
                                            <asp:CheckBox runat="server" ID="chkCc" CssClass="chk" AutoPostBack="true" />
                                            <%--TextAlign="left" style="display:inline-block"--%>
                                        </td>
                                        <td >
                                            <asp:TextBox TextMode="MultiLine" placeholder="abc@gmail.com,xyz@gmail.com" Rows="1" runat="server" ID="txtCc" CssClass="txt txttemp" Width="580px"></asp:TextBox>
                                        </td>
                                    </tr>
                                    <tr style = "height : 10px"></tr>
                                    <tr>
                                        <td colspan="2">
                                            <asp:Label ID="blbBcc" Text="Bcc" runat="server"> </asp:Label>
         
                                        </td>
                                         <td>                                        
                                            <asp:CheckBox runat="server" ID="chkBcc" CssClass="chk" AutoPostBack="true" />
                                            <%--TextAlign="left" style="display:inline-block"--%>
                                        </td>
                                        <td >
                                            <asp:TextBox TextMode="MultiLine" placeholder="abc@gmail.com,xyz@gmail.com" Rows="1" runat="server" ID="txtBcc" Width="580px" CssClass="txt txttemp"></asp:TextBox>
                                        </td>
                                    </tr>
                                </table>
                            </asp:Panel>

                            <%--<Rishabh C, Joel D|05-Feb-2020|Changes done|As per discussions with Tushar A, Lehanshu k, Swanand L|JIRA Ref UBSSINT-202 User group related changes in Counter party email configuration> --%>
                            <asp:Panel ID="pnlFrom" runat="server" Width="100%" Style="height: 100%; ">
                                <table style="padding: 5px;width: 100%;padding-bottom: 15px;">
                                    <tr>
                                        <td colspan="2"></td>
                            <%--            <td>
                                            <asp:label ID="Label1" runat="server" Text="DEFAULT"></asp:label>
                                        </td>--%>
                                    </tr>
                                    <tr>
                                        <td colspan="2" style="margin-left:10px !important;">
                                            <asp:Label ID="lblFrom" Text="From" runat="server" Width="50px"> </asp:Label>
                                        </td>
                                        <td>                                        
                                            <asp:CheckBox runat="server" ID="chkFrom" CssClass="chk" AutoPostBack="true" />
                                            <%--TextAlign="left" style="display:inline-block"--%>
                                        </td>
                                        <td >
                                            <asp:TextBox TextMode="MultiLine" placeholder="abc@gmail.com,xyz@gmail.com" Rows="1" runat="server" ID="txtFrom" CssClass="txt txttemp" Width="580px"></asp:TextBox>
                                        </td>
                                    </tr>
                                    </table>
                            </asp:Panel>
<%--                           <Rishabh C, Joel D|05-Feb-2020|Changes done|As per discussions with Tushar A, Lehanshu k, Swanand L>--%>
                         </fieldset>

                    </td>
                </tr>
                <tr>
                    <td>
                        <asp:label ID="lblNote" Text="To" runat="server" style="padding: 5px">Note: Multiple Email address with comma separated values allowed</asp:label>
                    </td>
                </tr>

            </table>
        <asp:HiddenField ID="hiddenUpdateInsertMode" Value="" runat="server" />
        <asp:HiddenField ID="hdnButtonClickCopyTo" Value="" runat="server" />
        </ContentTemplate>
    </asp:UpdatePanel>
</asp:content>
