I have a list view and want to pass only selected records from this list to a REST endpoint which accepts them as a JSON array.
Therefore, I am exploring Serialize List to Array methods. Is my case a fit for using this method? Can some please share an example using this method? I am not clear how to prepare Serialized List as input from the List View?
I have recently done this in K2 Five.
I loop through rows on the List View and use the Serialize Add Item To Array method:
I guess in your scenario you only want selected rows so you would need to do something like this:
Important: You will need to have a Data Label to store the Serialized Array.
Of course in order to do this, your Advanced SmartObject needs to expose the method:
You will see the property that we referenced earlier below:
If you need assistance setting up the SmartObject, I would suggest watching the K2 tutorial as it covers aspects of serialization (link at bottom of page).
I am at the point where I am now trying to do the opposite, rather than submitting to a POST endpoint, I am trying to display complex data from a GET endpoint. My challenge is that I have lists within lists, and I want to display the data using List Views but I do not want to store it first (unless I have to).
If you are interested, my post is here: https://community.nintex.com/t5/K2-Five-Forum/Displaying-Deserialised-Typed-Array-on-a-List-View-or-...
Hope this helps, if you have managed to display List Data from a REST call on a List View, without storing any data, please let me know!