<%@ Page Language="C#" MasterPageFile="~/masterpages/eDashboard.master" AutoEventWireup="true"
    Inherits="site_HITS_RatePlans_Default" Title="Brightstar Device Protection: Service Plans" Theme="eMain"
    Culture="auto" UICulture="auto" CodeBehind="Default.aspx.cs" %>

<%@ Register assembly="System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" namespace="System.Web.UI" tagprefix="cc2" %>

<%--<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="ajaxToolkit" %>
<%@ Register Src="~/Controls/PhoneNumber.ascx" TagName="PhoneNumber" TagPrefix="uc1" %>--%>
<%@ Register Src="~/Controls/PersistNav.ascx" TagName="PersistNav" TagPrefix="uc" %>
<%--<%@ Register Src="~/Controls/ScriptingHelper.ascx" TagName="ScriptingHelper" TagPrefix="uc" %>--%>
<%@ Register Src="~/Controls/HITSCalendar.ascx" TagName="HITSCalendar" TagPrefix="uc" %>
<%--<%@ Register Src="~/Controls/ChildHeader.ascx" TagName="ChildHeader" TagPrefix="uc" %>
<%@ Register Src="~/Controls/CustomSorter.ascx" TagName="CustomSorter" TagPrefix="uc" %>--%>
<%@ Register Assembly="eSecuritel.HITS.UI.Components" Namespace="eSecuritel.HITS.UI.Components"
    TagPrefix="cc1" %>
<%@ Register Src="~/Controls/ClientCarrierDropDowns.ascx" TagName="ClientCarrierDropDowns"
    TagPrefix="uc1" %>
<%--<%@ Register Assembly="System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
    Namespace="System.Web.UI" TagPrefix="cc2" %>--%>
