<%@ control language="VB" autoeventwireup="false" inherits="Template_CC_DigiCertProducts, MachSol.MachPanel.Web" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="EM" %>
<asp:HiddenField ID="HF_CurrencySymbol" runat="server" />
<asp:HiddenField ID="HF_CustomerId" runat="server" />
<div id="Tr_Products" runat="server">
    <asp:Repeater ID="Rep_Groups" runat="server" OnItemDataBound="Rep_Groups_ItemDataBound">
        <ItemTemplate>
            <div class="col-xs-12">
                <!-- Group Card -->
                <div class="card">
                    <div class="header">
                        <h3>
                            <asp:Label CssClass="upperCase" ID="Lbl_GroupName" runat="server"></asp:Label></h3>
                    </div>
                    <div class="body">
                        <div class="row">
                            <div class="col-xs-12">
                                <asp:Repeater ID="Rep_Products" runat="server" OnItemDataBound="Rep_Products_ItemDataBound" OnItemCommand="Rep_Products_ItemCommand">
                                    <ItemTemplate>
                                        <div class="col-lg-4 col-sm-6 col-xs-12">
                                            <div class="card">
                                                <div class="body">
                                                    <div class="PricingHeading">
                                                        <asp:Label CssClass="upperCase" ID="Lbl_ProductName" runat="server"></asp:Label>
                                                        <asp:HiddenField ID="Hf_ProductId" runat="server" />
                                                    </div>

                                                    <div class="store-cycle-dd">
                                                        <asp:DropDownList ID="DDL_Cycle" CssClass="selectpicker" runat="server">
                                                        </asp:DropDownList>
                                                    </div>
                                                    <div class="PricingDetail">
                                                        <h4 class="color-Orange">
                                                            <asp:Literal ID="Literal45" runat="server" Text='<%$Resources:Content,GN000112%>'
                                                                EnableViewState="false"></asp:Literal>:
                                                    <asp:Label ID="Lbl_Price" CssClass="pricing-style" runat="server"></asp:Label></h4>
                                                    </div>
                                                    <div class="PricingDetail">
                                                        <asp:LinkButton ID="Lb_PurchaseNow" CssClass="btn btn-primary waves-effect btnAction" runat="server" Text='<%$Resources:Content,PurchaseNow%>'
                                                            ToolTip='<%$Resources:Content,PurchaseNow%>' CommandName="PurchaseNow" />

                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                    </ItemTemplate>
                                </asp:Repeater>
                            </div>
                        </div>

                    </div>
                </div>
            </div>
        </ItemTemplate>
    </asp:Repeater>

    <div class="col-xs-12">
        <asp:Button ID="Btn_Cancel" class="btn btn-primary waves-effect" CausesValidation="false" runat="server" Text="<%$ Resources:Content,GN0000572%>" />
    </div>

