Multifield in Coral UI 3

Avatar

Avatar
Ignite 1
Level 2
ks_hitijingole
Level 2

Likes

3 likes

Total Posts

21 posts

Correct reply

0 solutions
Top badges earned
Ignite 1
Give Back 3
Give Back
Boost 3
Boost 1
View profile

Avatar
Ignite 1
Level 2
ks_hitijingole
Level 2

Likes

3 likes

Total Posts

21 posts

Correct reply

0 solutions
Top badges earned
Ignite 1
Give Back 3
Give Back
Boost 3
Boost 1
View profile
ks_hitijingole
Level 2

25-05-2021

Hi,

 

We are migrating components from Coral 2 to Coral 3. In components having multifield the data is currently being stored in JSON format.  After coral 3 migration for multifield, we have added a composite={Boolean}true. After migration multifield is storing data in node structure. (e.g item0, item1). We have done changes in Model class to adapt it.

 

Question : Is there any way we can migrate the multifield and even after migration the data can be stored in JSON format. We have 30 odd components having Multifiled which will require changes in Model and Test classes. Just want to see if there is any other alternative.

View Entire Topic

Avatar

Avatar
Coach
MVP
Arun_Patidar
MVP

Likes

1,462 likes

Total Posts

3,328 posts

Correct reply

949 solutions
Top badges earned
Coach
Contributor 2
Ignite 10
Give Back 700
Boost 1000
View profile

Avatar
Coach
MVP
Arun_Patidar
MVP

Likes

1,462 likes

Total Posts

3,328 posts

Correct reply

949 solutions
Top badges earned
Coach
Contributor 2
Ignite 10
Give Back 700
Boost 1000
View profile
Arun_Patidar
MVP

25-05-2021

ACS Common to store multifield as json has been already deprectaed.

1. I would suggest writing a utility that read the JSON and convert into nodes for all the existing pages e.g. https://github.com/arunpatidar02/aem63app-repo/blob/master/java/MultifieldConvertCoral2to3Servlet.ja...

2. Update the Model with a common util class that converts multifield node to JSON so that the existing JSON logic can be reused.

 

Another approach would be writing dialog listeners to create JSON from multifield nodes and store them in hidden field on dialog submit and multi-field would be saved as JSON.