Browse Source

fix when checkLocation when mobile do presence

pull/3/head
ardhi 2 years ago
parent
commit
6e92aab7c7
  1. 4
      app/Http/Controllers/PresenceController.php

4
app/Http/Controllers/PresenceController.php

@ -116,6 +116,7 @@ class PresenceController extends Controller
->whereDate("ma.end_date", ">=", $params->clock_time) ->whereDate("ma.end_date", ">=", $params->clock_time)
->get(); ->get();
$temp = []; $temp = [];
if (count($geom) > 0) {
foreach($geom as $dataGeom){ foreach($geom as $dataGeom){
$valGeom = json_decode($dataGeom->geom); $valGeom = json_decode($dataGeom->geom);
if($params->type=="out"){ if($params->type=="out"){
@ -131,8 +132,7 @@ class PresenceController extends Controller
); );
} }
} }
}
} }
return $temp; return $temp;
} }

Loading…
Cancel
Save