You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jul 17, 2024. It is now read-only.
I'm working on a project. For this project we want to minimise data transfer between app/server.
We're implementing your offlineSyncStore for this reason.
I would like to know if it's possible to alter your code in a way so that if the server only sends new data, these new rows get added to the local store, instead of replacing them.
Now, when trying to accomplish this with the "loadServer" method, the local store items get removed if they're not present in the server call.
As you can imagine, this causes a lot of data transfer that isn't really necessary.
In an older version of the app we sent along the id's of the rows that were already synced, so only new rows were sent by the server. These rows were added to the local store. Sadly this wasn't a sencha project so i can't copy this.
The user can't make any changes on the device, so sync'ing the other way isn't necessary.
Any tips are appreciated!
The text was updated successfully, but these errors were encountered:
I'm not sure that I completely understand what you're doing but perhaps you could override the loadServer method to take a copy of the current records in localstorage, load the sencha store, then put the records back?
My goal was to minimize the amount of data transferred between app and server.
That's why i was wondering if there was a way to append data sent from the server to the local store instead of replacing the data.
By injecting a "last id" or something the server could only send new items and these should then be appended to the localstore.
I know appending is against the normal behaviour for sencha so i think this question is more a feature request.
For now i've created my own extended store that syncs with two proxies. Mine is way simpler because the user can't change data and no data needs to be sent to the server.
So This point can be closed i think. Maybe you can keep this idea in mind as a feature request (appending data to local store instead of replacing) for anybody else wanting to minimise data transfers.
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Hi Andrew,
I'm working on a project. For this project we want to minimise data transfer between app/server.
We're implementing your offlineSyncStore for this reason.
I would like to know if it's possible to alter your code in a way so that if the server only sends new data, these new rows get added to the local store, instead of replacing them.
Now, when trying to accomplish this with the "loadServer" method, the local store items get removed if they're not present in the server call.
As you can imagine, this causes a lot of data transfer that isn't really necessary.
In an older version of the app we sent along the id's of the rows that were already synced, so only new rows were sent by the server. These rows were added to the local store. Sadly this wasn't a sencha project so i can't copy this.
The user can't make any changes on the device, so sync'ing the other way isn't necessary.
Any tips are appreciated!
The text was updated successfully, but these errors were encountered: