!40 修复-1 month出现当月1号的问题

Merge pull request !40 from stranger/master
This commit is contained in:
Anyon 2023-06-01 03:03:56 +00:00 committed by Gitee
commit 58465920ee
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F

View File

@ -128,7 +128,7 @@ class Transfer extends Auth
'total' => [
'锁定' => $locks,
'可提' => $total - $count,
'上月' => DataUserTransfer::mk()->where($map)->whereLike('date', date("Y-m-%", strtotime('-1 month')))->sum('amount'),
'上月' => DataUserTransfer::mk()->where($map)->whereLike('date', date("Y-m-%", strtotime('last day of -1 month')))->sum('amount'),
'本月' => DataUserTransfer::mk()->where($map)->whereLike('date', date("Y-m-%"))->sum('amount'),
'全年' => DataUserTransfer::mk()->where($map)->whereLike('date', date("Y-%"))->sum('amount'),
],