Skip to main content
hitesh_m
Level 3
Feb 24, 2016 3:58 PM UTC
Solved

Panel Validation with Rule Editor

Hi I am working on a wizard based form in AEM. 

As per the requirement I have to validate fields in panel before moving to the next panel. 

I am using Rule Editor for JS validations. I am not sure how to validate the panel with rule editor. As per adobe it should be called for "Step Completion Expression". I am not able to find this expression with Rule Editor. I tried following on click of a button 

if(window.guideBridge.validate([],this.panel.navigationContext.currentItem.somExpression))

{

//Move to next panel

}

But this is returning true always and my panel is not validating, 

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
smacdonald2008
smacdonald2008Accepted solution
Level 10
Feb 24, 2016 5:11 PM UTC

You can use Adative forms to create repeating sections (I was thinking form components on my 1st answer here)

See this topic: https://helpx.adobe.com/aem-forms/6/creating-forms-repeatable-sections.html

Here is a sample for this functionality:

http://localhost:4502/aem/formdetails.html/content/dam/formsanddocuments/geometrixx-gov/hardship-determination

As an alternative - you can create a custom component that would function as: 

http://www.jquery-steps.com/Examples#advanced-form

3 replies

smacdonald2008
Level 10
Feb 24, 2016 4:28 PM UTC

"I have to validate fields in panel before moving to the next panel"

Are you using a JQeury plug-in to perform this use case.  I would look for a JQuery plugin and then use a client lib to write script to perform your validation requirements.

We had a similair use case when user wanted to write a QUIZ component. That is- they answered a set of questions and then it moved to next screen. The solution was to write a custom QUIZ component using JQuery plugin. 

Developing a custom Adobe Experience Manager Quiz Component

In your use case - i would look at something like this: 

http://www.jquery-steps.com/

We can add this to the communtiy list of articles if you want. 

Translate
hitesh_m
hitesh_mAuthor
Level 3
Feb 24, 2016 5:07 PM UTC

Thanks for your reply. 

I am not using JQuery plugin. Is there any way from AEM out of the box ?

Translate
smacdonald2008
smacdonald2008Accepted solution
Level 10
Feb 24, 2016 5:11 PM UTC

You can use Adative forms to create repeating sections (I was thinking form components on my 1st answer here)

See this topic: https://helpx.adobe.com/aem-forms/6/creating-forms-repeatable-sections.html

Here is a sample for this functionality:

http://localhost:4502/aem/formdetails.html/content/dam/formsanddocuments/geometrixx-gov/hardship-determination

As an alternative - you can create a custom component that would function as: 

http://www.jquery-steps.com/Examples#advanced-form

Translate