!302 设置24小时时间设置不生效

Merge pull request !302 from fangzheng24/master
This commit is contained in:
openharmony_ci 2022-11-18 13:47:21 +00:00 committed by Gitee
commit 9f6cd20356
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F

View File

@ -100,11 +100,9 @@ export class DateAndTimeModel extends BaseModel {
}
LogUtil.info(ConfigData.TAG + 'DateAndTimeModel i18n set24HourClock ' + JSON.stringify(ret24HourClock));
let ret = settings.setValueSync(globalThis.settingsAbilityContext, ConfigData.TIME_FORMAT_KEY, format);
if (ret === true) {
this.timeFormat = format;
}
return ret;
settings.setValueSync(globalThis.settingsAbilityContext, ConfigData.TIME_FORMAT_KEY, format);
this.timeFormat = format;
return true;
}
/**