</div>
<div id="Tr_AsReseller" runat="server">
    <div class="col-xs-12">
        <!-- Group Card -->
        <div class="card">
            <div class="header">
                <h3>
                    <asp:Literal ID="Lt_Heading" runat="server" Text="<%$ Resources:Content,DigiCertSSL%>" EnableViewState="false"></asp:Literal></h3>
            </div>
            <div class="body">
                <div class="row">
                    <div class="col-sm-3 col-xs-12 row-label">
                        <label>
                            <asp:Literal ID="Literal3" runat="server" Text="<%$ Resources:Content,GN000141%>"
                                EnableViewState="false"></asp:Literal>:</label>
                        <asp:HiddenField ID="Hf_PGID" runat="server" />
                    </div>
                    <div class="col-sm-4 col-xs-12">
                        <div class="form-group">
                            <asp:DropDownList ID="DDL_Package" runat="server">
                            </asp:DropDownList>
                        </div>
                    </div>
                </div>
                <div class="row">
                    <div class="col-sm-3 col-xs-12 row-label">
                        <asp:Literal ID="Literal37" runat="server" Text='<%$ Resources:Content,Dev336%>' />:
                    </div>
                    <div class="col-sm-9 col-xs-12">
                        <div class="grow">
                            <div runat="server" ID="Ltl_PackageComments"></div>
                        </div>
                    </div>
                </div>
                <div class="row">
                    <div class="col-xs-12">
                        <asp:Button ID="Btn_Subscribe" class="btn btn-primary waves-effect" runat="server" Text="<%$ Resources:Content,String276%>" />
                        <asp:Button ID="LB_Cancel" class="btn btn-primary waves-effect" CausesValidation="false" runat="server" Text="<%$ Resources:Content,GN0000572%>" />
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
<asp:Button ID="Btn_Dummy1" Style="display: none" runat="server" />
<asp:Panel ID="Pnl_BuyNow" runat="server" CssClass="width-modal-popup-auto" Style="display: none;">
    <asp:UpdatePanel ID="UpdatePanel1" runat="server">
        <ContentTemplate>
            <div class="col-xs-12">
                <div class="card">
                    <div class="header container-fluid">
                        <h3 class="pull-left"><%= Resources.Content.AddOrganization%></h3>
                        <span>
                            <button type="button" class="close" onclick="$find('<%=MPE_BuyNow.ClientID%>').hide();">&times;</button>
                        </span>
                    </div>
                    <div class="body">
                        <div class="row">
                            <div class="col-xs-12">
                                <div class="input-group">
                                    <span class="input-group-addon">
                                        <asp:Literal ID="Literal2" Text='<%$ Resources:Content, BuyFor%>' runat="server"></asp:Literal>:</span>
                                    <div class="form-group">
                                        <asp:DropDownList ID="Ddl_Organization" runat="server" AutoPostBack="true"></asp:DropDownList>
                                    </div>
                                </div>
                            </div>
                        </div>
                        <div class="row" id="Div_Note" runat="server" style="display: none;">
                            <div class="col-xs-12 PricingHeading">
                                <asp:Label ID="Lb_LoginNote" runat="server"></asp:Label>
                            </div>
                        </div>
                        <div id="Div_NewOrg" runat="server">
                            <div class="row">
                                <div class="col-sm-4 col-xs-12 row-label">
                                    <asp:Literal ID="Literal1" runat="server" EnableViewState="false" Text='<%$ Resources:Content,DGN1110608 %>'></asp:Literal>
                                </div>
                                <div class="col-sm-5 col-xs-12">
                                    <div class="form-group">
                                        <div class="form-line">
                                            <asp:TextBox ID="Txt_OrgName" runat="server" MaxLength="300"></asp:TextBox>
                                        </div>
                                    </div>
                                    <asp:RequiredFieldValidator ID="Rfv_OrgName" Display="None" SetFocusOnError="True" runat="server" ControlToValidate="Txt_OrgName" ValidationGroup="Org"></asp:RequiredFieldValidator>
                                </div>
                            </div>
                            <div class="row">
                                <div class="col-sm-4 col-xs-12 row-label">
                                    <asp:Literal ID="Literal4" runat="server" EnableViewState="false" Text='<%$ Resources:Content,Dev613%>'></asp:Literal>
                                </div>
                                <div class="col-sm-5 col-xs-12">
                                    <div class="form-group">
                                        <div class="form-line">
                                            <asp:TextBox ID="Txt_OrgAddress" runat="server"></asp:TextBox>
                                        </div>
                                    </div>
                                    <asp:RequiredFieldValidator ID="RequiredFieldValidator1" Display="None" SetFocusOnError="True" runat="server" ControlToValidate="Txt_OrgAddress" ValidationGroup="Org"></asp:RequiredFieldValidator>
                                </div>
                            </div>
                            <div class="row">
                                <div class="col-sm-4 col-xs-12 row-label">
                                    <asp:Literal ID="Literal5" runat="server" EnableViewState="false" Text='<%$ Resources:Content,Dev614%>'></asp:Literal>
                                </div>
                                <div class="col-sm-5 col-xs-12">
                                    <div class="form-group">
                                        <div class="form-line">
                                            <asp:TextBox ID="Txt_OrgCity" runat="server"></asp:TextBox>
                                        </div>
                                    </div>
                                    <asp:RequiredFieldValidator ID="RequiredFieldValidator2" Display="None" SetFocusOnError="True" runat="server" ControlToValidate="Txt_OrgCity" ValidationGroup="Org"></asp:RequiredFieldValidator>
                                </div>
                            </div>
                            <div class="row">
                                <div class="col-sm-4 col-xs-12 row-label">
                                    <asp:Literal ID="Literal6" runat="server" EnableViewState="false" Text='<%$ Resources:Content,Dev615%>'></asp:Literal>
                                </div>
                                <div class="col-sm-5 col-xs-12">
                                    <div class="form-group">
                                        <div class="form-line">
                                            <asp:TextBox ID="Txt_OrgState" runat="server"></asp:TextBox>
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="row">
                                <div class="col-sm-4 col-xs-12 row-label">
                                    <asp:Literal ID="Literal7" runat="server" EnableViewState="false" Text='<%$ Resources:Content,Dev617%>'></asp:Literal>
                                </div>
                                <div class="col-sm-5 col-xs-12">
                                    <div class="form-group">
                                        <div class="form-line">
                                            <asp:TextBox ID="Txt_OrgZip" runat="server"></asp:TextBox>
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="row">
                                <div class="col-sm-4 col-xs-12 row-label">
                                    <asp:Literal ID="Literal8" runat="server" EnableViewState="false" Text='<%$ Resources:Content,Dev616%>'></asp:Literal>
                                </div>
                                <div class="col-sm-5 col-xs-12">
                                    <div class="form-group">
                                        <asp:DropDownList ID="Ddl_OrgCountry" runat="server"></asp:DropDownList>
                                    </div>
                                </div>
                            </div>
                            <div class="row">
                                <div class="col-sm-4 col-xs-12 row-label">
                                    <asp:Literal ID="Literal9" runat="server" EnableViewState="false" Text='<%$ Resources:Content,SPT002215%>'></asp:Literal>
                                </div>
                                <div class="col-sm-5 col-xs-12">
                                    <div class="form-group">
                                        <div class="form-line">
                                            <asp:TextBox ID="Txt_OrgTelephone" runat="server"></asp:TextBox>
                                        </div>
                                    </div>
                                    <asp:RequiredFieldValidator ID="RequiredFieldValidator4" Display="None" SetFocusOnError="True" runat="server" ControlToValidate="Txt_OrgTelephone" ValidationGroup="Org"></asp:RequiredFieldValidator>
                                </div>
                            </div>
                            <div class="row">
                                <div class="col-sm-4 col-xs-12 row-label">
                                    <asp:Literal ID="Literal10" runat="server" EnableViewState="false" Text='<%$ Resources:Content,Dev618%>'></asp:Literal>
                                </div>
                                <div class="col-sm-5 col-xs-12">
                                    <div class="form-group">
                                        <div class="form-line">
                                            <asp:TextBox ID="Txt_OrgContactFirstName" runat="server"></asp:TextBox>
                                        </div>
                                    </div>
                                    <asp:RequiredFieldValidator ID="RequiredFieldValidator5" Display="None" SetFocusOnError="True" runat="server" ControlToValidate="Txt_OrgContactFirstName" ValidationGroup="Org"></asp:RequiredFieldValidator>
                                </div>
                            </div>
                            <div class="row">
                                <div class="col-sm-4 col-xs-12 row-label">
                                    <asp:Literal ID="Literal11" runat="server" EnableViewState="false" Text='<%$ Resources:Content,Dev619%>'></asp:Literal>
                                </div>
                                <div class="col-sm-5 col-xs-12">
                                    <div class="form-group">
                                        <div class="form-line">
                                            <asp:TextBox ID="Txt_OrgContactLastName" runat="server"></asp:TextBox>
                                        </div>
                                    </div>
                                    <asp:RequiredFieldValidator ID="RequiredFieldValidator6" Display="None" SetFocusOnError="True" runat="server" ControlToValidate="Txt_OrgContactLastName" ValidationGroup="Org"></asp:RequiredFieldValidator>
                                </div>
                            </div>
                            <div class="row">
                                <div class="col-sm-4 col-xs-12 row-label">
                                    <asp:Literal ID="Literal12" runat="server" EnableViewState="false" Text='<%$ Resources:Content,Dev620%>'></asp:Literal>
                                </div>
                                <div class="col-sm-5 col-xs-12">
                                    <div class="form-group">
                                        <div class="form-line">
                                            <asp:TextBox ID="Txt_OrgContactEmail" runat="server"></asp:TextBox>
                                        </div>
                                    </div>
                                   <%-- <asp:RegularExpressionValidator ID="Rev_ContactEmail" Display="None" SetFocusOnError="True" runat="server" ControlToValidate="Txt_OrgContactEmail" ValidationGroup="Org" ValidationExpression='<%$Resources:MPRegex,EmailAddress%>'></asp:RegularExpressionValidator>--%>
                                </div>
                            </div>
                            <div class="row">
                                <div class="col-sm-4 col-xs-12 row-label">
                                    <asp:Literal ID="Literal13" runat="server" EnableViewState="false" Text='<%$ Resources:Content,Dev621%>'></asp:Literal>
                                </div>
                                <div class="col-sm-5 col-xs-12">
                                    <div class="form-group">
                                        <div class="form-line">
                                            <asp:TextBox ID="Txt_OrgContactTelephone" runat="server"></asp:TextBox>
                                        </div>
                                    </div>
                                    <asp:RequiredFieldValidator ID="RequiredFieldValidator3" Display="None" SetFocusOnError="True" runat="server" ControlToValidate="Txt_OrgContactTelephone" ValidationGroup="Org"></asp:RequiredFieldValidator>
                                </div>
                            </div>
                            <div class="row">
                                <div class="col-xs-12">
                                    <asp:Button ID="Btn_PurchaseNow" ValidationGroup="Org" OnClick="Btn_PurchaseNow_Click" runat="server" Text='<%$Resources:Content,PurchaseNow%>' CssClass="btn btn-primary waves-effect btnAction"></asp:Button>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
                </div>
        </ContentTemplate>
        <Triggers>
            <asp:AsyncPostBackTrigger ControlID="Ddl_Organization" EventName="SelectedIndexChanged" />
        </Triggers>
    </asp:UpdatePanel>
