Resolve "Auto-assign hub and rider" #1231

Merged
korina.cordero merged 22 commits from 374-auto-assign-hub-and-rider into master 2020-04-15 03:34:58 +00:00
Showing only changes of commit 51ad36b272 - Show all commits

View file

@ -995,7 +995,7 @@ class APIController extends Controller implements LoggedController
}
else
{
$nearest_hub = $this->findNearestHub($jo, $em, $map_tools, $im);
$nearest_hub = $this->findNearestHub($jo, $em, $map_tools);
}
if (!empty($nearest_hub))
@ -2258,8 +2258,8 @@ class APIController extends Controller implements LoggedController
return $cust;
}
protected function findNearestHub($jo, Battery $batt, EntityManagerInterface $em,
MapTools $map_tools, InventoryManager $im)
protected function findNearestHub($jo, EntityManagerInterface $em,
MapTools $map_tools)
{
// get the nearest 10 hubs
$selected_hub = null;