window.plugins.healthkit.saveWorkout(
{
'activityType': 'HKWorkoutActivityTypeFishing',
'quantityType': 'HKWorkoutTypeIdentifier',
'requestReadPermission' : true, // set this if you don't need to read workouts as well
'startDate': new Date(), // mandatory
'endDate': null, // optional, use either this or duration
'duration': 60 * 60 // in seconds, optional, use either this or endDate
},
onSuccess,
onError
);
Still requests the Active Calories data permission. I'm guessing it has to do with the code around line 162 of HealthKit.m:
Removing the "quantityTypeForIdentifier:HKQuantityTypeIdentifierActiveEnergyBurned" from that list works, but I know it will need to be optionally added back when people do use that value.
Entering an activity like this:
Still requests the Active Calories data permission. I'm guessing it has to do with the code around line 162 of HealthKit.m:
Removing the "quantityTypeForIdentifier:HKQuantityTypeIdentifierActiveEnergyBurned" from that list works, but I know it will need to be optionally added back when people do use that value.