Added new public method getJobsByTypeStatusInput to controller core/JQW_Controller

This commit is contained in:
Paolo
2020-07-22 17:10:11 +02:00
parent a9ba3f039f
commit 40766e7161
+13
View File
@@ -47,6 +47,19 @@ abstract class JQW_Controller extends JOB_Controller
return $jobs;
}
/**
* To get all the jobs specified by the given parameters
*/
protected function getJobsByTypeStatusInput($type, $status, $input)
{
$jobs = $this->jobsqueuelib->getJobsByTypeStatusInput($type, $status, $input);
// If an error occurred then log it in database
if (isError($jobs)) $this->logError(getError($jobs), array($type, $status, $input));
return $jobs;
}
/**
* Add new jobs in the jobs queue with the given type
* jobs is an array of job objects