IgniteEngine-iOS icon indicating copy to clipboard operation
IgniteEngine-iOS copied to clipboard

Ability to store array and dictionary objects in session, append arrays

Open brandonscript opened this issue 10 years ago • 2 comments

Should be able to store arrays and dictionary objects in $session, and should be able to append objects to Array.

brandonscript avatar Mar 20 '15 23:03 brandonscript

Related: https://github.com/ApigeeDelta/ignite-iOS-engine/commit/d3e669b6faed11681224cbca0726bf97d5fcef70

Pull this from the data provider, add these to JSONUtils, and use them to be able to modify both response object and $session.

brandonscript avatar Apr 30 '15 23:04 brandonscript

Should also be able to build a session array from a javascript eval? Thinking out loud, any or all of these would be awesome:

{
    "_type": "Modify",
    "set": {
        "$session.something#array": "apples,oranges,bananas"
    }
}

{
    "_type": "Modify",
    "set": {
        "$session.something#array": "{{ ['apples', 'oranges', 'bananas'] }}"
    }
}

{
    "_type": "Modify",
    "set": {
        "$session.something#array": "{{ [[session.something]].push('peaches') }}"
    }
}

@jeremyanticouni would appreciate your comments

brandonscript avatar May 06 '15 20:05 brandonscript