Expand my Community achievements bar.

Radically easy to access on brand approved content for distribution and omnichannel performant delivery. AEM Assets Content Hub and Dynamic Media with OpenAPI capabilities is now GA.

Button Dilemma

Avatar

Former Community Member

Hey everyone,

I am having some trouble finding an answer to my dilemma. I have a time-sheet form where users are to enter data, either a short line describing simple activities, or a detailed section of information which includes multiple text entry boxes and drop down lists for a more involved activity. I have created fragments for both of these types of activities. My question is whether there is a way to include a button for end users to click to create an instance for the simple or detailed fragment one at a time depending on what they have done throughout the day? Or is there another way to do this? Thanks for your help!

1 Reply

Avatar

Level 7

Yes,

Not sure if I fully understand, however, the answer most probably is yes!

Are you wanting more detail options to present themselves as the situation evolves? Or, more simply, give the user the ability to have more options as the user decides?

Either way, I believe your model is task oriented--that is the timesheet is made up of tasks, and depending upon the task (time involved, nature of task, billing, etc.) the user must provide additional information.

If so, then each task would be an instance of a subform (or "fragment" as you have referred to it) or a table or tablesection and within that subform instance would reside all the parts necessary to gather the addional data as necessary--you would need to reveal or set instances of objects within that task subform instance ("fragment") depending upon the needs--either calculated in response to or dictated by the user's actions.

Hope this helps,

Stephen