예제 #1
0
        public WebSessionDRC(WebSession websession)
        {
            this.AddInfo   = websession.AddInfo;
            this.Guid      = websession.Guid;
            this.Quote     = websession.Quote;
            this.Discounts = websession.Discounts;
            this.TotalDiscountSavingsWithoutPreferredPayer = websession.TotalDiscountSavingsWithoutPreferredPayer;
            this.TotalDiscountSavings           = websession.TotalDiscountSavings;
            this.SelectedPreferredPayerDiscount = websession.SelectedPreferredPayerDiscount;

            this.PolicyCoverages       = websession.PolicyCoverages;
            this.PolicyCoverageErrors  = websession.PolicyCoverageErrors;
            this.VehicleCoverages      = websession.VehicleCoverages;
            this.VehicleCoverageErrors = websession.VehicleCoverageErrors;
            this.EnhancedCoverages     = websession.EnhancedCoverages;
            this.CoveragePageDiscounts = websession.CoveragePageDiscounts;
            this.TotalPremium          = websession.TotalPremium;
            this.PayPlans        = websession.PayPlans;
            this.SelectedPayPlan = websession.SelectedPayPlan;
            this.AnnualPayPlanDiscountSavings = websession.AnnualPayPlanDiscountSavings;
            this.InstallmentFees            = websession.InstallmentFees;
            this.HasInstallmentFees         = websession.HasInstallmentFees;
            this.IsVibeState                = websession.IsVibeState;
            this.IsWebModelState            = websession.IsWebModelState;
            this.Questions                  = websession.Questions;
            this.IncidentSelections         = websession.IncidentSelections;
            this.HasAccidentsViolations     = websession.HasAccidentsViolations;
            this.RentersPropertySelections  = websession.RentersPropertySelections;
            this.RentersLiabilitySelections = websession.RentersLiabilitySelections;

            this.RentersDeductibleSelections = websession.RentersDeductibleSelections;
            this.RentersRates  = websession.RentersRates;
            this.xRentersRates = websession.xRentersRates;
        }
예제 #2
0
        //rules taken from Flex UDQuoteLibrary DiscountServices.as
        public static string FormatDiscountDescription(this string input, WebSession websession)
        {
            string result;

            result = input.Replace("{iMingleDescription}", getiMingleDescription(websession.Quote.getPolicyInfo().getMarketBrand(), websession.AddInfo.Referral));
            result = result.Replace("{CompanyName}", GetCompanyName(websession.Quote.getPolicyInfo().getMarketBrand()));
            result = result.Replace("{Group}", GetGroupName(websession.Quote.getPolicyInfo().getMarketBrand()));
            result = result.Replace("<sup>™</sup>", "™");
            result = result.Replace("<sup>®</sup>", "™");
            result = result.Replace("<sup>&trade;</sup>", "™");
            result = result.Replace("<sup>&reg;</sup>", "™");
            result = result.Replace("&lt;span style='font-weight:bold;'&gt;", "");
            result = result.Replace("<span style='font-weight:bold;'>", "");
            result = result.Replace("&lt;/span&gt;", "");
            result = result.Replace("</span>", "");
            result = result.Replace("&amp;nbsp;", " ");
            result = result.Replace("&nbsp;", " ");
            result = result.Replace("[Kemper Direct/Teachers/Partnership Direct]", GetGroupName(websession.Quote.getPolicyInfo().getMarketBrand()));
            if (result == "iMingle Network<sup>&trade;</sup> Discount" || result == "iMingle Network<sup>&reg;</sup> Discount" || result == "iMingle Network™")
            {
                int marketBrand = websession.Quote.getPolicyInfo().getMarketBrand();
                if (marketBrand == 1 || marketBrand == 0)
                {
                    result = "Network Discount";
                }
                else if (marketBrand == 3)
                {
                    result = "Teachers' Network™ Discount";
                }
            }
            return(result);
        }