Expand my Community achievements bar.

Dive into Adobe Summit 2024! Explore curated list of AEM sessions & labs, register, connect with experts, ask questions, engage, and share insights. Don't miss the excitement.
SOLVED

How to bind a different form model for the Adaptive fragment?

Avatar

Level 2

We are building Adaptive form with schema model as form data model. From adaptive form we are trying to break in to fragments, so it can reused by other applications. Adaptive fragments created from adaptive form is taking schema model as form data model by default. I didn't see any provision to change the form schema model like from form data model to json schema model. Only way I can see is changing from crxde.

These fragments might be reused by other apps, and they don't need the whole form data model. So we are looking create as small JSON schemas (Subset of formdatamodel) and looking to add it as form model as schema to the fragment.

Any advice will help us.

Thanks in advance.

Regards,

Chandra

1 Accepted Solution

Avatar

Correct answer by
Level 7

Theres a couple of ways to do this. Have a look at the section "Reusable schema definitions" (JSON) [1]

With XML Schemas you can create ComplexType libraries that are linked into your main form schema [2]

Once you create the separate abstracted schema definition or ComplexType, you can associate the reusable schema into your fragment which will still be valid when you link the fragment into your main form as the schema is essentially the same.

[1] Adobe Experience Manager Help | Creating adaptive forms using JSON Schema

[2] Design and Build Reusable XML Schemas: 10 Tips

View solution in original post

1 Reply

Avatar

Correct answer by
Level 7

Theres a couple of ways to do this. Have a look at the section "Reusable schema definitions" (JSON) [1]

With XML Schemas you can create ComplexType libraries that are linked into your main form schema [2]

Once you create the separate abstracted schema definition or ComplexType, you can associate the reusable schema into your fragment which will still be valid when you link the fragment into your main form as the schema is essentially the same.

[1] Adobe Experience Manager Help | Creating adaptive forms using JSON Schema

[2] Design and Build Reusable XML Schemas: 10 Tips