Results 1 to 4 of 4

Thread: how to an app work offline and store data without authentication

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Sencha User kukuoc's Avatar
    Join Date
    May 2012
    Posts
    7
    Vote Rating
    0
      0  

    Default Answered: how to an app work offline and store data without authentication

    hi,

    I have an app called "TodoList" with follow functionalites:
    - Login/registration to sencha touch
    - Create new task and list todo tasks.

    I user senchaio to register (username/password/email) and login then...I can sync data in different devices with condition is the app has to have network available. If not, user that i registered earlier will not be able to login (authenticate) .....
    So please tell me how to store data without authenticate and login in offline. Then go online again, data can sync together.

    thanks a lot

  2. > But how can i authenticate user login without network online. User can only create new task if you login successful. Or when user registrations with sencha io, does local storage of sencha touch save user information?

    You can't authenticate a user when the device is offline. But, once the user has authenticated (and not logged out) the client remembers the user's identify. So yes it's in local storage.

    Also, you can create and use a sync store before the user has authenticated. It's only when the client connects and tries to sync the data store that we need the user to authenticate themselves.

    John

  3. #2
    Sencha User
    Join Date
    Apr 2010
    Posts
    107
    Answers
    30
    Vote Rating
    -1
      0  

    Default

    You can write to your local sync store even when you are offline. If the user is not authenticated then sync with the remote servers will not work, when the device is online and the user has authenticated themselves then it will work.

    John

  4. #3
    Sencha User kukuoc's Avatar
    Join Date
    May 2012
    Posts
    7
    Vote Rating
    0
      0  

    Default

    Thanks for your share.
    But how can i authenticate user login without network online. User can only create new task if you login successful. Or when user registrations with sencha io, does local storage of sencha touch save user information?
    I am so confused about that.

  5. #4
    Sencha User
    Join Date
    Apr 2010
    Posts
    107
    Answers
    30
    Vote Rating
    -1
      0  

    Default

    > But how can i authenticate user login without network online. User can only create new task if you login successful. Or when user registrations with sencha io, does local storage of sencha touch save user information?

    You can't authenticate a user when the device is offline. But, once the user has authenticated (and not logged out) the client remembers the user's identify. So yes it's in local storage.

    Also, you can create and use a sync store before the user has authenticated. It's only when the client connects and tries to sync the data store that we need the user to authenticate themselves.

    John

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •