How to trigger reload of Touch UI component after modification? | Community
Skip to main content
Level 4
March 3, 2017
Solved

How to trigger reload of Touch UI component after modification?

  • March 3, 2017
  • 4 replies
  • 4788 views

Hello,

I have Touch UI component which on $(document).ready() laod information from some external API.

Parameters for this call are stored in dialog and I want to reload only this component(Refresh self) after dialog edit action performed.

I've tried to configure afteredit listener in _cq_editConfig.xml. But, content of the page is displayed in IFrame.

What is the best way to trigger initialization method?

Thanks

Alex

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 kautuk_sahni

i would recommend you to use "Touch UI validation" [1].

Please have a look at this reference implementation article :-http://www.nateyolles.com/blog/2016/02/aem-touch-ui-custom-validation

// Here from the validate function you can trigger any Ajex call.

I hope this would help you.

[1]https://docs.adobe.com/docs/en/aem/6-2/develop/ref/granite-ui/api/jcr_root/libs/granite/ui/components/foundation/clientlibs/foundation/js/validation/index.html

 

~kautuk

4 replies

smacdonald2008
Level 10
March 3, 2017

When the values in the dialog are changes - are they not reflected in the component? 

Level 4
March 3, 2017

Dialog changes are reflected in the html.

But, I have some js code, which take data attributes  and perform Ajax request

On initial load it performed on document ready.

kautuk_sahni
Community Manager
kautuk_sahniCommunity ManagerAccepted solution
Community Manager
March 6, 2017

i would recommend you to use "Touch UI validation" [1].

Please have a look at this reference implementation article :-http://www.nateyolles.com/blog/2016/02/aem-touch-ui-custom-validation

// Here from the validate function you can trigger any Ajex call.

I hope this would help you.

[1]https://docs.adobe.com/docs/en/aem/6-2/develop/ref/granite-ui/api/jcr_root/libs/granite/ui/components/foundation/clientlibs/foundation/js/validation/index.html

 

~kautuk

Kautuk Sahni
kautuk_sahni
Community Manager
Community Manager
March 7, 2017

Also please have a look at all the comments shared in this old forum post:

Link:- http://help-forums.adobe.com/content/adobeforums/en/experience-manager-forum/adobe-experience-manager.topic.html/forum__gzm2-hello_team_ihav.html

// 1.  Trigger event with touch UI events...

   2. Overlay 

~kautuk

Kautuk Sahni