Page 1 of 1

append to array

Posted: Fri Oct 16, 2015 8:08 am
by casey palmer

Hello,

I have created model and storage. See screen shots... I am assuming I did this correctly, I was trying to follow the instruction here:

https://devcenter.appery.io/documenta...

the array is supposed to be empty by default and I am looking to enter data into an input field, click a button and the data to the array in a local storage variable. I tried to use the update storage method but I have a good idea I am not coding it right.. Can you give me an example of the code used when trying to add to the array. Once I add the data to the array it should look like below...

I tried to do something like this..

Apperyio.storage.instruments.set("$['serial']", serial);

{
"instruments": [
{
"serial": "2223234"
},
{
"serial": "325124"
}
]
} Image Image


append to array

Posted: Fri Oct 16, 2015 10:45 am
by Serhii Kulibaba

Hello Casey,

Please look at this topic:
https://getsatisfaction.com/apperyio/...