-
Notifications
You must be signed in to change notification settings - Fork 209
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
iOs - Settings seems to get stored and fetched properly in app but not in system preferences. #93
Comments
After digging some more, I found that my preferences are not stored in the system preferences, but in local storage. In if (platform.nativeStore) {
return platform.nativeStore (resolve, reject, args);
}
return platform.nativeExec (resolve, reject, "AppPreferences", "store", [args]);
Is there a reason for that behavior @apla ? In my opinion the whole point of this plugin is to save the preferences in the system. So that's what it should try first and then maybe fallback to local storage if system preferences aren't available. |
@ldanet I noticed similar behavior and filed an issue against my project (e-mission/e-mission-data-collection#88) to investigate further. For me, it is less of an issue to see the preferences in the system preferences, and more that I want to use the value of the preference in native code. @apla, is there a config option possible, maybe |
This is completely wrong behavior. I've added test case and removed possible regression. You can try commit 80f060f, seems like it works, but I still working on some features and master can be unstable. |
@apla, I will test this next week and update the issue. I see that the commit adds a new test case, but doesn't appear to fix any existing behavior. Did you actually fix the code? Did the tests pass or fail? |
Regression introduced with pull request and I've fixed it with 2a2a6a2. LocalStorage fallback must be installed only for platforms where it is really needed. For platforms with native part this fallback is not needed. |
I'm seeing the same problem with the current build. I've verified that my plugin.xml looks like the one in 2a2a6a2 above. Everything in the app-settings.json gets set correctly, but all settings that I set dynamically from the app only seem to go to localStorage. I can set and fetch them, but they do NOT show up in the simulator's 'Settings' app. (Where I do see the results from app-settings.json) Is there a way to force the system settings rather than localStorage? |
@ldanet @jmargolese @shankari - hi all, hope you all are doing well. I was wondering if this fix got anywhere after the last comment on 12th of May 2017? |
@prashu2705 I ended up moving on from app preferences and just storing the preferences in an SQLite database. So the user can't use |
Thanks for quick response @shankari . Unfortunately for me I have to use settings.app. I will try and figure out if there's any other lib available or probably try updating this library. Thanks. |
Hi All, |
Hello,
When I store a value, the preferences I see in iOs' Settings app don't change, and when I try to change them in the Settings app, it does not affect the stored value. When I fetch a value I always get the one stored previously from inside my own app. It behaves like my preferences are actually stored somewhere, but not where the Settings app looks for it or saves changes to.
I'm using iOs 9.3.2.
This is my app-settings.json file:
And this is the code I use:
Is there something I am missing?
The text was updated successfully, but these errors were encountered: