Skip to content

Commit

Permalink
fix(modifier): consider null activities
Browse files Browse the repository at this point in the history
  • Loading branch information
KennethTrecy committed May 26, 2024
1 parent 38496f4 commit 691b863
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions app/Models/ModifierModel.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,13 @@ public function limitSearchToUser(BaseResourceModel $query_builder, User $user)
return $query_builder
->whereIn("debit_account_id", $account_subquery)
->whereIn("credit_account_id", $account_subquery)
->whereIn("debit_cash_flow_activity_id", $cash_flow_activity_subquery)
->whereIn("credit_cash_flow_activity_id", $cash_flow_activity_subquery);
->groupStart()
->whereIn("debit_cash_flow_activity_id", $cash_flow_activity_subquery)
->orWhere("debit_cash_flow_activity_id IS NULL")
->groupEnd()
->groupStart()
->whereIn("credit_cash_flow_activity_id", $cash_flow_activity_subquery)
->orWhere("credit_cash_flow_activity_id IS NULL")
->groupEnd();
}
}

0 comments on commit 691b863

Please sign in to comment.