cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Multi-Country SmartEdit - Shared Content Slot

0 Kudos
2,515

Hi,

I am currently working with the new multi country SmartEdit capabilities. I do have the following Catalog Structure: - MasterContentCatalog - EUContentCatalog (supercatalog is MasterContentCatalog) - USContentCatalog (supercatalog is MasterContentCatalog)

For matter of simplicity, assume that all ContentSlots, Pages and Templates are stored in the MasterContentCatalog. On the top left corner I do have a Logo that is placed in a Shared Content Slot (Slot of a template). Now I want to change the logo for all pages that relate to the template, but only for the USContentCatalog. Currently I do not find any solution to do it. The only thing I am able to find is the ability to change Page Content Slots, but not Template Content Slots.

Does anyone have a solution for that? Or is it just not supported right now?

Kind regards, Stephan

Accepted Solutions (1)

Accepted Solutions (1)

Hello,

It is possible to override Shared Content Slot in any Child Content Catalog using undocumented feature of the `ContentSlot` and `CMSPageService`.

You have to specify `originalSlot` of the `ContentSlot` which will be used by `CMSPageService.getSortedMultiCountryContentSlots(..)`.

Take a note that:

  • `ContentSlot.originalSlot` should point to Online version of the parent Content Slot.
  • `ContentSlot.uid` must be unique in the MultiCountry catalog hierarchy, otherwise you may face editing/rendering issues in the SmartEdit. I'd suggest to add catalog-unique prefix/suffix

Sample impex for overriding shared Footer Slot:

UPDATE GenericItem[processor = de.hybris.platform.commerceservices.impex.impl.ConfigPropertyImportProcessor]; pk[unique = true]

$contentCatalog = $config-eu.content.catalog
$contentCV = catalogVersion(CatalogVersion.catalog(Catalog.id[default = $contentCatalog]), CatalogVersion.version[default = Staged])[default = $contentCatalog:Staged]
$contentCVOnline = catalogVersion(CatalogVersion.catalog(Catalog.id[default = $contentCatalog]), CatalogVersion.version[default = Online])[default = $contentCatalog:Online]

$contentCatalogCountry = $config-eu.it.content.catalog
$contentCVCountry = catalogVersion(CatalogVersion.catalog(Catalog.id[default = $contentCatalogCountry]), CatalogVersion.version[default = Staged])[default = $contentCatalogCountry:Staged]

INSERT_UPDATE ContentSlot; uid[unique = true]; name        ; active; originalSlot(uid, $contentCVOnline)[unique = true]; $contentCVCountry[unique = true]
                         ; FooterSlot-EU_it        ; Footer Slot ; true  ; FooterSlot                                        ;

Regards,

Mykhailo Lytvyn

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Stephan, Have you considered adding a custom restriction type that would make your content (banner) site aware. So that for the US site in this case the US banner would be displayed whereas for the rest of the sites the global banner will be used. Also you could consider using Personalization based on SmartEdit to display a relevant content to the user from the US target group. In the future we also planning to add a feature allowing Content manager convert shared slot to non-shared slot on the catalog level, in your example for US site.

Thanks, Olga