<asp:Content ID="Content1" ContentPlaceHolderID="eContent" runat="Server">
    <asp:ScriptManagerProxy ID="ScriptManagerProxy1" runat="server">
        <Scripts>
            <asp:ScriptReference Path="~/script/eSetFormControls.js" />
            <asp:ScriptReference Path="~/script/eGridHelper.js" />
        </Scripts>
    </asp:ScriptManagerProxy>
    <%-- <cc1:ExtendedValidationSummary ID="m_extValidationSummaryTop" runat="server" HeaderText="The following items need to be reviewed before updating this Service Plan." />

            <td valign="top">
                <uc:PersistNav ID="PersistNav" runat="server"
    <table border="0" cellpadding="0" cellspacing="0" style="width: 96%">
        <tr>
            <td>
            </td> Visible="true" />
            </td>
        </tr>
    </table>--%>

    <script type="text/javascript">
        var isIE = false;       
    </script>    

    <cc1:ExtendedValidationSummary ID="m_extValidationSummaryTop" runat="server" ValidationGroup="ServicePlanGroup"
        HeaderText="<%$ Resources: ServicePlanManagement, FollowingItemsReviewedBeforUpdatingServicePlan %>" />
    <table border="0" cellpadding="0" cellspacing="0" style="width: 96%">
        <tr>
            <td>
            </td>
            <td valign="top">
                <uc:PersistNav ID="PersistNav" runat="server" Visible="true" />
            </td>
        </tr>
    </table>
    <!---------------------------------------TABLE ------------------------------------------->
    <h2>
        <asp:Literal ID="m_litGeneralInfo" runat="server" Text="<%$ Resources: ServicePlanManagement, LabelServicePlanDetails %>" />
        <%-- <asp:Literal  ID="lblSuccess" runat="server"></asp:Literal>--%>
        <asp:Label ID="lblStatus" runat="server" />
    </h2>
    <br />
    <br />
    <asp:UpdatePanel ID="updateTabPanel" runat="server" UpdateMode="Always">
        <ContentTemplate>
            <ajaxToolkit:TabContainer ID="tabContainerPlans" runat="server" ActiveTabIndex="0" 
                OnClientActiveTabChanged="tabContainerPlans_ClientActiveTabChanged" OnActiveTabChanged="tabContainerPlans_ActiveTabChanged">
                <ajaxToolkit:TabPanel ID="tabPanelGeneral" runat="server" HeaderText="<%$ Resources: Default, LabelGeneral %>">
                    <ContentTemplate>
                        <div class="tabPanelFix">
                            <h2>
                                <asp:Literal ID="Literal1" runat="server" Text="<%$ Resources: ServicePlanManagement, LabelServicePlanInformation %>" />
                            </h2>
                            <div style="background-color: #DBDCDE" id="m_pnlRatePlans">
                                <table class="gvTable" cellspacing="0" cellpadding="0" border="0">
                                    <tr>
                                        <td width="50px">
                                            &nbsp;
                                        </td>
                                        <%--<td width="200px">
                    <asp:Literal ID="LitCarrier" runat="server" Text=" Carrier:" />
                </td>
                <td align="left" width="300px">
                    <asp:DropDownList ID="m_ddlCarrier" runat="server" Width="200px">
                    </asp:DropDownList>
                </td>--%>
                                        <td align="left" colspan="2">
                                            <div>
                                                <uc1:ClientCarrierDropDowns ID="ucClientCarrierDropDowns" runat="server" LabelWidth="110"
                                                    OnClientChanged="ucClientCarrierDropDowns_ClientChanged" OnCarrierChanged="ucClientCarrierDropDowns_CarrierChanged"
                                                    OrientationOfDropDowns="Vertical" />
                                            </div>
                                        </td>
                                        <td>
                                            <asp:Label runat="server" Text="<%$ Resources: ServicePlanManagement, LabelServicePlanDurationColon %>" />
                                        </td>
                                        <td>
                                            <asp:TextBox runat="server" ID="txtRatePlanDuration" onKeyPress="return IntOnlyCheck(event);"></asp:TextBox>
                                        </td>
                                        <td>
                                            <asp:Label runat="server" Text="<%$ Resources: ServicePlanManagement, LabelEnrollmentGracePeriodColon %>" />
                                        </td>
                                        <td>
                                            <asp:TextBox runat="server" ID="txtGracePeriod" onKeyPress="return IntOnlyCheck(event);"></asp:TextBox>
                                            <%--<asp:RangeValidator ID = "txtgracevalidator" Type ="Integer" > </asp:RangeValidator>--%>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                        </td>
                                        <td align="left" id="labelFirstColumn">
                                            <asp:Label runat="server" Text="<%$ Resources: ServicePlanManagement, LabelCoverageTypeColon %>" />
                                        </td>
                                        <td>
                                            <asp:DropDownList runat="server" ID="ddlCoverageType" DataTextField="Refname" DataValueField="Refname" Width="100%">
                                            </asp:DropDownList>
                                        </td>
                                        <td>
                                            <asp:Literal ID="Literal3" runat="server" Text="<%$ Resources: ServicePlanManagement, LabelLapseWaitPeriodColon %>" />
                                        </td>
                                        <td>
                                            <asp:TextBox runat="server" ID="txtLapseWaitPeriod" onKeyPress="return IntOnlyCheck(event);"></asp:TextBox>
                                        </td>
                                        <td align="left">
                                            <asp:Label ID="Label1" runat="server" Text="<%$ Resources: ServicePlanManagement, LabelPremiumCancelationRefundsbyColon %>" />
                                        </td>
                                        <td>
                                            <asp:DropDownList runat="server" ID="ddlPremiumCancelledRefund" DataTextField="Refname"
                                                DataValueField="ID">
                                            </asp:DropDownList>
                                        </td>                                        
                                    </tr>
                                    <tr>
                                        <td>
                                        </td>
                                        <td>
                                            <asp:Literal ID="LitRatePlan" runat="server" Text="<%$ Resources: ServicePlanManagement, LabelServicePlanNameColon %>" />
                                        </td>
                                        <td align="left">
                                            <asp:TextBox ID="txtRatePlanName" runat="server" Width="183px" align="left" />
                                            <asp:RequiredFieldValidator ID="rfvTxtRatePlanName" runat="server" Text="<%$ Resources: Default, RequiredValidatorText %>"
                                                ValidationGroup="ServicePlanGroup" ErrorMessage="<%$ Resources: ServicePlanManagement, ErrorMessageServicePlanNameFieldisRequired %>"
                                                ControlToValidate="txtRatePlanName" Display="Dynamic" InitialValue=""></asp:RequiredFieldValidator>
                                        </td>
                                        <td width="180px">
                                            <asp:Label runat="server" Text="<%$ Resources: ServicePlanManagement, LabelPremiumAliasColon %>" />
                                        </td>
                                        <td>
                                            <asp:TextBox runat="server" ID="CarrierRatePlanNameInput"></asp:TextBox>
                                        </td>
                                        <td>
                                            <asp:Literal ID="LitWholesaleRate" runat="server" Text="<%$ Resources: ServicePlanManagement, LabelWholesaleRateColon %>" />
                                        </td>
                                        <td>
                                            <asp:TextBox runat="server" ID="m_txtWholesaleRate" Text="0.00"></asp:TextBox>
                                            <asp:RegularExpressionValidator ID="revM_txtWholesaleRate" runat="server" Text="<%$ Resources: Default, ErrorMessageInvalid %>"
                                                ValidationGroup="ServicePlanGroup" Display="Dynamic" ErrorMessage="<%$ Resources: ServicePlanManagement, ErrorMessageWholesaleRatehasanInvalidFormat %>"
                                                ValidationExpression="\d+\.\d{2}" ControlToValidate="m_txtWholesaleRate"> </asp:RegularExpressionValidator>
                                        </td>                                        
                                    </tr>
                                    <tr>
                                        <td>
                                            &nbsp;
                                        </td>
                                        <td>
                                            <asp:Literal ID="LitWirelessPlanType" runat="server" Text="<%$ Resources: ServicePlanManagement, LabelWirelessPlanTypeColon %>" />
                                        </td>
                                        <td align="left">
                                            <asp:DropDownList runat="server" ID="ddlWirelessPlanType" DataTextField="Refname"
                                                DataValueField="ID" Width="100%">
                                            </asp:DropDownList>
                                        </td>
                                        <%--<td width="180px">&nbsp;</td>
                <td>&nbsp;</td>--%>
                                        <td>
                                            <asp:Literal ID="LitHandsetOverrideFlag" runat="server" Text="<%$ Resources: ServicePlanManagement, LabelNewEnrollmentOverrideColon %>" />
                                        </td>
                                        <td align="left">
                                            <asp:CheckBox ID="m_chkHansetOverrideFlag" runat="server"></asp:CheckBox>
                                        </td>
                                        <td>
                                            <asp:Literal ID="LitRetailRate" runat="server" Text="<%$ Resources: ServicePlanManagement, LabelRetailRateColon %>" />
                                        </td>
                                        <td>
                                            <asp:TextBox runat="server" ID="m_txtRetailRate" Text="0.00"></asp:TextBox>
                                            <asp:RegularExpressionValidator ID="revM_txtRetailRate" runat="server" Text="<%$ Resources: Default, ErrorMessageInvalid %>"
                                                ValidationGroup="ServicePlanGroup" Display="Dynamic" ErrorMessage="<%$ Resources: ServicePlanManagement, LabelRetailRatehasanInvalidFormat %>"
                                                ValidationExpression="\d+\.\d{2}" ControlToValidate="m_txtRetailRate"> </asp:RegularExpressionValidator>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            &nbsp;
                                        </td>
                                        <td>
                                            <asp:Literal ID="LitStartDate" runat="server" Text="<%$ Resources: Default, LabelStartDateColon %>"></asp:Literal>
                                        </td>
                                        <td>
                                            <uc:HITSCalendar ID="m_calStartDate" runat="server" Required="true" ValidationGroup="ServicePlanGroup" />
                                        </td>
                                        <td>
                                            <asp:Literal ID="LitExtendedContractFlag" runat="server" Text="<%$ Resources: ServicePlanManagement, LabelExtendedContractColon %>" />
                                        </td>
                                        <td align="left">
                                            <asp:CheckBox ID="m_chkExtendedContractFlag" runat="server"></asp:CheckBox>
                                        </td>
                                        <td>
                                            <asp:Literal ID="Literal6" runat="server" Text="<%$ Resources: ServicePlanManagement, LabelAdditionalServicesColon %>" />
                                        </td>
                                        <td>
                                            <asp:TextBox runat="server" ID="txtAdditionalServices" Text="<%$ Resources: Default, LabelNone %>" MaxLength="255"></asp:TextBox>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            &nbsp;
                                        </td>
                                        <td>
                                            <asp:Literal ID="LitEndDate" runat="server" Text="<%$ Resources: Default, LabelEndDateColon %>"></asp:Literal>
                                        </td>
                                        <td>
                                            <uc:HITSCalendar ID="m_calEndDate" runat="server" />
                                        </td>
                                        <td>
                                            <asp:Literal ID="Literal2" runat="server" Text="<%$ Resources: ServicePlanManagement, LabelBullguardColon %>" />
                                        </td>
                                        <td align="left">
                                            <asp:CheckBox ID="chkBullguard" runat="server"></asp:CheckBox>
                                        </td>     
                                        <td>
                                            <asp:Literal runat="server" Text="<%$ Resources: ServicePlanManagement, LabelLossDateDays %>" />
                                        </td>
                                        <td align="left">
                                            <asp:TextBox ID="txtLossDateDays" runat="server"></asp:TextBox>
                                        </td>                                       
                                    </tr>
                                    <tr>
                                        <td>
                                            &nbsp;
                                        </td>
                                        <td>
                                            &nbsp;
                                        </td>
                                        <td>
                                            &nbsp;
                                        </td>
                                        <td>
                                            <asp:Literal ID="Literal4" runat="server" Text="<%$ Resources: ServicePlanManagement, LabelMISColon %>" />
                                        </td>
                                        <td align="left">
                                            <asp:CheckBox ID="chkMIS" runat="server"></asp:CheckBox>
                                        </td>
                                        <td>
                                            <asp:Literal ID="litClaimLimit" runat="server" Text="<%$ Resources: ServicePlanManagement, LabelServiceClaimLimitColon %>" />
                                        </td>
                                        <td align="left">
                                            <asp:TextBox runat="server" ID="txtClaimLimit" Enabled="false" Width="50px" onKeyPress="return IntOnlyCheck(event);"></asp:TextBox>
                                        </td>                                        
                                    </tr>
                                    <tr>
                                        <td>
                                            &nbsp;
                                        </td>
                                        <td>
                                            <asp:Literal ID="litClaimLimitDuration" runat="server" Text="<%$ Resources: ServicePlanManagement, LabelClaimLimitDurationColon %>" />
                                        </td>
                                        <td align="left">
                                            <asp:TextBox runat="server" ID="txtClaimLimitDuration" Width="80px" Text="365"></asp:TextBox>
                                        </td>
                                        <td>
                                            <asp:Literal ID="litUseClaimLimit" runat="server" Text="<%$ Resources: ServicePlanManagement, LabelUseClaimLimitColon %>" />
                                        </td>
                                        <td align="left">
                                            <asp:CheckBox runat="server" ID="chkUseClaimLimit" Enabled="false" OnCheckedChanged="chkUseClaimLimit_CheckedChanged"  />
                                        </td>             
                                        <td align="left">
                                            <asp:Literal ID="litPolicyNumber" runat="server" Text="<%$ Resources: ClaimsManagement, LabelPolicyNumber %>"></asp:Literal>
                                        </td>
                                        <td align="left">
                                             <asp:TextBox runat="server" ID="txt_PolicyNumber"  ></asp:TextBox>
                                        </td>                           
                                    </tr>
                                    <tr>
                                        <td>
                                            &nbsp;
                                        </td>
                                        <td>
                                            <asp:Literal ID="litServiceRefundMethod" runat="server" Text="<%$ Resources: ServicePlanManagement, LabelServiceRefundMethodColon %>" />
                                        </td>
                                        <td align="left">
                                            <asp:DropDownList runat="server" ID="ddlServiceRefundMethod" DataTextField="Refname"
                                                DataValueField="ID" Width="100%">
                                            </asp:DropDownList>
                                        </td>
                                        <td>
                                            <asp:Literal ID="LitServicePlanCancelled" runat="server" Text="<%$ Resources: ServicePlanManagement, LabelSevicePlancanbeCanceledColon %>" />
                                        </td>
                                        <td align="left">
                                            <asp:CheckBox ID="m_chkServicePlanCancelled" runat="server"></asp:CheckBox>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            &nbsp;
                                        </td>
                                        <td>
                                             &nbsp;
                                        </td>
                                        <td>
                                             &nbsp;
                                        </td>
                                        <td>
                                            <asp:Literal ID="Literal9" runat="server" Text="<%$ Resources: ServicePlanManagement, LabelAutoAcceptCIRColon %>" />
                                        </td>
                                        <td align="left">
                                            <asp:CheckBox ID="chkCIR" runat="server"></asp:CheckBox>
                                        </td>
                                        <td>
                                            &nbsp;
                                        </td>
                                        <td>
                                            &nbsp;
                                        </td>
                                    </tr>
                                </table>
                            </div>
                            <h2>
                                <asp:Literal ID="litTaxCodes" runat="server" Text="<%$ Resources: ServicePlanManagement, LabalTaxCodes %>" />
                            </h2>
                            <div style="background-color: #DBDCDE">
                                <table class="gvTable" border="0" cellpadding="0" cellspacing="0">
                                    <tr>
                                        <td width="50px">
                                            &nbsp;
                                        </td>                                        
                                        <td>
                                            <div style="margin-top: 20px">
                                                <asp:GridView ID="grdTaxCodes" runat="server" AutoGenerateColumns="False" BackColor="White" Width="40%" OnRowDataBound="grdTaxCodes_RowDataBound">
                                                    <Columns>
                                                        <asp:BoundField DataField="ID" Visible="False" />
                                                        <asp:BoundField DataField="RefName" HeaderText="<%$ Resources: ServicePlanManagement, HeaderTextTaxCodeType %>" HeaderStyle-HorizontalAlign="Center" HeaderStyle-Width="110px" HeaderStyle-Wrap="true" />
                                                        <asp:TemplateField HeaderStyle-HorizontalAlign="Center" ItemStyle-HorizontalAlign="Center" HeaderStyle-Width="100px">
                                                            <HeaderStyle Width="100px" Wrap="true" />
                                                            <HeaderTemplate>
                                                                <asp:Label ID="lblCode" runat="server" Text="<%$ Resources: ServicePlanManagement, HeaderTextTaxCode %>" />
                                                            </HeaderTemplate>
                                                            <ItemTemplate>
                                                                <asp:DropDownList runat="server" ID="ddlCodes" Width="70%" DataTextField="SOURCE2" DataValueField="ID">
                                                                </asp:DropDownList>
                                                            </ItemTemplate>
                                                        </asp:TemplateField>
                                                    </Columns>
                                                </asp:GridView>
                                            </div>
                                        </td>
                                        <td>
                                            &nbsp;
                                        </td>
                                    </tr>
                                </table>
                            </div>
                            <h2>
                                <asp:Literal ID="LitBilling" runat="server" Text="<%$ Resources: BillingManagement, LabelBilling %>" />
                            </h2>
                            <div style="background-color: #DBDCDE">
                                <table class="gvTable" border="0" cellpadding="0" cellspacing="0">
                                    <tr>
                                        <td style="font-weight: bold">
                                            &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                                            <asp:Label runat="server" Text="<%$ Resources: SubscriberManagement, LabelSubscriberColon %>" />
                                        </td>
                                        <td style="font-weight: bold">
                                            &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                                            <asp:Label runat="server" Text="<%$ Resources: OrganizationManagement, LabelClient %>" />
                                        </td>
                                    </tr>
                                </table>
                                <table class="gvTable" cellspacing="0" cellpadding="0" border="0">
                                    <tr>
                                        <td width="50px">
                                            &nbsp;
                                        </td>
                                        <td width="200px" valign="top">
                                            <asp:RadioButtonList ID="radiolist" runat="server">
                                                <asp:ListItem ID="rdbtBillOneTime" Text="<%$ Resources: ServicePlanManagement, ListItemOneTimeAmount %>" Value="One-Time" runat="server" />
                                                <asp:ListItem ID="rdbtBillAnnually" Text="<%$ Resources: ServicePlanManagement, ListItemAnnuallyAmount %>" Value="Annually" runat="server" />
                                                <asp:ListItem ID="rdbtBillMonthly" Text="<%$ Resources: ServicePlanManagement, ListItemMonthlyAmount %>" Value="Monthly" runat="server" />
                                            </asp:RadioButtonList>
                                            <asp:CustomValidator ID="cvBillingPeriods" runat="server" ErrorMessage="<%$ Resources: ServicePlanManagement, ErrorMessageBillingMethodRequired %>"
                                                ValidationGroup="ServicePlanGroup" Text="<%$ Resources: Default, RequiredValidatorText %>" ClientValidationFunction="ValidateBillingPeriods"></asp:CustomValidator>
                                        </td>
                                        <td width="300px" valign="top">
                                            <table class="gvTable" cellpadding="0" cellspacing="0" runat="server" style="white-space: nowrap">
                                                <tr>
                                                    <td>
                                                        <asp:Literal ID="Literal8" runat="server" Text="<%$ Resources: ServicePlanManagement, LabelPremiumColon %>"></asp:Literal>
                                                        &nbsp;<%=CurrencyData.CurrencySymbol%>:
                                                    </td>
                                                    <td width="180px">
                                                        <asp:TextBox ID="txtBillAmount" runat="server" align="right" />
                                                        <asp:RequiredFieldValidator ID="rfvTxtBillAmount" runat="server" Text="<%$ Resources: Default, RequiredValidatorText %>"
                                                            ValidationGroup="ServicePlanGroup" ErrorMessage="<%$ Resources: BillingManagement, ErrorMessageBillingAmountFieldisRequired %>"
                                                            ControlToValidate="txtBillAmount" Display="Dynamic" InitialValue=""></asp:RequiredFieldValidator>
                                                        <asp:RegularExpressionValidator ID="revTxtBillAmount" runat="server" Text="<%$ Resources: Default, ErrorMessageInvalid %>"
                                                            ValidationGroup="ServicePlanGroup" Display="Dynamic" ErrorMessage="<%$ Resources: BillingManagement, ErrorMessageBillingAmounthasanInvalidFormat %>"
                                                            ValidationExpression="\d+\.\d{2}" ControlToValidate="txtBillAmount"> </asp:RegularExpressionValidator>
                                                    </td>
                                                </tr>
                                                <tr>
                                                    <td nowrap="nowrap">
                                                        <asp:Label runat="server" Text="<%$ Resources: Default, LabelLowBound %>" /> (>) &nbsp;<%=CurrencyData.CurrencySymbol%>:
                                                    </td>
                                                    <td width="180px">
                                                        <asp:TextBox ID="txtLowBound" runat="server" align="right" />
                                                        <asp:RequiredFieldValidator ID="rfvLowBound" runat="server" Text="<%$ Resources: Default, RequiredValidatorText %>" ErrorMessage="<%$ Resources: Default, ErrorMEssageLowBoundValueisRequired %>"
                                                            ValidationGroup="ServicePlanGroup" ControlToValidate="txtLowBound" Display="Dynamic"
                                                            InitialValue=""></asp:RequiredFieldValidator>
                                                    </td>
                                                </tr>
                                                <tr>
                                                    <td nowrap="nowrap">
                                                        <asp:Label runat="server" Text="<%$ Resources: Default, LabelUpperBound %>" /> (<=) &nbsp;<%=CurrencyData.CurrencySymbol%>:
                                                    </td>
                                                    <td width="180px">
                                                        <asp:TextBox ID="txtUpperBound" runat="server" align="right" />
                                                        <asp:RequiredFieldValidator ID="rfvUpperBound" runat="server" Text="<%$ Resources: Default, RequiredValidatorText %>" ErrorMessage="<%$ Resources: Default, ErrorMessageUpperBoundValueisRequired %>"
                                                            ValidationGroup="ServicePlanGroup" ControlToValidate="txtUpperBound" Display="Dynamic"
                                                            InitialValue=""></asp:RequiredFieldValidator>
                                                        <asp:CustomValidator ID="cvUpperBound" runat="server" Display="Dynamic" ErrorMessage="<%$ Resources: Default, ErrorMessageLowerBoundmustbelesserthanupperbound %>"
                                                            ValidationGroup="ServicePlanGroup" OnServerValidate="cvUpperBound_Validate"></asp:CustomValidator>
                                                    </td>
                                                </tr>
                                                <tr>
                                                    <td>
                                                        <asp:Literal ID="m_chkDirectBillingFlag" runat="server" Text="<%$ Resources: BillingManagement, LabelDirectBillingColon %>" />
                                                    </td>
                                                    <td width="180px">
                                                        <asp:CheckBox ID="chkDirectBillingFlag" runat="server" 
                                                            OnCheckedChanged="chkDirectBillingFlag_CheckedChanged" />
                                                    </td>
                                                </tr>
                                            </table>
                                        </td>
                                        <td width="300px" valign="top">
                                            <div style="padding-left: 10%">
                                                <table id="Table1" class="gvTable" cellpadding="0" cellspacing="0" runat="server" style="white-space: nowrap"
                                                valign="top">
                                                <tr valign="top">
                                                    <td align="left" valign="top"  >
                                                        <asp:Literal ID="Literal7" runat="server" Text="<%$ Resources: ServicePlanManagement, LabelCapCost %>"></asp:Literal>&nbsp;
                                                        <%=CurrencyData.CurrencySymbol%>:
                                                    </td>
                                                    <td align="left" width="280px" valign="top"  >
                                                        <asp:TextBox runat="server" ID="txtCapCost"></asp:TextBox>
                                                        <asp:RegularExpressionValidator runat="server" ID="revCapCost" ControlToValidate="txtCapCost"></asp:RegularExpressionValidator>
                                                    </td>
                                                </tr>
                                                <tr valign="top">
                                                    <td align="left" style="white-space: nowrap" valign="top"  >
                                                        <asp:Literal ID="Literal5" runat="server" Text="<%$ Resources: BillingManagement, LabelBillingAndCollection %>"></asp:Literal>
                                                        <%=CurrencyData.CurrencySymbol%>:
                                                    </td>
                                                    <td align="left" width="280px" valign="top"  >
                                                        <asp:TextBox runat="server" ID="BandCInput"></asp:TextBox>
                                                        <asp:RegularExpressionValidator runat="server" ID="BAndCRegexValidator" ControlToValidate="BandCInput"
                                                            ValidationGroup="ServicePlanGroup"></asp:RegularExpressionValidator>
                                                    </td>
                                                </tr>






                                                <tr valign="top">
                                                    <td align="left" style="white-space: nowrap" valign="top"  >
                                                        <asp:Literal ID="Literal11" runat="server" Text="INS_BNC"></asp:Literal>
                                                        <%=CurrencyData.CurrencySymbol%>:
                                                    </td>
                                                    <td align="left" width="280px" valign="top"  >
                                                        <asp:TextBox runat="server" ID="txtINSBNC"></asp:TextBox>
                                                        <asp:RegularExpressionValidator runat="server" ID="RegexValidatorINSBNC" ControlToValidate="txtINSBNC"
                                                            ValidationGroup="ServicePlanGroup"></asp:RegularExpressionValidator>
                                                    </td>
                                                </tr>

                                                <tr valign="top">
                                                    <td align="left" style="white-space: nowrap" valign="top"  >
                                                        <asp:Literal ID="Literal12" runat="server" Text="SK_BNC"></asp:Literal>
                                                        <%=CurrencyData.CurrencySymbol%>:
                                                    </td>
                                                    <td align="left" width="280px" valign="top"  >
                                                        <asp:TextBox runat="server" ID="txtSKBNC"></asp:TextBox>
                                                        <asp:RegularExpressionValidator runat="server" ID="RegexValidatorSKBNC" ControlToValidate="txtSKBNC"
                                                            ValidationGroup="ServicePlanGroup"></asp:RegularExpressionValidator>
                                                    </td>
                                                </tr>
                                                <tr valign="top">
                                                    <td align="left" style="white-space: nowrap" valign="top"  >
                                                        <asp:Literal ID="Literal13" runat="server" Text="MW_BNC"></asp:Literal>
                                                        <%=CurrencyData.CurrencySymbol%>:
                                                    </td>
                                                    <td align="left" width="280px" valign="top"  >
                                                        <asp:TextBox runat="server" ID="txtMWBNC"></asp:TextBox>
                                                        <asp:RegularExpressionValidator runat="server" ID="RegexValidatorMWBNC" ControlToValidate="txtMWBNC"
                                                            ValidationGroup="ServicePlanGroup"></asp:RegularExpressionValidator>
                                                    </td>
                                                </tr>
                                                <tr valign="top">
                                                    <td align="left" style="white-space: nowrap" valign="top"  >
                                                        <asp:Literal ID="Literal14" runat="server" Text="RW_BNC"></asp:Literal>
                                                        <%=CurrencyData.CurrencySymbol%>:
                                                    </td>
                                                    <td align="left" width="280px" valign="top"  >
                                                        <asp:TextBox runat="server" ID="txtRWBNC"></asp:TextBox>
                                                        <asp:RegularExpressionValidator runat="server" ID="RegexValidatorRWBNC" ControlToValidate="txtRWBNC"
                                                            ValidationGroup="ServicePlanGroup"></asp:RegularExpressionValidator>
                                                    </td>
                                                </tr>
                                                <tr valign="top">
                                                    <td align="left" style="white-space: nowrap" valign="top"  >
                                                        <asp:Literal ID="Literal15" runat="server" Text="AS_BNC"></asp:Literal>
                                                        <%=CurrencyData.CurrencySymbol%>:
                                                    </td>
                                                    <td align="left" width="280px" valign="top"  >
                                                        <asp:TextBox runat="server" ID="txtASBNC"></asp:TextBox>
                                                        <asp:RegularExpressionValidator runat="server" ID="RegexValidatorASBNC" ControlToValidate="txtASBNC"
                                                            ValidationGroup="ServicePlanGroup"></asp:RegularExpressionValidator>
                                                    </td>
                                                </tr>






                                                 <tr valign="top">
                                                    <td align="left" style="white-space: nowrap" valign="top"  >
                                                        <asp:Literal ID="Literal10" runat="server" Text="<%$ Resources: BillingManagement, LabelDefaultChargebackFee %>"></asp:Literal>
                                                        <%=CurrencyData.CurrencySymbol%>:
                                                    </td>
                                                    <td align="left" width="280px" valign="top"  >
                                                        <asp:TextBox runat="server" ID="txtDefaultChargebackFee"></asp:TextBox>
                                                        <asp:RegularExpressionValidator runat="server" ID="revDefaultChargebackFee" ControlToValidate="txtDefaultChargebackFee" 
                                                            ValidationGroup="ServicePlanGroup" ></asp:RegularExpressionValidator>
                                                    </td>
                                                </tr>
                                            </table>
                                            </div> 
                                        </td>
                                    </tr>
                                </table>
                            </div>
                            <!-- this is the New section for Fullfillment method and deductible collector -->
                            <h2>
                                <asp:Literal ID="litFullfillmentSection" runat="server" Text="<%$ Resources: FulfillmentManagement, LabelClaimFullfillment %>" />
                            </h2>
                            <div style="background-color: #DBDCDE; padding-left: 50px">
                                <table class="gvTable" cellspacing="0" cellpadding="0" border="0">
                                    <tr>
                                        <%--<td width="150px">Fullfillment Method </td>             
                            <td width="200px"  valign="top"> 
                                 <asp:DropDownList ID="ddlFullFillmentMethod"  runat="server" AutoPostBack="true"
                                                    OnSelectedIndexChanged="ddlFullFillmentMethod_SelectionChanged" >
                                    <asp:ListItem  Text="In-Store" Value="92" />
                                    <asp:ListItem  Text="Advance Exchange" Value="91" />
                                   <asp:ListItem  Text="Hybrid" Value="93" />--%>
                                        <%--       <asp:ListItem  Text="Post Exchange" Value="94" />
                                    <asp:ListItem  Text="Reimbursment" Value="103" />
                                </asp:DropDownList> 
                            </td> --%>
                                        <td width="175px">
                                            <asp:Label runat="server" Text="<%$ Resources: FulfillmentManagement, LabelInStoreDeductibleCollectorColon %>" />
                                        </td>
                                        <td width="200px" valign="top">
                                            <asp:DropDownList ID="ddlDeductibleCollector" runat="server">
                                                <asp:ListItem Text="<%$ Resources: OrganizationManagement, ListItemClient %>" Value="1543" />
                                                <asp:ListItem Text="<%$ Resources: OrganizationManagement, ListItemeSecuritel %>" Value="1544" />
                                            </asp:DropDownList>
                                        </td>
                                    </tr>
                                </table>
                            </div>
                        </div>
                    </ContentTemplate>
                </ajaxToolkit:TabPanel>
            </ajaxToolkit:TabContainer>
        </ContentTemplate>
    </asp:UpdatePanel>
    <table width="100%">
        <tr>
            <td align="center">
                <asp:Button ID="m_btnSave" OnClick="m_btnSave_Click" Text="<%$ Resources: Default, ButtonSave %>" runat="server" CssClass="pagebutton"
                    CausesValidation="true" />
                <asp:Button ID="m_btnCancel" runat="server" CssClass="pagebutton" Text="<%$ Resources: Default, ButtonCancel %>"
                     OnClientClick="ClickBack();return false;" />
            </td>
        </tr>
    </table>
    <script language="javascript" type="text/javascript">
        function ValidateBillingPeriods(oSrc, args) {

            var radioBtnBillOneTime = $get('<%= radiolist.ClientID %>_0');
            var radioBtnBillAnnually = $get('<%= radiolist.ClientID %>_1');
            var radioBtnBillMonthly = $get('<%= radiolist.ClientID %>_2');
            args.IsValid = radioBtnBillOneTime.checked
                                || radioBtnBillAnnually.checked
                                || radioBtnBillMonthly.checked;
        }

        function tabContainerPlans_ClientActiveTabChanged(sender, args) {
            var price = 0;
            $("[id$=txtPrice]").each(function () { price += parseFloat($(this).val()) });
            $("[id$=_txtBillAmount]").val(price.toFixed(2));
            var manageRecordingURL = window.location.href.split('WebSite')[0] + "WebSite/ManageRecording.aspx";
            var url = manageRecordingURL + "?TabIndex=" + sender.get_activeTabIndex() + "&PageUrl=" + window.location.href.split('?')[0] + "&TabId=tabContainerPlans";
            $.ajax({ url: url, cache: false });

            var lblStatus = $get('<%= lblStatus.ClientID %>');
            if (lblStatus != null) {
                lblStatus.style.display = 'none';
            }

            ServicePlanInformation_LayoutFix();
        }

        function CheckIfInternetExplorer() {

            var rv = -1; // Return value assumes failure.
            if (navigator.appName == 'Microsoft Internet Explorer') {
                var ua = navigator.userAgent;
                var re = new RegExp("MSIE ([0-9]{1,}[\.0-9]{0,})");
                if (re.exec(ua) != null)
                    rv = parseFloat(RegExp.$1);
                if (rv == 7.0 || rv == 8.0 || rv == 9.0 || rv == 10.0) {
                    isIE = true;
                }
            } else if (navigator.appName == 'Netscape') {
                var usAg = navigator.userAgent;
                var reg = new RegExp("Trident/.*rv:([0-9]{1,}[\.0-9]{0,})");
                if (reg.exec(usAg) != null)
                    rv = parseFloat(RegExp.$1);
                if (rv == 11.0 || rv > 11.0) {
                    isIE = true;
                }
            }

        }

        function ServicePlanInformation_LayoutFix() {

            var widthToSet = $('[id$=tabPanelGeneral_txtRatePlanName]').outerWidth(true);

            $('[id$=tabPanelGeneral_ucClientCarrierDropDowns_ddlClient]').css('width', widthToSet);
            $('[id$=tabPanelGeneral_ucClientCarrierDropDowns_ddlCarrier]').css('width', widthToSet);
            $('[id$=tabPanelGeneral_ddlCoverageType]').css('width', widthToSet);
            $('[id$=tabPanelGeneral_ddlWirelessPlanType]').css('width', widthToSet);
            $('[id$=tabPanelGeneral_ddlServiceRefundMethod]').css('width', widthToSet);
            $('[id$=tabPanelGeneral_ucClientCarrierDropDowns_lblClient]').parent().attr('align', 'left');
            $('[id$=tabPanelGeneral_ucClientCarrierDropDowns_lblCarrier]').parent().attr('align', 'left');
            
            $('[ID$=tabPanelGeneral_txtClaimLimit]').css('width', $('[ID$=tabPanelGeneral_txtAdditionalServices]').css('width'));

            var labelWidth = $('#labelFirstColumn').css('width');
            if (isIE) {
                labelWidth = (parseInt($('#labelFirstColumn').css('width'), 10) - 13) + 'px';
            }

            $('[id$=tabPanelGeneral_ucClientCarrierDropDowns_lblClient]').css('width', labelWidth);
            $('[id$=tabPanelGeneral_ucClientCarrierDropDowns_lblCarrier]').css('width', labelWidth);

        }

        $(document).ready(function () {

            CheckIfInternetExplorer();

            ServicePlanInformation_LayoutFix();

        });

        function ClickBack()
        {
            $('[id$=PersistNav_m_hlBack]')[0].click();
        }

    </script>
</asp:Content>
