Skip to content

Commit 0e063b9

Browse files
authored
Merge pull request #7134 from woocommerce/issue/6493-coupon-creation-success-tracks
Coupons: Track when sharing coupon from the coupon creation success screen
2 parents 189addc + fb2cb0a commit 0e063b9

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

WooCommerce/Classes/Analytics/WooAnalyticsStat.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -590,6 +590,7 @@ public enum WooAnalyticsStat: String {
590590
case couponCreationInitiated = "coupon_creation_initiated"
591591
case couponCreationSuccess = "coupon_creation_success"
592592
case couponCreationFailed = "coupon_creation_failed"
593+
case couponCreationSuccessShareTapped = "coupon_creation_success_share_tapped"
593594

594595
// MARK: Inbox Notes
595596
case inboxNotesLoaded = "inbox_notes_loaded"

WooCommerce/Classes/ViewRelated/Coupons/Add and Edit Coupons/CouponCreationSuccess.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ struct CouponCreationSuccess: View {
3636
VStack(alignment: .center, spacing: Constants.contentPadding) {
3737
Button(Localization.shareCoupon) {
3838
showingShareSheet = true
39-
// TODO: add analytics
39+
ServiceLocator.analytics.track(.couponCreationSuccessShareTapped)
4040
}
4141
.buttonStyle(PrimaryButtonStyle())
4242
.shareSheet(isPresented: $showingShareSheet) {

0 commit comments

Comments
 (0)