mirror of
https://github.com/silverstripe/silverstripe-contentreview
synced 2024-10-22 17:05:47 +02:00
FIX Import QueuedJobService namespace in job classes
This commit is contained in:
parent
de6ca323e0
commit
cc7763afa4
@ -39,6 +39,7 @@ use SilverStripe\Security\Security;
|
||||
use SilverStripe\SiteConfig\SiteConfig;
|
||||
use SilverStripe\View\Requirements;
|
||||
use Symbiote\QueuedJobs\DataObjects\QueuedJobDescriptor;
|
||||
use Symbiote\QueuedJobs\Services\QueuedJobService;
|
||||
|
||||
/**
|
||||
* Set dates at which content needs to be reviewed and provide a report and emails to alert
|
||||
@ -642,7 +643,7 @@ class SiteTreeContentReview extends DataExtension implements PermissionProvider
|
||||
$runHour = Config::inst()->get(ContentReviewNotificationJob::class, "first_run_hour");
|
||||
$firstRunTime = date("Y-m-d H:i:s", mktime($runHour, 0, 0, date("m"), date("d") + 1, date("y")));
|
||||
|
||||
singleton("QueuedJobService")->queueJob(
|
||||
singleton(QueuedJobService::class)->queueJob(
|
||||
$nextRun,
|
||||
$firstRunTime
|
||||
);
|
||||
|
@ -7,6 +7,7 @@ use SilverStripe\Control\HTTPRequest;
|
||||
use SilverStripe\Core\Config\Config;
|
||||
use Symbiote\QueuedJobs\Services\AbstractQueuedJob;
|
||||
use Symbiote\QueuedJobs\Services\QueuedJob;
|
||||
use Symbiote\QueuedJobs\Services\QueuedJobService;
|
||||
|
||||
if (!class_exists(AbstractQueuedJob::class)) {
|
||||
return;
|
||||
@ -106,7 +107,7 @@ class ContentReviewNotificationJob extends AbstractQueuedJob implements QueuedJo
|
||||
date("Y")
|
||||
);
|
||||
|
||||
singleton("QueuedJobService")->queueJob(
|
||||
singleton(QueuedJobService::class)->queueJob(
|
||||
$nextRun,
|
||||
date("Y-m-d H:i:s", $nextRunTime)
|
||||
);
|
||||
|
Loading…
Reference in New Issue
Block a user