Adding policies to the component in the Header.html in Page Component | Community
Skip to main content
Level 3
October 10, 2024
Solved

Adding policies to the component in the Header.html in Page Component

  • October 10, 2024
  • 2 replies
  • 476 views

We have a requirement to create header using tabs component.

 

We have added this tab component in Header.html file using below code:

 

<header>

    <sly data-sly-resource="${ @9556322 = header, resourceType = '/apps/abc/components/content/tabs', wcmmode=mode}"></sly>

</header>

 

In the pages, we are not able to add any tab item.

We need to allow only one specific component to be added to the tabs in this scenario.

 

We tried to add policies but its giving PersistenceEsxception: unable to create node at /conf/abc/settings/wcm/policies.

 

Any suggestions on this issue how to fix it?

 

@kautuk_sahni @arunpatidar @aanchal-sikka @EstebanBustamante 

@Raja_Reddy @TarunKumar @Saravanan_Dharmaraj @Jörg_Hoh 

@lukasz-m 

 
This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by arunpatidar

Hi @s__k__agarwal 
Yes, you can add policies to the include component,

Please check snippet here, where tabs component have different policy for parsys, you need to do similar but for header component : https://experienceleaguecommunities.adobe.com/t5/adobe-experience-manager/aem-how-to-restrict-components-on-responsive-grid-added-inside/m-p/701243

 

2 replies

arunpatidar
Community Advisor
arunpatidarCommunity AdvisorAccepted solution
Community Advisor
October 15, 2024

Hi @s__k__agarwal 
Yes, you can add policies to the include component,

Please check snippet here, where tabs component have different policy for parsys, you need to do similar but for header component : https://experienceleaguecommunities.adobe.com/t5/adobe-experience-manager/aem-how-to-restrict-components-on-responsive-grid-added-inside/m-p/701243

 

Arun Patidar