Skip to content

Commit

Permalink
Merge pull request #4988 from kiva/fix-snowplow-events-in-basket
Browse files Browse the repository at this point in the history
fix: format value to integer
  • Loading branch information
christian14b authored Sep 27, 2023
2 parents 4f29961 + 301e0a6 commit ad1d901
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/components/Checkout/DonationItem.vue
Original file line number Diff line number Diff line change
Expand Up @@ -891,7 +891,7 @@ export default {
}
const donationProperty = this.donation.isUserEdited ? 'user-set' : 'kiva-set';
this.$kvTrackEvent('basket', 'show', 'tip-donation-amount', donationProperty, this.donation.price);
this.$kvTrackEvent('basket', 'show', 'tip-donation-amount', donationProperty, this.donation.price * 100);
this.setupContentfulContent();
},
watch: {
Expand Down
8 changes: 4 additions & 4 deletions src/components/Checkout/OrderTotals.vue
Original file line number Diff line number Diff line change
Expand Up @@ -443,11 +443,11 @@ export default {
},
trackBasketInfoEvents() {
const creditProperty = !this.showApplyKivaCredit ? 'applied' : 'not-applied';
const creditValue = !this.showApplyKivaCredit ? this.totals.kivaCreditAppliedTotal
: this.totals.creditAvailableTotal;
const creditValue = 100 * (!this.showApplyKivaCredit ? this.totals.kivaCreditAppliedTotal
: this.totals.creditAvailableTotal);
this.$kvTrackEvent('basket', 'show', 'kiva-credit', creditProperty, creditValue);
this.$kvTrackEvent('basket', 'show', 'loans', null, this.totals.loanReservationTotal);
this.$kvTrackEvent('basket', 'show', 'basket-size', null, this.totals.itemTotal);
this.$kvTrackEvent('basket', 'show', 'loans', null, this.totals.loanReservationTotal * 100);
this.$kvTrackEvent('basket', 'show', 'basket-size', null, this.totals.itemTotal * 100);
}
},
apollo: {
Expand Down

0 comments on commit ad1d901

Please sign in to comment.