Commit 3bde5fcdd5b3ac32adbbf3a0e09895301dcbd889

Authored by 常守达
1 parent d16f2b12

fix(today):上传去掉loading

... ... @@ -257,14 +257,14 @@ class TodayController extends GetMaterialController {
bool success = await _hostApi.requestHealthClientAuthorization();
AppLogger.d("requestHealthClientAuthorization : $success");
if (success) {
await LoadingService.instance.run(() async {
try {
final result = await _hostApi.performHealthUpload();
} catch (error, stackTrace) {
AppLogger.e('Apple Health upload failed', error, stackTrace);
}
});
result.status = 1;
// await LoadingService.instance.run(() async {
try {
final result = _hostApi.performHealthUpload();
} catch (error, stackTrace) {
AppLogger.e('Apple Health upload failed', error, stackTrace);
}
// });
// result.status = 1;
// AppToast.show('刷新完成');
if (isFromNoPermissionPage) {
Get.back();
... ... @@ -276,13 +276,13 @@ class TodayController extends GetMaterialController {
}
return;
} else if (result.status == 1) {
await LoadingService.instance.run(() async {
try {
final result = await _hostApi.performHealthUpload();
} catch (error, stackTrace) {
AppLogger.e('Apple Health upload failed', error, stackTrace);
}
});
// await LoadingService.instance.run(() async {
try {
final result = _hostApi.performHealthUpload();
} catch (error, stackTrace) {
AppLogger.e('Apple Health upload failed', error, stackTrace);
}
// });
if (isFromNoPermissionPage) {
Get.back();
}
... ...
... ... @@ -105,7 +105,7 @@
"phoneLoginCodeSentSuccess": "Code sent",
"phoneLoginInvalidCode": "Invalid verification code",
"todayHealthDataAuthTitle": "Unable to access heart rate health data",
"todayHealthDataAuthDescription": "DoubleFeel needs permission to access your health data to provide stress reminders, real-time stress statistics, and health suggestions. Otherwise, some app features may not work properly. Your health data is stored locally only and will not be uploaded to any server.",
"todayHealthDataAuthDescription": "DoubleFeel needs access to your Apple Health data to provide stress reminders, real-time stress statistics, and health suggestions.\nIf you have not authorized it yet, please click below to complete the authorization; if you have authorized it, it may take a few minutes to sync a large amount of health data for the first time, please try again later.",
"todayHealthDataAuthAction": "Authorize health data access",
"measureYourHrvNow": "Measure your HRV now",
"todayBottomSheetGotIt": "Got it",
... ...
... ... @@ -182,7 +182,7 @@
"@todayHealthDataAuthTitle": {
"description": "今日页健康数据授权卡片标题"
},
"todayHealthDataAuthDescription": "DoubleFeel 需要授权访问你的健康数据,才能提供压力提醒、实时压力统计和健康建议;否则应用功能可能无法正常使用。请放心,你的健康数据仅存储在本地,不会上传到任何服务器。",
"todayHealthDataAuthDescription": "DoubleFeel 需要访问你的 Apple 健康数据,以提供压力提醒、实时压力统计和健康建议。\n如果尚未授权,请点击下方完成授权;如果已经授权,首次同步大量健康数据可能需要等待几分钟,请稍后再试。",
"@todayHealthDataAuthDescription": {
"description": "今日页健康数据授权卡片说明"
},
... ...
... ... @@ -732,7 +732,7 @@ abstract class AppLocalizations {
/// 今日页健康数据授权卡片说明
///
/// In zh, this message translates to:
/// **'DoubleFeel 需要授权访问你的健康数据,才能提供压力提醒、实时压力统计和健康建议;否则应用功能可能无法正常使用。请放心,你的健康数据仅存储在本地,不会上传到任何服务器。'**
/// **'DoubleFeel 需要访问你的 Apple 健康数据,以提供压力提醒、实时压力统计和健康建议。\n如果尚未授权,请点击下方完成授权;如果已经授权,首次同步大量健康数据可能需要等待几分钟,请稍后再试。'**
String get todayHealthDataAuthDescription;
/// 今日页健康数据授权卡片按钮文案
... ...
... ... @@ -351,7 +351,7 @@ class AppLocalizationsEn extends AppLocalizations {
@override
String get todayHealthDataAuthDescription =>
'DoubleFeel needs permission to access your health data to provide stress reminders, real-time stress statistics, and health suggestions. Otherwise, some app features may not work properly. Your health data is stored locally only and will not be uploaded to any server.';
'DoubleFeel needs access to your Apple Health data to provide stress reminders, real-time stress statistics, and health suggestions.\nIf you have not authorized it yet, please click below to complete the authorization; if you have authorized it, it may take a few minutes to sync a large amount of health data for the first time, please try again later.';
@override
String get todayHealthDataAuthAction => 'Authorize health data access';
... ...
... ... @@ -334,7 +334,7 @@ class AppLocalizationsZh extends AppLocalizations {
@override
String get todayHealthDataAuthDescription =>
'DoubleFeel 需要授权访问你的健康数据,才能提供压力提醒、实时压力统计和健康建议;否则应用功能可能无法正常使用。请放心,你的健康数据仅存储在本地,不会上传到任何服务器。';
'DoubleFeel 需要访问你的 Apple 健康数据,以提供压力提醒、实时压力统计和健康建议。\n如果尚未授权,请点击下方完成授权;如果已经授权,首次同步大量健康数据可能需要等待几分钟,请稍后再试。';
@override
String get todayHealthDataAuthAction => '授权访问健康数据';
... ...