@@ -31,9 +31,11 @@ |
||
31 | 31 | $group = Group::findOrFail($groupId); |
32 | 32 | $this->authorize($group); |
33 | 33 | $meetings = $group->meetings(); |
34 | - if ($request->query('current')) |
|
35 | - $meetings->where(function ($query) { //parenthesis for conditions ...(C1 OR C2)... |
|
36 | - $query->where('start_time', '=', NULL);//to be planned |
|
34 | + if ($request->query('current')) { |
|
35 | + $meetings->where(function ($query) { //parenthesis for conditions ...(C1 OR C2)... |
|
36 | + $query->where('start_time', '=', NULL); |
|
37 | + } |
|
38 | + //to be planned |
|
37 | 39 | //datetime to consider timezone, don't use mysql NOW() |
38 | 40 | $query->orWhere('start_time', '>=', new \DateTime());//planned |
39 | 41 | }); |