Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
snipe committed Feb 15, 2024
2 parents 81b9753 + d8b1eec commit d6159d8
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion app/Http/Controllers/Api/ReportsController.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,12 @@ public function index(Request $request)

if (($request->filled('item_type')) && ($request->filled('item_id'))) {
$actionlogs = $actionlogs->where('item_id', '=', $request->input('item_id'))
->where('item_type', '=', 'App\\Models\\'.ucwords($request->input('item_type')));
->where('item_type', '=', 'App\\Models\\'.ucwords($request->input('item_type')))
->orWhere(function($query) use ($request)
{
$query->where('target_id', '=', $request->input('item_id'))
->where('target_type', '=', 'App\\Models\\'.ucwords($request->input('item_type')));
});
}

if ($request->filled('action_type')) {
Expand Down

0 comments on commit d6159d8

Please sign in to comment.