Allow subscriptions with no free plans, and adjust styles

This commit is contained in:
James Allen 2015-01-29 10:44:42 +00:00
parent 69c3f48c1e
commit 2a78a7843a
3 changed files with 17 additions and 9 deletions

View file

@ -22,11 +22,9 @@ block content
.card.card-highlighted
.page-header
.row
.col-md-9
.col-xs-9
h2 {{planName}}
div !{translate("first_few_days_free", {trialLen:'{{trialLength}}'})}
div #{translate("every")} {{billingCycleType}}
.col-md-3
.col-xs-3
div.dropdown.changePlanButton.pull-right(ng-cloak)
a.btn.btn-default.dropdown-toggle(
href="#",
@ -39,7 +37,13 @@ block content
a(
ng-click="changeCurrency(currency)",
) {{currency}} ({{value['symbol']}})
h2.pull-right.totalPrice {{price.currency.symbol}}{{price.next.total}}
hr.thin
.row
.col-md-12.text-center
div(ng-if="trialLength") !{translate("first_few_days_free", {trialLen:'{{trialLength}}'})}
div(ng-if="price")
strong {{price.currency.symbol}}{{price.next.total}}
span #{translate("every")} {{billingCycleType}}
.row
.col-md-12
form(ng-show="planName")
@ -150,16 +154,16 @@ block content
.row
.col-md-7
.col-xs-7
.form-group
button.btn.btn-success(ng-click="submit()", ng-disabled="processing") #{translate("upgrade_now")}
.col-md-3.pricingBreakdown
.col-xs-3.pricingBreakdown
div Subtotal
div Tax
div
strong Total
.col-md-2
.col-xs-2
div.pull-right {{price.currency.symbol}}{{price.next.subtotal}}
div.pull-right {{price.currency.symbol}}{{price.next.tax}}
div.pull-right

View file

@ -46,7 +46,7 @@ define [
pricing.on "change", =>
$scope.planName = pricing.items.plan.name
$scope.price = pricing.price
$scope.trialLength = pricing.items.plan.trial.length
$scope.trialLength = pricing.items.plan.trial?.length
$scope.billingCycleType = if pricing.items.plan.period.interval == "months" then "month" else "year"
$scope.$apply()

View file

@ -114,6 +114,10 @@ hr {
margin-bottom: @line-height-computed;
border: 0;
border-top: 1px solid @hr-border;
&.thin {
margin-top: @line-height-computed / 2;
margin-bottom: @line-height-computed / 2;
}
}