|
...
|
...
|
@@ -8,6 +8,7 @@ import 'package:intl/date_symbol_data_local.dart'; |
|
|
|
|
|
|
|
import 'app/bootstrap/app_bootstrap.dart';
|
|
|
|
import 'app/double_feel_app.dart';
|
|
|
|
import 'core/config/app_environment_config.dart';
|
|
|
|
import 'core/services/raw_data_service/health_raw_data_core_service.dart';
|
|
|
|
import 'core/services/raw_data_service/health_raw_models.dart';
|
|
|
|
import 'core/theme/app_theme.dart';
|
|
...
|
...
|
@@ -138,6 +139,9 @@ Future<void> _runPendingHealthTasks( |
|
|
|
Future<void> _recordTemporaryHealthTaskReceived(
|
|
|
|
List<_BackgroundHealthTask> tasks,
|
|
|
|
) async {
|
|
|
|
if (!_isHealthPipelineDebugEnabled) {
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
try {
|
|
|
|
await HealthKitRawDataHostApi().saveLocalNotificationDebugEvent(
|
|
|
|
event: <String, Object?>{
|
|
...
|
...
|
@@ -162,6 +166,9 @@ bool _hasNewHealthCalculationResult(HealthRawStressCalculationResult result) { |
|
|
|
}
|
|
|
|
|
|
|
|
Future<void> _healthBackgroundLog(MethodChannel channel, String message) async {
|
|
|
|
if (!_isHealthPipelineDebugEnabled) {
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
try {
|
|
|
|
await channel.invokeMethod('healthBackgroundLog', {
|
|
|
|
'message': message,
|
|
...
|
...
|
@@ -170,6 +177,13 @@ Future<void> _healthBackgroundLog(MethodChannel channel, String message) async { |
|
|
|
} catch (_) {}
|
|
|
|
}
|
|
|
|
|
|
|
|
bool get _isHealthPipelineDebugEnabled {
|
|
|
|
if (!Get.isRegistered<AppEnvironmentConfig>()) {
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
return Get.find<AppEnvironmentConfig>().isDebug;
|
|
|
|
}
|
|
|
|
|
|
|
|
List<_BackgroundHealthTask> _backgroundHealthTasksFromArguments(
|
|
|
|
Object? arguments,
|
|
|
|
) {
|
...
|
...
|
|