fat=ConfigModel::GetInstance()->get_configData_int(ConfigModel::CONFIGMODEL_ITEM_SPORTS_GOAL_DURATION);
calories=ConfigModel::GetInstance()->get_configData_int(ConfigModel::CONFIGMODEL_ITEM_SPORTS_GOAL_CALORIES);
stand=ConfigModel::GetInstance()->get_configData_int(ConfigModel::CONFIGMODEL_ITEM_SPORTS_GOAL_STANDUP_TIMES);
+
+ standdata_now=get_now_stand_count();
}
bool GoalModel::is_goal_stand_done()
{
- int standdata_now = get_now_stand_count();
+ int standdata_now_ = standdata_now+get_stand_falg();
int standdata_goal = stand;
- if(standdata_now>=standdata_goal)
+ if(standdata_now_>=standdata_goal)
return true;
else
return false;
char standnewstr[20];
char *GoalModel::getstandnew()
{
- int standdata = get_now_stand_count();
+ int standdata = standdata_now+get_stand_falg();
memset((void *)standnewstr, 0, 20);
sprintf_s(standnewstr, 20, "%d", standdata);
#include "main/include/PullUpDownView.h"
#include "player/include/PlayersModelC.h"
+#include "ui_service.h"
#define DIALDATASET 1
//#include "Systemupgrade.h"
namespace OHOS {
WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "保存每小时步数");
step_history_save();
WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "保存每小时站立数据");
+ if(get_stand_falg())
+ {
stand_history_save();
+ SendMsgToUIService(UI_UPDATE_GOAL, 0, nullptr, 0);
+ }
+
+
+
WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "保存每小时卡路里数据");
calories_history_save();
WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "保存每小时距离数据");