Ionic toggle to store in native

can you display the data when you call getDataFromStorage

not in ionviewdid, in showmore()

that’s shown in the picture

not that data!!
i mean json data

and when you change toggle where you save the data in localstorage or databse ?

that’s stored at local storage

ok here when you change the toggle it will not stord in localstorage
can you print the data into console so we can get the isuue ?

i cant print the data from local storage in console (cordova not available in browser).
but the data is correctly stored ,and the data displayed correctly in my flight page.

are you use chrome ?

1 Like

yes, i used the chrome

then you can see your localstorage data

how i can see the data?

ok
run your application Press F12
in Application tab select LocalStorage

there is data available if your localstorage is set !!!

Actually istored data in Native storage not in local storage(sqlite)

ok then how can you caheck your

“idcheckarvl”

variable is set or not ?
is there any way to get the data from idcheckarvl variable from native storage?

i set “idcheckarvl” varialble
idcheckarvl:any=[];

have you set this varible in updateItemarrivals() function ?

nop, i not set in that funtion.

you change the toggle but you not save the value of it then how can you get it is selected or not :sweat_smile::sweat_smile: