fix(接口): 今日打卡记录 完善补卡显示逻辑

master
yin5th 2023-01-14 13:55:56 +08:00
parent 48c060ea08
commit b8ebcd8b5e
1 changed files with 12 additions and 9 deletions

View File

@ -377,8 +377,11 @@ class User extends Base
} }
$where = []; $where = [];
$where[] = ['cl.created_at', '>', date($day.' 00:00:00')]; // $where[] = ['cl.created_at', '>', date($day.' 00:00:00')];
$where[] = ['cl.created_at', '<', date($day.' 23:59:59')]; // $where[] = ['cl.created_at', '<', date($day.' 23:59:59')];
$dayInt = str_replace('-', '', $day);
$where[] = ['cl.day', '=', $dayInt];
$where[] = ['cl.account_id', '=', $accountId]; $where[] = ['cl.account_id', '=', $accountId];
if ($worksiteId) { if ($worksiteId) {
$where[] = ['cl.worksite_id', '=', $worksiteId]; $where[] = ['cl.worksite_id', '=', $worksiteId];