Girish Chhugani
Posts: 0
Joined: Thu Apr 17, 2014 10:18 pm

Login.execute gives error this morning

FYI. U guys updated something. I can login but now quotes showing up around all local storage variables and nothing really working. Some problem with local storage it seems like....

Maryna Brodina
Posts: 0
Joined: Thu Apr 05, 2012 7:27 am

Login.execute gives error this morning

Yes, another problem we are working on...

Maryna Brodina
Posts: 0
Joined: Thu Apr 05, 2012 7:27 am

Login.execute gives error this morning

Now, you would need to use:
pre$a.storage.myLocalVar.get()/pre
Instead of:
prelocalStorage.getItem("myLocalVar");/preHere is new doc
http://devcenter.appery.io/documentat...

Please let us know result.

Girish Chhugani
Posts: 0
Joined: Thu Apr 17, 2014 10:18 pm

Login.execute gives error this morning

Seriously have to change entire app ? Did you give everyone warning about this. ? This is crazy. What else has changed??

Girish Chhugani
Posts: 0
Joined: Thu Apr 17, 2014 10:18 pm

Login.execute gives error this morning

What else do we need to change in our apps ?

Maryna Brodina
Posts: 0
Joined: Thu Apr 05, 2012 7:27 am

Login.execute gives error this morning

We are sorry for inconvenience. New mapping and Model and Storage were announsed in our blog http://blog.appery.io/2014/05/new-map.... You don't need to change anything else in app.

To support type of data being saved to/loaded from storage variable we've implemented background serialization/deserialization (using JSON.stringify()/JSON.parse()). So, if to read data from storage using HTML5 Web Storage API, "raw" data will be returned.

Old way of using storage variables:pre// Local Storage
localStorage.setItem("localVar", "Hello Local");
undefined
localStorage.getItem("localVar");
"Hello Local"

// Session Storage
sessionStorage.setItem("sessionVar", "Hello session");
undefined
sessionStorage.getItem("sessionVar");
"Hello session"

// Global Variable
window.globalWindowVar = "Hello window";
"Hello window"
window.globalWindowVar
"Hello window"/pre

New way of using storage variables (note: before trying a new way of using storage variables (with Storage API) all the variables must be registered in editor):
pre// Local Storage
$a.storage.localVar.set("Hello local")
undefined
$a.storage.localVar.get()
"Hello local"

// Session Storage
$a.storage.sessionVar.set("Hello session")
undefined
$a.storage.sessionVar.get()
"Hello session"

// Global Variable
$a.storage.globalWindowVar.set("Hello window")
undefined
$a.storage.globalWindowVar.get()
"Hello window"
localStorage.getItem("localVar")
""Hello local""
JSON.parse(localStorage.getItem("localVar"))
"Hello local"

// Getting "raw" data
localStorage.getItem("localVar")
""Hello local"" // double quotes doubled

// Converting "raw" data resonse to "old way" response (if necessary)
JSON.parse(localStorage.getItem("localVar"))
"Hello local" // OK/pre
For more information please see
Storage API: http://devcenter.appery.io/documentat...
HTML5 Web Storage API: http://www.w3schools.com/html/html5_w...

Girish, please let us know if there are still some problems with app.

Girish Chhugani
Posts: 0
Joined: Thu Apr 17, 2014 10:18 pm

Login.execute gives error this morning

Thats amazing. U guys wrote a blog and posted it night before the update that everyone has to change their app. And I am not sure if you guys told everyone else that I they were supposed to read this blog and change their app and what they were supposed to change In this app but I certainly had no idea. Thank God my app is not in production. I feel very sorry for people who do. Next time u guys decide to change something in the system that's going to screw people over you should make sure they all get the memo and read it.

Return to “Issues”