Draft: Resolve "Update capi calls for warranty" #1565

Closed
jankstudio wants to merge 77 commits from 642-update-capi-calls-for-warranty into master
Showing only changes of commit d812e34797 - Show all commits

View file

@ -306,7 +306,7 @@ class HubSelector
protected function getClosestHubsWithTime(Point $point, $limit_results, $limit_distance, $date_time)
{
// get closest hubs that are open at the given time based on st_distance function from db
$query = $this->em->createQuery('SELECT h, st_distance(h.coordinates, point(:lng, :lat)) as dist FROM App\Entity\Hub h' . ($time ? ' WHERE :time BETWEEN h.time_open AND h.time_close' : '') . ' ORDER BY dist')
$query = $this->em->createQuery('SELECT h, st_distance(h.coordinates, point(:lng, :lat)) as dist FROM App\Entity\Hub h' . ($time ? ' WHERE :time BETWEEN h.time_open AND h.time_close' : '') . ' ORDER BY dist');
$query = $this->em->createQuery($query_string)
->setParameter('lat', $point->getLatitude())