mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-02-25 18:45:27 -06:00
Fixed a bug in relevantOnDate
This commit is contained in:
parent
fa3f18b60f
commit
6bbaf1523c
@ -37,13 +37,13 @@ class PiggyBankRepetition extends Model
|
||||
{
|
||||
return $query->where(
|
||||
function($q) use ($date) {
|
||||
$q->where('startdate', '>=', $date->format('Y-m-d 00:00:00'));
|
||||
$q->where('startdate', '<=', $date->format('Y-m-d 00:00:00'));
|
||||
$q->orWhereNull('startdate');
|
||||
})
|
||||
|
||||
->where(function($q) use ($date) {
|
||||
|
||||
$q->where('targetdate', '<=', $date->format('Y-m-d 00:00:00'));
|
||||
$q->where('targetdate', '>=', $date->format('Y-m-d 00:00:00'));
|
||||
$q->orWhereNull('targetdate');
|
||||
});
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user