作者 lyh

gx

... ... @@ -81,7 +81,7 @@ class WeekProject extends Command
$endOfLastWeekFormatted = date('Y-m-d', $endOfLastWeek);
$countModel = new Count();
$startOfLastWeekFormattedInfo = $countModel->read(['date'=>$startOfLastWeekFormatted,'project_id'=>$value['id']],['inquiry_num','country']);
$endOfLastWeekFormattedInfo = $countModel->read(['date'=>$endOfLastWeekFormatted,'project_id'=>$value['id']],['inquiry_num']);
$endOfLastWeekFormattedInfo = $countModel->read(['date'=>$endOfLastWeekFormatted,'project_id'=>$value['id']],['inquiry_num','country']);
$data['inquiry_total'] = $endOfLastWeekFormattedInfo['inquiry_num'] ?? 0;//询盘数量
$data['inquiry_country'] = $endOfLastWeekFormattedInfo['country'] ?? json_encode([]);
$data['week_inquiry_total'] = ($endOfLastWeekFormattedInfo['inquiry_num'] ?? 0) - ($startOfLastWeekFormattedInfo['inquiry_num'] ?? 0);
... ...