15 Replies Latest reply on Nov 6, 2017 1:28 AM by Rahul_Bhardwaj

    Extended Journal Component not Working

    titli Level 1

      Hi

      Im using GitHub - Adobe-Marketing-Cloud/aem-scf-sample-components-extension: Sample package for AEM Social Communities - Social C… to Extend a journal Component and customise it. However it is not working. These are the steps I have done

      1. Installed the package after building

      2. Added Subtitle field to the below as recommended (

      1. Add a property "subtitle" in your author and publish instance's /system/console/configMgr/com.adobe.cq.social.journal.client.endpoints.impl.JournalOperat ionsService

      3. Added the 3 Clientlibs to the page

      1. cq.ckeditor

      2. cq.social.hbs.voting

      3. cq.social.hbs.journal

       

      Issue: When I write in the blog it doesnt save anything when i click on publish.

       

      After refresh the page shows blank as before.

       

      Can someone please help me in resolving the issue? One More thing when I put my code on debug the CustomJournalEntryComponent code does NOT get called at all.

        • 1. Re: Extended Journal Component not Working
          smacdonald2008 Adobe Employee

          Does it work when you do not extend it?

          • 2. Re: Extended Journal Component not Working
            Rahul_Bhardwaj Adobe Employee

            Hi Titli,

            1. What's the AEM version, you are on?

            2. Did you get any client side errors?

            3. Anything in server logs?

            4. To which page, you added clientlibs? Can you point me to the documentation, which you followed to add these?

            5. Can you see the bundle to be resolved in your /system/console/bundles?

            6. You seem to have your classic authoring on, have you tried it on publish instance?

             

            -Rahul

            • 3. Re: Extended Journal Component not Working
              titli Level 1

              Im using the sample component. GitHub - Adobe-Marketing-Cloud/aem-scf-sample-components-extension: Sample package for AEM Social Communities - Social C…

               

              This sample is provided as a example to extend and implement the Journal component. Thats what Im trying to do. The normal journal component works fine otherwise. Im extending the journal component thats inside libs/social as is given. Infact the sample project contains pages and an instruction which Im following.

              • 4. Re: Extended Journal Component not Working
                titli Level 1

                1. AEM 6.1 with SP1 and communities latest feature pack

                2. No client side error

                3. I do see some errors on the log but thats related to the replication agent not being able to replicate. Thats coz my publish was down at that time.

                4. I added the clientlibs to a page i made inside acme/en via the clientliblist component. (content/acme was already there as part of the project, i just made one more page with the same template)

                5 Yes, bundle are all up and active

                6. No i havent published it. But I dont see the point of it not working in the author environment, as all other components in the sample project work absolutely fine for me. (Ideas page)

                • 5. Re: Extended Journal Component not Working
                  titli Level 1

                  Just to clarify the sample itself is not working for me and Im wondering why.

                  • 6. Re: Extended Journal Component not Working
                    Rahul_Bhardwaj Adobe Employee

                    The samples are verified to have worked with AEM >= 6.2. Let me try to reproduce issue inhouse and get back to you. It might take a few days.

                    • 7. Re: Extended Journal Component not Working
                      titli Level 1

                      okay... But in the meanwhile can you tell me how the java classes CustomJournalEntryComponent and the corresponding factory is connected to the component. For me in debug mode those classes arent getting called at all. I am getting the feeling that I must be missing some sort of configuration.

                      • 8. Re: Extended Journal Component not Working
                        titli Level 1

                        When I try in AEM 6.2  and on a fresh instance I get the following errors on the console

                         

                        Uncaught ReferenceError: SCFValidator is not defined

                        site.js:2144 Uncaught ReferenceError: SCFValidator is not defined

                        journal.js:4261 Uncaught TypeError: Cannot read property 'validate' of undefined

                        site.js:2144 Uncaught ReferenceError: SCFValidator is not defined

                            at Function.SCF.View.bindDataForms (site.js:2144)

                            at HTMLFormElement.<anonymous> (site.js:1762)

                            at Function.each (jquery.js:384)

                            at jQuery.fn.init.each (jquery.js:136)

                            at child.bindView (site.js:1761)

                            at child.initialize (site.js:1602)

                            at child.Backbone.View (backbone.js:987)

                            at child [as constructor] (backbone.js:1531)

                            at child [as constructor] (backbone.js:1531)

                            at child [as constructor] (backbone.js:1531)

                         

                        This page has the following libraries added cq.ckeditor, cq.social.hbs.voting, cq.social.hbs.journal

                         

                        • 9. Re: Extended Journal Component not Working
                          Rahul_Bhardwaj Adobe Employee

                          To understand "how the java classes CustomJournalEntryComponent and the corresponding factory is connected to the component", I would encourage you to read documentation for server side customization[0].

                          If you are facing trouble with 6.2 too, I would suggest you to try a restart of your instance, if possible. Else, it's difficult to debug the issue without taking a look at your environment. I would suggest you to log a support ticket so that your environment can be analyzed and a it can solved for you.

                           

                           

                          [0] - Server-side Customization

                          • 10. Re: Extended Journal Component not Working
                            titli Level 1

                            I will surely go through it again. But what I essentially wanted to know was if there was any configuration required which is not mentioned in here. And I had tried the sample on a fresh instance just for test purposes. I actually need it for AEM 6.1. The sample just does not work for me. The backend classes are simply not getting called. They get called only for the ideation component and not for the custom blog component.

                            I'm stuck! Can you try it on 6.1 with sp1 and community feature pack installed?

                            • 11. Re: Extended Journal Component not Working
                              Rahul_Bhardwaj Adobe Employee

                              Just checked - It's working for me on 6.1 too. I had to take just three steps :

                              1. Add "subtitle" to whitelist in configMgr

                              2. Build and install content package from the repo.

                              3. Add Extended journal to the site and created ugc.

                              Can you check without adding any clientlibs?

                              • 12. Re: Extended Journal Component not Working
                                titli Level 1

                                Did you create any new page? Can you share the package with the component added?

                                Step 1 : I did it

                                Step 2: did it

                                Step 3:. Might differ from yours. I checked in the acme/en/newsblog  please share your package from 6.1 with the working component.

                                 

                                I will install it 

                                • 13. Re: Extended Journal Component not Working
                                  titli Level 1

                                  HI,

                                   

                                  I tried out this component. there might have been some problem with the clientlibs. Now the data is getting save but when I open the entry the extended component does not get called. The default component entry_topic gets displayed.

                                   

                                  For example if in

                                  /apps/custom-blog/components/hbs/entry_topic/entry_topic.hbs

                                  I change the following line

                                          <p class="scf-breadcrumb scf-quiet">{{i18n "Entries!!"}} &#187; <a href="{{pageInfo.basePageURL}}.html">{{i18n "Blog!!"}}</a> &#187; {{subject}}</p>

                                  It does not get reflected in the page.

                                   

                                  Can you check if thats happening for you too?

                                  • 14. Re: Extended Journal Component not Working
                                    titli Level 1

                                    Just to keep the post updated I finally managed to find out a solution.

                                    The etc/design must have the resourceType properly set in the correct path. My project structure was such that setting the paths via the design dialog was not sufficient. I have to find the path where this value was required to be set

                                    1 person found this helpful
                                    • 15. Re: Extended Journal Component not Working
                                      Rahul_Bhardwaj Adobe Employee

                                      Great job Titli. Unfortunately, I lost track of our discussion and this discussion went down in my stack. Sorry for the inconvenience that you might have faced, when I failed to respond to your earlier query.

                                      -Rahul