feat(analytics): differentiate party CTA scenarios

This commit is contained in:
SabreCat
2023-05-03 16:04:22 -05:00
parent c77dd5f200
commit 8183699cb7

View File

@@ -235,15 +235,23 @@ export default {
},
createOrInviteParty () {
if (this.user.party._id) {
this.$router.push('/looking-for-party');
} else {
this.$root.$emit('bv::show::modal', 'create-party-modal');
Analytics.track({
eventName: 'Start a Party button',
eventAction: 'Start a Party button',
eventName: 'Header Party CTA',
eventAction: 'Header Party CTA',
eventCategory: 'behavior',
hitType: 'event',
state: 'Find Party Members',
}, { trackOnClient: true });
this.$router.push('/looking-for-party');
} else {
Analytics.track({
eventName: 'Header Party CTA',
eventAction: 'Header Party CTA',
eventCategory: 'behavior',
hitType: 'event',
state: 'Get Started',
}, { trackOnClient: true });
this.$root.$emit('bv::show::modal', 'create-party-modal');
}
},
loadMembers (payload = null) {