We use both classic UI and touch ui. In the classic UI we have multifiled which has data stored as string with values as contentpath^textvalue where ^ is delimiter.
Please let me know how could i achieve the same in touch ui using multifield.
Below is the snapshot for the field stored as string in crxde for classic UI .
The multifield i am trying is below which is not working
fieldDescription="Configure Links Manually"
fieldDescription="Label of Link"
As the property is getting stored as string by classic ui with delimiter ^ ,due to this the code above i mentioned is not populating up the mutifield value in touch ui.
Any inputs as how i could solve.
It is not stored as node is stored as property navItems of String .But would want to show it up in multi-field in touch ui .hence all this issue.
Did you mean that still we can make it work using sling model. Any samples will help.
I got it now, you are trying to poluate touch UI dialog from classic UI authored value.
This would be tricky, you have two options
1. Create a utility which would read the String property and create the nodes for touch ui multifield
2. When you open the touch ui dialog, get the value via ajax call and populate the multifield values in dailog.
I don't have any sample code though but 1st but would be easy, just authored one multifield again in touch UI and see how touch UI stores the value and converted same using utility
Thanks for the inputs .Any reference will help as currently i don't have much idea on Point1.
Point2 also using ajax we will have many multifields values in one dialog so cannot use id for populating it and looks to me like an issue.
The first approach is very straight forward.
1. Create a servlet which run SQL2 query to look for the multifield resource node where data is stored in String type property.
2. If found, read the value of String type and convert into nodes and add node to above multifield resource node .
I don't know the dialog structure so couldn't exact point the steps but above is generic solution