</asp:Panel>
<EM:ModalPopupExtender runat="server" ID="MPE_BuyNow" BackgroundCssClass="modalBackground"
    DropShadow="false" PopupControlID="Pnl_BuyNow" TargetControlID="Btn_Dummy1">
</EM:ModalPopupExtender>

<div class="modal fade" id='digiCert' role="dialog">
    <div class="modal-dialog">
        <!-- Modal content-->
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal">&times;</button>
                <div class="PopupHeading pull-left"><%= Resources.Content.ImportantNote %></div>
            </div>
            <div class="modal-body">
                <div class="col-sm-12">
                    <p>Please note the following while purchasing DigiCert product(s):</p>
                    <ul>
                        <li style="list-style: disc;">Your account is created at DigiCert portal, please check your email and validate. Skip this step if your account is already verified.</li>
                        <li style="list-style: disc;">Login to DigiCert portal, Navigate to buy SSL, select needed certificate and perform inputs to complete order.</li>
                        <li style="list-style: disc;">Your order will be reviewed by service provider and it may take many days to process order.</li>
                    </ul>
                </div>
            </div>
            <div class="modal-footer">
                <div class="col-xs-12">
                    <asp:HiddenField ID="Hf_ProductId" runat="server" />
                    <asp:HiddenField ID="Hf_CycleId" runat="server" />
                    <asp:Button ID="Btn_Pop_Close" runat="server" OnClick="Btn_Pop_Close_Click" Text='<%$Resources:Content,GN000150%>' CssClass="btn btn-primary waves-effect" />
                </div>
            </div>
        </div>

    </div>
</div>

<script type='text/javascript'>
    function openModal(modalId) {
        $('.modal').modal('hide');      // hide all modals
        $('.modal-backdrop').remove();  // remove grey background
        //$(modalId).modal('show');       // show the required popup
        //alert(modalId);
        $(modalId).modal();
    }

</script>
