Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

CQ5 - Cancel individual property inheritance of a Live Copy component

Tags:

aem

Does anyone know how to configure a CQ component so that each property can be cancelled individually inside of a Live Copy? I am trying to have it set up the same way as the Page Properties, so that canceling one property does not break inheritance for all of them.

Page Properties:

Page Property

Component Properties:

Page Property

The only difference that I'm noticing is the mixin types on the respective jcr:content nodes.

Page Mixins:

cq:PropertyLiveSyncCancelled cq:LiveRelationship

Component Mixins:

cq:LiveSyncCancelled cq:LiveRelationship

I've even tried manually setting the cq:PropertyLiveSyncCancelled Mixin for the component in the content along with ["jcr:description"], but CQ is ignoring this directive entirely.

Does anyone know how this could be done? Thanks!

like image 800
lyma Avatar asked Feb 15 '23 23:02

lyma


2 Answers

Add "fieldEditLockMode" property with value "true" to your component dialog to enable cancelling of individual properties inheritance:

set fieldEditLockMode to true

enter image description here

It works for AEM 6.0.

like image 76
Evgeny Konstantinov Avatar answered Feb 23 '23 01:02

Evgeny Konstantinov


On the livecopy you can cancel property inheritance with the following:

<jcr:content
    jcr:mixinTypes="[cq:LiveSync]"
    jcr:primaryType="cq:PageContent"
    sling:resourceType="project/pages/homepage"
    insertCode="FG"
    cq:propertyInheritanceCancelled="[insertCode]" />

If the insertCode property is present in the blueprint it wont be copied over to the livecopy nor created if not present on the livecopy - entirely ignored.

like image 21
Sören Geier Avatar answered Feb 22 '23 23:02

Sören Geier