MWPW-181558 [M@S Catalog] Analytics
Analytics for M@S catalog page.
The code is more or less copied from https://github.com/adobecom/cc/blob/stage/creativecloud/blocks/catalog/catalog.js#L34 and adapted.
Test page https://main--cc--adobecom.aem.live/drafts/rivero/products/catalog?milolibs=mwpw181558cata--milo--bozojovicic
Should be also checked https://main--cc--adobecom.aem.live/creativecloud/plans?milolibs=mwpw181558cata--milo--bozojovicic
Resolves: MWPW-181558
Test URLs:
- Before: https://main--milo--adobecom.aem.live/?martech=off
- After: https://mwpw181558cata--milo--bozojovicic.aem.live/?martech=off
This PR has not been updated recently and will be closed in 7 days if no action is taken. Please ensure all checks are passing, https://github.com/orgs/adobecom/discussions/997 provides instructions. If the PR is ready to be merged, please mark it with the "Ready for Stage" label.
@Roycethan Conflicts resolved.
1 - Fixed. Also if we open the page with #filter=photo that is automatically added as well.
2 - On Milo catalog page each card is a new block while on MAS Catalog the card collection and all cards inside are one block and that's why we don't have these bx on cards on mas catalog. It is the same on MAS Plans page. Generally we use the same analytics principles and the same custom analytics code for mas plans and mas catalog. These pages also have similar structure. So if we try to make the mas catalog page similar to milo catalog page we will need to add tons of code which will then be executed also on mas plans page so I would rather avoid that.
3 - Geri and Lucy also reported this. If we don't add daa-ll to card links there is some code which runs at the end and adds some generic values using the same index for all cards and that's why we have these 100+ indexes. I updated the code to add daa-ll to links with meaningful values so now we have :
-
daa-ll="photoshop--phsp--card"for card title link -
daa-ll="learn-more--phsp--card"for "learn more" link -
daa-ll="buy-now-1--phsp--card"for card CTA, as before
The similar values we have for card links on plans page.
@bozojovicic Plz review below feedbacks and resolve the JS conflicts. On Milo catalog https://main--cc--adobecom.aem.live/products/catalog Click event on any links say for example click on Second merch card title (Acrobat Pro) and event name: Acrobat Pro-1--acrobat-pro|s2|all|b2|merch-card|nopzn|catalog
and on M@S test page https://main--cc--adobecom.aem.page/drafts/fredw/catalog/catalog-mas?maslibs=MWPW-182519--mas--adobecom&milolibs=mwpw181558cata--milo--bozojovicic
Event Name: Acrobat Pro-6--Acrobat Pro|s2|b1|content|nopzn|catalog
1)Without clicking on the Side navigation filter, like on initial page load - the event is missing the filter name 'all' - it appends only when user clicks on the filter. 2)if you see the value 'b2' in Milo page and 'b1' in M@S, for each merch card or block the counter is incremented in Milo...like b3,b4 and so on... 3)Also theres a difference at counter at Acrobat Pro-1 VS Acrobat Pro-6
#1 and #3 are fixed, #2 is by design.
@Blainegunn @joaquinrivero @TsayAdobe Reviews plz... , from my and Bozo's side qa/fixes completed.
@Blainegunn @joaquinrivero @TsayAdobe Reviews plz... , from my and Bozo's side qa/fixes completed.
Plz add your reviews guys , since this is blocked for merge
@bozojovicic Take a look on the conlicts
@bozojovicic Plz pull latest from stage/resolve conflicts