diff --git a/services/web/app/views/subscriptions/new.jade b/services/web/app/views/subscriptions/new.jade index 7ab6e90aa6..1ef9eaac01 100644 --- a/services/web/app/views/subscriptions/new.jade +++ b/services/web/app/views/subscriptions/new.jade @@ -41,7 +41,9 @@ block content hr.thin .row .col-md-12.text-center - div(ng-if="trialLength") !{translate("first_few_days_free", {trialLen:'{{trialLength}}'})} + div(ng-if="trialLength") + span !{translate("first_few_days_free", {trialLen:'{{trialLength}}'})} + span(ng-if="discountMonths && discountRate")   - {{discountMonths}} #{translate("month")}s {{discountRate}}% Off div(ng-if="price") strong {{price.currency.symbol}}{{price.next.total}} span(ng-if="monthlyBilling") #{translate("every")} #{translate("month")} diff --git a/services/web/public/coffee/main/new-subscription.coffee b/services/web/public/coffee/main/new-subscription.coffee index a4e2631380..bb20977272 100644 --- a/services/web/public/coffee/main/new-subscription.coffee +++ b/services/web/public/coffee/main/new-subscription.coffee @@ -58,6 +58,10 @@ define [ if pricing.items?.coupon?.discount?.type == "percent" basePrice = parseInt(pricing.price.base.plan.unit) $scope.normalPrice = basePrice + if pricing.items.coupon.applies_for_months > 0 and pricing.items.coupon?.discount?.rate and pricing.items.coupon?.applies_for_months? + $scope.discountMonths = pricing.items.coupon?.applies_for_months + $scope.discountRate = pricing.items.coupon?.discount?.rate * 100 + if pricing.price?.taxes[0]?.rate? $scope.normalPrice += (basePrice * pricing.price.taxes[0].rate) $scope.$apply()