AEM · AEM 6

AEM | ACS – Generic List | Extend Template for your site


ACS List template is visible to “/etc/acs-commons/lists” path only. As we will be creating Site specific lists, We need to override Generic List template.

Note: Please see Generic List – Support Site Inheritance for better understanding of Generic List requirement and complete solution.

We will support the following  list hierarchy

    |
    |-- etc
    |-------lists
    |------------ <site A>
    |--------------------- <List 1>
    |--------------------- <List 2>
    |--------------------- <List 3>
    |------------ <site B>
    |--------------------- <List 1>
    |--------------------- <List 2>

Steps to create a new Generic List Template:

  1. Create a node named “genericlist” of node type “cq:Template” under your template folder (eg. /apps/<siteName>/templates/genericlist), add following properties in this node
    Name Type Value
    allowedPaths String[] /etc/lists(/.*)?
    jcr:title String <Your Site name> Generic List
    jcr:description String A generic list of name/value pairs.
    jcr:primaryType Name cq:Template
    ranking Long 100
  2. Create “jcr:content” node of node type “cq:PageContent” below “genericlist” node (we created in step 1). Add following properties in this node
    Name Type Value
    cq:designPath String /etc/designs/acs-commons *
    sling:resourceType String acs-commons/components/utilities/genericlist *
    jcr:primaryType Name cq:PageContent

    * ACS Commons implementation for Generic list.

Advertisements

One thought on “AEM | ACS – Generic List | Extend Template for your site

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s