Expand my Community achievements bar.

Don’t miss the AEM Skill Exchange in SF on Nov 14—hear from industry leaders, learn best practices, and enhance your AEM strategy with practical tips.
SOLVED

2 Part Form on One Page

Avatar

Level 2

Is it possible to create a 20 field form on one page with the following requirements:

1.  The first 5 fields will be filled-in by the first user, saved, and forwarded to the second user.

2.  The second user will then fill-out the remaining 15 fields however, I do not want to give the second user the ability to edit the first 5 fields filled-out by the first user.  Ideally, the landing field on opening the form by the second user would be the 6th field.

Thanks!

1 Accepted Solution

Avatar

Correct answer by
Former Community Member

Sure ...its just a button click that kicks off the logic. Note that you cannot do an unattended save, the user will have to ackowledge the save.

Paul

View solution in original post

6 Replies

Avatar

Former Community Member

Does the 2nd user need to see what is typed into the first 5 fields (even though he cannot change it) or woudl you rather have them look like they were not even on his form?

Paul

Avatar

Level 2

Yes, the second user needs to see what the first user entered and saved.  The second user should not be able to edit what the first user entered.

Thanks!

Avatar

Former Community Member

Then you will need to set up a flag (hidden fields work best) that tells you which user is filing the form. When the first user clicks the button to send,check the flag to see which user it is then make those fields readonly by using Fieldname.access = "readOnly"then update the flag to indicate user2

Paul

Avatar

Level 2

The form will not be submitted via a button; the form is saved on the server and is accessible through the network.  Instead of "send" is there a "save" solution?

Avatar

Correct answer by
Former Community Member

Sure ...its just a button click that kicks off the logic. Note that you cannot do an unattended save, the user will have to ackowledge the save.

Paul

Avatar

Level 2

Thanks for all your help Paul!

The following has evaluated to null or missing: ==> liqladmin("SELECT id, value FROM metrics WHERE id = 'net_accepted_solutions' and user.id = '${acceptedAnswer.author.id}'").data.items [in template "analytics-container" at line 83, column 41] ---- Tip: It's the step after the last dot that caused this error, not those before it. ---- Tip: If the failing expression is known to be legally refer to something that's sometimes null or missing, either specify a default value like myOptionalVar!myDefault, or use <#if myOptionalVar??>when-present<#else>when-missing. (These only cover the last step of the expression; to cover the whole expression, use parenthesis: (myOptionalVar.foo)!myDefault, (myOptionalVar.foo)?? ---- ---- FTL stack trace ("~" means nesting-related): - Failed at: #assign answerAuthorNetSolutions = li... [in template "analytics-container" at line 83, column 5] ----