2014-02-12 05:23:40 -05:00
extends ../layout
2014-12-18 12:48:23 -05:00
2016-10-11 09:30:27 -04:00
block scripts
2014-10-13 12:28:00 -04:00
script(type='text/javascript').
2015-01-07 08:16:19 -05:00
window.countryCode = '#{countryCode}'
2014-10-13 12:28:00 -04:00
window.plan_code = '#{plan_code}'
2014-12-23 07:08:01 -05:00
window.recurlyApiKey = "!{settings.apis.recurly.publicKey}"
2017-03-14 13:53:48 -04:00
window.couponCode = !{JSON.stringify(couponCode)}
window.recomendedCurrency = !{JSON.stringify(currency.slice(0,3))}
2014-02-12 05:23:40 -05:00
block content
2014-07-07 08:43:36 -04:00
.content.content-alt
2018-06-13 12:22:34 -04:00
2014-10-14 10:46:44 -04:00
.container(ng-controller="NewSubscriptionController" ng-cloak)
.row.card-group
2015-01-07 09:51:54 -05:00
.col-md-5.col-md-push-4
2018-08-30 14:20:58 -04:00
.card.card-highlighted.card-border
2014-10-15 05:23:08 -04:00
.page-header
2014-12-28 13:16:55 -05:00
.row
2015-01-29 05:44:42 -05:00
.col-xs-9
2018-04-16 05:35:12 -04:00
h2 {{planName}}
2015-01-29 05:44:42 -05:00
.col-xs-3
2015-06-03 06:14:26 -04:00
div.dropdown.changePlanButton.pull-right(ng-cloak, dropdown)
2014-12-28 13:16:55 -05:00
a.btn.btn-default.dropdown-toggle(
href="#",
2015-06-03 06:14:26 -04:00
data-toggle="dropdown",
dropdown-toggle
2014-12-28 13:16:55 -05:00
)
2018-11-13 08:35:50 -05:00
| {{currencyCode}} ({{allCurrencies[currencyCode]['symbol']}})
2014-12-28 13:16:55 -05:00
span.caret
ul.dropdown-menu(role="menu")
2018-11-13 08:35:50 -05:00
li(ng-repeat="(currency, value) in availableCurrencies")
2014-12-28 13:16:55 -05:00
a(
ng-click="changeCurrency(currency)",
2018-04-12 17:11:52 -04:00
) {{currency}} ({{value['symbol']}})
2018-08-27 10:03:01 -04:00
.row(ng-if="planCode == 'student-annual' || planCode == 'student-monthly'")
2018-04-12 17:11:52 -04:00
.col-xs-12
p.student-disclaimer #{translate('student_disclaimer')}
2018-06-13 12:22:34 -04:00
2015-01-29 05:44:42 -05:00
hr.thin
.row
.col-md-12.text-center
2015-11-17 07:23:27 -05:00
div(ng-if="trialLength")
span !{translate("first_few_days_free", {trialLen:'{{trialLength}}'})}
span(ng-if="discountMonths && discountRate") - {{discountMonths}} #{translate("month")}s {{discountRate}}% Off
2015-01-29 05:44:42 -05:00
div(ng-if="price")
2018-11-13 08:35:50 -05:00
strong {{availableCurrencies[currencyCode]['symbol']}}{{price.next.total}}
2015-02-10 13:05:39 -05:00
span(ng-if="monthlyBilling") #{translate("every")} #{translate("month")}
span(ng-if="!monthlyBilling") #{translate("every")} #{translate("year")}
2015-11-17 06:42:03 -05:00
div(ng-if="normalPrice")
2018-11-13 08:35:50 -05:00
span.small Normally {{availableCurrencies[currencyCode]['symbol']}}{{normalPrice}}
2015-01-07 08:16:19 -05:00
.row
2016-10-11 09:07:31 -04:00
div()
.col-md-12()
2018-04-13 11:29:01 -04:00
form(
name="simpleCCForm"
novalidate
)
2016-08-18 12:41:55 -04:00
2018-04-13 11:29:01 -04:00
div.payment-method-toggle
a.payment-method-toggle-switch(
href
ng-click="setPaymentMethod('credit_card');"
ng-class="paymentMethod.value === 'credit_card' ? 'payment-method-toggle-switch-selected' : ''"
)
i.fa.fa-cc-mastercard.fa-2x
span
i.fa.fa-cc-visa.fa-2x
span
i.fa.fa-cc-amex.fa-2x
a.payment-method-toggle-switch(
href
ng-click="setPaymentMethod('paypal');"
ng-class="paymentMethod.value === 'paypal' ? 'payment-method-toggle-switch-selected' : ''"
)
i.fa.fa-cc-paypal.fa-2x
.alert.alert-warning.small(ng-show="genericError")
strong {{genericError}}
2018-04-13 11:57:33 -04:00
div(ng-show="paymentMethod.value === 'credit_card'")
2018-04-13 11:29:01 -04:00
.row
.col-xs-6
2018-04-16 05:35:12 -04:00
.form-group(ng-class="validation.errorFields.first_name || inputHasError(simpleCCForm.firstName) ? 'has-external-error' : ''")
2018-04-13 11:29:01 -04:00
label(for="first-name") #{translate('first_name')}
input#first-name.form-control(
type="text"
maxlength='255'
data-recurly="first_name"
name="firstName"
ng-model="data.first_name"
required
)
span.input-feedback-message {{ simpleCCForm.firstName.$error.required ? 'This field is required' : '' }}
.col-xs-6
2018-04-16 05:35:12 -04:00
.form-group(for="last-name",ng-class="validation.errorFields.last_name || inputHasError(simpleCCForm.lastName)? 'has-external-error' : ''")
2018-04-13 11:29:01 -04:00
label(for="last-name") #{translate('last_name')}
input#last-name.form-control(
type="text"
maxlength='255'
data-recurly="last_name"
name="lastName"
ng-model="data.last_name"
required
)
2018-04-16 05:35:12 -04:00
.form-group(ng-class="validation.errorFields.number ? 'has-external-error' : ''")
2018-04-13 11:29:01 -04:00
label(for="card-no") #{translate("credit_card_number")}
2018-04-13 11:51:55 -04:00
div#card-no(
2018-04-13 11:29:01 -04:00
type="text"
name="ccNumber"
data-recurly='number'
)
.row
.col-xs-3
2018-04-16 05:35:12 -04:00
.form-group.has-feedback(ng-class="validation.errorFields.month ? 'has-external-error' : ''")
2018-04-17 06:26:02 -04:00
label(for="month").capitalised #{translate("month")}
2018-04-13 11:51:55 -04:00
div(
2018-04-16 05:10:25 -04:00
type="number"
2018-04-13 11:29:01 -04:00
name="month"
data-recurly="month"
)
.col-xs-3
2018-04-16 05:35:12 -04:00
.form-group.has-feedback(ng-class="validation.errorFields.year ? 'has-external-error' : ''")
2018-04-17 06:26:02 -04:00
label(for="year").capitalised #{translate("year")}
2018-04-13 11:51:55 -04:00
div(
2018-04-16 05:10:25 -04:00
type="number"
2018-04-13 11:29:01 -04:00
name="year"
data-recurly="year"
)
.col-xs-6
2018-04-16 05:35:12 -04:00
.form-group.has-feedback(ng-class="validation.errorFields.cvv ? 'has-external-error' : ''")
2018-04-13 11:29:01 -04:00
label #{translate("security_code")}
2018-04-13 11:51:55 -04:00
div(
2018-04-16 05:10:25 -04:00
type="number"
2018-04-13 11:29:01 -04:00
ng-model="data.cvv"
data-recurly="cvv"
name="cvv"
cc-format-sec-code
)
.form-control-feedback
a.form-helper(
href
tabindex="-1"
tooltip-template="'cvv-tooltip-tpl.html'"
tooltip-trigger="mouseenter"
tooltip-append-to-body="true"
) ?
div
2018-04-16 05:35:12 -04:00
.form-group(ng-class="validation.errorFields.country || inputHasError(simpleCCForm.country) ? 'has-external-error' : ''")
2018-04-13 11:29:01 -04:00
label(for="country") #{translate('country')}
select#country.form-control(
data-recurly="country"
ng-model="data.country"
name="country"
ng-change="updateCountry()"
2018-04-16 10:12:03 -04:00
required,
ng-options="country.code as country.name for country in countries",
ng-selected="{{country.code == data.country}}"
2018-04-13 11:29:01 -04:00
)
2018-04-16 10:12:03 -04:00
option(value='', disabled, selected) #{translate("country")}
option(value='-') --------------
2018-04-13 11:29:01 -04:00
span.input-feedback-message {{ simpleCCForm.country.$error.required ? 'This field is required' : '' }}
if (showVatField)
.form-group
label(for="vat-no") #{translate('vat_number')}
input#vat-no.form-control(
type="text"
ng-blur="applyVatNumber()"
ng-model="data.vat_number"
)
if (showCouponField)
.form-group
label(for="coupon-code") #{translate('coupon_code')}
input#coupon-code.form-control(
type="text"
ng-blur="applyCoupon()"
ng-model="data.coupon"
)
p(ng-if="paymentMethod.value === 'paypal'") #{translate("paypal_upgrade")}
div.price-breakdown(ng-if="price.next.tax !== '0.00'")
hr.thin
span Total:
2018-11-13 08:35:50 -05:00
strong {{availableCurrencies[currencyCode]['symbol']}}{{price.next.total}}
span ({{availableCurrencies[currencyCode]['symbol']}}{{price.next.subtotal}} + {{availableCurrencies[currencyCode]['symbol']}}{{price.next.tax}} tax)
2018-04-13 11:29:01 -04:00
span(ng-if="monthlyBilling") #{translate("every")} #{translate("month")}
span(ng-if="!monthlyBilling") #{translate("every")} #{translate("year")}
hr.thin
div.payment-submit
button.btn.btn-success.btn-block(
ng-click="submit()"
2018-04-16 06:01:14 -04:00
ng-disabled="processing || !isFormValid(simpleCCForm);"
2018-04-13 11:29:01 -04:00
)
span(ng-show="processing")
i.fa.fa-spinner.fa-spin
|
2018-04-13 12:04:35 -04:00
span(ng-if="paymentMethod.value === 'credit_card'")
| {{ monthlyBilling ? '#{translate("upgrade_cc_btn")}' : '#{translate("upgrade_now")}'}}
span(ng-if="paymentMethod.value !== 'credit_card'") #{translate("upgrade_paypal_btn")}
2018-04-13 11:29:01 -04:00
.col-md-3.col-md-pull-4
if showStudentPlan == 'true'
a.btn-primary.btn.plansPageStudentLink(
href,
ng-click="switchToStudent()"
) #{translate("half_price_student")}
.card.card-first
.paymentPageFeatures
h3 #{translate("unlimited_projects")}
p #{translate("create_unlimited_projects")}
h3
if plan.features.collaborators == -1
- var collaboratorCount = 'Unlimited'
else
- var collaboratorCount = plan.features.collaborators
| #{translate("collabs_per_proj", {collabcount:collaboratorCount})}
p #{translate("work_on_single_version")}. #{translate("view_collab_edits")} in real time.
h3 #{translate("full_doc_history")}
p #{translate("see_what_has_been")}
span.added #{translate("added")}
| #{translate("and")}
span.removed #{translate("removed")}.
| #{translate("restore_to_any_older_version")}.
h3 #{translate("sync_to_dropbox")}
p
| #{translate("acces_work_from_anywhere")}.
| #{translate("work_offline_and_sync_with_dropbox")}.
hr
2018-06-22 09:24:41 -04:00
p.small.text-center We're confident that you'll love #{settings.appName}, but if not you can cancel anytime. We'll give you your money back, no questions asked, if you let us know within 30 days.
2015-11-11 12:59:35 -05:00
2014-02-12 05:23:40 -05:00
2014-08-27 06:09:22 -04:00
script(type="text/javascript").
2014-03-08 13:31:07 -05:00
ga('send', 'event', 'pageview', 'payment_form', "#{plan_code}")
2016-08-17 12:34:17 -04:00
script(
type="text/ng-template"
id="cvv-tooltip-tpl.html"
)
p For #[strong Visa, MasterCard and Discover], the #[strong 3 digits] on the #[strong back] of your card.
p For #[strong American Express], the #[strong 4 digits] on the #[strong front] of your card.