AEM communities: Link in email notification on moderation approval | Community
Skip to main content
Level 3
October 24, 2017
Solved

AEM communities: Link in email notification on moderation approval

  • October 24, 2017
  • 5 replies
  • 4423 views

Hi All,

I am facing an issue in email subscription feature of AEM communities.

The domain in the blog/Qna link in the email that is generated on blog approval by the moderator, is getting picked from externalizer which takes runmode value by default to pick the domain.

But when we are to use the communities blog in more than one application having more than one domain, looks like community email subscription feature needs major customization to have domain picked from the respective site.

Please let me know if I missing anything here. Any solution to handle this scenario would be very helpful.

Thanks,

Sagar

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 Rahul_Bhardwaj

Hi Sagar,

This will need you to write a service implementing interface - CommentEmailBuilder from com.adobe.cq.social.commons.emailreply because you will have to override the internal implementation which uses Externalizer. After that, you can pass custom property, as described in [0] and get that custom property from ugc node to utilize the domain, you provided.

Please note that the inputs I provided are theoretical only and not already tried.

Let me know, if you face any problems.

Best of luck,

Rahul

[0] - AEM communities: Pass a custom property from the community components.

5 replies

Rahul_Bhardwaj
Adobe Employee
Adobe Employee
October 26, 2017

Hi Sagar,

This is a known limitation with the AEM platform and not just communities but you can try community component extension as a workaround and see if that helps.

You can refer following link, for a public discussion on this issue from platform point of view:

[0] - MultiSite Externalizer · Issue #229 · Adobe-Consulting-Services/acs-aem-commons · GitHub

I think, there are certain workarounds shared there too from platform perspective instead of communities perspective.

Best of luck,

Rahul

Level 3
November 2, 2017

Is it possible to pass domain as a custom property from the community components and receive the same in email templates?

Rahul_Bhardwaj
Adobe Employee
Rahul_BhardwajAdobe EmployeeAccepted solution
Adobe Employee
November 6, 2017

Hi Sagar,

This will need you to write a service implementing interface - CommentEmailBuilder from com.adobe.cq.social.commons.emailreply because you will have to override the internal implementation which uses Externalizer. After that, you can pass custom property, as described in [0] and get that custom property from ugc node to utilize the domain, you provided.

Please note that the inputs I provided are theoretical only and not already tried.

Let me know, if you face any problems.

Best of luck,

Rahul

[0] - AEM communities: Pass a custom property from the community components.

Level 3
November 20, 2017

Hi Rahul,

I was able to override the CommentEmailBuilder method but its always picking the default OOTB CommentEmailBuilder implementation and my service will be used if I stop the OOTB CommentEmailBuilder implementation from system/console/components which I dont think is a right approach. Also tried by giving ranking in properties but it didnt help.

Is there a way that communities component use the custom CommentEmailBuilder implementation without having to stop the OOTB implementation or have the custom implementation run for my application alone.

Thanks,

Sagar

Rahul_Bhardwaj
Adobe Employee
Adobe Employee
November 21, 2017

Hi Sagar,

Normally, service rankings serve that purpose of prioritizing implementations. But if it's not working for you, I will need to take a look at it before commenting on why it's not working the way, its supposed to work.
Since, its your code, I won't recommend to paste it here. Can you please open a daycare ticket soliciting these inputs? Please, make sure that you share your code(or atleast a stripped version, which should take care of bare minimum functionality without any sensitive information, if any) with daycare ticket.

-Rahul