Open BenLaKnet opened 1 week ago
there may be a bug in the openHealthSettings, I'll need to check on an newish Android phone. If you see anything strange on logcat, please post it here
When Google Health Connect is not installed, I have this message (with Chrome: chrome://inspect/#devices):
No Activity found to handle Intent { act=androidx.health.ACTION_HEALTH_CONNECT_SETTINGS }
Maybe the Google Health service is ok, but no Intent is defined to show parameters.
Ok, I tried the pull request, it is running. I do that in my app:
function openHealthSettings() {
cordova.plugins.health.openHealthSettings(function () {
console.log("ok");
}, function (err) {
console.log(err);
openHealthInstall();
});
}
function openHealthInstall() {
if (cordova.platformId == "android") {
cordova.InAppBrowser.open("https://play.google.com/store/apps/details?id=com.google.android.apps.healthdata", '_system', 'location=yes');
}
else if (cordova.platformId == "ios") {
cordova.InAppBrowser.open("https://apps.apple.com/app/apple-health/id1242545199", '_system', 'location=yes');
}
}
Hi @dariosalvi78, Have you published new version of source code? I do not see changes.
Hi,
Strange thing with this phone or Android version.
Google Health is a system service, but when I tried to use
"openHealthSettings()"
, it does not work.isAvailable
returns true, but nothing to do withopenHealthSettings()
.I installed cordova-android 13.
When I installed manually "Google Health Connect", all is running...