Datagrid2 - JSON config

0
Hello, I'm having issue with Json config of Datagrdi2, when using Import and Export mapping, seems like this part of Json can't be used in both of action (Export always return only number and array is missing). Is anybody figure this out? I already did it in Java action, but I just wanna check if somebody find workaround for this. "columnFilters": [ [ "1", [ "contains", null, null ] ], [ "2", [ "contains", "to search", "" ] ] ]  
asked
1 answers
0

Hello Slavko Skoric ,

 

Export mappings in Mendix cannot handle this kind of nested array, so the columnFilters part gets broken and only the number comes back.

A simple workaround is to keep columnFilters as a plain JSON string instead of using Import/Export mapping for it. This way the full JSON stays safe. If you need to read or change it, you can parse the string in a JavaScript or Java action, and then save it back as JSON.

This avoids the problem because Mendix does not touch the array structure when it is stored as a string.

 

Regards 

Reemali

answered