user2415476
user2415476

Reputation: 221

Azure-mobile-apps-net-client just patch changes

I use Xamarin Forms with azure-mobile-apps-net-client with the .net backend. What I noticed is, that if I change a value in my mobile app for my model like

var dog = get_dog_from_sqlite_database();
dog.Color = "black";

and call

await dogTable.UpdateAsync(dog);

and then sync with the server, the Delta<Dog> patch object in the public Task<Dog> PatchDog(string id, Delta<Dog> patch) method in the backend, contains every property from my dog model, although changing just one value.

Is it possible to change some settings, that just changed values are patched to the backend? I ask, as I have to do some restrictions on who can change what values, so my backend code would be cleaner as I just have to look if a forbidden property was changed and then throw an exception.

Upvotes: 0

Views: 53

Answers (1)

Adrian Hall
Adrian Hall

Reputation: 8035

No - when we do offline sync, we don't necessarily know which fields have changed - we don't keep that granular information. We just keep the new record. You can check out the operations queue in the SQLite database to confirm this.

Upvotes: 1

Related Questions