Resolve "Final CMB Fixes" #1229

Merged
korina.cordero merged 102 commits from 270-final-cmb-fixes into master 2020-04-03 02:54:29 +00:00
Showing only changes of commit bf535e37f5 - Show all commits

View file

@ -320,7 +320,18 @@ class Rider
{
// check if we have set a custom active
if ($this->active_job_order != null)
return $this->active_job_order;
{
switch ($this->active_job_order->getStatus())
{
// if jo is open, return it
case JOStatus::ASSIGNED:
case JOStatus::IN_TRANSIT:
case JOStatus::IN_PROGRESS:
return $this->active_job_order;
}
// if active jo is not open, get the next open one
}
// no custom active job order
$active_status = [