作者 王智

xiugao

... ... @@ -367,9 +367,9 @@ class Question extends Api
$List = Db::name('sleep')->where('user_id', $UserId)->where('type', 1)->where($map)->select();
foreach ($List as $key => $value) {
$DayArray[$k][$key]['date'] = date('Y-m-d', $value['createtime']);
$DayArray[$k][$key]['V'] = $value['v'];
$DayArray[$k][$key]['P'] = $value['p'];
$DayArray[$k][$key]['K'] = $value['k'];
$DayArray[$k][$key]['V'] = $value['current_wind'];
$DayArray[$k][$key]['P'] = $value['current_fire'];
$DayArray[$k][$key]['K'] = $value['current_water'];
}
}
foreach ($DayArray as $k => $v) {
... ... @@ -387,9 +387,9 @@ class Question extends Api
$List = Db::name('sleep')->where('user_id', $UserId)->where('type', 1)->where($map)->select();
foreach ($List as $key => $value) {
$MonthArray[$k][$key]['date'] = date('Y-m', $value['createtime']);
$MonthArray[$k][$key]['V'] = $value['v'];
$MonthArray[$k][$key]['P'] = $value['p'];
$MonthArray[$k][$key]['K'] = $value['k'];
$MonthArray[$k][$key]['V'] = $value['current_wind'];
$MonthArray[$k][$key]['P'] = $value['current_fire'];
$MonthArray[$k][$key]['K'] = $value['current_water'];
}
}
foreach ($MonthArray as $k => $v) {
... ...