JSON serializer sorting

Hi all, I'm looking for a fix for the following problem: I am creating a widget that needs a JSON string to fill it with data. This data consists of 7 predefined columns, and rows with cells to fill them. The order in which these cells need to be mapped in JSON is very important, since all values are called 'v'. Because the attribute 'v' can be anything (String, Integer, DateTime, etc), the following domain model is the only possible way I can see this working. The biggest problem is that when the data gets serialized by the SerializeObjectToJSON action, it's automatically sorted by id. Since the list with cells are all specializations, the id's are completely different and the order gets scrambled and therefore the widget won't work properly. Does anyone have an idea on how to make the sorting work properly?
0 answers