5 Replies Latest reply on Jun 20, 2013 2:51 AM by Yao Xing Chua

    Setting default parsys component and packaging them

    Yao Xing Chua Level 1

      Hi,

       

      Is anyone familiar with how to enable default components to appear in a certain parsys?

       

      Usually what I would do is manually go into Design Mode, find that certain parsys that I want to edit, click on the Edit, and locate the component under the "Allowed Components" list and check the box corresponding to enabling that component. I found out that when a component is checked to appear in that certain parsys, it will also automatically create a node (eg. mynode) at "/etc/design/default/jcr:content/mynode". And within this node, there will be a property called "components" that will determine what component will appear in this parsys. So I am assuming that this is the way to enable components in the parsys through the codes (without having to manually enable them at that webpage).

       

      After which, I will package all the contents of "/etc/design/default/jcr:content/mynode" and proceed to deploy it in my client's server. The problem now is, the contents once installed (in client's server), is deleted once again. I suspect it has something to do with it being under jcr:content. Is my assumption right? And how do I solve this? And if I package "/etc/design/default" and deploy it, it seems to work fine. I cannot deploy the whole default folder though. This is because, I cannot confirm if there are other projects that adds their "default components" under that folder. By putting only my "/etc/design/default", there might be a possibility of removing my client's other project's default components.

       

      To summarise, what I want is to package the contents of "/etc/design/default/jcr:content/mynode" and place it in my client's server, and make sure that it is not deleted (Assuming editing the contents of "/etc/design/default/jcr:content/mynode" is the way to create default parsys components).

       

      Any detailed help will be appreciated! Thanks!

        • 1. Re: Setting default parsys component and packaging them
          rush_pawan Level 4

          Hi,

           

          Please refer our earlier discussion i hope it helps you. http://forums.adobe.com/message/5402838#5402838

           

          Also if you configure a node inside /etc/design/<sitename> then your template configuration settings will persist there only and you will not have any issues during export/import.

           

          Thanks,

          Pawan

          • 2. Re: Setting default parsys component and packaging them
            Yao Xing Chua Level 1

            Hi Pawan,

             

            You mentioned on the earlier discussion that from /etc/designs/yoursitename under the jcr:content, I should be able to see the templates of my site. I can see it for the geometrixx example, but for my project, the /etc/designs/yoursitename/jcr:content appears to be empty. Will it be automatically generated when I enabled it from the Design Mode? Or do I have to add nodes by myself?

             

            On top of that, what structure does it follow for the nodes under /etc/designs/yoursitename/jcr:content? Is it /etc/designs/yoursitename/jcr:content/pagename/parsysname/(followed by the rest of the contents)?

             

            Thanks.

            Yao

            • 3. Re: Setting default parsys component and packaging them
              rush_pawan Level 4

              Hi,

               

              Yes, it will automatically create the template configuration inside jcr:content if you have created the site page using same "sitename" from "http://localhost:4502/miscadmin#/etc/designs" not from crxde or crx/explorer.

               

              to see the example you can refer default geometrixx site /etc/designs/geometrixx/jcr:content

               

              I hope above helps you to proceed.

               

              Thanks,

              Pawan

              • 4. Re: Setting default parsys component and packaging them
                Yao Xing Chua Level 1

                How do I create a site page from "http://localhost:4502/miscadmin#/etc/designs"? I am a little confused over here.

                 

                When I refer to the geometrixx site example, I can see that the "components" property inside "/etc/designs/geometrixx/jcr:content/examplepage/parsys" has my enabled component's path in it. But when I duplicate the exact same structure into "/etc/designs/myproject/jcr:content/myprojectpage/myparsys" in its components property, the component that I want to enable doesn't show up. Even when I created a new page, it doesn't show up. But when it is created in "/etc/designs/default/jcr:content/myprojectpage/myparsys", it works.

                 

                So as you can see, somehow my projects are directing the path to "/etc/designs/default", instead of "/etc/designs/myproject". How do I change the direction path? There seems to be no place to configure this.

                • 5. Re: Setting default parsys component and packaging them
                  Yao Xing Chua Level 1

                  Ok solved the problem.

                   

                  In CRXDE, I didn't specify the "cq:designPath" property under "/apps/myproject/templates/mycomponent" initially. So I added that property and under that property's value, I added the path /etc/designs/myproject.

                   

                  Following that, I added a component structure (/myprojectname/myparsysname/section) that was automatically generated earlier on (when I enabled a component in Design Mode in my webpage by checking the box under "Allowed Components. And the structure will appear in CRXDE under /etc/designs/default, since I didn't specify my design path earlier on), into "/etc/designs/myproject/jcr:content".

                   

                  Hope this could be of use to anyone who is trying to add default components to a template/webpage.

                   

                  Cheers.