mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-21 20:47:08 -05:00
added event tracking to subscription cretion/cancelation
This commit is contained in:
parent
e7602321e9
commit
3d0bd34b50
2 changed files with 15 additions and 2 deletions
|
@ -58,7 +58,7 @@ block content
|
|||
p Your subscription has been canceled and will terminate on <strong>#{subscription.nextPaymentDueAt}</strong>. No further payments will be taken.
|
||||
form(action="/user/subscription/reactivate",method="post")
|
||||
input(type="hidden", name="_csrf", value=csrfToken)
|
||||
input(type="submit",value="Reactivate your subscription").btn.btn-success
|
||||
input(type="submit",value="Reactivate your subscription").btn.btn-success#cancelSubscription
|
||||
when "expired"
|
||||
p Your subscription has expired.
|
||||
a(href="/user/subscription/plans") Create New Subscription
|
||||
|
@ -80,4 +80,11 @@ block content
|
|||
mixin printPlans(plans.individualAnnualPlans)
|
||||
|
||||
|
||||
script(type="text/javascript")
|
||||
$('#cancelSubscription').on("click", function() {
|
||||
ga('send', 'event', 'subscription-funnel', 'cancelation')
|
||||
})
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -14,7 +14,13 @@ block content
|
|||
|
||||
script(type="text/javascript")
|
||||
Recurly.config(!{recurlyConfig})
|
||||
Recurly.buildSubscriptionForm(!{subscriptionFormOptions});
|
||||
var recurlySubscriptionFormConfig = !{subscriptionFormOptions}
|
||||
recurlySubscriptionFormConfig.successHandler = function(){
|
||||
ga('send', 'event', 'subscription-funnel', 'created')
|
||||
}
|
||||
|
||||
Recurly.buildSubscriptionForm();
|
||||
|
||||
|
||||
include ../general/small-footer
|
||||
|
||||
|
|
Loading…
Reference in a new issue