2020 Jul 10 1:39 PM - edited 2024 Feb 03 7:22 PM
Hi Everyone,
Problem -- Trying to show Banner on PLP and PDP page according to the category selected.Used Category restriction to control the banner component as per category selected. But After providing restriction , On PLP page i am able to see the banner Component as Per the category selected . But on PDP page the banner component disappears even after the product selected is from the same Category to which restriction Applied on Component.
I have to use the same banner component for both PDP and PLP page.
I have given the lines of code being used by me to create component and restrictions:
INSERT_UPDATE BannerComponent;$contentCV[unique=true];uid[unique=true];name;ComponentRef;urlLink;content;headline;$picture
;;Category1BannerComponent;Category1 Component;Category1BannerComponent;"/pcs";"Content1";"Find the right";pic1.jpg
;;Category2BannerComponent;Category2 Component;Category2BannerComponent;"/pcs";"Content2";"Find the right";pic2.jpg
;;Category3BannerComponent;Category3 Component;Category3BannerComponent;"/pcs";"Content3";"Find the right";pic3.jpg
INSERT_UPDATE ComponentSelectorBannerComponent;$contentCV[unique=true];uid[unique=true];name;banners(componentRef);componentRef
;;CustomBannerComponent;Custom BannerComponent;Category1BannerComponent,Category2BannerComponent,Category3BannerComponent;CustomBannerComponent
INSERT_UPDATE CMSCategoryRestriction; uid[unique = true] ; $contentCV[unique = true]; categories(code, $productCV) ; components(uid, $contentCV) ; ComponentRef
; Category1CommponentRestriction ;; 101001000000 ; Category1BannerComponent ; Category1CommponentRestriction
; Category2CommponentRestriction ;; 101002000000 ; Category2BannerComponent ; Category2CommponentRestriction
; Category3ComponentRestriction ;; 101007190900,40141600; Category3BannerComponent ; Category3ComponentRestriction
Any help would be appreciated.
Thanks
Request clarification before answering.
| User | Count |
|---|---|
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.